生成タスクを作成
入力を検証し、クレジットを差し引き、タスクを作成して taskId を返します。
ペイロードパラメータ
- 必須。sora-2-text-to-video、sora-2-image-to-video、sora-2-pro-text-to-video、sora-2-pro-image-to-video、sora-2-pro-storyboard のいずれか。
- 条件付き。sora-2-pro-storyboard 以外のすべてのモデルで必須。
- 条件付き。data:image/png;base64,... のような Base64 データ URL。imageUrl がない場合、image-to-video で必須。
- 条件付き。imageData が提供されていない場合に使用される公開画像 URL。
- オプション。portrait または landscape。デフォルト: landscape。
- オプション。10、15、または 25(ストーリーボードのみ)。デフォルトはモデルによって異なります。
- オプション。standard または high。Pro テキスト/画像モデルのみ。
- オプション。非ストーリーボードモデルのウォーターマークを削除。デフォルト: true。
- 条件付き。sora-2-pro-storyboard で必須。'{ Scene, duration }' の配列。
注意事項
- 両方が提供された場合、imageData が imageUrl より優先されます。
- prompt はストーリーボードではオプションで、プロバイダーには送信されません。コンテンツには shots を使用してください。
- nFrames はモデルごとの許可値に正規化されます。
- removeWatermark は非ストーリーボードモデルではデフォルトで true です。
- shots には Scene(大文字の S)と duration > 0 を含める必要があります。
リクエスト例
curl -X POST https://freesoragenerator.com/api/v1/video/sora-pro \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "sora-2-pro-text-to-video",
"prompt": "A cinematic shot of a futuristic city at sunset.",
"aspectRatio": "landscape",
"nFrames": "10",
"size": "high",
"removeWatermark": true
}'curl -X POST https://freesoragenerator.com/api/v1/video/sora-pro \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "sora-2-image-to-video",
"prompt": "Turn this image into a dynamic 10s clip.",
"imageUrl": "https://example.com/reference.png",
"aspectRatio": "portrait",
"nFrames": "10"
}'curl -X POST https://freesoragenerator.com/api/v1/video/sora-pro \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "sora-2-pro-storyboard",
"shots": [
{ "Scene": "Establishing shot of a city skyline at dusk", "duration": 5 },
{ "Scene": "Close-up of a runner splashing through puddles", "duration": 5 }
],
"aspectRatio": "landscape",
"nFrames": "10"
}'レスポンス例
{
"code": 0,
"message": "ok",
"data": {
"taskId": "281e5b0*********************f39b9"
}
}