API reference

Errors & limits

Error envelope

Errors always use the standard envelope: an error object with a stable code, a human-readable message, and optional details, alongside ok: false.

{
  "error": {
    "code": "insufficient_scope",
    "details": { "missing": ["brand:ads:launch"] },
    "message": "This token is missing required scopes."
  },
  "ok": false
}

Status codes

StatusCodeMeaning
401unauthorizedMissing or invalid bearer token
403insufficient_scopeToken lacks a required scope
403forbiddenYour role cannot perform this action
404not_foundRoute or resource does not exist
405method_not_allowedMethod not supported — see the Allow header
413request_too_largeRequest body exceeds the size limit
422invalid_*Payload failed validation
503*_not_configuredAuth backend unavailable

Scope failures also set a WWW-Authenticate header naming the required scopes, so clients can request a correctly-scoped token.

Limits

Request bodies are capped at 10 MiB; larger payloads are rejected with 413 request_too_large and the limit echoed in details.maxBytes. Media uploads (creator videos, images) have their own dedicated endpoints with different limits documented on those resources.