Query metrics
Run up to 50 catalog metrics over one date range, optionally with the preceding window of equal width for period-over-period deltas. This is the same engine the dashboard cards use, so the numbers match the product exactly. It is a read that takes a body because 50 metric ids do not belong in a query string. Call /metrics/catalog for valid ids; custom:<event_name> resolves for any tracked event.
Authorizations
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Body
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.
1 - 50 elements120Inclusive ISO 8601 start instant. Supply with end_date; omit both for the last 30 days.
Inclusive ISO 8601 end instant. Must be later than start_date.
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.