豆包 seedance 视频模型
- 2026.09.21 本站支持视频模型
- 官网文档: https://docs.volcengine.com/docs/ark/create-video-generation-task-api
doubao seedance API
- 2026.09.21 本站支持视频模型
- 官网文档: https://docs.volcengine.com/docs/ark/create-video-generation-task-api
- 提交官网的
baseurl为的https://ark.cn-beijing.volces.com修改为https://api.openai-hk.com/doubao
1. 创建任务
post https://api.openai-hk.com/doubao/api/v3/contents/generations/tasks
shell
curl --request POST \
--url https://api.openai-hk.com/doubao/api/v3/contents/generations/tasks \
--header 'Authorization: Bearer hk-your-key' \
--header 'Content-Type: application/json' \
--data '{
"model": "doubao-seedance-2-0-mini-260615",
"content": [
{
"type": "text",
"text": "明亮多彩的广告片风格,果味饼干为主角,包含草莓、苹果、葡萄、橙子四种口味,草莓味参考@图像1,饼干与对应水果以强秩序感的几何阵列排布,整体画面干净、高级、节奏强。开场水果快速建立视觉聚焦,参考@视频1的构图,音乐重拍切入。随后不同口味饼干整齐排列,切特写,参考@视频2的动态和运镜。随后迅速回到快节奏剪辑。结尾英文文字 Design by OpenHK 快速分词切换入画,配合强节奏文字运动与产品定格。"
},
{
"type": "image_url",
"image_url": {
"url": "https://arkdocs.tos-cn-beijing.volces.com/images/video-generation/seedance2.5_reference1.png"
},
"role": "reference_image"
},
{
"type": "video_url",
"video_url": {
"url": "https://arkdocs.tos-cn-beijing.volces.com/videos/video-generation/seedance2.5_reference2.mp4"
},
"role": "reference_video"
},
{
"type": "video_url",
"video_url": {
"url": "https://arkdocs.tos-cn-beijing.volces.com/videos/video-generation/seedance2.5_reference3.mp4"
},
"role": "reference_video"
}
],
"generate_audio": true,
"ratio": "16:9",
"duration": 15,
"resolution": "480p",
"omni_reference_task_type": "reference"
}'curl --request POST \
--url https://api.openai-hk.com/doubao/api/v3/contents/generations/tasks \
--header 'Authorization: Bearer hk-your-key' \
--header 'Content-Type: application/json' \
--data '{
"model": "doubao-seedance-2-0-mini-260615",
"content": [
{
"type": "text",
"text": "明亮多彩的广告片风格,果味饼干为主角,包含草莓、苹果、葡萄、橙子四种口味,草莓味参考@图像1,饼干与对应水果以强秩序感的几何阵列排布,整体画面干净、高级、节奏强。开场水果快速建立视觉聚焦,参考@视频1的构图,音乐重拍切入。随后不同口味饼干整齐排列,切特写,参考@视频2的动态和运镜。随后迅速回到快节奏剪辑。结尾英文文字 Design by OpenHK 快速分词切换入画,配合强节奏文字运动与产品定格。"
},
{
"type": "image_url",
"image_url": {
"url": "https://arkdocs.tos-cn-beijing.volces.com/images/video-generation/seedance2.5_reference1.png"
},
"role": "reference_image"
},
{
"type": "video_url",
"video_url": {
"url": "https://arkdocs.tos-cn-beijing.volces.com/videos/video-generation/seedance2.5_reference2.mp4"
},
"role": "reference_video"
},
{
"type": "video_url",
"video_url": {
"url": "https://arkdocs.tos-cn-beijing.volces.com/videos/video-generation/seedance2.5_reference3.mp4"
},
"role": "reference_video"
}
],
"generate_audio": true,
"ratio": "16:9",
"duration": 15,
"resolution": "480p",
"omni_reference_task_type": "reference"
}'- 返回得到的 task_id
json
{
"id": "task_6esMYNTJqw6h763PeafCp8N92fVY9Jic"
}{
"id": "task_6esMYNTJqw6h763PeafCp8N92fVY9Jic"
}2.请求体主要参数说明
| 字段 | 必填 | 说明 |
|---|---|---|
model | 是 | 上表中的模型名 |
content | 是 | 提示词 + 参考素材数组,见下 |
duration | 否 | 时长(秒) |
resolution | 否 | 分辨率,如 480p / 720p |
ratio | 否 | 画幅,如 16:9(别名 aspect_ratio) |
generate_audio | 否 | 是否生成音频 |
content 数组元素:
type | 取素材的字段 | role | 说明 |
|---|---|---|---|
text | text | — | 提示词。取第一条非空 text |
image_url | image_url.url | reference_image(默认) | 参考图,对应 @Image1、@Image2… |
image_url | image_url.url | first_frame / last_frame | 首帧 / 尾帧图,不参与 @ImageN 编号 |
video_url | video_url.url | reference_video | 参考视频,对应 @Video1、@Video2… |
audio_url | audio_url.url | reference_audio | 参考音频 |
编号规则:顺序就是语义。
@Image1永远是数组里的第一张参考图,@Video1是 第一段参考视频——按 role 分别从 1 开始数。搞错顺序不会报错,只会渲染出一个和你描述 不一样的视频,并照常计费。
3. 查询任务
get https://api.openai-hk.com/doubao/api/v3/contents/generations/tasks/{taskId}
shell
curl --request GET \
--url https://api.openai-hk.com/doubao/api/v3/contents/generations/tasks/task_6esMYNTJqw6h763PeafCp8N92fVY9Jic \
--header 'Authorization: Bearer hk-your-key' \
--header 'Content-Type: application/json'curl --request GET \
--url https://api.openai-hk.com/doubao/api/v3/contents/generations/tasks/task_6esMYNTJqw6h763PeafCp8N92fVY9Jic \
--header 'Authorization: Bearer hk-your-key' \
--header 'Content-Type: application/json'- 返回得到.正确结果
json
{
"content": {
"video_url": "https://ark-acg-cn-beijing.tos-cn-beijing.volces.com/doubao-seedance-2-0-mini/02178996062422000000000000000000000ffffac1446bb35c08d.mp4?X-Tos-Algorithm=TOS4-HMAC-SHA256&X-Tos-Credential=AKLTYWJkZTExNjA1ZDUyNDc3YzhjNTM5OGIyNjBhNDcyOTQ%2F20260921%2Fcn-beijing%2Ftos%2Frequest&X-Tos-Date=20260921T031836Z&X-Tos-Expires=86400&X-Tos-Signature=601f68beb9da380599efea3817ce91612be94beabb085848281fa1ba9047b66c&X-Tos-SignedHeaders=host"
},
"created_at": 1789960624,
"draft": false,
"duration": 4,
"execution_expires_after": 172800,
"framespersecond": 24,
"generate_audio": true,
"id": "task_6esMYNTJqw6h763PeafCp8N92fVY9Jic",
"model": "doubao-seedance-2-0-mini-260615-max",
"origin_id": "cgt-20260921111703-hsk6d",
"output_format": "mp4",
"priority": 0,
"ratio": "16:9",
"resolution": "480p",
"seed": 47550,
"service_tier": "default",
"status": "succeeded",
"updated_at": 1789960725,
"usage": {
"completion_tokens": 40594,
"total_tokens": 40594
}
}{
"content": {
"video_url": "https://ark-acg-cn-beijing.tos-cn-beijing.volces.com/doubao-seedance-2-0-mini/02178996062422000000000000000000000ffffac1446bb35c08d.mp4?X-Tos-Algorithm=TOS4-HMAC-SHA256&X-Tos-Credential=AKLTYWJkZTExNjA1ZDUyNDc3YzhjNTM5OGIyNjBhNDcyOTQ%2F20260921%2Fcn-beijing%2Ftos%2Frequest&X-Tos-Date=20260921T031836Z&X-Tos-Expires=86400&X-Tos-Signature=601f68beb9da380599efea3817ce91612be94beabb085848281fa1ba9047b66c&X-Tos-SignedHeaders=host"
},
"created_at": 1789960624,
"draft": false,
"duration": 4,
"execution_expires_after": 172800,
"framespersecond": 24,
"generate_audio": true,
"id": "task_6esMYNTJqw6h763PeafCp8N92fVY9Jic",
"model": "doubao-seedance-2-0-mini-260615-max",
"origin_id": "cgt-20260921111703-hsk6d",
"output_format": "mp4",
"priority": 0,
"ratio": "16:9",
"resolution": "480p",
"seed": 47550,
"service_tier": "default",
"status": "succeeded",
"updated_at": 1789960725,
"usage": {
"completion_tokens": 40594,
"total_tokens": 40594
}
}- 返回得到.错误结果
json
{
"error": {
"code": "invalid_request",
"message": "Upstream submit failed (400): {\"code\":\"fail_to_fetch_task\",\"message\":\"{\\\"error\\\":{\\\"code\\\":\\\"InvalidParameter\\\",\\\"message\\\":\\\"The parameter `output_format` specified in the request is not valid: the specified model does not support this output_format"
},
"id": "task_6CyBKW7HUIRQGEB45CQ8r1a0gQwugHDF",
"model": "doubao-seedance-2-0-mini-260615-max",
"status": "failed"
}{
"error": {
"code": "invalid_request",
"message": "Upstream submit failed (400): {\"code\":\"fail_to_fetch_task\",\"message\":\"{\\\"error\\\":{\\\"code\\\":\\\"InvalidParameter\\\",\\\"message\\\":\\\"The parameter `output_format` specified in the request is not valid: the specified model does not support this output_format"
},
"id": "task_6CyBKW7HUIRQGEB45CQ8r1a0gQwugHDF",
"model": "doubao-seedance-2-0-mini-260615-max",
"status": "failed"
}4.返回结果参数说明
| Field | Type | Description |
|---|---|---|
| id | string | task_id |
| model | string | model name |
| content.video_url | string | Video URL 结果视频 |
| usage | object | 用量信息 使用这个来计费 |
| status | string | Status: queued running succeeded failed |
| error | string | 错误信息 |
计费
- 根据
usage.total_tokens计费 - 价格会涉及
是否含有参考视频、resolution模型 - 价格单位 price:人民币/百万 token
- 价格计算公式:usage.total_tokens*price
- 含视频单价<不含视频,但是含视频的
usage.total_tokens更高,总价含视频的更高
| 模型 | 含视频 | 不含视频 |
|---|---|---|
| doubao-seedance-2-0-mini-260615 所有分辨率 | 14 | 23 |
| doubao-seedance-2-0-fast-260128 所有分辨率 | 22 | 37 |
| doubao-seedance-2-0-260128 480P/720P | 28 | 46 |
| doubao-seedance-2-0-260128 1080P | 31 | 51 |
| doubao-seedance-2-0-260128 4K | 16 | 26 |
| doubao-seedance-2-5-260628 480P/720P | 42 | 70 |
| doubao-seedance-2-5-260628 1080P | 46 | 77 |
计费规则
- 本站计费规则:当提交任务时会先预扣
10万积分,任务完成后再按实际消耗积分多退少补 - 比如:提交任务先预扣
10万积分,完成后实际积分是3万积分,那么退回7万积分
OpenAi-HK