> ## Documentation Index
> Fetch the complete documentation index at: https://docs.mixroute.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Doubao

> Doubao video generation parameters, supported values, input constraints, and request examples.

This page documents the `doubao-seedance-*` video routes. Doubao is the route/product prefix; Seedance is the video model family. Use the complete model ID rather than exchanging prefixes.

`POST https://api.mixroute.ai/v1/video/generations`

<Info>
  Keep `model`, `prompt`, and `asset` at the root. Put every provider field inside the single `metadata` object, including `content`, `duration`, `ratio`, `resolution`, and `generate_audio`.
</Info>

For the separate text/chat route, see [Dola-Seed-SC](/en/model-api/volcengine/dola-seed-sc). This page covers video generation.

## Model IDs

| Version           | MixRoute model ID                 |
| ----------------- | --------------------------------- |
| Seedance 2.5      | `doubao-seedance-2-5-260628`      |
| Seedance 2.0      | `doubao-seedance-2-0-260128`      |
| Seedance 2.0 Fast | `doubao-seedance-2-0-fast-260128` |
| Seedance 2.0 Mini | `doubao-seedance-2-0-mini-260615` |

Model availability is account-specific. Use the complete ID shown in the [Model Marketplace](https://console.mixroute.ai/models).

## Top-Level Fields

| Field      | Type    | Required    | Description                                                                                                      |
| ---------- | ------- | ----------- | ---------------------------------------------------------------------------------------------------------------- |
| `model`    | string  | Yes         | Complete MixRoute model ID from the model table.                                                                 |
| `prompt`   | string  | Yes         | MixRoute video prompt. If `metadata.content` includes a text item, keep both texts consistent.                   |
| `asset`    | boolean | Conditional | MixRoute media-processing switch, not a provider field. Keep it at the root; the text-only examples use `false`. |
| `metadata` | object  | Yes         | Container for the provider fields described below.                                                               |

## Generation Parameters

| Field                               | Type      | Required | Description                                                                                                                                                                                                                     |
| ----------------------------------- | --------- | -------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| `metadata.content`                  | object\[] | Yes      | Video inputs: text, images, video, and supported audio references. Pure text generation requires a text item; text is optional in provider media-input combinations.                                                            |
| `metadata.omni_reference_task_type` | string    | No       | Seedance 2.5 only. Default `auto`; values: `auto`, `reference`, `edit`, `extend`. Explicit modes enable early task-type validation. A mismatch between the declared mode and the inferred intent can still fail asynchronously. |
| `metadata.resolution`               | string    | No       | Output resolution tier. Supported values and defaults depend on the model version; see the version table. Values are case-sensitive.                                                                                            |
| `metadata.ratio`                    | string    | No       | Default `adaptive`. Values: `16:9`, `4:3`, `1:1`, `3:4`, `9:16`, `21:9`, `adaptive`. Scenario constraints are listed below.                                                                                                     |
| `metadata.duration`                 | integer   | No       | Requested duration in seconds; see the version table. `-1` selects the duration automatically on supported versions. Seedance 2.5 defaults to `-1`, and video editing requires `-1`.                                            |
| `metadata.generate_audio`           | boolean   | No       | Default `true`: generate synchronized mono audio, including speech, sound effects, or music. `false` produces a silent video.                                                                                                   |
| `metadata.watermark`                | boolean   | No       | Default `false`. `true` adds an AI-generated watermark in the lower-right corner; `false` omits it.                                                                                                                             |
| `metadata.output_format`            | string    | No       | Seedance 2.5 only. Default `mp4`; values: `mp4`, `mov`. MP4 is intended for general playback; MOV preserves higher color precision for post-production and requires compatible playback software.                               |
| `metadata.return_last_frame`        | boolean   | No       | Default `false`. `true` returns a watermark-free PNG of the final frame, with the same pixel dimensions as the generated video, in the task result.                                                                             |
| `metadata.callback_url`             | string    | No       | Task-status callback URL. The provider sends POST notifications with its task-query response structure. Statuses include `queued`, `running`, `succeeded`, `failed`, and `expired`.                                             |
| `metadata.execution_expires_after`  | integer   | No       | Range 3600-259200 seconds; default 172800 (48 hours), measured from task creation. A task that exceeds this threshold is terminated with status `expired`.                                                                      |
| `metadata.priority`                 | integer   | No       | 2.5 and 2.0 only. Range 0-9; default 0. Higher values move ahead of lower-priority queued tasks on the same endpoint. Equal priorities remain FIFO; running tasks are not interrupted. Not supported with `flex`.               |
| `metadata.safety_identifier`        | string    | No       | Stable, unique identifier for the end user, limited to 64 English characters. Use a hashed identifier instead of raw personal information.                                                                                      |
| `metadata.tools`                    | object\[] | No       | 2.5 and 2.0 only. Each tool requires `type`; the supported value is `web_search`. The model decides whether to search. The query result exposes the search count in `usage.tool_usage.web_search`.                              |

## Version Limits

| Version                  | Resolution                       | Default Resolution | Duration    | Reference Limits (Images / Videos / Audio) |
| ------------------------ | -------------------------------- | ------------------ | ----------- | ------------------------------------------ |
| Seedance 2.5             | `480p` / `720p` / `1080p`        | `720p`             | 4-30 s / -1 | 30 / 10 / 10                               |
| Seedance 2.0             | `480p` / `720p` / `1080p` / `4k` | `720p`             | 4-15 s / -1 | 9 / 3 / 3                                  |
| Seedance 2.0 Fast / Mini | `480p` / `720p`                  | `720p`             | 4-15 s / -1 | 9 / 3 / 3                                  |

The nested content fields and media size/format constraints are defined in [Seedance](/en/api-reference/endpoint/seedance).

## Scenario Constraints

* First-frame, first/last-frame, and multimodal reference workflows are mutually exclusive. Do not mix frame roles with `reference_*` roles.
* Seedance 2.5 requires `ratio="adaptive"` for first/last-frame input, editing, and extension. Editing requires at least one reference video lasting 4-30 seconds and `duration=-1`; extension requires a reference video. The optional `omni_reference_task_type` can explicitly select `edit` or `extend` instead of automatic classification.
* Seedance 2.0 audio references require at least one image or video reference. Seedance 2.5 also supports audio-only reference input.

## Examples

Set `MIXROUTE_API_KEY` before calling the API. Replace media placeholders with accessible inputs. Accepted requests create billable generation tasks; do not automatically resubmit after a submission timeout.

```bash theme={null}
curl --request POST "https://api.mixroute.ai/v1/video/generations" \
  --header "Authorization: Bearer $MIXROUTE_API_KEY" \
  --header "Content-Type: application/json" \
  --data '{
  "model": "doubao-seedance-2-5-260628",
  "prompt": "A red cube slowly rotates on a white background. Static camera.",
  "asset": false,
  "metadata": {
    "content": [
      {
        "type": "text",
        "text": "A red cube slowly rotates on a white background. Static camera."
      }
    ],
    "duration": 4,
    "ratio": "9:16",
    "resolution": "480p",
    "generate_audio": false
  }
}'
```

### Python

```python theme={null}
import json
import os
import requests

payload = json.loads(r'''
{
  "model": "doubao-seedance-2-5-260628",
  "prompt": "A red cube slowly rotates on a white background. Static camera.",
  "asset": false,
  "metadata": {
    "content": [
      {
        "type": "text",
        "text": "A red cube slowly rotates on a white background. Static camera."
      }
    ],
    "duration": 4,
    "ratio": "9:16",
    "resolution": "480p",
    "generate_audio": false
  }
}
''')
response = requests.post(
    "https://api.mixroute.ai/v1/video/generations",
    headers={"Authorization": "Bearer " + os.environ["MIXROUTE_API_KEY"]},
    json=payload,
    timeout=120,
)
response.raise_for_status()
result = response.json()
print(result)
```

## Task Results

Save the MixRoute task ID returned by submission and poll [Query Video Task](/en/api-reference/endpoint/query-video-task). A successful submission creates a task; read the result only after the task reaches a successful terminal state. Response envelopes and result locations vary by route.
