提交任务
- 以 Seedance 原生结构提交异步视频任务
- 支持文生视频、图生视频、首尾帧与全模态参考
- 提交即返回任务 ID,用任务状态接口轮询
认证
所有接口均使用 Bearer Token 进行认证。
Seedance 系列的接口需要在 ark 站 单独获取 Key,与 api 站的 Key 不通用。
请求时在请求头中添加:
Authorization: Bearer YOUR_ARK_KEYAll endpoints authenticate with a Bearer token.
Seedance series endpoints require a key obtained separately from the ark site; it isn't shared with the api site's key.
Add it to the request header:
Authorization: Bearer YOUR_ARK_KEY请求结构
content 放在顶层,不放在 metadata 里。prompt 可在顶层,也可作为 content 中的 text 条目。时长字段是整数类型的 duration。其余参数(ratio、resolution、watermark 等)在顶层。
content sits at the top level, not inside metadata. prompt can be at the top level or as a text entry inside content. The duration field is the integer duration. Other parameters (ratio, resolution, watermark, etc.) are at the top level.
支持的场景
| 场景 | content 条目 |
|---|---|
| 文生视频 | text |
| 图生视频·首帧 | text + image_url,role 为 first_frame |
| 图生视频·首尾帧 | text + 两个 image_url,role 分别为 first_frame、last_frame |
| 全模态参考 | text + 任意组合的 image_url、video_url、audio_url |
| 编辑视频 | 引用 @视频1 的 text + video_url,并设 omni_reference_task_type: edit |
| 延长视频 | 引用 @视频1 的 text + video_url,并设 omni_reference_task_type: extend |
素材引用:每个引用既可以是 HTTP(S) URL,也可以是 Base64 data URI,例如 data:image/png;base64,...,格式标识需小写。
网关对 Base64 素材有两种处理:渠道配置了图床时,会先把 Base64 转存为 URL 再上送上游(便于走真人过白);未配置图床则原样转发。单渠道可以覆盖这个行为,设为跟随全局、始终转存或从不转存。
| Scenario | Content entries |
|---|---|
| Text to video | text |
| Image to video, first frame | text + image_url with role first_frame |
| Image to video, first and last frame | text + two image_url entries, with roles first_frame and last_frame |
| All-modality reference | text + any combination of image_url, video_url, audio_url |
| Video editing | text referencing @video1 + video_url, with omni_reference_task_type: edit |
| Video extension | text referencing @video1 + video_url, with omni_reference_task_type: extend |
Asset references: each reference can be an HTTP(S) URL or a Base64 data URI such as data:image/png;base64,...; the format tag must be lowercase.
The gateway handles Base64 assets two ways: when the channel has image hosting configured, it converts Base64 to a URL before sending upstream (which helps with real-person clearance); otherwise it forwards as-is. A single channel can override this behavior — follow the global setting, always convert, or never convert.
请求参数
取值:seedance-2.5、seedance-2.0、seedance-2.0-fast、seedance-2.0-mini。
内容数组。至少包含一个 text 条目或一条素材引用。
取值 text、image_url、video_url、audio_url。
type 为 text 时使用,写提示词。
图片地址,支持 HTTP(S) 与 Base64 data URI。
视频地址,按视频输入计费。
音频地址。
取值 first_frame、last_frame、reference_image、reference_video、reference_audio。首帧、首尾帧、全模态参考三类互斥,不能混用。
会被 content 里的 text 条目覆盖。
时长,单位秒。传 -1 由模型决定。2-5 最长 30 秒,其余 2.x 最长 15 秒。
取值 adaptive、16:9、9:16、1:1、4:3、3:4。
取值 480p、720p、1080p、4k。2-5 支持到 1080p,2-0 支持 4K,fast 与 mini 仅 480p 与 720p。
随机种子,范围 0 到 2147483647。
是否加水印,默认 false。
固定镜头,默认 false。
是否同时生成音频,默认 false。
是否返回末帧图片,默认 false。
草稿模式,默认 false。先用低成本出片看构图,确认后再正式生成。
取值 reference、edit、extend。仅 2-5 使用,不传则由模型推断。
取值 mp4(默认)或 mov。
影响优先级,示例值 default。
按方舟格式接收完成回调。
One of: seedance-2.5, seedance-2.0, seedance-2.0-fast, seedance-2.0-mini.
The content array. Must contain at least one text entry or one asset reference.
One of text, image_url, video_url, audio_url.
Used when type is text; holds the prompt.
The image URL; supports HTTP(S) and Base64 data URIs.
The video URL; billed as video input.
The audio URL.
One of first_frame, last_frame, reference_image, reference_video, reference_audio. First-frame, first-and-last-frame, and all-modality reference are mutually exclusive and can't be mixed.
Overridden by a text entry inside content.
Duration in seconds. -1 lets the model decide. 2-5 allows up to 30 seconds; the rest of the 2.x line up to 15.
adaptive, 16:9, 9:16, 1:1, 4:3, or 3:4.
480p, 720p, 1080p, or 4k. 2-5 supports up to 1080p, 2-0 supports 4K, and fast and mini support only 480p and 720p.
Random seed, 0 to 2147483647.
Whether to add a watermark; defaults to false.
Fixed camera; defaults to false.
Whether to generate audio alongside; defaults to false.
Whether to return the last-frame image; defaults to false.
Draft mode; defaults to false. Render cheaply first to check the composition, then generate for real.
reference, edit, or extend. Used only by 2-5; when omitted, the model infers it.
mp4 (default) or mov.
Affects priority; an example value is default.
Receives completion callbacks in the Ark format.
响应
任务 ID。
实际使用的模型。
取值 pending、processing、succeeded、failed。
成功时返回的成片地址。
本次实际使用的种子。
输出分辨率。
实际输出秒数。
输出画幅比例。
输出帧率。
实际生效的服务档位。
上游返回时才有。
上游返回时才有。
失败时返回,如 content_policy_violation。
失败时的错误描述。
创建时间,Unix 秒。
状态更新时间,Unix 秒。
The task ID.
The model actually used.
One of pending, processing, succeeded, failed.
The finished video URL, returned on success.
The seed actually used.
The output resolution.
The actual output length in seconds.
The output aspect ratio.
The output frame rate.
The service tier actually in effect.
Present only when the upstream returns it.
Present only when the upstream returns it.
Returned on failure, e.g. content_policy_violation.
The error description on failure.
Creation time, in Unix seconds.
Status update time, in Unix seconds.
错误码
| HTTP | 含义 |
|---|---|
| 400 | 参数错误,type 为 invalid_request_error |
| 401 | Token 缺失或无效,type 为 authentication_error |
| 402 | 余额不足,type 为 permission_error |
| 429 | 触发限流 |
| HTTP | Meaning |
|---|---|
| 400 | Invalid parameters, with type invalid_request_error |
| 401 | Token missing or invalid, with type authentication_error |
| 402 | Insufficient balance, with type permission_error |
| 429 | Rate limit hit |
For more status codes and retry guidance see Error codes and rate limits; for troubleshooting steps on common errors see the FAQ.
支持的模型列表
以下视频模型均可通过本接口提交任务,清单只列各厂商最新一代,实际可用范围以你的账号分组为准:
Seedance 系列
seedance-2.5旗舰,支持音画同步seedance-2.0上一代主力seedance-2.0-fast快速版seedance-2.0-mini轻量,成本最低 等
更多模型持续更新中…
各型号的能力差异:
| 项目 | 2.0 家族 | 2.5 |
|---|---|---|
| 最长时长 | 15 秒 | 30 秒 |
| 分辨率 | 480p / 720p / 1080p / 4k | 480p / 720p / 1080p |
2.0 家族里 fast 与 mini 只支持 480p 与 720p,4K 仅 2.0 标准版可用。
GET https://ark.oairoute.com/api/pricing。Every video model below can be submitted through this endpoint; the list shows only each vendor's latest generation, and what your account group actually allows takes precedence:
Seedance 系列
seedance-2.5旗舰,支持音画同步seedance-2.0上一代主力seedance-2.0-fast快速版seedance-2.0-mini轻量,成本最低 等
更多模型持续更新中…
Differences between model families:
| Item | 2.0 family | 2.5 |
|---|---|---|
| Max duration | 15 s | 30 s |
| Resolution | 480p / 720p / 1080p / 4k | 480p / 720p / 1080p |
Within the 2.0 family, fast and mini support only 480p and 720p; 4K is available only on the 2.0 standard model.
GET https://ark.oairoute.com/api/pricing.使用示例
文生视频
豆包原生通道用 content 数组描述输入:文本和图片都是 content 条目。提交后返回 task_id,再用任务状态接口轮询。
图生视频
把首帧图作为 content 条目传进去,role 标为 first_frame,模型会以这张图起手生成。
首尾帧过渡
同时给首帧和尾帧,模型生成中间的过渡过程。两帧风格差异越大,中间的运动幅度越明显。
参考视频
传 video_url 可以按参考视频的运镜和节奏生成新内容,适合批量做同风格素材。
Text to video
The Doubao native channel describes input with a content array: both text and images are content entries. Submission returns a task_id; poll the task status endpoint from there.
Image to video
Pass the first-frame image as a content entry with role set to first_frame, and the model starts from that image.
First-and-last-frame transition
Provide both the first and last frames and the model generates the transition between them. The larger the style difference between the two frames, the more pronounced the motion in between.
Reference video
Passing a video_url lets the model generate new content following the reference video's camera work and rhythm — handy for producing batches in one style.