Sume TTS: webhook_url, sync wait or polling? The four modes

Sume TTS jobs take mode async, sync, subscribe or webhook. A webhook needs a public HTTPS webhook_url, and sync waits at most 30 seconds.

4 min readSume
All posts

A Sume TTS request can set mode to async, sync, subscribe or webhook. If you pick webhook you must also send webhook_url, which has to be a public HTTPS URL; sync waits at most 30 seconds for the job. Without any of these, a request with no webhook_url runs in async mode and you poll the job.

What the schema accepts

The shared communication options in the request schema are mode, webhook_url and wait_timeout_seconds. wait_timeout_seconds is an integer from 0 to 30. If you send only a webhook_url, the mode defaults to webhook; if you send neither, it defaults to async. Asking for mode webhook without a URL returns an invalid-options error.

TTS request communication options, read 2026-10-06 from the repo schema
You sendResulting modeNotes
NothingasyncPoll the job
webhook_url onlywebhookURL must be public HTTPS, max 2,048 characters
mode: webhook, no URLErrorInvalid communication options
mode: sync, wait_timeout_seconds: 30syncWait capped at 30 seconds
callback_url on a TTS bodyRejectedTTS body is strict and lists webhook_url only

Which to choose

For a short line, sync is the simplest: one call, and you get the result if it finishes inside the wait. For a long script near the 20,000-character limit, do not count on 30 seconds. Use a webhook if you have a public endpoint, or poll the shared job status route if you do not. Polling and results use GET /v1/jobs/:id/status and /result, the same surface as other Sume jobs.

  • Short line, interactive: sync with a wait up to 30 seconds.
  • Long script, server to server: webhook_url.
  • No public endpoint: async and poll the job.

Choosing by workload

A narration pipeline that submits fifty scripts overnight does not want fifty open connections. Submit them in async mode with idempotency keys, or give each a webhook_url and let the completions come to you. A chat product that speaks one reply to a person is different: there, a synchronous wait of a few seconds is acceptable, and the 30-second ceiling tells you where to switch to polling.

Remember that TTS on Sume is an asynchronous file job, not a live audio stream. If you need audio to start while text is still arriving, this is the wrong surface, and the live-voice comparison post linked below explains where it fits.

A caveat on callback_url

Some Sume routes accept callback_url as an alias of webhook_url, and they must match if both are sent. The TTS body schema only lists webhook_url, so use that name for TTS and verify against the request reference. Also verify webhook signatures on your receiver; never accept an empty secret.

Sources

Related posts

More in Developers

All Developers posts

Written by Sume