Sume bulk queue says completed but some runs failed: read the counts
A Sume Format bulk queue turns completed when every item is terminal, not when every item worked. Read counts.failed and each item error before you ship.

A Sume bulk queue reaches completed when every item is terminal. That is not the same as every item succeeding. Read counts.failed and the error on each row of items[] before you publish the batch, and fetch each child at GET /v1/format-runs/{run_id} for its own receipt and media.
What the queue is
POST /v1/formats/{handle}/{slug}/bulk-runs creates a server-side queue of ordinary Format runs. Each item is the same unit of work as one POST .../runs: one sandbox, one agent turn, one receipt. The body takes concurrency (1 to 16) and items (1 to 100). The accepted create returns 202 with a format.run_queue object, and the first concurrency items are already in flight.
Reading the receipt
counts.total equals items.length. counts.running includes an item that the API still treats as in flight.
| Field | What it tells you |
|---|---|
status | queued, running or completed |
counts | total, queued, running, completed, failed, canceled |
items[].status | One row per submitted item, in order |
items[].run_id | Null until the item is claimed |
items[].error | The cause for a failed item |
finished_at | Set when the queue becomes completed |
A check that does not lie
Poll GET /v1/format-run-queues/{queue_id} and wait for status: completed. Then decide on the counts. This shell fragment fails the job if any child failed.
QUEUE="frq_example"
Q=$(curl -sS "https://api.sume.com/v1/format-run-queues/$QUEUE" \
-H "Authorization: Bearer $SUME_API_KEY")
echo "$Q" | jq '.data.counts'
test "$(echo "$Q" | jq '.data.counts.failed')" = "0"Things that surprise people
- The queue has no webhook.
communication.webhook_urlis per item, and the queue is polled throughstatus_url. - Every item runs with
on_active_run: "allow". Sendingskiporrejecton an item does not stall the window. - A bad item fails the whole create with
400 invalid_requestanddetails.index, before any queue exists. - There is no public list-queues or cancel-queue endpoint. Cancel a child with
POST /v1/format-runs/{run_id}/cancel.
A realistic batch
The docs describe a production batch of this shape: a spreadsheet of broadcast rows, concurrency: 2, 20 items, one item per row. The client skips rows that have no finished draft, and each item binds its own output_schema and its own generation_spend_cap_usd.
That per-item cap is the useful part. A queue has no cap of its own, so the sum of your item caps is the most that the batch can spend. Add them up before you send, and keep the batch within what your wallet holds.
Fresh key for each batch
Mint a new Idempotency-Key for every batch. If you replay a spent key, the API returns 202 with the old queue, which looks like a new batch that finished instantly. Derive the key from the batch you intend, such as the sheet name and the week.
Related posts
More in Formats
- Bulk run for an ad matrix: 3 hooks by 4 ratios in 12 queue items
Build a 3 by 4 creative matrix as one Sume bulk run: 12 items, concurrency 4, and an index-to-name map so every finished file has a clear label.
- Same Idempotency-Key replay: bulk run answers 202, single run 200
Replaying a Format bulk-run create returns 202 and the original queue with no idempotency_hit flag. A single run returns 200 with idempotency_hit true.
- Call a Sume catalog Format without forking it: the sume handle
Sume ships ready-made Formats at the reserved sume handle. Read the io profile, call POST /v1/formats/sume/{slug}/runs, and fork only to change the recipe.
- Same intro and outro on every Short: allowed on YouTube?
YouTube allows a repeated intro and outro if the rest differs. What that means for AI-made Shorts built on a fixed format, and how to vary the body.
Written by Sume