sessions

Get phone session metrics

Changed on

Returns your organization's ended phone sessions over a window as points: one per hour or day in time_zone (and per group with group_by), each with the sessions, their phone time in seconds and what it cost. A session counts in the bucket it was billed in, as it ended, dedicated phones' at no cost; sessions still going are not counted. The window defaults to the last 7 days and may start at most a year back; hour buckets need a window of 7 days or less.

get/sessions/metrics

Request

Query parameters

period_start_atstring date-time

Start of the window (RFC 3339). Defaults to 7 days before period_end_at, and may be at most a year before now.

period_end_atstring date-time

End of the window (RFC 3339). Defaults to now, and a later time is read as now.

granularity'hour' | 'day'

Bucket size: hour or day. hour is allowed for windows of 7 days or less.

time_zonestring

IANA time zone the buckets follow, such as America/Los_Angeles: a day starts at local midnight and an hour on the local hour. An unknown name is an error.

group_by'allocated_by' | 'device_class' | 'platform'

Split each bucket by allocated_by, device_class or platform. Omit for one point per bucket.

Response

OK

$schemastring uri

A URL to the JSON Schema for this object.

Example response

{
  "$schema": "/api/v1/PhoneSessionMetricsResponse.json"
}

Changes