VIDEOS

Retrieve a Video

Retrieve a video job by its ID. Poll this until the status is completed, then download the MP4 from the content endpoint. Once completed, size and seconds report the actual rendered output.

GET/v1/videos/{video_id}

Authorization

Authorizationstringheaderrequired

Bearer token — your API key. Example: Bearer sk-...

Response

idstringrequired

The video ID (e.g. "video_abc123").

object"video"required

Object type — always "video".

modelstringrequired

The model used for the generation.

status"queued" | "in_progress" | "completed" | "failed"required

The current status of the generation job.

queuedin_progresscompletedfailed
progressintegerrequired

Estimated completion percentage. 0 while queued, an elapsed-time estimate (capped at 95) while in progress, 100 on completion.

created_atintegerrequired

Unix timestamp of when the job was created.

completed_atintegerrequired

Unix timestamp of when the job reached a terminal state.

expires_atintegerrequired

Unix timestamp of when the stored video expires. Currently always null — generated videos are retained until you delete them.

promptstringrequired

The prompt used for the generation.

sizestringrequired

Output size as WIDTHxHEIGHT. Shows the requested size while the job is pending, and the actual rendered pixels once completed (some models render close-but-not-exact sizes, e.g. 1248x704 for a 1280x720 request).

secondsstringrequired

Clip duration in seconds. Shows the requested value while pending and the actual rendered duration once completed.

audiobooleanrequired

Whether the video was generated with a synchronized audio track. Always false on models that only produce silent video.

errorobjectrequired

Error details when the job failed; null otherwise.

remixed_from_video_idstringrequired

Always null — remixing is not supported.

Request

import OpenAI from "openai";

const client = new OpenAI({
  apiKey: "your-scx-api-key",
  baseURL: "https://api.scx.ai/v1",
});

let video = await client.videos.retrieve("video_9f6c2c4e");

while (video.status === "queued" || video.status === "in_progress") {
  await new Promise((r) => setTimeout(r, 4000));
  video = await client.videos.retrieve(video.id);
}

console.log(video.status, video.size, video.seconds);

Response

{
  "id": "video_9f6c2c4e-1c39-4d1a-b7bd-1c0d6d6a2f30",
  "object": "video",
  "model": "seedance-1.0-pro",
  "status": "completed",
  "progress": 100,
  "created_at": 1783652619,
  "completed_at": 1783652650,
  "expires_at": null,
  "prompt": "A red kite surfs over turquoise waves at golden hour, cinematic",
  "size": "1248x704",
  "seconds": "5",
  "audio": false,
  "error": null,
  "remixed_from_video_id": null
}