Client timeouts for Sume jobs: SDK defaults and the 30-second cap
Sume's sync wait caps at 30 seconds, waitForRun defaults to 10 minutes, subscribeFormatRun and waitForJob to 20. Pick a deadline per job type, keep the job id.

Three timeouts apply to a Sume job and they are not the same thing: the server's bounded sync wait, at most 30 seconds; the SDK's wait helpers, 10 or 20 minutes by default; and your own application deadline. Only the last should decide when your user gets an answer.
The defaults
wait_timeout_seconds is clamped to 0 through 30 and bounds one HTTP request, not the job. The SDK helpers poll client-side with a 2 second interval floor, and next_poll_after_seconds wins when it asks for a longer gap.
| Mechanism | Default wait | Throws on timeout |
|---|---|---|
| mode sync or subscribe | Up to 30 seconds | No; returns the envelope, poll on |
| waitForRun | 10 minutes | SumeRunTimeoutError |
| subscribeFormatRun | 20 minutes | SumeRunTimeoutError |
| waitForJob | 20 minutes | SumeJobTimeoutError |
Set a deadline per job type
Images often finish inside the sync window; video, avatar-video and face swap routinely do not. Give each type its own deadline and surface a pending state to the user instead of a spinner that ends in an error.
A timeout is not a cancel
When any of these fire, the job keeps running and keeps billing. The timeout error carries the job or run id: save it, resume from status_url, or cancel explicitly. Never resubmit the same paid intent without the original idempotency key.
Sources
Related posts
More in Developers
- Which Sume submit errors to retry: a Python status triage function
Retry 429 and 503 with the same Idempotency-Key, fix 400, 413 and 415, stop on 402, poll on 409 job_not_completed. A short Python function and its table.
- Choosing a Sume Idempotency-Key: business key plus a payload version
A good Idempotency-Key is stable across retries and changes with the request. Build it from your order id and a payload hash, or hit 409 idempotency_conflict.
- Sume image API size vs resolution vs aspect_ratio: which to send
On POST /v1/images, size is only a shorthand for a resolution tier and exact pixels are not served. Send resolution and aspect_ratio from the model's list.
- Sume job status: stop on terminal, fetch on result_ready
A Sume status reply has two booleans. terminal says stop polling; result_ready says GET /result will work. Failed and canceled jobs stop but have no result.
Written by Sume