Video / Seedance 2

Seedance 2.0 Video Generation

asV3 localized example text (snake_case Request Body + ).in use endpointSeedance 2.0 V2 endpointlocalized example text.task and, can.

Overview

The Seedance 2.0 video generation endpoint supports multimodal inputs including text, images, video, and audio.Request Bodyand snake_case, with, Modelmodel fieldlocalized example text.

localized example text:
- 🎬 localized example text:supported 480p / 720p / 1080p output
-🧠 localized example text:image, video, audio etc. reference asset
-🎯 Task Typecan:supported Reference-to-Video, Video Editing, video
-🔊 defaultaudio:generate_audio not when defaulttrue
- 🇨🇳 localized example text:asBase URL: https://mm-internal-cn.leonecloud.com


Authentication

All endpoints require a token in the request header for authentication:

Authorization: Bearer {YOUR_AUTH_TOKEN}

Failurereturned when applicable HTTP 401:```json
{
"error": {
"code": "AuthenticationError",
"message": "API Key no",
"type": "Unauthorized"
}
}


---

## model Values

`model` as**Required**field, as:| model | Description |
|-------|------|
| `seedance-2-0` | localized example text|

localized example text`model` return HTTP 400 (`supported model: xxx`); not Model return HTTP 404 (`Model not: xxx`).

---

## Defaultand value range| field | Default | value range |
|------|--------|---------|
| `ratio` | `adaptive` | `adaptive` / `16:9` / `9:16` / `1:1` / `4:3` / `3:4` / `21:9` |
| `duration` | `5` | 4 ~ 15 seconds, or`-1` Duration ( token )|
| `resolution` | `720p` | `480p` / `720p` / `1080p` |
| `generate_audio` | `true` | `true` / `false` |
| `bitrate_mode` | If omitted (etc.`standard`) | `standard` / `high` |
| `watermark` | `false` | `true` / `false` |

**asset**:Limit`content` in the asset, Model; when task will Failure return Error.

### duration

`duration` value range 4 ~ 15 seconds, not when default`5` seconds.range`-1` return HTTP 400.

**Duration**:localized example text`duration: -1` Model in 4~ 15 secondsseconds.create when 15 seconds, task after, Duration can query endpoint`duration` fieldlocalized example text.

DurationRequirements as**token localized example text** (default).as Per-second billing,`-1` return HTTP 400 (`first as Per-second billing, supported Duration(duration=-1), seconds`)——Per-second billingseconds.

### resolution

supported`480p` / `720p` / `1080p`, default `720p`.

supported`480pto720p` Resolution: 480p after 720p, task return, 720p.as use Resolution, when will return HTTP 400 (`first only supported 480pto720p Resolution, will resolution as 480pto720p`).

---

## Supported Scenarios

### Scenario 1: Text-to-Video

```bash

curl -X POST "https://mm-internal-cn.leonecloud.com/api/v3/contents/generations/tasks" \
-H "Authorization: Bearer your_auth_token_here" \
-H "Content-Type: application/json" \
-d '{
"model": "seedance-2-0",
"content": [
{
"type": "text",
"text": ",,,, in, with"
}
],
"ratio": "16:9",
"duration": 5,
"resolution": "720p",
"generate_audio": true
}'


### Scenario 2: Image-to-Video (First Frame)

```bash

curl -X POST "https://mm-internal-cn.leonecloud.com/api/v3/contents/generations/tasks" \
-H "Authorization: Bearer your_auth_token_here" \
-H "Content-Type: application/json" \
-d '{
"model": "seedance-2-0",
"content": [
{
"type": "text",
"text": ",,,"
},
{
"type": "image_url",
"image_url": { "url": "https://example.com/portrait.jpg" },
"role": "first_frame"
}
],
"duration": 5,
"resolution": "720p"
}'


### Scenario 3: First/Last Frame to Video

first frame and last frame image, Model image video.first frame / last frame when output input asset,`ratio` localized example text.

```bash

curl -X POST "https://mm-internal-cn.leonecloud.com/api/v3/contents/generations/tasks" \
-H "Authorization: Bearer your_auth_token_here" \
-H "Content-Type: application/json" \
-d '{
"model": "seedance-2-0",
"content": [
{
"type": "text",
"text": "number images image number images image,, and,"
},
{
"type": "image_url",
"image_url": { "url": "https://example.com/frame_start.jpg" },
"role": "first_frame"
},
{
"type": "image_url",
"image_url": { "url": "https://example.com/frame_end.jpg" },
"role": "last_frame"
}
],
"duration": 5,
"resolution": "720p"
}'


### Scenario4:image Reference-to-Video

 in Prompt in"Image 1", "Image 2" (up to 9 images ).

```bash

curl -X POST "https://mm-internal-cn.leonecloud.com/api/v3/contents/generations/tasks" \
-H "Authorization: Bearer your_auth_token_here" \
-H "Content-Type: application/json" \
-d '{
"model": "seedance-2-0",
"content": [
{
"type": "text",
"text": "[Image 1]T and[Image 2], in[image3], video"
},
{ "type": "image_url", "image_url": { "url": "https://example.com/boy.png" }, "role": "reference_image" },
{ "type": "image_url", "image_url": { "url": "https://example.com/dog.png" }, "role": "reference_image" },
{ "type": "image_url", "image_url": { "url": "https://example.com/grass.png" }, "role": "reference_image" }
],
"ratio": "16:9",
"duration": 5,
"resolution": "720p"
}'


### Scenario5:Video Editing

`omni_reference_task_type=edit` mustlocalized example text`role=reference_video` Reference video, return HTTP 400.`ratio` / `duration`, will.

```bash

curl -X POST "https://mm-internal-cn.leonecloud.com/api/v3/contents/generations/tasks" \
-H "Authorization: Bearer your_auth_token_here" \
-H "Content-Type: application/json" \
-d '{
"model": "seedance-2-0",
"content": [
{ "type": "text", "text": "will Video 1 in the, as" },
{ "type": "video_url", "video_url": { "url": "https://example.com/house.mp4" }, "role": "reference_video" }
],
"omni_reference_task_type": "edit",
"duration": 5,
"resolution": "720p"
}'


### Scenario6:videolocalized example text`omni_reference_task_type=extend` mustReference video,`ratio` / `duration` localized example text.

```bash

curl -X POST "https://mm-internal-cn.leonecloud.com/api/v3/contents/generations/tasks" \
-H "Authorization: Bearer your_auth_token_here" \
-H "Content-Type: application/json" \
-d '{
"model": "seedance-2-0",
"content": [
{ "type": "text", "text": ",, as" },
{ "type": "video_url", "video_url": { "url": "https://example.com/clip.mp4" }, "role": "reference_video" }
],
"omni_reference_task_type": "extend",
"duration": 5,
"resolution": "720p"
}'


---

## Endpoint details

### 1. Create Task

**POST** `/api/v3/contents/generations/tasks`

**Content-Type**: `application/json`

#### Request Parameters

| Parameter | Type | Required | Description |
|-----|------|-----|------|
| model | string | Yes | localized example text`seedance-2-0` |
| content | array | Yes |,[content Items](#content-Content item) |
| omni_reference_task_type | string | No | Task Type:`auto` / `reference` / `edit` / `extend`.onlyParameter,`ratio` / `duration`, localized example text[Task Type](#Task Type-omni_reference_task_type) |
| ratio | string | No | Aspect ratio, default `adaptive` |
| duration | int | No | videoDuration (seconds), range 4 ~ 15, default `5`.localized example text`-1` as Duration, Modelseconds ( as token, default)|
| frames | int | No |,.⚠️ Model first Parameter, will return ParameterError; Duration`duration` |
| resolution | string | No | Output resolution:`480p` / `720p` / `1080p`, default `720p` |
| generate_audio | bool | No | audio, default`true` |
| bitrate_mode | string | No | Resolution output:`standard`(default, etc. If omitted) /`high`.`high` as,, file.return ParameterError|
| watermark | bool | No | watermark, default`false` |
| seed | int | No | random seed, localized example text.localized example text|
| camera_fixed | bool | No | Whether to fix the camera, localized example text.⚠️ Model first Parameter, will return ParameterError|
| return_last_frame | bool | No | return last-frame image|
| callback_url | string | No | Callback notification URL after the task is complete, Format[Callback Notification](#Callback Notification) |
| task_nickname | string | No | Task label for business tracking |
| real_person_mode | bool | No |, default`false` |
| priority | int | No |,|
| service_tier | string | No |,|
| execution_expires_after | int | No | taskexecute when (seconds),|
| safety_identifier | string | No |,|
| draft | bool | No |,|

> localized example text「localized example text」field,, as Model.

#### content Items

| Type | field | Description |
|-----|------|------|
| text | `type`: "text", `text`: "Prompt" | **must**, videoPrompt (3-20000characters)|
| image_url | `type`: "image_url", `image_url`: {"url": "URL"}, `role`: see below | Reference image (up to 9 images, supported jpeg/png/webp/bmp/tiff/gif, Aspect ratio 0.4-2.5, dimensions 300-6000px, maximum 30MB)|
| video_url | `type`: "video_url", `video_url`: {"url": "URL"}, `role`: "reference_video" | Reference video (up to 3, mp4/mov, 480p/720p, 2-15 seconds, maximum 200MB, 24-60FPS) |
| audio_url | `type`: "audio_url", `audio_url`: {"url": "URL"}, `role`: "reference_audio" | Reference audio (up to 3, wav/mp3, 2-15 seconds, maximum 15MB) |

content must`text` TypeContent item as Prompt, return HTTP 400 (`content in must text Type Prompt`); `content` as return 400 (`content as`).in Prompt in"Image 1", "Image 2", "Video 1", "Audio 1" Location reference asset.

> asset: in[Seedance asset](/docs/seedance-asset-library) create asset, Status as`Active` after, in`image_url.url` / `video_url.url` / `audio_url.url` in`asset://<asset Id>` can.

#### role Values for image_url

| role localized example text| Description |
|---------|------|
| `reference_image` | Reference image |
| `first_frame` | first-frame image |
| `last_frame` | last-frame image |

#### Response Parameters

create Success return HTTP 200:| Parameter | Type | Description |
|-----|------|------|
| id | string | Task ID, used to query task status |

#### Response Example

```json

{
"id": "task_20260817163906_i0ing18n"
}


create Failure return HTTP Status Code,[Error Codes](#Error Codes):

```json

{
"error": {
"code": "InvalidParameter",
"message": "supported model: seedance-9",
"type": "BadRequest"
}
}


---

### 2. Query Task Status

**GET** `/api/v3/contents/generations/tasks/{id}`

#### Path Parameters

| Parameter | Type | Required | Description |
|-----|------|-----|------|
| id | string | Yes | Task ID (create endpoint return`id`) |

#### Response Parameters

| Parameter | Type | Description |
|-----|------|------|
| id | string | Task ID |
| model | string | Create Taskwhen`model` localized example text|
| status | string | Task Status:`running` (queuedand in as`running`)/ `succeeded` / `failed` / `cancelled` (,「4. / task」) |
| content.video_url | string | video URL (`succeeded` returned when applicable) |
| content.last_frame_url | string | last frame image URL (Request`return_last_frame` with returned when applicable)|
| error.code | string | Error Codes (`failed` returned when applicable) |
| error.message | string | Error(`failed` returned when applicable) |
| created_at | int | Created Time (Unix seconds) |
| updated_at | int | Updated Time (Unix seconds) |
| usage.completion_tokens | int | token|
| usage.prompt_tokens | int | token|
| usage.total_tokens | int | token|

return field with`id` / `model` / `status` / `created_at` / `updated_at`.`duration` / `frames_per_second` / `generate_audio` / `ratio` / `resolution` / `service_tier` / `priority` / `output_format` / `draft` / `execution_expires_after` / `usage` / `content.last_frame_url` etc. fieldonly in with returned when applicable,「fieldcan in」Method.with data when return.

#### Response Example

**processing**
```json

{
"id": "task_20260817163906_i0ing18n",
"model": "seedance-2-0",
"status": "running",
"created_at": 1786955946,
"updated_at": 1786955950
}


**Success**
```json

{
"id": "task_20260817163906_i0ing18n",
"model": "seedance-2-0",
"status": "succeeded",
"content": {
"video_url": "https://example-oss.com/videos/2026/08/17/output.mp4"
},
"duration": 5,
"ratio": "16:9",
"resolution": "720p",
"output_format": "mp4",
"created_at": 1786955946,
"updated_at": 1786956142
}


**Failure**
```json

{
"id": "task_20260817163906_i0ing18n",
"model": "seedance-2-0",
"status": "failed",
"error": {
"code": "InternalServiceError",
"message": "Video GenerationFailure, localized example text"
},
"created_at": 1786955946,
"updated_at": 1786956060
}


**Task not found** (HTTP 404)
```json

{
"error": {
"code": "NotFound",
"message": "Task not found",
"type": "NotFound"
}
}


---

### 3. Query Tasklist

ConditionQuery Task, return task Status.

**GET** `/api/v3/contents/generations/tasks`

#### Query Parameter

| Parameter | Type | Required | Description |
|-----|------|-----|------|
| filter.task_ids | string[] | No | Task ID,, supported.Parameter:`filter.task_ids=id1&filter.task_ids=id2`.If omittedreturn first API Key tasklist|
| filter.status | string | No | Status:`queued` / `running` / `succeeded` / `failed` / `cancelled`, in`queued` and`running` processing.If omittedStatus ( not will return list)|
| page_num | int | No |, default`1`, range `[1, 500]`, localized example text|
| page_size | int | No |, default`20`, range `[1, 500]`, localized example text|

> query first API Key task, no query task.`filter.model` and`filter.service_tier` can Request, will.

#### Response Parameters

| Parameter | Type | Description |
|-----|------|------|
| items | array | tasklist, and「2. Query Task Status」exactly identical|
| total | int | Condition task|

#### Request Example

GET /api/v3/contents/generations/tasks?filter.status=succeeded&page_num=1&page_size=20
Authorization: Bearer {API_KEY}


#### Response Example

```json

{
"items": [
{
"id": "task_20260817163906_i0ing18n",
"model": "seedance-2-0",
"status": "succeeded",
"content": {
"video_url": "https://example-oss.com/videos/2026/08/17/output.mp4"
},
"duration": 5,
"resolution": "720p",
"created_at": 1786955946,
"updated_at": 1786956142
}
],
"total": 1
}


---

### 4. / task**DELETE** `/api/v3/contents/generations/tasks/{id}`

as task first Status, can:| Task Status | as| localized example text|
|---------|------|---------|
| queued | task, Status as`cancelled` | localized example text|
| in| no.task will Request ( return`running`):taskStatus when, complete; task return HTTP 409`TaskRunning` | Success when; complete|
| (`succeeded` / `failed` / `cancelled`) | task data, task as| ()|

task after supported, returned when applicable HTTP 400`CancelNotSupported`, taskcomplete and.

#### Path Parameters

| Parameter | Type | Required | Description |
|-----|------|-----|------|
| id | string | Yes | Task ID (create endpoint return`id`) |

#### Response Parameters

| Parameter | Type | Description |
|-----|------|------|
| id | string | Task ID |
| status | string | after Task Status:`cancelled`;`running` Request, after query results as;`succeeded` / `failed` tasklocalized example text|
| message | string | Description|

#### Request Example

```bash

curl -X DELETE "https://mm-internal-cn.leonecloud.com/api/v3/contents/generations/tasks/task_20260817163906_i0ing18n" \
-H "Authorization: Bearer {API_KEY}"


#### Response Example

queuedtaskSuccess:```json
{
 "id": "task_20260817163906_i0ing18n",
 "status": "cancelled",
 "message": "Task cancelled, localized example text"
}

in task (Request, can ):```json
{
"id": "task_20260817163906_i0ing18n",
"status": "running",
"message": "taskin no, as Request: will, taskStatus and; task complete, will, no"
}


taskSuccess ( return ):```json
{
 "id": "task_20260817163906_i0ing18n",
 "status": "succeeded",
 "message": "task data, task as"
}

Failurereturned when applicable error and HTTP Status Code (Error Codes):

HTTPerror.codeerror.messageDescription
404NotFoundTask not foundTask ID in or first API Key
400CancelNotSupportedtask supportedtaskwill complete and
409TaskFinishedtask, notaskcomplete, in, after query can; complete after can data
409TaskRunningtask, no, will complete andtaskin in, no
503ServiceUnavailabletaskin, aftertaskcreate, in, after can
503ServiceUnavailabletaskFailure, afterwhen Failure, not, can

Note-localized example text:taskUsually, when inid after, etc. PollingStatus after -in no:task -query results as:returnrunning when Query Task Status, ascancelled Success and, assucceeded task complete -localized example text:taskdata,; after video can,

---## Callback Notification

task complete (Success or Failure) when, if Create Task when providecallback_url, was provided when creating the task, the system sends a POST request to that URL.and query endpoint,.taskwhen will:status asfailed, errorMsg asTask cancelled.

Headers

Content-Type: application/json
X-Funcloud-Event: task.completed
X-Funcloud-Signature: {localized example text}

Body

{
 "event": "task.completed",
 "taskId": "task_20260817163906_i0ing18n",
 "status": "success",
 "result": ["https://example-oss.com/videos/output.mp4"],
 "errorMsg": "",
 "timestamp": "2026-08-17T16:42:22+08:00",
 "signature": "a1b2c3d4e5f6..."
}

Task Type (omni_reference_task_type)

Optional.Modelcontent in the asset Method, fieldParameter: willratio / duration, and Duration,duration.

localized example textDescriptionasset Requirements
autolocalized example textno
reference/ Reference image / last frame Videono
editVideo Editing:reference Video Generationmustlocalized example textrole=reference_video
extendvideolocalized example textmustlocalized example textrole=reference_video

edit / extend Reference video, or, return HTTP 400.


Error Codes

ErrorHTTP Status Code anderror return:```json
{
"error": {
"code": "InvalidParameter",
"message": "Errorlocalized example text",
"type": "BadRequest"
}
}


| HTTP | error.code | error.type | localized example text|
|------|-----------|-----------|-------------|
| 400 | `InvalidParameter` | `BadRequest` | `model as`, `supported model: xxx`, `content as`, `content in must text Type Prompt`, `duration onlysupported 4~15 secondsor -1(Duration)`, `first as Per-second billing, supported Duration(duration=-1), seconds`, `bitrateMode onlysupported standard / high` |
| 401 | `AuthenticationError` | `Unauthorized` | API Key invalid or missing |
| 402 | `InsufficientBalance` | `PaymentRequired` | Insufficient balance |
| 403 | `PermissionDenied` | `Forbidden` | no|
| 404 | `NotFound` | `NotFound` | Task not found; or`Model not: xxx` |
| 400 | `CancelNotSupported` | `BadRequest` | task:task supported|
| 409 | `TaskFinished` | `Conflict` | task:task, no|
| 409 | `TaskRunning` | `Conflict` | task:task, no|
| 500 | `InternalServiceError` | `InternalServerError` | Internal server error, can|
| 503 | `ServiceUnavailable` | `ServiceUnavailable` | task: when Failure, can|

recommendedHTTP Status Code ( can / Parameter / ),`error.code` localized example text.

with (Success and Failure)`X-Trace-Id`, Request.when provide and task`id`.

---

## Migrating from V2

| localized example text| V2 | V3 ()|
|------|----|-------------|
| create Path| ModelPath| localized example text`POST /api/v3/contents/generations/tasks`, Modellocalized example text`model` localized example text|
| query Path| V2 query endpoint| `GET /api/v3/contents/generations/tasks/{id}` |
| fieldlocalized example text| camelCase (`generateAudio`) | snake_case (`generate_audio`) |
| create| `{code, msg, data}` localized example text| localized example text`{"id": "..."}` |
| query| localized example text+ `data.output` localized example text| return task|
| Errorlocalized example text| Error Codes| HTTP Status Code+ `{"error": {...}}` |
| `ratio` Default | `16:9` | `adaptive` |
| V3 localized example text| — | `omni_reference_task_type`, listquery endpoint|

V2 endpointcan use, task and.fieldDescription[Seedance 2.0 V2 endpointlocalized example text](/docs/seedance-2-0-v2).

---

## Best Practices

### 1. Polling Strategy

- First 30 seconds:query every 3 seconds
- 30 seconds ~ 2 minutes:query every 5 seconds
- After 2 minutes:query every 10 seconds

### 2. Status Handling

localized example text`status`:`running` as processing (),`succeeded` localized example text`content.video_url`, `failed` localized example text`error.message`, `cancelled` Task cancelled,.

### 3. Prompt Tips

- Prompt:3~ 20,000 characters
- Prompt = subject+,+,+ - can (,, etc. )
-"Image 1", "Image 2", "Video 1", "Audio 1" content in Location reference asset 
- generated result when, 
- with when, recommended image Modelimage, Image-to-Video

---## FAQ

### Q1: can`frames` localized example text?

**A**: recommended.will`frames`, Model first Parameter, will return ParameterError.localized example text`duration` Duration.

### Q2: Why did `duration: -1` return an error?

**A**: Model supported Duration, Requirements as**token localized example text** (default).

return`first as Per-second billing, supported Duration(duration=-1)`, DescriptionPer-second billing——Per-second billingseconds, no Duration.when 4~ 15 seconds (If omitteddefault 5 seconds), or Billing Method.

in 4~ 15 range, range`-1` return HTTP 400.

### Q3: Why are fields like `duration` and `resolution` missing from the query response?

**A**: fieldonly in with returned when applicable, in with`id` / `model` / `status` / `created_at` / `updated_at`.localized example text「fieldcan in」Method.

### Q4: Will the `model` I send be rewritten?

**A**: will.query`model` Create Task when.

### Q5: Can I omit text inside content?

**A**: can.mustlocalized example text`text` TypeContent item as Prompt, Request (HTTP 400).

---

## Task ID 

Optional,.after with API Key, V3 endpoint, V2 endpoint.

| Item | not (default)| after|
|------|---------------|--------|
| create, query, list, endpoint return`id` | Task ID (`task_` )| Task ID (`cgt-20261104163907-xxxxx`), create endpointsee belowDescription|
| query, list, endpoint ID| Task ID| Task ID and Task ID can|
| video`content.video_url` | default return|, 24 hours after|
| query, listendpoint return`model` | Create Taskwhen`model` localized example text| ModelID:`doubao-seedance-2-0-260128` |
| frame rate field| `frames_per_second` | `frames_per_second` and`framespersecond` returned when applicable,|
| in the`taskId` | Task ID| Task ID ()|

**create endpoint return ID**

- not`real_person_mode` or`false`:create endpoint etc. task complete after return Task ID, up to etc. 30 seconds; when return Task ID, task execute.create endpoint when as 30 seconds.
- localized example text`real_person_mode: true`:create endpoint return Task ID, after query endpoint return Task ID.

ID task, can.recommendedquery endpoint return`id` as.

**Notelocalized example text**

- 24 hours after, in taskSuccess after and when.
- Task ID create task API Key query or, Key ( query return HTTP 404).

---

## Technical Support

If you have any questions, please contact our technical support team.
Updated 2026-11-18