Errors
How the API reports failures, and what to do about each one.
Response Envelope
Every response, success or failure, has the same two top-level keys:
Code
On failure error is an object and payload is normally null:
Code
error.code always matches the HTTP status code. Check error first: a null error means the request succeeded.
HTTP Status Codes
| Code | Meaning | When |
|---|---|---|
200 | OK | The request succeeded. |
400 | Bad Request | The request could not be processed as sent (for example a missing file on an upload, or a storage limit reached). |
402 | Payment Required | Your plan does not include the Public API, or the feature the endpoint needs (for example custom fields). |
403 | Forbidden | Missing or invalid API key, insufficient scope, or an action that needs explicit consent. |
404 | Not Found | The resource does not exist in your organization, or the endpoint does not exist. |
405 | Method Not Allowed | The endpoint exists but not for this HTTP method. |
422 | Unprocessable Entity | Validation failed; payload lists the errors per field. |
429 | Too Many Requests | Rate limit exceeded. See Rate Limiting. |
500 | Internal Server Error | Something failed on our side. Retry with backoff; contact support if it persists. |
Common Errors
Missing or invalid API key
Status: 403 Forbidden
Code
The API answers 403, not 401, for a missing or unknown key. Check that the key is sent as Authorization: Bearer YOUR_API_KEY and has not been regenerated.
Plan does not include the API
Status: 402 Payment Required
Code
The key is valid but your subscription plan does not include the Public API, or does not include the feature the endpoint depends on (custom fields endpoints and the custom_fields parameter). Upgrade the plan or drop the parameter.
Insufficient scope
Status: 403 Forbidden
Code
Only extension apps authenticating with an OAuth token see this. Organization API keys carry every scope.
Explicit consent required
Status: 403 Forbidden
Code
Deleting courses, modules and elements, and creating members, are gated behind consents an organization owner grants once in Developers on the dashboard.
Resource not found
Status: 404 Not Found
Code
Returned both for an unknown endpoint and for a resource id that does not exist in your organization. Ids belonging to another organization are reported as not found, never as forbidden.
Validation failed
Status: 422 Unprocessable Entity
Code
This is the one failure where payload is set: an object keyed by parameter name, each holding the list of messages for that parameter. Nested parameters use dot notation (custom_fields.field_7).
Rate limit exceeded
Status: 429 Too Many Requests
Code
Wait for the window to reset, then retry. See Rate Limiting.
Handling Errors
Code
Code
Next Steps
- Authentication - API key setup
- Rate Limiting - Usage limits