Errors

Errors use standard HTTP status codes and a JSON body that says what went wrong.

The error body

Errors follow the Problem Details format (RFC 7807). The status code tells you the category; detail tells you what happened, in English:

JSON
{  "type": "/errors/404",  "title": "An error occurred",  "status": 404,  "detail": "Not Found"}

Some business errors use a shorter form, with an optional context holding structured details:

JSON
{  "title": "Invalid Request",  "status": 400,  "detail": "Missing organization filter. Provide either \"organization.id\" or \"organization.slug\"."}

Validation errors

When a request body breaks a rule, the API answers 422 Unprocessable Entity with one entry per problem in violations. propertyPath names the field:

JSON
{  "status": 422,  "detail": "email: This value is not a valid email address.",  "violations": [    { "propertyPath": "email", "message": "This value is not a valid email address.", "code": "bd79c0ab-…" }  ]}

Show message next to the field it concerns; it is written for people.

Status codes

CodeMeaningWhat to do
200, 201, 204Success
304Not modifiedReuse your cached copy
400The request is malformed or not allowed in this state (slot taken, registrations closed, missing filter)Read detail; do not retry unchanged
401No valid credentialsCheck the API key
403Authenticated, but not allowed, or the module is not enabled for this organizationCheck the role of the key's owner and the organization's modules
404Unknown organization, slug or identifier, or unpublished contentCheck the identifiers and the publication status
422Validation failedFix the fields listed in violations
429Too many requestsWait, then retry; see Rate limiting
5xxSomething went wrong on our sideRetry with backoff; contact us if it persists

Retrying safely

Retry 429 and 5xx responses with exponential backoff. Do not retry 4xx responses other than 429 unchanged: they will fail again. Creating requests (POST) are not idempotent, so before retrying a reservation or a registration after a timeout, check whether the first attempt went through.