Documentation

Base URL: https://api.metricsink.dev/v1

Authentication

Bearer token per project. Tokens can be scoped to ingest-only.

POST /ingest

Body is NDJSON, one event per line. Max 1 MB per request, unlimited requests per stream.

FieldTypeNotes
tsintUnix seconds. Required.
devstringDevice id. Required.
*number/stringAny flat fields become columns.

GET /health

Returns {"ok":true}. Unauthenticated.

Backpressure

On 429 the response includes Retry-After. Devices should buffer locally and resume from the last acknowledged cursor.

Errors

CodeMeaning
400Malformed NDJSON
401Bad token
413Batch too large
429Backpressure