Skip to main content
The API answers with standard HTTP status codes and one of three JSON shapes. Branch on the HTTP status first, then on data.code when it is present. message is written for a person; don’t parse it.

Response shapes

1. Standard response (most success and error answers)

  • status is a boolean: true for 2xx, false otherwise.
  • data holds the result on success. On some errors it holds a machine-readable code and details (for example data.missing on entity_not_active). It is {} when there is nothing to add.
  • error is an array, usually empty.

2. Validation failure (HTTP 422)

A body that is missing a required field or has a field of the wrong type:
In this shape status is the string "error", not a boolean, and the details are in errors (plural), keyed by field. Treat any HTTP 422 as a validation failure regardless of the body.

3. Rate limited (HTTP 429)

with X-RateLimit-Limit, X-RateLimit-Remaining and X-RateLimit-Reset headers (see Authentication).

Status codes

Error codes

Refunds have their own codes; see Refunds.

Common messages without a code

Retrying safely

Send an Idempotency-Key on every request that creates or moves money. Then a retry after a timeout, a 5xx or a 409 either returns the first answer or runs once, never twice. See Making retries safe.