200-299 range indicate success, codes in the 400-499 range indicate a client
error (e.g failed validation) and should be fixed and retried in your end, and codes in
the 500-599 range indicate a server error on our end. Status codes in the 300-399 range
indicate a redirect. Some endpoints are idempotent and so are safe to retry.
Error response
A machine-readable error code that can be used to programmatically handle the error.
A developer-facing description of the error. This description is not meant to be
displayed to the user.
A URL to the error documentation page.
An array of objects describing the parameters that caused the error. This is mostly
present for validation errors (HTTP 400).
A context object that provides additional information about the error. This is mostly
present for errors that are related to the request (e.g. insufficient funds) and not
a specific parameter.
Examples
Debugging errors
In addition to error codes returned from API responses, you can inspect the response headers for a unique request ID (Request-Id). This ID is assigned as soon as the
request is received and is used to identify the request in our logs.
We recommend logging request IDs in your production deployments for more efficient
troubleshooting with our support team, should the need arise.
Client request IDs
In addition to our request IDs, you can also supply your own request IDs via theClient-Request-Id header. This header is not added automatically; you must explicitly
set it on the request.
The format is up to you; we recommend using a UUID or your internal trace ID up to a
maximum of 255 characters. We will reject any request with a Client-Request-Id header
that is longer than 255 characters.
If you supply a client request ID, we will log this value in our internal logs so make
sure it is not leaking any sensitive information. In cases of timeouts or network issues
when you can”t get the Request-Id response header, you can share the Client-Request-Id
value with our support team, and we can look up whether we received the request and when.