Query viewership metrics
Changed onRequires a private (non-CORS) API key to be used.
Request
- Base URLhttps://livepeer.studio/api
- URLhttps://livepeer.studio/api/data/views/query
- AuthHTTP bearer
Query parameters
The playback ID to filter the query results. This can be a canonical playback ID from Livepeer assets or streams, or dStorage identifiers for assets
Start timestamp for the query range (inclusive)
End timestamp for the query range (exclusive)
The time step to aggregate viewership metrics by
The asset ID to filter metrics for
The stream ID to filter metrics for
The creator ID to filter the query results
The list of fields to break down the query results. Specify this query-string multiple times to break down by multiple fields.
Response
A list of Metric objects
Example response
[
{
"playbackId": "1bde4o2i6xycudoy",
"creatorId": "john@doe.com",
"viewerId": "1bde4o2i6xycudoy",
"dStorageUrl": "ipfs://QmZ4",
"timestamp": 1587667174725,
"device": "iPhone",
"deviceType": "mobile",
"cpu": "ARM",
"os": "iOS",
"browser": "Safari",
"browserEngine": "WebKit",
"continent": "North America",
"country": "United States",
"subdivision": "California",
"timezone": "America/Los_Angeles",
"viewCount": 100,
"playtimeMins": 10,
"ttffMs": 100,
"rebufferRatio": 0.1,
"errorRate": 0.1,
"exitsBeforeStart": 0.5
}
]Changes
- breaking
the response property
became optional for the status
- breaking
- warning
removed the optional property
/from the response with the status - info
api operation id
getViewershipMetricswas added - info
api tag
metricsadded - info
added the optional property
/to the response with the status
- warning