Skip to content
v1
Docs

Ingest reference

Metrics ingest

Send custom metric points with a metric source’s token, and read back the points and limits that token’s source holds.

Its operations take the source's token as Authorization: Bearer <token>, never an API key.

Send metric points

POST/api/metric-sources/ingest

Sends a batch of custom metric points with a metric source’s token. The body is a JSON envelope {"points": […]}, a JSON array, one point or newline-delimited JSON, any of them gzipped. Each point names its metric by key (metric) or by uuid (metric_uuid) and carries a numeric value and an optional recorded_at. The answer counts what was queued and, per reason, what was refused; a batch can be partly accepted.

Limits (by default):

  • 1,000 points in one request.
  • A body of 1,048,576 bytes as sent and 10,485,760 bytes after decompression.
  • A recorded_at at most 300 seconds ahead of the server’s clock, and at most 1,095 days back.

Headers

  • Idempotency-KeystringOptional

    Any text of 1 to 255 visible ASCII characters. Required for points older than 30 days. A repeat of the same batch with the same key within 30 days is answered as the first was and counted once; a different batch under a used key is refused.

Body parameters

  • pointsarray of objectsRequired

    The points of the batch.

Returns

200 OK:

What was queued and how many points each reason refused.

The response panel's status selector shows each failure this operation can answer.

List a source's metrics

GET/api/metric-sources/ingest

Returns the metrics of the token’s own metric source, deleted ones included, sorted by key, each with its type and status, and the organisation’s metric allowance and use. Read only: it does not count as a push.

Returns

200 OK:

The source’s metrics and the organisation’s metric allowance.

The response panel's status selector shows each failure this operation can answer.