All API errors return a consistent JSON structure with an error object containing a machine-readable code and human-readable message.
Error Response Format
Every error response follows this structure:
{"object":"error","error":{"code":"ERROR_CODE","message":"Human-readable description of the error","details":{// Optional additional context},"documentationUrl":"https://docs.mapademics.com/errors/error-code"}}
Field
Type
Description
code
string
Machine-readable error code (use for programmatic handling)
message
string
Human-readable error description
details
object
Optional field-level details or additional context
documentationUrl
string
Link to relevant documentation
Error Codes by HTTP Status
400 Bad Request
Invalid request parameters or malformed input.
Error Code
Description
INVALID_INPUT
Request parameters failed validation
MISSING_REQUIRED_FIELD
A required field was not provided
INVALID_FORMAT
A field has an invalid format
Example: Invalid CIP Code Format
401 Unauthorized
Missing or invalid authentication credentials.
Error Code
Description
UNAUTHORIZED
Missing or invalid API key
INVALID_API_KEY
API key format is correct but key doesn't exist
EXPIRED_API_KEY
API key has been revoked or expired
Example: Missing API Key
403 Forbidden
Valid authentication but insufficient permissions.
Error Code
Description
FORBIDDEN
API key doesn't have access to this resource
QUOTA_EXCEEDED
Monthly quota has been exceeded
FEATURE_NOT_ENABLED
Feature not available on your plan
Example: Feature Not Enabled
404 Not Found
The requested resource doesn't exist.
Error Code
Description
NOT_FOUND
Resource not found
CIP_NOT_FOUND
CIP code not in database
SOC_NOT_FOUND
SOC code not in database
SKILL_NOT_FOUND
Skill ID doesn't exist
TASK_NOT_FOUND
Extraction task doesn't exist
Example: CIP Code Not Found
429 Rate Limited
Too many requests in the current time window.
Error Code
Description
RATE_LIMITED
Request rate limit exceeded
Rate limit responses include additional headers:
Header
Description
X-RateLimit-Limit
Maximum requests allowed per window
X-RateLimit-Remaining
Requests remaining (will be 0)
X-RateLimit-Reset
Unix timestamp when limit resets
Retry-After
Seconds until you can retry
Example: Rate Limit Exceeded
500 Internal Error
An unexpected error occurred on our servers.
Error Code
Description
INTERNAL_ERROR
Unexpected server error
Example: Internal Error
Always include the requestId when contacting support about internal errors. This helps us quickly locate the issue in our logs.
Handling Errors in Code
TypeScript Example
Python Example
Troubleshooting
For detailed troubleshooting steps and common solutions, see the FAQ & Common Issues page.
{
"object": "error",
"error": {
"code": "FORBIDDEN",
"message": "Your API key does not have access to the Syllabus Skills Extraction API",
"documentationUrl": "https://docs.mapademics.com/permissions"
}
}