Errors & rate limits
Error shape
Many endpoints return JSON with a human-readable message and an optional errCode:
{
"message": "Unauthorized",
"errCode": 401
}
Some endpoints also include an error string with more detail.
Common status codes
| Status | Meaning |
|---|---|
200 / 201 | Success |
202 | Accepted — job queued (poll with the returned jobId) |
400 | Invalid request (missing fields, bad URL, prompt limits, etc.) |
401 | Missing or invalid API key |
403 | Plan or credit limit — upgrade or wait for credits |
404 | Resource or job not found |
429 | Too many requests from this IP |
500 | Server error |
Rate limits
API traffic is limited per client IP:
| Limit | Window |
|---|---|
| 1500 requests | 15 minutes |
After about 1000 requests in the same window, responses may be delayed (slowdown) before hard limiting applies.
If you hit the cap, wait for the window to reset and retry with backoff.
Credits and plan limits
Generation endpoints consume AI credits according to your plan. When you are out of credits you typically receive 403 with a plan/limit message. Visibility report endpoints also enforce per-plan prompt counts.