Seedance 2.0 API
ByteDance による Seedance 2.0 動画生成モデルの完全な API リファレンスです。
モデルバリアント {#}
この API は6つのモデルバリアントをサポートしています。
クイック比較
サポートされているアスペクト比
21:9, 16:9, 9:16, 1:1, 4:3, 3:4
解像度オプション
Seedance 2.0 Text to Video
エンドポイント
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 Image to Video
リクエストパラメータ
必須
オプション
リクエスト例
{
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 Reference to Video
リクエストパラメータ
必須
参照メディア
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) Reference-to-Video リクエスト例
{
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']
}
高速バリアント
高速バリアントは処理速度を優先します。すべての高速モデルは "480p" と "720p" の出力のみをサポートします。高速 Text-to-Video と高速 Image-to-Video は、それ以外について対応する標準リクエスト形式に従い、高速 Reference-to-Video は標準参照モデルと同じ参照メディア制限を使用します。
高速リクエスト例
{
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) 高速 Reference-to-Video リクエスト例
{
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 高速 Reference-to-Video パラメータ
必須
参照メディア
上記の 1 から始まるプレースホルダー規則は、高速 Reference-to-Video モデルにも適用されます。
オプション
レスポンス形式
初期レスポンス
すべてのモデルはポーリング用の 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": {
"videos": [
{
"url": "https://example.com/generated-video.mp4"
}
]
}
}
}
ステータス値
submitted: タスク送信済み、処理待ち
processing: 動画生成中
succeed: 動画生成完了
failed: 動画生成失敗
処理時間
標準モデル: 動画の長さと解像度によって3〜8分かかります。
高速モデル: ほとんどの設定で1〜4分です。
ステータスを確認するために5〜10秒ごとにポーリングしてください。
ベストプラクティス
- 適切なバリアントを選択する: 反復作業には高速モデル、最終出力には標準モデルを使用してください
- モーションを明確に記述する: プロンプトに具体的な動きの説明を含めてください
- 解像度の選択: より高速な処理には
480p、現在利用可能な最高品質には 720p を使用してください
- カメラコントロール: 静止カメラアングルが必要な場合は
camera_fixed: true を設定してください
- 参照動画: reference-to-video では、鮮明で高品質な参照動画を使用してください
- 再現性: 特定の生成結果を再現するには
seed パラメータを使用してください
- 音声強化: より没入感のある動画体験のために
sound を有効にしてください