ByteDance の Seedance 2.0 動画生成モデルの完全な API リファレンスです。
モデルの種類
この API は 6 種類のモデルに対応しています。
比較一覧
対応アスペクト比
21:9, 16:9, 9:16, 1:1, 4:3, 3:4
解像度の選択肢
Seedance 2.0 テキストから動画
エンドポイント {#}
POST /api/v1/video/task
リクエストパラメータ
必須
任意
リクエスト例
const response = await fetch('https://api.flaq.ai/api/v1/video/task', {
method: 'POST',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
},
body: JSON.stringify({
model_name: 'seedance-v2.0-text-to-video',
prompt: 'A golden retriever running through a sunlit meadow',
duration: 6,
resolution: '720p',
aspect_ratio: '16:9'
})
});
const { data } = await response.json();
const taskId = data.task_id;
Seedance 2.0 画像から動画
リクエストパラメータ
必須
任意
リクエスト例
{
model_name: 'seedance-v2.0-image-to-video',
image_url: 'https://example.com/image.jpg',
image_end_url: 'https://example.com/end-frame.jpg',
prompt: 'Camera slowly pulls back to reveal the full landscape',
duration: 6,
resolution: '720p',
aspect_ratio: '16:9'
}
Seedance 2.0 参照素材から動画
リクエストパラメータ
必須
参照素材
画像を 1-9 枚送信します。少なくとも 1 本の参照動画を提供する場合に限り、画像を省略できます。
@(AT)参照プレースホルダー
@(AT)参照機能は、番号付きの <<<...>>> プレースホルダーで参照素材とプロンプトを結び付けます。番号は素材の種類ごとに 1 から始まり、対応する配列の順序に従います。
たとえば、1 枚目の画像がキャラクター、2 枚目がシーンの参照画像の場合、prompt 内でキャラクターに <<<image_1>>>、シーンに <<<image_2>>> を使用します。各プレースホルダーは、対応する配列に存在する項目を指す必要があります。
任意
リクエスト例
{
model_name: 'seedance-v2.0-reference-to-video',
prompt: 'Use image one for the subject, video one for the movement, and audio one for the atmosphere',
duration: 8,
resolution: '1080p',
aspect_ratio: '16:9',
sound: true,
images: ['https://example.com/subject-reference.jpg'],
videos: ['https://example.com/motion-reference.mp4'],
audios: ['https://example.com/atmosphere-reference.mp3']
}
@(AT)参照素材から動画のリクエスト例
{
model_name: 'seedance-v2.0-reference-to-video',
prompt: 'Place the explorer from <<<image_1>>> in the environment from <<<image_2>>>, following the camera movement in <<<video_1>>> and speaking with the reference voice from <<<audio_1>>>',
duration: 8,
resolution: '1080p',
aspect_ratio: '16:9',
sound: true,
images: [
'https://example.com/explorer-reference.jpg',
'https://example.com/environment-reference.jpg'
],
videos: ['https://example.com/camera-movement-reference.mp4'],
audios: ['https://example.com/voice-reference.mp3']
}
Fast バージョン
Fast バージョンは処理速度を優先します。すべての Fast モデルの出力は "480p" と "720p" のみに対応しています。Fast のテキストから動画および画像から動画のその他のリクエスト構造は、それぞれ対応する標準モデルと同じです。Fast の参照素材から動画は標準の参照モデルと同じ素材制限を使用します。
Fast リクエスト例
{
model_name: 'seedance-v2.0-fast-reference-to-video',
prompt: 'Use image one for the subject, follow the movement from video one, and use audio one for the atmosphere',
duration: 8,
resolution: '720p',
aspect_ratio: '9:16',
sound: true,
images: ['https://example.com/subject-reference.jpg'],
videos: ['https://example.com/motion-reference.mp4'],
audios: ['https://example.com/atmosphere-reference.mp3']
}
@(AT)Fast 参照素材から動画のリクエスト例
{
model_name: 'seedance-v2.0-fast-reference-to-video',
prompt: 'Have the dancer from <<<image_1>>> perform the movement from <<<video_1>>> on the stage in <<<image_2>>>, using the rhythm from <<<audio_1>>>',
duration: 8,
resolution: '720p',
aspect_ratio: '9:16',
sound: true,
images: [
'https://example.com/dancer-reference.jpg',
'https://example.com/stage-reference.jpg'
],
videos: ['https://example.com/dance-movement-reference.mp4'],
audios: ['https://example.com/rhythm-reference.mp3']
}
Seedance 2.0 Fast 参照素材から動画のパラメータ
必須
参照素材
上記の 1 から始まるプレースホルダー規則は、Fast 参照素材から動画モデルにも適用されます。
任意
素材の制限
これらの制限は、このページのモデルの開始フレーム画像、終了フレーム画像、参照素材に適用されます。
参照音声と参照動画には、それぞれ個別に合計 15 秒の上限があります。件数は独立しており、画像は最大 9 枚、動画は 3 本、音声は 3 件です。動画を追加しても、画像の上限は減りません。
すべてのモデルのデフォルトは 720p ですが、resolution の指定は必須です。音声スイッチのデフォルトは true で、このスイッチも参照音声も料金には影響しません。参照素材から動画には少なくとも画像 1 枚または動画 1 本が必要で、音声のみのリクエストには対応していません。参照動画をアップロードすると、本数や長さに関係なく生成料金が 2 倍になります。
レスポンス形式
初期レスポンス
すべてのモデルはポーリング用の task_id を返します。
{
"code": 0,
"message": "success",
"data": {
"task_id": "{task_id}",
"response_url": "https://api.flaq.ai/api/v1/video/{task_id}",
"task_status": "submitted"
}
}
ポーリングレスポンス
GET /api/v1/video/{taskId} をポーリングしてステータスを確認します。
{
"code": 0,
"message": "success",
"data": {
"task_id": "{task_id}",
"response_url": "https://api.flaq.ai/api/v1/video/{task_id}",
"task_status": "succeed",
"task_status_msg": null,
"task_result": {
"credit": 0.2,
"videos": [
{
"url": "https://example.com/generated-video.mp4"
}
]
}
}
}
ステータス値
submitted:タスクを受け付け、処理待ち
processing:動画を生成中
succeed:動画生成完了
failed:動画生成失敗
処理時間
標準モデル:長さと解像度に応じて 3-8 分。
Fast モデル:ほとんどの設定で 1-4 分。
5-10 秒ごとにポーリングしてステータスを確認してください。
ベストプラクティス
- 適切なモデルを選択:試行には Fast モデル、最終出力には標準モデルを使用します
- 動きを明確に記述:プロンプトに具体的な動きの説明を含めます
- 解像度の選択:すべての標準 Seedance 2.0 モデルは
480p、720p、1080p、4k に対応し、すべての Fast モデルは 480p と 720p のみに対応します
- 参照素材の順序:
images、videos、audios を意図した順序に並べ、プロンプト内で一貫して参照します
- 動画のみのリクエスト:少なくとも 1 本の参照動画を提供する場合に限り、空の
images 配列を使用します
- 素材の長さ:各参照音声と動画を 2-15 秒に収めます
- 音声の活用:
sound を省略するとデフォルトの true が使われます。音声生成を無効にするには false に設定します