Which Sume timeout is which: sync, jobs_wait, waitForJob, webhooks
Sume's waits differ: 30 s sync cap, 50 s jobs_wait, a 20-minute SDK default in ms, 10 s per webhook attempt. A table of each unit and what expiry does.

Sume has no single timeout. The sync wait is capped at 30 seconds, the remote MCP jobs_wait tool waits 50 seconds by default, the TypeScript waitForJob helper gives up after 20 minutes, and a webhook attempt must answer within 10 seconds. None of these cancels the job when it expires, so a timeout is a reason to poll again, not to resubmit.
The table below puts every wait side by side with its unit, because the mixed units (seconds in the API, milliseconds in the SDK) cause most of the confusion.
Every wait in one table
Values come from the Sume jobs, webhooks and SDK run docs, plus the SDK source, read 2026-10-10.
| Wait | Default | Unit | What expiry does |
|---|---|---|---|
Sync or subscribe response (wait_timeout_seconds) | Capped at 30 | seconds | The response returns with the job still running; poll by id |
Remote MCP jobs_wait | 50, cap 55 | seconds | Returns wait_slice_expired; call it again with the same ids |
waitForJob timeout (TypeScript SDK) | 20 minutes (1,200,000) | milliseconds | Throws SumeJobTimeoutError; the job keeps running |
waitForJob pollInterval | 2,000 | milliseconds | A floor: the server hint can raise the gap, never shorten it |
waitForRun (Formats runs) | 10 minutes | milliseconds | Throws; the run keeps going |
subscribeFormatRun | 20 minutes | milliseconds | Stops the subscription; the run keeps going |
| Webhook attempt | 10 per attempt | seconds | Counts as a failed attempt; 10 attempts, 30 s apart |
The two traps
The first is units. wait_timeout_seconds takes seconds; timeout: 600 in waitForJob is 600 milliseconds, not ten minutes. Write 10 * 60_000 so the unit is visible in the code. The second is that the MCP tool and the REST parameter differ: the API accepts a larger wait value and clamps it, while the MCP tool is capped at 55 seconds. Do not assume that a longer number buys a longer wait.
- Use sync mode only for work that normally finishes inside 30 seconds; for video, submit with
mode: "async". - Treat any wait expiring as "not finished yet": read
GET /v1/jobs/{id}and look atstatusandnext_poll_after_seconds. - Never cancel a job just because your own timer fired; a canceled job is a separate call.
Choosing the right wait
A browser-facing request has a few seconds of patience, so submit async and return the id. A worker can use waitForJob with a ten-minute budget and let the server hint pace its polls. A fire-and-forget pipeline should use a webhook and stop polling at all, with a polling sweep as the backstop for a missed delivery.
One more consequence: because expiry never cancels, a script that times out and resubmits the same prompt can end up paying twice. Reuse the original job id, or resubmit with the same Idempotency-Key.
Worst case for a webhook
A webhook that never answers has a bounded cost. Each attempt can use up to 10 seconds, there are 10 attempts, and the docs give a 30-second spacing between them. Ten attempts of 10 seconds plus nine gaps of 30 seconds is 370 seconds, or a little over six minutes, before delivery is marked exhausted.
Your fallback poll should therefore start after that window, not before. A sweep that lists active jobs every few minutes catches any completion your endpoint missed without hammering the read budget.
Sources
Related posts
More in Developers
- Write a Sume video URL back to a CMS record: what to store
Sume media URLs in a finished run are durable and public. Store them on your CMS record, and proxy or copy them if you need per-customer access control.
- Which MCP server lets Claude Code or Cursor generate video and images?
MCP servers that let Claude Code and Cursor make video and images: Sume, fal, Replicate, Runway, Higgsfield. Endpoints, sign-in, billing, setup.
- Idempotency keys for AI video APIs: retry without paying twice
An idempotency key makes a retried create return the original run or job instead of a second paid one. How Sume's Idempotency-Key works on each API.
- Signed webhooks for Sume video runs: events, retries, verification
Sume sends one HMAC-SHA256 signed POST when a Format, Action, or Agent Completion run completes or fails. Verify the raw body and dedupe on request_id.
Written by Sume