Skip to main content

Error Format

All errors return a consistent JSON body:
{
  "statusCode": 400,
  "message": "branchId is required for branch type keys",
  "errors": {
    "branchId": "required"
  }
}
For validation errors, errors is an object mapping field names to error codes. For single-message errors, only message is present.

HTTP Status Codes

CodeMeaningCommon Causes
200OKSuccessful GET / PATCH
201CreatedSuccessful POST
204No ContentSuccessful DELETE
400Bad RequestMissing required fields, invalid values
401UnauthorizedMissing, invalid, expired, or revoked API key
403ForbiddenValid key, but insufficient permissions
404Not FoundResource doesn’t exist or is not in your scope
422Unprocessable EntityBusiness rule violation (e.g., order can’t be cancelled in current status)
429Too Many RequestsRate limit exceeded — see Rate Limits
500Internal Server ErrorUnexpected server error

Common Error Examples

Invalid API key

{
  "statusCode": 401,
  "message": "Invalid or revoked API key"
}

Expired API key

{
  "statusCode": 401,
  "message": "API key has expired"
}

Rate limit exceeded

{
  "statusCode": 429,
  "message": "Rate limit exceeded",
  "retryAfter": 23
}

Validation error

{
  "statusCode": 400,
  "message": ["url must be a URL address", "events should not be empty"],
  "error": "Bad Request"
}

Resource not found

{
  "statusCode": 404,
  "errors": {
    "order": "notFound"
  }
}

Idempotency

The Partner API does not currently support idempotency keys. To avoid duplicate orders, check for existing orders before creating a new one using GET /partner/orders.