VIDEOS
List Videos
List your organization's video jobs, newest first, with cursor pagination.
GET/v1/videos
Authorization
AuthorizationstringheaderrequiredBearer token — your API key. Example: Bearer sk-...
Query parameters
query stringlimitintegerNumber of videos to return, 1–100. Defaults to 20. Values outside the range (or non-integers) are rejected with a 400.
afterstringCursor for pagination: a video ID from a previous page (its `last_id`). Returns results after that video; an unknown cursor is rejected with a 400.
order"asc" | "desc"Sort order by creation time. Defaults to "desc" (newest first).
ascdescResponse
object"list"requiredObject type — always "list".
dataobject[]requiredThe page of video objects.
first_idstringrequiredID of the first video in this page; null when the page is empty.
last_idstringrequiredID of the last video in this page — pass as `after` to fetch the next page. Null when the page is empty.
has_morebooleanrequiredWhether more videos exist beyond this page.
Request
import OpenAI from "openai";
const client = new OpenAI({
apiKey: "your-scx-api-key",
baseURL: "https://api.scx.ai/v1",
});
const page = await client.videos.list({ limit: 20 });
for (const video of page.data) {
console.log(video.id, video.status);
}import OpenAI from "openai";
const client = new OpenAI({
apiKey: "your-scx-api-key",
baseURL: "https://api.scx.ai/v1",
});
const page = await client.videos.list({ limit: 20 });
for (const video of page.data) {
console.log(video.id, video.status);
}Response
{
"object": "list",
"data": [
{
"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",
"size": "1248x704",
"seconds": "5",
"audio": false,
"error": null,
"remixed_from_video_id": null
}
],
"first_id": "video_9f6c2c4e-1c39-4d1a-b7bd-1c0d6d6a2f30",
"last_id": "video_9f6c2c4e-1c39-4d1a-b7bd-1c0d6d6a2f30",
"has_more": false
}{
"object": "list",
"data": [
{
"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",
"size": "1248x704",
"seconds": "5",
"audio": false,
"error": null,
"remixed_from_video_id": null
}
],
"first_id": "video_9f6c2c4e-1c39-4d1a-b7bd-1c0d6d6a2f30",
"last_id": "video_9f6c2c4e-1c39-4d1a-b7bd-1c0d6d6a2f30",
"has_more": false
}