Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.laozhang.ai/llms.txt

Use this file to discover all available pages before exploring further.

Access Notice Seedance 2.0 currently has very limited upstream concurrency. To avoid long queues and failed tasks, we are not opening new access at this time. This page is for users who already have access and developers preparing an integration. Availability and concurrency updates will be posted in the TG announcement channel @laozhang_ai.
Base URL: https://api.laozhang.ai/seedance/api/v3Endpoints:
  1. POST /contents/generations/tasks: create a video generation task
  2. GET /contents/generations/tasks/{id}: query task status and result
Video generation is asynchronous. The create endpoint may return only the task id; poll the query endpoint and read the final video URL from content.video_url.

Route Setup

The LaoZhang API creation URL is:
https://api.laozhang.ai/seedance/api/v3/contents/generations/tasks
If you are configuring the upstream channel in the admin panel, use:
SettingValue
Upstream API URLhttps://ark.cn-beijing.volces.com
Secret keyVolcengine Ark API key
Custom prefix/seedance
Prefix to removeEmpty
Available modelsUse only the plain model IDs in the model table below

Token Setup

When creating a token for Seedance 2.0 in Token management, use:
SettingValue
Billing modeVolume priority / pay-as-you-go
GroupSeeDance2
RecommendationCreate a dedicated Seedance 2.0 token for easier log and billing review
Seedance 2.0 requests must use a token assigned to the SeeDance2 group. Tokens in the default group or other video groups may produce no-channel, model mismatch, or billing-group errors.
Do not directly append the official path /api/v3/contents/generations/tasks to https://api.laozhang.ai. Use the Base URL with the /seedance/api/v3 prefix.
Under the current relay path, GET /contents/generations/tasks without a task ID returns the site HTML instead of API JSON. Do not use the list endpoint in client integrations. Use create task plus query by task ID.

API Flow

1

Create task

Call POST /contents/generations/tasks, put the plain model ID in model, and provide the prompt plus optional assets in the content array.
2

Poll status

Call GET /contents/generations/tasks/{id} until status reaches a terminal state.
3

Download result

When status=succeeded, download the video from content.video_url. If return_last_frame=true was set, read content.last_frame_url as well.
Status values:
StatusMeaning
queuedThe task is queued
runningThe task is generating
succeededThe task succeeded and result data is in content
failedThe task failed; check error
expiredThe task expired
Do not wait for completed and do not read a top-level video_url. The LaoZhang relay keeps the official Ark response shape: success status is succeeded, and the video URL is content.video_url.

Models

model must be a plain model ID. Do not use console endpoint IDs, and do not append human-readable labels to the model name.
Model IDDescriptionRecommended use
doubao-seedance-2-0-fast-260128Seedance 2.0 fastFast generation, text-to-video, image reference, video reference, audio reference, multimodal reference, video extension, track completion
doubao-seedance-2-0-260128Seedance 2.0 standardStandard quality, first/last frames, video editing, and workflows that need more stable output
Do not pass an ep-... endpoint ID in client requests. The LaoZhang relay matches channels by plain model ID.

Create Task

/contents/generations/tasks
Create a Seedance 2.0 video generation task.

Headers

HeaderRequiredDescription
AuthorizationYesBearer $API_KEY, using a LaoZhang API token assigned to the SeeDance2 group
Content-TypeYesapplication/json
AcceptRecommendedapplication/json
Accept-EncodingRecommended for debuggingidentity, which avoids compression decoding noise in some clients

Request Parameters

ParameterTypeRequiredDescription
modelstringYesPlain model ID, for example doubao-seedance-2-0-fast-260128
contentarrayYesMultimodal content array; text prompts also go here
ratiostringNo16:9, 4:3, 1:1, 3:4, 9:16, 21:9, or adaptive
durationintegerNoSeedance 2.0 supports 4 to 15 seconds, or -1 for adaptive duration
framesintegerNoControl output by frame count; takes priority over duration
resolutionstringNoCommon value: 720p. Seedance 2.0 fast does not support 1080p
watermarkbooleanNoWhether to add a watermark
generate_audiobooleanNoWhether to generate or use audio
return_last_framebooleanNoWhether to return the final frame image URL

content Items

FieldTypeRequiredDescription
typestringYestext, image_url, video_url, or audio_url
textstringRequired when type=textPrompt text
image_url.urlstringRequired when type=image_urlImage URL
video_url.urlstringRequired when type=video_urlVideo URL
audio_url.urlstringRequired when type=audio_urlAudio URL
rolestringRecommended for assetsAsset purpose
Common role values:
rolePurpose
first_frameFirst-frame image
last_frameLast-frame image
reference_imageMultimodal image reference
reference_videoMultimodal video reference
reference_audioMultimodal audio reference
Audio cannot be the only reference asset. When using audio_url, include at least one image or video asset in the same request.

Text-to-Video

curl -X POST "https://api.laozhang.ai/seedance/api/v3/contents/generations/tasks" \
  -H "Content-Type: application/json" \
  -H "Accept: application/json" \
  -H "Authorization: Bearer $API_KEY" \
  --data-raw '{
    "model": "doubao-seedance-2-0-fast-260128",
    "content": [
      {
        "type": "text",
        "text": "First-person apple fruit tea ad, 4 seconds, fast-paced edit, show apple tea preparation and finished product, fresh bright style"
      }
    ],
    "ratio": "16:9",
    "duration": 4,
    "resolution": "720p",
    "watermark": false,
    "generate_audio": false,
    "return_last_frame": true
  }'
The create response usually contains only the task ID:
{
  "id": "cgt-example-task-id"
}

First and Last Frame

curl -X POST "https://api.laozhang.ai/seedance/api/v3/contents/generations/tasks" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $API_KEY" \
  --data-raw '{
    "model": "doubao-seedance-2-0-260128",
    "content": [
      {
        "type": "text",
        "text": "The first frame is image 1 and the final frame is image 2. Create a smooth commercial transition from a red apple product close-up to a finished apple fruit tea cup. Keep product appearance consistent and avoid people."
      },
      {
        "type": "image_url",
        "image_url": {
          "url": "https://ark-project.tos-cn-beijing.volces.com/doc_image/r2v_tea_pic1.jpg"
        },
        "role": "first_frame"
      },
      {
        "type": "image_url",
        "image_url": {
          "url": "https://ark-project.tos-cn-beijing.volces.com/doc_image/r2v_tea_pic2.jpg"
        },
        "role": "last_frame"
      }
    ],
    "ratio": "adaptive",
    "duration": 4,
    "resolution": "720p",
    "watermark": false,
    "generate_audio": false,
    "return_last_frame": true
  }'

Image, Video, and Audio References

curl -X POST "https://api.laozhang.ai/seedance/api/v3/contents/generations/tasks" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer $API_KEY" \
  --data-raw '{
    "model": "doubao-seedance-2-0-fast-260128",
    "content": [
      {
        "type": "text",
        "text": "Use image 1 for the apple product details, video 1 for first-person camera motion, and audio 1 as the background music. Generate a concise apple fruit tea commercial with quick ingredient cuts and a clean finished cup close-up."
      },
      {
        "type": "image_url",
        "image_url": {
          "url": "https://ark-project.tos-cn-beijing.volces.com/doc_image/r2v_tea_pic1.jpg"
        },
        "role": "reference_image"
      },
      {
        "type": "video_url",
        "video_url": {
          "url": "https://ark-project.tos-cn-beijing.volces.com/doc_video/r2v_tea_video1.mp4"
        },
        "role": "reference_video"
      },
      {
        "type": "audio_url",
        "audio_url": {
          "url": "https://ark-project.tos-cn-beijing.volces.com/doc_audio/r2v_tea_audio1.mp3"
        },
        "role": "reference_audio"
      }
    ],
    "ratio": "16:9",
    "duration": 4,
    "resolution": "720p",
    "watermark": false,
    "generate_audio": true
  }'

Query Task

/contents/generations/tasks/{id}
Query the status of a video generation task.
curl "https://api.laozhang.ai/seedance/api/v3/contents/generations/tasks/cgt-example-task-id" \
  -H "Authorization: Bearer $API_KEY"
Successful response example:
{
  "id": "cgt-example-task-id",
  "model": "doubao-seedance-2-0-fast-260128",
  "status": "succeeded",
  "ratio": "16:9",
  "duration": 4,
  "resolution": "720p",
  "content": {
    "video_url": "https://example.com/generated-video.mp4",
    "last_frame_url": "https://example.com/last-frame.jpeg"
  },
  "usage": {
    "completion_tokens": 87300,
    "total_tokens": 87300
  }
}
Result URLs are temporary signed URLs, usually valid for 24 hours. In production, download successful results immediately and copy them to your own object storage.

Full Python Example

import os
import time
import requests

API_KEY = os.environ["API_KEY"]
BASE_URL = "https://api.laozhang.ai/seedance/api/v3"

headers = {
    "Authorization": f"Bearer {API_KEY}",
    "Content-Type": "application/json",
    "Accept": "application/json",
}

payload = {
    "model": "doubao-seedance-2-0-fast-260128",
    "content": [
        {
            "type": "text",
            "text": "First-person apple fruit tea ad, 4 seconds, fast-paced edit, fresh bright style",
        }
    ],
    "ratio": "16:9",
    "duration": 4,
    "resolution": "720p",
    "watermark": False,
    "generate_audio": False,
    "return_last_frame": True,
}

create_resp = requests.post(
    f"{BASE_URL}/contents/generations/tasks",
    headers=headers,
    json=payload,
    timeout=60,
)
create_resp.raise_for_status()
task_id = create_resp.json()["id"]

while True:
    query_resp = requests.get(
        f"{BASE_URL}/contents/generations/tasks/{task_id}",
        headers={"Authorization": f"Bearer {API_KEY}", "Accept": "application/json"},
        timeout=60,
    )
    query_resp.raise_for_status()
    task = query_resp.json()
    status = task.get("status")

    if status == "succeeded":
        video_url = task["content"]["video_url"]
        video_resp = requests.get(video_url, timeout=180)
        video_resp.raise_for_status()
        with open(f"{task_id}.mp4", "wb") as output:
            output.write(video_resp.content)
        break

    if status in {"failed", "expired"}:
        raise RuntimeError(task)

    time.sleep(15)

Common Integration Questions

The current path is /seedance/api/v3/contents/generations/tasks. Do not remove /api from the official path.
No. The request model must be the plain model ID, such as doubao-seedance-2-0-260128. Do not send doubao-seedance-2-0-260128 (2.0-audio-video).
Not recommended. The LaoZhang relay matches channels by plain model ID, so do not pass ep-....
The final video URL is content.video_url. If return_last_frame=true was set when creating the task, the final frame image URL is content.last_frame_url.
No. Audio references must be sent with at least one image or video asset, otherwise the official API rejects the request.