Skip to main content

Error Response Format

Every error response from the Parallel AI API returns a JSON body with a single error field describing what went wrong:
Always check both the HTTP status code and the error message when debugging — the message provides specific context that the status code alone cannot.

HTTP Status Codes

Common Errors and Solutions

Symptom: You receive {"error": "Unauthorized"} on every request.Solutions:
  • Confirm you’re sending the X-API-Key header (or Authorization: Bearer ...) with every request.
  • Verify the key is correct — copy it fresh from the dashboard to rule out typos.
  • If you’re using a Personal Access Key (PAK), you must also include the X-Company-ID header:
Symptom: Your request is authenticated but returns {"error": "Forbidden"}.Solutions:
  • The endpoint or feature you’re calling may not be included in your current Parallel AI plan.
  • Contact Parallel AI support to confirm which features are available on your plan or to request access.
Symptom: A resource lookup returns {"error": "Not found"}.Solutions:
  • Double-check the resource ID in your request path (e.g. agent ID, sequence ID).
  • Confirm the resource belongs to the company associated with your API key — you cannot access resources from other companies.
  • The resource may have been deleted. Use a list endpoint to verify it still exists.
Symptom: Requests start returning {"error": "Too many requests"}.Solutions:
  • Slow down the rate at which you’re making requests.
  • Implement exponential backoff: wait before retrying, doubling the wait time on each successive failure.
  • Batch operations where possible, or use pageSize=100 to retrieve more data per request.
Symptom: The API returns a 500 status unexpectedly.Solutions:
  • This indicates an issue on Parallel AI’s servers, not your request.
  • Retry the request after a short delay — most transient errors resolve quickly.
  • If the error persists, contact Parallel AI support with the request details and timestamp.

Retry Logic with Exponential Backoff

For production integrations, implement retry logic to handle transient errors (429 and 500) gracefully:
Add jitter (a small random delay) to your backoff to prevent multiple clients from retrying simultaneously and creating a thundering-herd effect:
Do not retry 400, 401, 403, or 404 errors — these indicate problems with your request or credentials that will not resolve on their own.