Skip to main content

Upload multiple video files in one request

POST 

/api/v1/videos/batch/upload

Multipart-upload several video files at once, each indexed independently. A failure in one file (bad format, storage error) does not abort the rest — every file gets its own outcome, and GET /v1/videos/batch/{batch_id} reports per-item status (submitted / skipped / failed) plus the resulting video_id for each submitted file.

Recommended for ~10 files or fewer per request — split larger uploads across multiple requests instead. There's no hard cap on file count, only a loose safety backstop (413 above 500 files, counted per request and across a reused batch_id) to reject runaway requests.

If a request itself fails partway (e.g. connection drop), poll the batch's status first — files already recorded won't be re-submitted cleanly since uploads have no natural dedup key, so resend only the files still missing rather than the whole batch. Before doing so, drop any rollup item whose error is dispatch_failed from that missing set — its video row is already committed, so resending it indexes the file twice.

Per-item bookkeeping is best-effort: if this call returns, trust its accepted/skipped/failed counts over the batch rollup. A rollup listing fewer items than accepted means a bookkeeping write was lost, not that a file went unsubmitted — re-sending those files would index them twice.

Optional batch_id: pre-create one with POST /v1/videos/batch so you can poll progress under that id even if this upload call itself fails before returning.

Request​

Responses​

Successful Response