Retrieve Video Content
Download the generated video file as MP4.
Download a generated video as an MP4 file. The response body is the raw
video bytes with Content-Type: video/mp4 and a
Content-Disposition: attachment header.
GET /v1/videos/:video_id/contentThis endpoint is only available once the job's status is completed.
You rarely need to build the URL yourself: a completed
job lists it in
unsigned_urls and, signed, in urls.
Authentication
There are two ways to call it:
- With your API key - send the usual
Authorization: Bearerheader. This is what the job'sunsigned_urlsneed. - With a signed URL - use a URL from the job's
urlsas is. It carriesexpiresandsignaturequery parameters and needs noAuthorizationheader, so you can hand it to a browser, a<video>element or another service. It stops working at the job'sexpires_at(about one hour after the job was retrieved); retrieve the job again for a fresh one. A tampered or expired signature is rejected with403.
Path parameters
video_idstringrequiredThe id of the video job.
Query parameters
indexintegeroptionalDefault 0Which output of the job to download. Every job has exactly one output
today, so only 0 exists; any other value returns 404.
expiresintegeroptionalPart of a signed URL. Copy it from urls, do not build it yourself.
signaturestringoptionalPart of a signed URL. Copy it from urls, do not build it yourself.
Single byte ranges (Range: bytes=start-end) are supported and answered
with 206 Partial Content, so video players can seek.
Response
bodybinaryoptionalRaw MP4 video bytes. No JSON envelope.
Errors
| Status | Reason |
|---|---|
401 | No API key and no signature. |
403 | The signature is invalid or has expired. |
404 | Video not found, belongs to another workspace, or index is not 0. |
409 | Video generation is not yet complete. Wait for status: 'completed'. |
416 | The requested byte range lies outside the file. |
502 | The video could not be fetched from the model yet. Try again later. |