Video API callback_url and Idempotency-Key: a sume/auto job in curl
Submit a video job on Sume with callback_url instead of polling, add an Idempotency-Key so retries are safe, and let sume/auto pick the model. Curl and errors.

To avoid polling, add an HTTPS callback_url to the POST /v1/videos body and Sume will POST to it when the job reaches a terminal state. Add an Idempotency-Key header so a retry returns the original job instead of creating and charging a second one.
With model: "sume/auto", Sume chooses the model from the request. The default target is Gemini Omni Flash 1.1, with 3 to 10 second clips at 360p to 4K in 16:9 or 9:16.
The request
The prompt, duration and ratio below fit the Auto envelope. The default is 720p and 8 seconds when you omit them.
curl -X POST "https://api.sume.com/v1/videos" \
-H "Authorization: Bearer $SUME_API_KEY" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: ad-spring-001" \
-d '{"model":"sume/auto","prompt":"A vertical UGC-style product clip on a desk, natural light","aspect_ratio":"9:16","duration":6,"callback_url":"https://example.com/hooks/sume-video"}'What to rely on
Sume signs the raw JSON body and sends x-sume-webhook-timestamp and x-sume-webhook-signature headers. The payload is Sume's standard job webhook envelope, not an OpenRouter video.generation.* event. Follow the verification steps in the API reference and refuse to run the check if your signing secret is empty.
A webhook can be delayed or lost, so treat it as a nudge and confirm with GET /v1/videos/{id} before you act on the result. The same job is also readable at GET /v1/jobs/{id}/status and /result.
| Control | Behavior on Sume |
|---|---|
| callback_url | HTTPS only; POST on terminal state |
| Idempotency-Key | Replay returns the original job; same key with a different body gives 409 |
| sume/auto | Echoed back as the model; the resolved family is not disclosed |
| Billing | Reserved at submit; usage.cost is the billable amount |
Auto's limits
Auto validates against the Omni 1.1 envelope and fails closed. A 2-second or 11-second duration, 480p, or generate_audio: false returns 400 unsupported_capability, and the error names sume/auto, not an underlying model. If you need a longer clip or silence, pin a catalog id instead.
Auto does not appear in GET /v1/videos/models, because it is a routing value, not a model.
- Longer than 10 seconds: pin
wan-3.0,seedance-2.5,kling-3or an H3 row. - Silent output: pin
kling-3and sendgenerate_audio: false. - Retry on 429 or 5xx with the same
Idempotency-Key.
Sources
Related posts
More in Developers
- waitForJob polls every 2 s: 600 reads in a 20-minute Sume video job
The SDK's waitForJob floor is a 2-second poll and a 20-minute timeout: at most 600 reads per job. The read budget by plan and why next_poll_after_seconds wins.
- Wan 3.0 API in Node: vertical image-to-video from a first frame
Call Wan 3.0 on Sume from Node with fetch: pin a first frame, ask for 9:16 at 720p, poll the job and save the MP4. Includes limits and the 8-second price.
- Wan 3.0 API request cheat sheet: three modes, 2 to 30 seconds
Wan 3.0 on Sume: the request body for text, first/last frame and reference modes, the 480p/720p/1080p rates and the 2 to 30 second window, on one page.
- Wan 3.0 API rate limit: 300 RPM on Model Studio vs Sume jobs
Alibaba lists 300 requests per minute for Wan 3.0 on Model Studio. Here is what that means for a batch, and how Sume submits Wan 3.0 as async jobs.
Written by Sume