Authenticate, page through results, retry safely and read every error the API can return. Everything a client needs before its first call: which credential to use and which role it carries, how paging, formats, rate limits, idempotency and request ids work, what every error code means, and how an administrator operates the API. Examples use three shell variables — the installation's URL, a scoped service token and a project path.
GET /api/v1/me tells a client which identity, role and rate limit it has — the first call to make with a new credential.
The API takes the same credentials as the rest of the backend:
The installation token acts as admin. Give every integration its own scoped service token, with the lowest role that does the job, so that it can be revoked on its own and is named in the audit trail.
The table is enforced by the backend's role classifier, and a test asserts that it agrees with the API catalogue. Row- and column-level security and object-level grants apply to API calls exactly as they do in the application.
Responses carry nextCursor (also sent as the ATX-Next-Cursor header). Send the same body plus "cursor". null means the last page. The maximum limit is 50 000; the default is 1 000.
A cursor is tied to the statement, the project and the page size. Replaying it against a different query returns 400 bad_request and never returns another query's rows.
Each credential has a token bucket — 600 requests a minute with a burst of 100 by default, configured with ANALYTICS_API_RATE_PER_MIN and ANALYTICS_API_BURST. Every response carries RateLimit-Limit, RateLimit-Remaining, RateLimit-Reset and RateLimit-Policy. When the bucket is empty, the answer is 429 rate_limited with Retry-After.
Callers that share the installation token are bucketed per IP address, so one script cannot starve the others.
On a POST, send Idempotency-Key: <uuid>. A retry with the same key and the same body within 24 hours gets the first answer back with Idempotent-Replayed: true, and the call does not run again.
Queries use the application's admission lanes. Under load the API answers 503 unavailable with Retry-After. A query that exceeds the installation's time limit is stopped. A result that exceeds the result-size limit returns 413 payload_too_large: ask for fewer rows per page.
Errors use the application/problem+json content type (RFC 9457). code is the stable, machine-readable part; title and detail are prose. Decide whether to retry from retryable, and wait for Retry-After when it is present.
A refusal from a layer that does not know about v1 — access control, RBAC, the licence gate, the body parser — is still converted to a problem document, with the original reason in reason.
This site needs JavaScript for the full experience. Every page above is reachable without it.