Skip to main content

Error format

Errors are returned with an HTTP status and a JSON body. Branch on code, which is stable; message is for people and may change.
details is included when there is something to act on, such as the quoted and current amounts of a drifted quote. retryAfterMs is included on 429 responses. A request that fails validation, such as a missing field or an unknown chain key, returns 400 with the code invalid_request. details.issues lists each problem: in is where it was (json, query or param), path is the field, and message says what is wrong.
A body that is not valid JSON gets the same response.

Error codes

Quote

Build

Submit

Fast fill

Any endpoint