API Reference
HTTP Status Codes
| Status | Meaning |
|---|---|
200 | Success |
400 | Bad request — malformed input or validation failure |
401 | Unauthorized — missing or invalid API key |
403 | Forbidden — valid key but insufficient permissions |
404 | Not found — project or resource doesn't exist |
429 | Too many requests — rate limit exceeded |
500 | Internal server error — something went wrong on our end |
Error Response Format
All errors return a JSON body:
{
"error": {
"code": "invalid_request",
"message": "The 'sourceLanguage' field is required."
}
}Common Error Codes
| Code | Status | Description |
|---|---|---|
invalid_request | 400 | Request body failed validation |
unauthorized | 401 | API key is missing, expired, or malformed |
forbidden | 403 | API key doesn't have access to this project |
not_found | 404 | Project or resource not found |
rate_limited | 429 | Too many requests — back off and retry |
translation_failed | 500 | AI translation failed after retries |
internal_error | 500 | Unexpected server error |
LLM Failure Handling
The API retries failed LLM calls up to 3 times with exponential backoff. If all retries are exhausted, the entire batch fails — partial results are not returned. This is an all-or-nothing approach per batch chunk to avoid inconsistent translation states.