Tarseek API
Errors
Every public chat error uses one stable envelope:
{
"error": {
"message": "Human-readable explanation",
"type": "authentication_error",
"code": "invalid_api_key",
"param": null,
"retryable": false
},
"request_id": "req_..."
}x-request-id matches the body request_id. Send an optional printable-ASCII X-Client-Request-Id (maximum 512 characters) to correlate the call with your own logs. Retryable provider throttling includes Retry-After and error.retry_after_seconds when a delay is known.
| HTTP | Code | Type | Retry | Cause | Action |
|---|---|---|---|---|---|
| 400 | validation_error | invalid_request_error | No | Invalid JSON or request schema | Fix the request |
| 401 | invalid_api_key | authentication_error | No | Missing, unknown, or disabled key | Use an active project key |
| 402 | insufficient_credits | billing_error | No | Prepaid balance too low | Add credits |
| 404 | model_not_found | invalid_request_error | No | Unknown or unlisted model ID | Use the catalog |
| 400 | unsupported_parameter | invalid_request_error | No | Parameter not supported by this model | Remove the field |
| 400 | context_length_exceeded | invalid_request_error | No | Prompt longer than context | Shorten input |
| 429 | rate_limit_exceeded | rate_limit_error | Yes | Project or key RPM/TPM/concurrency limit | Backoff using Retry-After |
| 429 | provider_rate_limit | rate_limit_error | Yes | Upstream 429 after failover exhausted | Retry later or another model |
| 503 | model_unavailable | service_unavailable_error | Yes | No healthy deployment | Retry or switch model |
| 502 | provider_error | api_error | Yes | Upstream failure after failover | Retry with backoff |
| 502 | provider_authentication_error | provider_error | Yes | Tarseek’s provider credential failed | Report to support; try another model |
| 504 | provider_timeout | timeout_error | Yes | Upstream deadline | Retry; reduce max output |
| 500 | internal_error | internal_error | Yes | Unexpected Tarseek error | Retry; contact support with request_id |
