Image-to-Video API

1 枚または 2 枚の画像を動画に変換します。動作は渡す画像枚数によって決まります。

  • 1 枚最初フレームモード。画像が動画の最初のフレームとなり、モデルがそこから前進する動きを生成します。
  • 2 枚最初・最後フレームモード。1 枚目が動画の冒頭、2 枚目が末尾となり、モデルがその間のトランジションアニメーションを生成します。

エンドポイント

POST https://api.evolink.ai/v1/videos/generations

モデル ID: seedance-2.0-image-to-video

Fast バリアント seedance-2.0-fast-image-to-video は画像枚数に基づいて最初フレームモードと最初・最後フレームモードを自動判定します。

リクエストパラメータ

パラメータ必須デフォルト説明
modelstringはいseedance-2.0-image-to-video を指定
promptstringはい動き/カメラ/雰囲気を自然言語で記述。中国語 500 文字以下または英語 1000 ワード以下
image_urlsarray<string>はい1〜2 枚 の公開アクセス可能な画像 URL
durationintegerいいえ5動画の長さ(秒)、範囲は 415
qualitystringいいえ720p480p または 720p
aspect_ratiostringいいえ16:916:99:161:14:33:421:9adaptive
generate_audiobooleanいいえtrue同期音声を生成するか
callback_urlstringいいえタスク完了コールバック用の HTTPS URL、最大 2048 文字

注意: 画像は URL のみ で渡します。Base64 のインライン埋め込みはサポートされていません。URL は認証なしで公開 GET できる必要があり、ログインページにリダイレクトしてはいけません。

画像入力の要件

制約上限
枚数1 または 2 枚
フォーマット.jpeg.png.webp
寸法各辺 300〜6000 px
アスペクト比0.4〜2.5(つまり 2:5 から 5:2)
1 枚あたりの最大サイズ30 MB
リクエストボディの合計64 MB 以下

これらの制限を超えるリクエストは invalid_request を返します。実写の人間の顔はサポートされていません — システムは自動的に拒否します。

最初フレームモード(画像 1 枚)

curl -X POST https://api.evolink.ai/v1/videos/generations \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "seedance-2.0-image-to-video",
    "prompt": "The camera slowly pushes in and the scene comes alive, with wind gently moving the grass in the background.",
    "image_urls": ["https://example.com/first-frame.jpg"],
    "duration": 5,
    "aspect_ratio": "adaptive"
  }'

aspect_ratio: "adaptive" を指定すると、出力のアスペクト比が入力画像に自動的に合わせられます。

最初・最後フレームモード(画像 2 枚)

curl -X POST https://api.evolink.ai/v1/videos/generations \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "seedance-2.0-image-to-video",
    "prompt": "A smooth transition from the sunrise ocean to the sunset ocean in the same location",
    "image_urls": [
      "https://example.com/sunrise.jpg",
      "https://example.com/sunset.jpg"
    ],
    "duration": 6,
    "quality": "720p",
    "aspect_ratio": "16:9"
  }'

両方の画像は寸法とアスペクト比が近いものを使用してください。そうでないとモデルがトランジション中に歪みを生じる可能性があります。

Python の例

import requests

response = requests.post(
    "https://api.evolink.ai/v1/videos/generations",
    headers={
        "Authorization": "Bearer YOUR_API_KEY",
        "Content-Type": "application/json"
    },
    json={
        "model": "seedance-2.0-image-to-video",
        "prompt": "The model slowly turns, hair flowing gently in the wind",
        "image_urls": ["https://example.com/portrait.jpg"],
        "duration": 5,
        "quality": "720p"
    }
)

task = response.json()
print(f"Task ID: {task['id']}")

レスポンス

{
    "id": "task-unified-1774857405-abc123",
    "object": "video.generation.task",
    "created": 1774857405,
    "model": "seedance-2.0-image-to-video",
    "status": "pending",
    "progress": 0,
    "type": "video",
    "task_info": {
        "can_cancel": true,
        "estimated_time": 165,
        "video_duration": 5
    },
    "usage": {
        "billing_rule": "per_second",
        "credits_reserved": 50,
        "user_group": "default"
    }
}

フィールドの意味は他の Seedance 2.0 モデルと同一です。完全なライフサイクルは 非同期タスク を参照してください。

FAQ

画像を 3 枚渡すとどうなりますか?invalid_request が返ります。image-to-video は厳密に 1 枚または 2 枚の画像を要求します。スタイルや被写体の参照として 2 枚を超える画像が必要な場合は Reference-to-Video を使用してください。

画像 URL は自前ホスティングが必要ですか? 必須ではありません。公開 GET 可能な URL であれば動作します。再現性が必要な本番パイプラインでは、サードパーティ URL の有効期限切れを避けるため、画像を自社のオブジェクトストレージ(OSS / S3 / R2)にホスティングすることを推奨します。

入力画像中の人物の顔は保持されますか? 入力画像が実写の人間の顔を含む場合、リクエストはそのまま拒否されます。顔の一貫性のある仮想キャラクターが必要な場合は、別のツールでまず非実写の顔を合成し、それを本 API に渡してください。

関連