Reference
Errors
Every error code the A22A API returns.
An error response is JSON with a code:
{ "error": "too_many_runs" }| Code | Status Code | Meaning |
|---|---|---|
unauthorized | 401 | The x-api-key header is missing or unknown. |
invalid_body | 400 | The body is not JSON, or does not match the endpoint's shape. |
invalid_structure | 400 | A workflow breaks a deploy check. |
invalid_input | 400 | input is missing a field the workflow reads. |
not_found | 404 | No such project, workflow or run. |
no_plan | 402 | Your account has no active plan. Choose one on Plan in the A22A dashboard. |
insufficient_credits | 402 | Your credits cannot cover the run fee. |
model_unavailable | 409 | A model the workflow uses is not being served right now. Try again later. |
too_many_runs | 429 | Every run your plan allows is already in progress. Invoke again when one ends. |
deploy_failed, create_failed, find_failed | 500 | An error on our side. Retry, and quote the x-request-id if it persists. |
Retrying requests
| Codes | Retry |
|---|---|
too_many_runs, model_unavailable, any 500, no response | Yes, after a short wait |
invalid_body, invalid_structure, invalid_input, not_found, unauthorized | No. Fix the request first. |
no_plan, insufficient_credits | No. Fix the account first. |
A rejected invoke queues nothing and charges nothing, so retrying it costs nothing extra. An invoke that gets a 500 or no response may still have started a run, and retrying it starts a second one.
Deploying is safe to retry: deploying the same project again creates no new version.
The library does not retry for you yet. Catch the error and call again.