Skip to main content
POST
Query metrics

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
metric_ids
string[]
required

Metric ids from /metrics/catalog, or custom:<event_name> for any tracked event. Ids that do not resolve come back in unknown_metric_ids rather than failing the request; a request where NO id resolves is a 400.

Required array length: 1 - 50 elements
Maximum string length: 120
start_date
string<date-time>

Inclusive ISO 8601 start instant. Supply with end_date; omit both for the last 30 days.

end_date
string<date-time>

Inclusive ISO 8601 end instant. Must be later than start_date.

comparison
boolean
default:false

Also compute the preceding window of equal width. Windows ending in the future are clamped to the same elapsed width, so a partial period is never compared against a full one.

Response

Successful response. Shape evolving — read fields defensively and do not depend on the absence of a field. Each entry in metrics mirrors the dashboard report contract verbatim (current, previous, currentTotal, previousTotal, granularity, and optionally dataStatus, unavailableReason, dataModel), which is why those keys are camelCase while the envelope is snake_case.

The response is of type object.