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.
Authorization
AuthorizationstringheaderrequiredBearer token — your API key. Example: Bearer sk-...
Response
idstringrequiredThe video ID (e.g. "video_abc123").
object"video"requiredObject type — always "video".
modelstringrequiredThe model used for the generation.
status"queued" | "in_progress" | "completed" | "failed"requiredThe current status of the generation job.
queuedin_progresscompletedfailedprogressintegerrequiredEstimated completion percentage. 0 while queued, an elapsed-time estimate (capped at 95) while in progress, 100 on completion.
created_atintegerrequiredUnix timestamp of when the job was created.
completed_atintegerrequiredUnix timestamp of when the job reached a terminal state.
expires_atintegerrequiredUnix timestamp of when the stored video expires. Currently always null — generated videos are retained until you delete them.
promptstringrequiredThe prompt used for the generation.
sizestringrequiredOutput 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).
secondsstringrequiredClip duration in seconds. Shows the requested value while pending and the actual rendered duration once completed.
audiobooleanrequiredWhether the video was generated with a synchronized audio track. Always false on models that only produce silent video.
errorobjectrequiredError details when the job failed; null otherwise.
remixed_from_video_idstringrequiredAlways 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);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
}{
"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
}