Errors and retries
Diagnose failures with errors and request IDs.
Inspect error.type: insufficient_balance means remaining Credits are insufficient; api_key_monthly_limit means the key reached its monthly cap; outstanding_undercharge requires reconciling a prior call. Check Dashboard → Keys for key limits; buying credits does not raise key caps.
Balance errors may include required_vnd and available_vnd; key-cap errors may include limit_vnd and spent_vnd. Save these fields with the request ID for investigation, without sharing the API key.
This API key is not allowed to use the selected model. Check its model permissions in Dashboard → Keys or select an allowed model.
The body exceeds {mb} MB or the input exceeds a model/provider-specific limit. Read the message and reduce context, images or files; a body below the gateway limit can still receive 413.
HTTP 429 can mean local admission pressure, a full queue or upstream throttling. Read the error and Retry-After; it does not imply unlimited RPM or TPM.
Honor Retry-After and use bounded exponential backoff with jitter. Cap attempts and total time. For video jobs that may already exist, look up the job ID before submitting again.
Save x-request-id and the error timestamp for support; some legacy routes return x-api-request-id instead. Never include API keys or sensitive data in a bug report.
curl https://api.giacatgroup.vn/v1/models \
-H "Authorization: Bearer sk-gcg-your_key"HTTP Status Codes & Troubleshooting
| HTTP | Meaning | Resolution |
|---|---|---|
400 | Bad Request | Validate JSON payload, model ID, and request fields. |
401 | Unauthorized | Verify API key and Authorization or x-api-key header. |
402 | Payment Required | Insufficient ST balance — top up credits in Dashboard. |
403 | Forbidden | Key lacks permission for this model or is paused. |
404 | Not Found | Check base URL path (/v1 vs root) and active model ID. |
413 | Payload Too Large | Reduce prompt size or media payload. |
429 | Too Many Requests | Rate limit exceeded — apply exponential backoff and retry. |
500 / 502 / 503 / 504 | Upstream / Gateway Error | Transient upstream error — retry with backoff and keep x-request-id. |