Guides
Errors
Errors
Failed merchant API requests return JSON with success: false, a human-readable error, and a machine code.
Common codes (API key auth)
| HTTP | Code | Meaning |
|---|---|---|
| 401 | UNAUTHORIZED | Missing, invalid, or revoked API key |
| 403 | FORBIDDEN | Scope denied, account not ready for charges, or function blocked for API keys |
| 403 | API_GATEWAY_KEY_FORBIDDEN | Function is dashboard-only — see Dashboard vs API |
| 429 | RATE_LIMIT_EXCEEDED | Too many requests — back off and retry |
| 404 | NOT_FOUND | Resource not found (no cross-tenant hints) |
Session-only dashboard errors (for example EMAIL_NOT_VERIFIED) are returned when using a Clerk session on dashboard routes — not when calling the merchant HTTP API with an API key. See Dashboard vs API.
Example
Code
Include an optional x-cid header on requests so support can trace audit logs.
Next steps
- Authentication — headers and base URL
- Rate limits — backoff guidance
- API Reference — per-operation responses
Last modified on