メインコンテンツへスキップ
POST
/
v1
/
videos
curl https://api.cometapi.com/v1/videos \
  -H "Authorization: Bearer <COMETAPI_KEY>" \
  -F 'prompt="A slow cinematic camera push across a coastal landscape at sunrise"' \
  -F 'model="doubao-seedance-2-0-fast"' \
  -F 'seconds="5"' \
  -F 'size="16:9"' \
  -F 'resolution="720p"'
{
  "id": "task_abc123",
  "task_id": "task_abc123",
  "object": "video",
  "model": "doubao-seedance-2-0-fast",
  "status": "SUBMITTED",
  "progress": 0,
  "created_at": 1776681149
}
このエンドポイントを使用して、ByteDance Seedance の動画ジョブを開始します。すべての Seedance モデルティアは同じリクエスト形式を共有しており、model フィールドを設定してモデルを選択します。呼び出しは即座に task id を返し、レンダリングはバックグラウンドで継続されます。

モデルを選択する

Model idTierNotes
doubao-seedance-2-02.02.0 ファミリーの中で最も高品質な出力です。
doubao-seedance-2-0-fast2.0迅速な反復やプレビュー向けの 2.0 の高速バリアントです。
doubao-seedance-1-5-pro1.5 Pro1080p をサポートします。テキストから動画のみ対応です。
doubao-seedance-1-0-pro1.0 Pro1080p と 2 秒からの短いクリップをサポートします。テキストから動画のみ対応です。
利用状況については、Models page を参照してください。

パラメータ範囲

FieldTypeRequiredDefaultAllowed values
promptstringyes任意のテキスト
modelstringyesdoubao-seedance-2-0, doubao-seedance-2-0-fast, doubao-seedance-1-5-pro, doubao-seedance-1-0-pro
secondsintegerno5モデルに依存(以下を参照)
sizestringno16:921:9, 16:9, 4:3, 1:1, 3:4, 9:16
resolutionstringno720p2.0 モデルでは 480p, 720p、1.5 Pro と 1.0 Pro では 480p, 720p, 1080p
input_referencefilenoJPEG、PNG、または WebP。2.0 モデルでのみ受け付けられます。

モデルごとの再生時間範囲

Modelseconds range
doubao-seedance-2-0, doubao-seedance-2-0-fast4 ~ 15
doubao-seedance-1-5-pro4 ~ 12
doubao-seedance-1-0-pro2 ~ 10
モデルの範囲外の値を送信すると、HTTP 400 が返され、code: "InvalidParameter"duration に関するメッセージが含まれます。

画像から動画への対応

input_reference ファイルを受け付けるのは 2.0 モデルのみです。doubao-seedance-1-5-pro または doubao-seedance-1-0-proinput_reference を送信すると、the specified task_type r2v does not support model seedance-1-5-pro の形式のメッセージを含む HTTP 400 が返されます。これらのモデルはテキストから動画専用として使用してください。

参照画像をアップロードする

リクエスト本文は multipart/form-data です。2.0 モデルで画像から動画を実行するには、同じリクエスト内で画像を input_reference パートとして添付します。
curl https://api.cometapi.com/v1/videos \
  -H "Authorization: Bearer <COMETAPI_KEY>" \
  -F 'prompt="A slow cinematic camera push across a coastal landscape at sunrise."' \
  -F 'model="doubao-seedance-2-0"' \
  -F 'seconds="5"' \
  -F 'size="16:9"' \
  -F 'resolution="720p"' \
  -F 'input_reference=@/path/to/reference.jpg'
/path/to/reference.jpg は、最初のフレームのアンカーとして使用したい画像の絶対パスまたは相対パスに置き換えてください。対応フォーマットは JPEG、PNG、WebP です。

タスクの流れ

1

Submit the task

promptmodel を少なくとも含む POST リクエストを送信します。次のステップのために返された id を保存してください。
2

Poll the task

10 ~ 20 秒ごとに Seedance 動画を取得する を呼び出します。
3

Download the output

statusSUCCESS になったら、video_url のファイルをダウンロードし、長期的なアクセスが必要な場合は再ホストしてください。URL には署名が付いており、一定時間後に期限切れになります。

エラーレスポンス

このエンドポイントは、必須フィールドが欠けている場合、値が受け付け範囲外である場合、または画像から動画に対応していないモデルに input_reference を送信した場合に HTTP 400 を返します。Bearer トークンがない、または無効な場合は HTTP 401 を返します。エラー本文は 2 種類の形式のいずれかを使用します。正確なフィールドについては、playground の 400 および 401 の例を参照してください。

承認

Authorization
string
header
必須

Bearer token authentication. Use your CometAPI key.

ボディ

multipart/form-data
prompt
string
必須

Text prompt that describes the video. Required.

:

"A slow cinematic camera push across a coastal landscape at sunrise."

model
enum<string>
必須

Seedance model id. Choose doubao-seedance-2-0 for the highest quality 2.0 output, doubao-seedance-2-0-fast for quick iteration on 2.0, doubao-seedance-1-5-pro for the 1.5 Pro tier, or doubao-seedance-1-0-pro for the 1.0 Pro tier. Only the two 2.0 models accept input_reference.

利用可能なオプション:
doubao-seedance-2-0,
doubao-seedance-2-0-fast,
doubao-seedance-1-5-pro,
doubao-seedance-1-0-pro
:

"doubao-seedance-2-0-fast"

seconds
integer
デフォルト:5

Video duration in seconds. The accepted range depends on the model: doubao-seedance-2-0 and doubao-seedance-2-0-fast accept 4 to 15, doubao-seedance-1-5-pro accepts 4 to 12, and doubao-seedance-1-0-pro accepts 2 to 10. The default is 5 for every model.

必須範囲: 2 <= x <= 15
:

5

size
enum<string>
デフォルト:16:9

Output aspect ratio. All Seedance models accept the same set of values.

利用可能なオプション:
21:9,
16:9,
4:3,
1:1,
3:4,
9:16
:

"16:9"

resolution
enum<string>
デフォルト:720p

Output resolution. 480p and 720p are accepted by every model; 1080p is supported only by doubao-seedance-1-5-pro and doubao-seedance-1-0-pro.

利用可能なオプション:
480p,
720p,
1080p
:

"720p"

input_reference
file

Optional reference image. When included, the job runs in image-to-video mode and uses the image as the visual anchor. Only doubao-seedance-2-0 and doubao-seedance-2-0-fast accept this field; sending it with a 1.0 Pro or 1.5 Pro model returns HTTP 400.

レスポンス

Task created. Save the returned id and poll GET /v1/videos/{id}.

id
string
必須

Task id. Use it as the path parameter for GET /v1/videos/{id}.

object
string
必須

Object type, always video.

model
string
必須

Echo of the requested model id.

status
enum<string>
必須

Initial task status. A newly created task is returned as SUBMITTED.

利用可能なオプション:
SUBMITTED,
IN_PROGRESS,
SUCCESS,
FAILED,
ERROR
progress
integer
必須

Completion percentage. 0 at creation.

必須範囲: 0 <= x <= 100
created_at
integer
必須

Task creation time as a Unix timestamp in seconds.

task_id
string

Alias of id returned for compatibility. The value matches id.