Query Status and Download the Video (Doubao / Seedance Format)

Querying uses the same endpoint as Get Video Generation Task Status, returning the unified task JSON (status flow and fields: that page). Once SUCCESS, download the video from data.result_url.

Endpoint

GET /v1/video/generations/{task_id}

Request Examples

Poll once every 10 seconds or so. Note that result_url is a signed upstream direct link that expires in about 24 hours — download and store it promptly.

cURL
Python
Node.js
curl https://api-model.shuntianchuang.cn/v1/video/generations/task_xxxxxxxx \
  -H "Authorization: Bearer sk-your-token"

Response Body

The query response is a unified task JSON. data.data is the upstream's raw task response, echoing the values that actually took effect — verify your parameters here:

data.data fieldNotes
seed / ratio / resolution / durationThe generation parameters that actually took effect — verify your parameters here
framespersecondFrame rate, fixed at 24fps for text-to-video
generate_audioWhether audio was generated; successful outputs carry an audio track
usage.completion_tokensActual usage for the Seedance 2.0 series' per-token billing; 1.0 series rules: Model Plaza
content.video_urlThe video direct link, same as data.result_url
content.last_frame_urlLast-frame image (only present when return_last_frame: true was passed on submit)

Response Example

{
  "code": "success",
  "data": {
    "task_id": "task_xxxxxxxx",
    "status": "SUCCESS",
    "progress": "100%",
    "result_url": "https://xxxx/video.mp4",
    "fail_reason": "",
    "data": {
      "id": "cgt-xxxx",
      "seed": 42,
      "ratio": "16:9",
      "resolution": "1080p",
      "duration": 5,
      "framespersecond": 24,
      "generate_audio": true,
      "output_format": "mp4",
      "usage": { "completion_tokens": 245025, "total_tokens": 245025 },
      "content": {
        "video_url": "https://…/video.mp4",
        "last_frame_url": "https://…/last-frame.png"
      }
    }
  }
}

Status Callback (Optional)

When metadata.callback_url (a publicly reachable, POST-accepting URL) is passed on submit, The upstream pushes one POST per status change: the body is the upstream task object JSON (with id, model, status, content, etc.) — use the status field to detect the terminal state (succeeded / failed). Callbacks and polling are independent and can be used together.