Limiti e tempi di attesa
Comprendere i limiti e i timeout di ricezione.
Il timeout del primo byte e il timeout quando il flusso è silenzioso sono diversi dal limite temporale del percorso. Questo limite dipende dall'endpoint, dal modello e dalla configurazione, l'impostazione predefinita è 600.000 ms per il non streaming. Il cliente, il procuratore o il fornitore possono rescindere prima; Questo non è un impegno di tempo.
HTTP 429 può essere causato dalla ricezione locale, da una coda piena o da un limite del provider. Leggere il contenuto dell'errore e riprovare dopo; Non interpretare come RPM/TPM illimitati.
Rispetta Retry-After; Utilizza il backoff esponenziale con jitter, limitando il numero di volte e il tempo totale di tentativi. Con l'attività video già creata, cerca prima l'ID per evitare richieste duplicate.
curl https://apistorehub.com/v1/models \
-H "Authorization: Bearer sk-ash-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. |