Synchronous errors
Most HTTP errors use the FastAPI error envelope:detail. Do not parse human-readable messages to make permanent business decisions.
Terminal failures
An accepted request can later finish withfailed or nsfw:
Safe retry policy
- Retry
GETstatus requests after network failures and5xxresponses. - Do not retry authentication or validation failures without changing the request.
- Use exponential backoff with jitter.
- Set maximum attempts and a total retry deadline.
- Send an
Idempotency-Keywith every generation submission. - After an ambiguous timeout, network failure, or
5xx, repeat the same generation request with the same idempotency key.
X-Correlation-ID header. Record it with the request_id and include both when contacting support.