Cluster Viewers Geolocation
Returns geolocation data for active viewers, suitable for displaying on a map.
Request
| Property | Value |
|---|---|
| Method | GET |
| URL | /api/cluster/viewers/geolocation |
| Content-Type | application/json |
| Authentication | Bearer Token |
Request
curl -X GET "{BASE_URL}/api/cluster/viewers/geolocation" \
-H "Authorization: Bearer YOUR_TOKEN"
Response Body
Developer Info
| Parameter | Type | Description |
|---|---|---|
data.dev | object | Development/debug information |
data.dev.aggregationMode | string | Marker aggregation mode (e.g., "AUTO", "NONE", "CLUSTERED") |
Statistics
| Parameter | Type | Description |
|---|---|---|
data.stats | object | Summary statistics for the map |
data.stats.isClustered | boolean | Indicates if markers are clustered |
data.stats.totalMarkers | integer | Total number of markers on the map |
Markers
| Parameter | Type | Description |
|---|---|---|
data.markers | array | Array of map markers |
data.markers[].type | string | Marker type (e.g., "individual" for single viewer, "cluster" for grouped viewers) |
data.markers[].position | number[] | Geographic coordinates as [latitude, longitude] |
data.markers[].data | object | Viewer data associated with this marker |
data.markers[].data.connectionId | string | Unique identifier of the viewer session |
data.markers[].data.streamKey | string | Stream key being viewed |
data.markers[].data.outBandwidth | integer | Outgoing bandwidth in bytes/sec |
data.markers[].data.healthScore | integer | Connection health score (0-100) |
Timestamp
| Parameter | Type | Description | |------------------|---------|--------------------------------------------|} | data.timestamp | integer | Data timestamp (Unix timestamp in ms) |
Metadata
| Parameter | Type | Description |
|---|---|---|
meta.executionTime | integer | Request processing time in milliseconds |
meta.generatedAt | integer | Response generation timestamp (Unix timestamp in ms) |
Successful Response (200)
{
"data": {
"dev": {
"aggregationMode": "AUTO"
},
"stats": {
"isClustered": false,
"totalMarkers": 1
},
"markers": [
{
"data": {
"streamKey": "123",
"connectionId": "v_88uzmg57ml98uni0",
"outBandwidth": 447669,
"healthScore": 88
},
"position": [
53.0176,
18.6202
],
"type": "individual"
}
],
"timestamp": 1770283311253
},
"meta": {
"executionTime": 2,
"generatedAt": 1770283311253
}
}
| Parameter | Type | Description |
|---|---|---|
message | string | Human-readable error message |
Error Response (4xx/5xx)
{
"message": "Error message"
}
Support Needed?
Create a free ticket and our support team will provide you necessary assistance.