Error Handling

How to handle API errors gracefully.

Error Format

{
  "error": "http_422",
  "message": "Validation failed: email is required",
  "details": null,
  "request_id": "abc123-def456-..."
}

Common Status Codes

CodeMeaning
200Success
201Created
400Bad request — check your parameters
401Unauthorized — invalid or missing API key
403Forbidden — insufficient scope
404Not found — resource doesn't exist
409Conflict — duplicate resource
422Validation error — check request body
429Rate limit exceeded — slow down
500Server error — retry or contact support