Skip to main content

System - Aggregator Status Read

Endpoint

/o/system/aggregator

Overview

Returns per-aggregator lag status by comparing aggregator checkpoints with current time and latest drill data timestamp.

Authentication

  • API Key (parameter): api_key=YOUR_API_KEY
  • Auth Token (parameter): auth_token=YOUR_AUTH_TOKEN
  • Auth Token (header): countly-token: YOUR_AUTH_TOKEN

Permissions

  • Requires authenticated dashboard user access to management-read endpoints.

Request Parameters

ParameterTypeRequiredDescription
api_keyStringYes (or use auth_token)Dashboard API key.
auth_tokenStringYes (or use api_key)Dashboard auth token.

Response

Success Response

[
{
"name": "events",
"last_cd": "2026-02-17T11:20:00.000Z",
"drill": "2026-02-17T11:20:02.000Z",
"last_id": "67b2f7ba7acdc44f5079c100",
"diff": 3,
"diffDrill": 1
}
]

Response Fields

FieldTypeDescription
(root)ArrayOne item per aggregator stream key in countly.plugins._changeStreams.
nameStringAggregator stream name.
last_cdStringLast accepted change date of this stream.
drillStringLatest drill event cd value used for drill lag comparison.
last_idStringLast processed change stream object id for this stream.
diffNumberSeconds from last_cd to current server time.
diffDrillNumberSeconds from last_cd to latest drill cd value.

Error Responses

Status Code: 400 Bad Request

{
"result": "Error fetching aggregator status"
}

Behavior/Processing

Behavior Modes

ModeTriggerResponse Shape
Aggregator rows available_changeStreams document has stream keysArray with lag objects.
No stream rows_changeStreams missing or only _idEmpty array.
Query failureMongo/drill query throwsWrapped error message.

Database Collections

CollectionUsed forData touched by this endpoint
countly.pluginsSource of _changeStreams checkpoint document.Reads checkpoint rows for each stream key.
countly_drill.drill_eventsSource of latest drill cd timestamp.Reads most recent drill change date (cd).

Examples

Example 1: Read aggregator lag status

/o/system/aggregator?api_key=YOUR_API_KEY
[
{
"name": "events",
"diff": 6,
"diffDrill": 3
}
]

Operational Considerations

  • High diff values indicate aggregator lag relative to current time.
  • High diffDrill values indicate lag versus current drill ingestion state.

Last Updated

2026-02-17