Reports API

The Vonage Business Communications Reports API enables you to retrieve call logs for your account.

Your application must subscribe to the Reports API suite to use this API.

Télécharger la spécification OpenAPI

Retrieve call logs for your account

Retrieve call logs for your account

gethttps://api.vonage.com/t/vbc.prod/reports/accounts/:account_id/call-logs

Authentification

CléDescriptionExemple
Authorization

Votre jeton OAuth.
En savoir plus sur les jetons OAuth

Headers

Bearer <access_token>

Trajectoire Paramètres

account_id
string
Exigée

The Vonage Business Communications account ID

Demande de renseignements Paramètres

start:gte
string

Filter records by start date (greater equal or equal to) [yyyy-MM-dd HH:mm:ss in UTC]

start:lte
string

Filter records by start date (less equal or equal to) [yyyy-MM-dd HH:mm:ss in UTC]

end:gte
string

Filter records by end date (greater equal or equal to) [yyyy-MM-dd HH:mm:ss in UTC]

end:lte
string

Filter records by end date (less equal or equal to) [yyyy-MM-dd HH:mm:ss in UTC]

page_size
number
Défaut10

Number of records per page

page
number
Défaut1

Current page number

to
string

Filter by called number

from
string

Filter by source number

source_user
string

Filter by source user

destination_user
string

Filter by destination user

direction
string

Filter by call direction.

Il doit s'agir de l'un d'entre eux :InboundOutbound

Réponses
Type de contenu
application/json

Success

page_size
number
exemple10

Number of records per page

page
number
exemple1

Current page number

total_pages
number
exemple10

Total number of pages

total_items
number
exemple100

Total number of records

_links
object
first
object

URL to the first page of records

href
string
prev
object

URL to the previous page of records

href
string
self
object

URL to the current page of records

href
string
next
object

URL to the next page of records

href
string
_embedded
object
call_logs
array
id
string
exemplef27b937d-6dde-441a-9595-006e7302eac1

Unique identifier of the call

in_network
boolean
exempletrue

Indicates if call was on/off network

international
boolean

Indicates if call was international

from
string
exemple17325550100

Source number of the call

to
string
exemple17325550100

Destination number of the call

direction
string
exempleInbound

Direction of the call

length
number
exemple60

Duration of the call in seconds

start
string
exemple2019-01-01 00:00:00

Start time of the call

end
string
exemple2019-01-01 00:00:00

End time of the call

charge
number

Amount charged for the call

rate
number

Rate charged for the call

destination_device_name
string
exempleSmith

Name of the destination device of the call

destination_user_full_name
string
exempleJohn Smith

Full name of the destination user of the call

destination_user
string
exempleJSmith

Destination user of the call

destination_sip_id
string
exempleVH1111111

SIP ID of the destination device of the call

destination_extension
number
exemple1000

Destination extension of the call

source_device_name
string
exempleSmith

Name of the source device of the call

source_user_full_name
string
exempleJohn Smith

Full name of the source user of the call

source_user
string
exempleJSmith

Source user of the call

custom_tag
string
exempleSales

Custom tag added to caller id

source_sip_id
string
exempleVH1111111

SIP ID of the source device of the call

source_extension
number
exemple1000

Source extension of the call

result
string
exempleAnswered

Result of the call

recorded
boolean
exempletrue

Indicates if call was recorded

Exemple Réponse

{
   "page_size": 10,
   "page": 1,
   "total_pages": 10,
   "total_items": 100,
   "_links": {
      "first": {
         "href": "string"
      },
      "prev": {
         "href": "string"
      },
      "self": {
         "href": "string"
      },
      "next": {
         "href": "string"
      }
   },
   "_embedded": {
      "call_logs": [
         {
            "id": "f27b937d-6dde-441a-9595-006e7302eac1",
            "in_network": true,
            "international": false,
            "from": 17325550100,
            "to": 17325550100,
            "direction": "Inbound",
            "length": 60,
            "start": "2019-01-01 00:00:00",
            "end": "2019-01-01 00:00:00",
            "charge": 0,
            "rate": 0,
            "destination_device_name": "Smith",
            "destination_user_full_name": "John Smith",
            "destination_user": "JSmith",
            "destination_sip_id": "VH1111111",
            "destination_extension": 1000,
            "source_device_name": "Smith",
            "source_user_full_name": "John Smith",
            "source_user": "JSmith",
            "custom_tag": "Sales",
            "source_sip_id": "VH1111111",
            "source_extension": 1000,
            "result": "Answered",
            "recorded": true
         }
      ]
   }
}