Developers

Errors

The one error envelope, the closed set of machine codes, and why a cross-workspace id is a 404.

Read as markdown · OpenAPI 3.1 · llms.txt

Every error has the same shape:

{
  "error": {
    "code": "insufficient_scope",
    "message": "This credential is missing the \"contacts:write\" scope.",
    "request_id": "req_8f2c…",
    "details": { "required": "contacts:write", "granted": ["contacts:read"] }
  }
}

Switch on code. It is a closed set and part of the contract; message is for humans and may be reworded.

codestatuswhat it means
invalid_request400The body or query string failed validation. details.issues has the specifics.
unauthenticated401Missing, expired, revoked, or malformed credential.
insufficient_scope403Valid credential, wrong scopes. details.required names the one you need.
access_denied403The workspace revoked your app, or never authorized it.
not_found404No such object for this workspace.
conflict409A uniqueness constraint — e.g. two API keys with the same name.
unprocessable422Well-formed but the domain refused it.
compliance_blocked422A send was refused by the compliance gate. message names the reason.
rate_limited429Slow down; see Retry-After.
server_error500Ours. request_id is what support needs.

404 vs 403

Another workspace's object id returns 404, not 403. A 403 would confirm the row exists somewhere, which turns every id endpoint into a platform-wide existence oracle. "Not found" is the honest answer from your credential's point of view.

request_id

Every response — success or failure — carries X-Request-Id, and errors repeat it in the body. Log it. It is the fastest path to an answer from support.