Skip to content

Analytics

This API exposes Unleash live read-only endpoints, allowing developers and users to retrieve AI-generated analytics data.

API access is currently an optional add-on. Please contact your account manager to request a demo or for more information.

Base URL: https://api.unleashlive.com


All endpoints described in this section require a custom header containing your individual customer API key. See API KEY for information on how to obtain your key.

x-api-key: <API-KEY>
Terminal window
curl -X GET -H "x-api-key: <API-KEY>" https://api.unleashlive.com/v1/analytics/version
import urllib3
http = urllib3.PoolManager()
r = http.request('GET', 'https://api.unleashlive.com/v1/analytics/version', headers={'x-api-key': '<API-KEY>'})
r.data

GET /v1/analytics/version

Retrieves the current API version number. This endpoint is useful for testing and confirming that your API key is valid.

"1.0.1"

GET /v1/analytics/devices

Returns a list of all valid devices for the authenticated API key and account.

["Wb8fabc31378ce07", "W022abc5be35bb72", "Weea288bc1faaddd"]

Each item corresponds to an Unleash live Device ID.


GET /v1/analytics/sessions

Returns a list of all sessions for the authenticated API key and account.

["1595418530512", "1595452859625", "1595492155987"]

Each item corresponds to an Unleash live Session ID.


GET /v1/analytics/{deviceId}/{unixUTCTimeStampFrom}/{unixUTCTimeStampTo}/{pageNumber}

Retrieves raw analytics data generated between two given dates for a specific device.

This endpoint is size-optimized — returning a list of keys and an array of data values that map to those keys. See the Analytics Data Object reference for the response structure.

See Path Parameters in the reference section for full descriptions.

GET /v1/analytics/Wabcdb35be35bb72/1597630156000/1597630156000/1
{
"keys": [
"class_name",
"count",
"device_id",
"frame_number",
"model_id",
"session_id",
"source_file_name",
"timestamp"
],
"total_num_pages": 1,
"data": [
[
"person",
1,
"Wabcdb35be35bb72",
110251,
"starter-ai",
"1597622730877",
"Wabcdb35be35bb72?token=sneaky-firefox-288",
"2020-08-17T02:08:49.000Z"
],
[
"person",
3,
"Wabcdb35be35bb72",
110252,
"starter-ai",
"1597622730878",
"Wabcdb35be35bb72?token=sneaky-firefox-288",
"2020-08-17T02:08:49.000Z"
]
]
}

GET /v1/analytics/tableau/{deviceId}/{unixUTCTimeStampFrom}/{unixUTCTimeStampTo}/{pageNumber}

Retrieves Tableau-formatted analytics data generated between two given dates for a specific device.

This endpoint is descriptive, structuring the data as an array of JSON objects, allowing it to be read natively by services such as Tableau and Salesforce easily. See the Tableau Data Object reference for the response structure.

See Path Parameters in the reference section for full descriptions.

GET /v1/analytics/tableau/Wabcdb35be35bb72/1597630156000/1597630156000/1
{
"total_num_pages": 1,
"data": [
{
"timestamp": "2020-08-17T02:08:49.000Z",
"class_name": "person",
"count": 1,
"device_id": "Wabcdb35be35bb72",
"source_file_name": "Wabcdb35be35bb72?token=sneaky-firefox-288",
"frame_number": 110251,
"model_id": "starter-ai",
"session_id": "1597622730877"
},
{
"timestamp": "2020-08-17T02:08:49.000Z",
"class_name": "truck",
"count": 1,
"device_id": "Wabcdb35be35bb72",
"source_file_name": "Wabcdb35be35bb72?token=sneaky-firefox-288",
"frame_number": 110252,
"model_id": "starter-ai",
"session_id": "1597622730877"
}
]
}

The data retrieval endpoints use the following path parameters:

ParameterTypeDescription
deviceIdStringrequired Unique Device ID
unixUTCTimeStampFromIntegerrequired Unix epoch start, milliseconds
unixUTCTimeStampToIntegerrequired Unix epoch end, milliseconds
pageNumberIntegerrequired Page number (starts at 1)

Note: Payload is paginated starting with page number 1.

The compact response format for GET /v1/analytics/{deviceId}/...:

FieldTypeDescription
keysString[]A list of all keys used in the data field, in order of use
total_num_pagesIntegerThe total number of pages available for the requested data
dataArray[]List containing all requested data values, mapping to keys

The descriptive response format for GET /v1/analytics/tableau/{deviceId}/...:

FieldTypeDescription
total_num_pagesIntegerThe total number of pages available for the requested data
dataObject[]List of JSON objects containing all requested data