VoiceStatistics

Get your Inbound Calls statistics data

Fetch Inbound Calls statistics based on CDRs, filtrated by given parameters. Statistics accumulates calls and groups them based on given grouping parameters, collecting statistics data for time periods, destination numbers and/or countries. Statistics are gathered once an hour. By default, grouping is done by date. Returns data with pagination. For Inbound Calls statistics, time period parameters filter by start_time field of the call, not by statistics date itself, so it can be used with other groupings.

GET
/api/v1/voice/statistics/inbound

Query Parameters

country_code?array<string>

Optional filter. Restricts statistics to selected destination country codes. Accepts a list of ISO alpha-2 country codes in upper case.

dids?array<string>

Optional filter. Restricts statistics to selected DID numbers. Only statistics related to the provided DID numbers will be returned.

group_by?array<>

Defines grouping dimensions: date — groups statistics by time intervals; country — groups statistics by country codes; did — groups statistics by destination DID numbers. If provided an empty list, by default the time grouping will be used.

interval?string

Defines aggregation granularity. If time grouping is selected, and no value is provided for interval, by default the day interval will be used.

Value in"hour" | "day" | "week" | "month"
page?integer

Pagination parameters. Accepts page number. Pagination starts on page=1. If parameter is not provided, the default value of 1 will be set.

page_size?integer

Pagination parameter. Accepts the size of page for pagination. Minimal page size is 1. If parameter is not provided, the default value of 10 will be set.

period_end?string

Time period filter, determines the end of the period. Accepts string with time either as UNIX timestamp, or in format 2006-01-02T15:04:05Z07:00.

period_start?string

Time period filter, determines the start of the period. Accepts string with time either as UNIX timestamp, or in format 2006-01-02T15:04:05Z07:00.

sort_by?string

Ordering parameter. Defines by which field the data will be sorted. If parameter is not provided, will be used entity's default ordering. To use entity's default sorting, pass _default as value.

Value in"did" | "country_code" | "date" | "total_count" | "billable_count" | "total_duration" | "total_cost" | "acd" | "asr" | "country_code,date" | "date,country_code"
sort_order?string

Ordering parameter. Defines the order of sorting (asc or desc). If parameter is not provided, will be used entity's default ordering.

Value in"asc" | "desc"

Header Parameters

Authorization*string

Your API token

Response Body

application/json

application/json

application/json

application/json

curl -X GET "https://dev-refactor-api-e.voipenv.uk/api/v1/voice/statistics/inbound" \  -H "Authorization: string"
{
  "data": [
    {
      "acd": 0,
      "asr": 0,
      "billable_count": 0,
      "country_code": "string",
      "date": "string",
      "did": "string",
      "total_cost": 0,
      "total_count": 0,
      "total_duration": 0
    }
  ],
  "page": 0,
  "page_size": 0,
  "total": 0,
  "total_pages": 0
}
{
  "code": 0,
  "error_details": {
    "property1": [
      "string"
    ],
    "property2": [
      "string"
    ]
  },
  "message": "string",
  "request_id": "string",
  "status": "error"
}
{
  "code": 0,
  "error_details": {
    "property1": [
      "string"
    ],
    "property2": [
      "string"
    ]
  },
  "message": "string",
  "request_id": "string",
  "status": "error"
}
{
  "code": 0,
  "error_details": {
    "property1": [
      "string"
    ],
    "property2": [
      "string"
    ]
  },
  "message": "string",
  "request_id": "string",
  "status": "error"
}
Form Call To Action

Contact us

You can always send us a message or email. Weʼd be happy to help you out.