Record Offline Views
watch.stream.session.record_offline_views
Reports how many times a downloaded title was watched offline, so the views count against the screener's allowance once the device is back online.
Headers
| Header | Value |
|---|---|
| Authorization | Bearer api_key |
| ClientID | platform-\<id>-app_version-\<id> |
The ClientID header is required. It must have four hyphen-separated components, and the first component must be one of web, roku, firestick, fireos, appletv, ipad, tizen.
Endpoint
POST v2/watch/stream/{screener_key}/offline-views
Request Body
{
"views_consumed": 2
}
| Parameter | Type | Requirement | Description |
|---|---|---|---|
views_consumed |
Integer | Required | Number of offline views to record. Must be at least 1. |
Response Body
The updated title is returned, in the same shape as the screener room video APIs, so the client can refresh its view allowance without a second call.
{
"key": "vid-01j1pagnn41xv3hwg8v3sqbmxx",
"name": "ABC",
"screening_details": {
"screener_key": "scr-01j1pagnn41xv3hwg8v3sqbmxx",
"expired": false,
"max_views": 3,
"views_consumed": 3,
"start_date": 1719599515,
"expiry_date": 1722191515,
"offline": true
},
"status_code": "W0000",
"status_message": "Success"
}
| Field | Type | Description |
|---|---|---|
key |
String | Unique key of the title. |
name |
String | Name of the title. |
screening_details |
JSON | The screening window and view allowance, with views_consumed reflecting the views just recorded. |
status_code |
String | The Indee status code for the response. |
status_message |
String | Human readable message describing the response. |
The response carries the same fields as the screener room video detail API — poster, duration_in_sec, subtitles, auth_details, overlay_watermark_details and the rest — abbreviated here.
Status Codes
| Indee status code | HTTP Response Code | Description |
|---|---|---|
| W0000 | HTTP 200 | Success |
| W2000 | HTTP 401 | Authorization header was either not passed or there was some issue parsing it |
| W2001 | HTTP 401 | API key is invalid or expired, or is not fully configured |
| W2009 | HTTP 401 | ClientID header was either not passed or is malformed |
| W2100 | HTTP 403 | Origin domain is not whitelisted for this API key |
| W2108 | HTTP 403 | Watch product is inactive |
| W2102 | HTTP 451 | Request blocked by geofencing for the resolved region |
| W4200 | HTTP 400 | The screener does not allow offline viewing, belongs to a different watch product, or has no viewer linked to it |
| W4201 | HTTP 400 | The specified screener key does not exist |
| W4900 | HTTP 400 | views_consumed is missing, not an integer, or less than 1 |
| W5001 | HTTP 429 | Rate limited |
| W5000 | HTTP 500 | Unknown server error occurred |