> ## Documentation Index
> Fetch the complete documentation index at: https://docs.aiid.edu.kg/llms.txt
> Use this file to discover all available pages before exploring further.

# 動画を作成（Seedance）

> このシリーズはOpenAIの動画生成形式をサポートしています（詳細はリンク [動画生成Sora互換形式](/api-reference/ja/video-generation-sora-compatible-format/create-video) を参照してください）。

動画生成タスクを作成し、タスクIDを使用してステータスと結果を照会するために使用します。

タスク作成の主要フィールド：
- `model`：必須、モデル名。
- `prompt`：必須、動画生成のメイン説明文。
- `content`：任意。Volcano Ark の content 配列で、テキスト、画像、動画、音声素材を混在して配置できます。
- `function_mode`：任意、通常、万能リファレンスなどのアドバンスドモードで使用されます。

互換性のある入力パラメータ：

以下のフィールドは主に既存クライアントおよび旧プロトコルとの互換性のために使用します。新規接続では、できるだけこのページの「リクエスト例」にある標準形式を使用してください。テキストと参考素材は `content` 配列を使用し、生成設定は最上位の `duration`、`ratio`、`resolution`、`fps` などのフィールドを使用します。

- `mode`：`t2v / i2v / i2v_first_last / reference_images / reference_material`
- `image_url / image_urls / input_reference`
- `end_image_url / last_image_url`
- `video_urls / audio_urls`
- `seconds / duration`
- `aspect_ratio / ratio / size`
- `quality / resolution`
- `fps`
- `generate_audio / watermark`

呼び出しの詳細：
- `mode=reference_material` または `function_mode=omni_reference` の場合、`content` を介してテキストとリファレンス素材を渡すことを推奨します。
- `content` テキスト項目の記述形式は `{ "type": "text", "text": "测试文字" }` です。
- `content` 画像、動画、音声素材項目はそれぞれ `image_url`、`video_url`、`audio_url` のオブジェクト形式を使用します。例: `{ "type": "image_url", "image_url": { "url": "https://example.com/ref.png" }, "role": "reference_image", "name": "1" }`。
- `role` で素材の用途を識別でき、`name` はプロンプト内で名前指定による参照に使用できます。
- `ratio`、`duration`、`resolution`、`fps` は、最終的な生成設定に影響します。

Gemini Omni の呼び出し：
- `gemini-omni` は、本 Seedance タスク API からも呼び出せます。
- `mode=t2v` はテキストから動画の生成に使用し、`mode=r2v` は参照画像/参照素材を用いた生成に使用し、`mode=edit` は動画編集に使用します。
- テキストは `prompt` または `content` の `text` 項目に配置できます。画像は `image_url / image_urls / reference_images / input_reference / content` に、動画は `video_urls / content` に配置できます。
- 再生時間フィールドは `duration` または `seconds` を使用でき、4 / 6 / 8 / 10 秒のいずれかに自動でマッチします。

MiniMax / Hailuo の呼び出し：
- `minimax-h3` は本タスク API で呼び出せます。テキストから動画生成、画像参照、音声参照に対応しています。テキストは `prompt` または `content` のテキスト項目に、素材は `content`、`image_urls`、`audio_urls` などのフィールドに指定できます。
- `hailuo-2.3` は本タスク API で呼び出せます。最初のフレーム画像が必要です。`content` には `role=first_frame` の `image_url` 項目を渡すことを推奨します。
- `minimax-h3` でよく使うのは `duration=5~15`、`resolution=1440p` です。`hailuo-2.3` でよく使うのは `duration=6` または `10`、`resolution=768p` です。

照会結果の注目フィールド：
- `items[].status`
- `items[].content.video_url` または `items[].video_url`
- `items[].error`
- `items[].progress`

Error fields: `error.code`, `error.message`.

```json
{
  "error": {
    "code": "invalid_request_error",
    "message": "requires at least one image in `images`"
  }
}
```



## OpenAPI

````yaml api-reference/ja/openapi.json POST /api/v3/contents/generations/tasks
openapi: 3.0.0
info:
  title: 出海营 API 参考ドキュメント
  version: 1.0.0
  description: Public AI Gateway API Reference
servers:
  - url: https://api.aiid.edu.kg
security:
  - BearerAuth: []
tags:
  - name: OpenAI形式(Chat)
  - name: OpenAI形式（Responses）
  - name: 画像生成Gemini形式
  - name: 画像生成OpenAI DALL-E形式
  - name: モデル一覧の取得
  - name: 動画生成HappyHorseとWan
  - name: 動画生成Kling形式
  - name: 動画生成OmniとVeo形式
  - name: Video generation Seedance
  - name: 動画生成Sora対応形式
  - name: Video generation Vidu
  - name: 音楽生成タスクの形式
paths:
  /api/v3/contents/generations/tasks:
    post:
      tags:
        - Video generation Seedance
      summary: 動画を作成（Seedance）
      description: >-
        このシリーズはOpenAIの動画生成形式をサポートしています（詳細はリンク
        [動画生成Sora互換形式](/api-reference/ja/video-generation-sora-compatible-format/create-video)
        を参照してください）。


        動画生成タスクを作成し、タスクIDを使用してステータスと結果を照会するために使用します。


        タスク作成の主要フィールド：

        - `model`：必須、モデル名。

        - `prompt`：必須、動画生成のメイン説明文。

        - `content`：任意。Volcano Ark の content 配列で、テキスト、画像、動画、音声素材を混在して配置できます。

        - `function_mode`：任意、通常、万能リファレンスなどのアドバンスドモードで使用されます。


        互換性のある入力パラメータ：


        以下のフィールドは主に既存クライアントおよび旧プロトコルとの互換性のために使用します。新規接続では、できるだけこのページの「リクエスト例」にある標準形式を使用してください。テキストと参考素材は
        `content` 配列を使用し、生成設定は最上位の `duration`、`ratio`、`resolution`、`fps`
        などのフィールドを使用します。


        - `mode`：`t2v / i2v / i2v_first_last / reference_images /
        reference_material`

        - `image_url / image_urls / input_reference`

        - `end_image_url / last_image_url`

        - `video_urls / audio_urls`

        - `seconds / duration`

        - `aspect_ratio / ratio / size`

        - `quality / resolution`

        - `fps`

        - `generate_audio / watermark`


        呼び出しの詳細：

        - `mode=reference_material` または `function_mode=omni_reference`
        の場合、`content` を介してテキストとリファレンス素材を渡すことを推奨します。

        - `content` テキスト項目の記述形式は `{ "type": "text", "text": "测试文字" }` です。

        - `content` 画像、動画、音声素材項目はそれぞれ `image_url`、`video_url`、`audio_url`
        のオブジェクト形式を使用します。例: `{ "type": "image_url", "image_url": { "url":
        "https://example.com/ref.png" }, "role": "reference_image", "name": "1"
        }`。

        - `role` で素材の用途を識別でき、`name` はプロンプト内で名前指定による参照に使用できます。

        - `ratio`、`duration`、`resolution`、`fps` は、最終的な生成設定に影響します。


        Gemini Omni の呼び出し：

        - `gemini-omni` は、本 Seedance タスク API からも呼び出せます。

        - `mode=t2v` はテキストから動画の生成に使用し、`mode=r2v`
        は参照画像/参照素材を用いた生成に使用し、`mode=edit` は動画編集に使用します。

        - テキストは `prompt` または `content` の `text` 項目に配置できます。画像は `image_url /
        image_urls / reference_images / input_reference / content` に、動画は
        `video_urls / content` に配置できます。

        - 再生時間フィールドは `duration` または `seconds` を使用でき、4 / 6 / 8 / 10
        秒のいずれかに自動でマッチします。


        MiniMax / Hailuo の呼び出し：

        - `minimax-h3` は本タスク API で呼び出せます。テキストから動画生成、画像参照、音声参照に対応しています。テキストは
        `prompt` または `content` のテキスト項目に、素材は `content`、`image_urls`、`audio_urls`
        などのフィールドに指定できます。

        - `hailuo-2.3` は本タスク API で呼び出せます。最初のフレーム画像が必要です。`content` には
        `role=first_frame` の `image_url` 項目を渡すことを推奨します。

        - `minimax-h3` でよく使うのは `duration=5~15`、`resolution=1440p`
        です。`hailuo-2.3` でよく使うのは `duration=6` または `10`、`resolution=768p` です。


        照会結果の注目フィールド：

        - `items[].status`

        - `items[].content.video_url` または `items[].video_url`

        - `items[].error`

        - `items[].progress`


        Error fields: `error.code`, `error.message`.


        ```json

        {
          "error": {
            "code": "invalid_request_error",
            "message": "requires at least one image in `images`"
          }
        }

        ```
      operationId: create__seedance__task
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              required:
                - model
                - prompt
              properties:
                model:
                  type: string
                  example: doubao-seedance-2-0-260128
                  enum:
                    - doubao-seedance-1-0-lite-i2v-250428
                    - doubao-seedance-1-0-lite-t2v-250428
                    - doubao-seedance-1-0-pro-250528
                    - doubao-seedance-1-0-pro-fast-251015
                    - doubao-seedance-1-5-pro-251215
                    - doubao-seedance-2-0-260128
                    - doubao-seedance-2-0-fast-260128
                    - minimax-h3
                    - hailuo-2.3
                    - gemini-omni
                  description: >-
                    必須。モデル名。Seedance 対外モデル、`gemini-omni`、`minimax-h3` または
                    `hailuo-2.3` を指定できます。
                prompt:
                  type: string
                  example: 参考素材生成一段剧情短视频
                  description: 必須。動画生成のメイン説明です。空にすることはできません。
                content:
                  type: array
                  description: >-
                    任意指定。火山方舟の content 配列で、テキスト項目と素材項目を順番に混在させます。テキスト項目には `{
                    "type": "text", "text": "..." }` を使用します。画像、動画、音声項目にはそれぞれ
                    `image_url`、`video_url`、`audio_url` オブジェクトを使用し、その中に `url`
                    を設定します。必要に応じて `role`（例:
                    `reference_image`、`reference_video`、`reference_audio`）と
                    `name` を組み合わせて、テキストから参照できます。
                  items:
                    type: object
                    required:
                      - type
                    properties:
                      type:
                        type: string
                        enum:
                          - text
                          - image_url
                          - video_url
                          - audio_url
                        description: コンテンツ項目タイプ。
                      text:
                        type: string
                        description: テキスト内容。type=text の場合にのみ使用します。
                      image_url:
                        oneOf:
                          - type: string
                          - type: object
                            properties:
                              url:
                                type: string
                        description: 画像の URL。推奨されるオブジェクト形式：`{"url":"https://..."}`。
                      video_url:
                        oneOf:
                          - type: string
                          - type: object
                            properties:
                              url:
                                type: string
                        description: 動画 URL。推奨のオブジェクト記法：`{"url":"https://..."}`。
                      audio_url:
                        oneOf:
                          - type: string
                          - type: object
                            properties:
                              url:
                                type: string
                        description: '音声 URL。推奨されるオブジェクト形式: `{"url":"https://..."}`。'
                      role:
                        type: string
                        description: >-
                          素材の用途を示す識別子。一般的な値は
                          reference_image、reference_video、reference_audio などです。
                      name:
                        type: string
                        description: 素材名。テキストプロンプトで参照したり、複数の素材を区別したりするために使用できます。
                function_mode:
                  type: string
                  description: 任意。高度な機能モードです。全般的なリファレンス用の `omni_reference` などがあります。
                mode:
                  type: string
                  description: >-
                    任意。互換モードのフィールド。`t2v`、`i2v`、`i2v_first_last`、`reference_images`、`reference_material`
                    など。`gemini-omni` は `t2v`、`r2v`、`edit` をサポートします。
                image_url:
                  type: string
                  description: 任意。単一の参照画像URL。
                image_urls:
                  type: array
                  items:
                    type: string
                  description: 任意。複数の参照画像URLのリスト。
                input_reference:
                  type: string
                  description: 任意。互換性のためのリファレンス入力フィールドです。
                end_image_url:
                  type: string
                  description: 任意。最終フレームの参照画像の URL。
                last_image_url:
                  type: string
                  description: オプション。最終フレームの参照画像URLのエイリアス。
                video_urls:
                  type: array
                  items:
                    type: string
                  description: 任意。参照用動画URLのリスト。
                audio_urls:
                  type: array
                  items:
                    type: string
                  description: 任意。参照オーディオURLのリスト。
                seconds:
                  oneOf:
                    - type: number
                    - type: string
                  description: オプション。動画の長さ（秒）。`duration` と互換性があります。
                duration:
                  oneOf:
                    - type: number
                    - type: string
                  description: オプション。動画の長さ（秒）。`seconds` と互換性があります。
                aspect_ratio:
                  type: string
                  description: 任意。アスペクト比（例：`16:9`）。
                ratio:
                  type: string
                  description: 任意。アスペクト比のエイリアス（例：`16:9`）。
                size:
                  type: string
                  description: 任意。解像度またはサイズ互換フィールド。
                quality:
                  type: string
                  description: 任意。生成品質の設定。
                resolution:
                  type: string
                  description: 任意。出力解像度。
                fps:
                  type: number
                  description: 任意。フレームレート。
                generate_audio:
                  type: boolean
                  description: 任意。オーディオを生成するかどうか。
                watermark:
                  type: boolean
                  description: 任意。ウォーターマークを追加するかどうか。
            examples:
              seedance_tasks_reference_material:
                summary: Seedance コンテンツのタスク
                value:
                  model: doubao-seedance-1-0-lite-i2v-250428
                  mode: reference_material
                  prompt: 测试文字
                  content:
                    - type: text
                      text: 测试文字
                    - type: image_url
                      image_url:
                        url: >-
                          https://imageproxy.zhongzhuan.chat/api/proxy/image/9979f1a754b3571d5e8bdcc397eedf53.png
                      role: reference_image
                      name: '1'
                    - type: video_url
                      video_url:
                        url: >-
                          https://imageproxy.zhongzhuan.chat/api/proxy/video/1979f1a754b3571d5e8bdcc397eedf53.mp4
                      role: reference_video
                      name: '2'
                    - type: audio_url
                      audio_url:
                        url: >-
                          https://imageproxy.zhongzhuan.chat/api/proxy/video/3979f1a754b3571d5e8bdcc397eedf53.mp3
                      role: reference_audio
                      name: '3'
                  duration: 5
                  size: 1280x720
              minimax_h3_tasks_content:
                summary: MiniMax H3 コンテンツタスク
                value:
                  model: minimax-h3
                  prompt: A cinematic product video with smooth camera motion
                  content:
                    - type: text
                      text: >-
                        Use the product image as reference and match the rhythm
                        of the audio.
                    - type: image_url
                      image_url:
                        url: https://example.com/product.jpg
                      role: reference_image
                      name: product
                    - type: audio_url
                      audio_url:
                        url: https://example.com/music.mp3
                      role: reference_audio
                      name: music
                  duration: 8
                  resolution: 1440p
                  ratio: '16:9'
                  generate_audio: true
              hailuo_2_3_tasks_first_frame:
                summary: Hailuo 2.3 最初のフレーム画像から動画を生成
                value:
                  model: hailuo-2.3
                  prompt: >-
                    The camera slowly pushes in, natural motion and cinematic
                    lighting.
                  content:
                    - type: text
                      text: >-
                        The camera slowly pushes in, natural motion and
                        cinematic lighting.
                    - type: image_url
                      image_url:
                        url: https://example.com/first-frame.jpg
                      role: first_frame
                      name: first
                  duration: 10
                  resolution: 768p
                  ratio: '16:9'
              gemini_omni_seedance_t2v:
                summary: Gemini Omni t2v
                value:
                  model: gemini-omni
                  mode: t2v
                  prompt: A cinematic product video with smooth camera motion
                  duration: 8
                  size: 1280x720
              gemini_omni_seedance_r2v:
                summary: Gemini Omni r2v
                value:
                  model: gemini-omni
                  mode: r2v
                  content:
                    - type: text
                      text: Keep the product consistent and create a short ad video
                    - type: image_url
                      image_url:
                        url: https://example.com/product.jpg
                  duration: 8
                  size: 1280x720
              gemini_omni_seedance_edit:
                summary: Gemini Omni edit
                value:
                  model: gemini-omni
                  mode: edit
                  content:
                    - type: text
                      text: Change the outfit color while keeping the motion natural
                    - type: video_url
                      video_url:
                        url: https://example.com/input.mp4
                    - type: image_url
                      image_url:
                        url: https://example.com/style.jpg
                  duration: 8
                  size: 1280x720
      responses:
        '200':
          description: タスクの作成に成功しました
          content:
            application/json:
              schema:
                type: object
                required:
                  - id
                properties:
                  id:
                    type: string
                    example: task_xxx
                    description: タスク ID。
                  status:
                    type: string
                    description: タスクのステータス。
                    enum:
                      - queued
                      - running
                      - succeeded
                      - failed
                  created_at:
                    type: string
                    description: 作成日時（Unix秒）。
                  items:
                    type: string
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          description: タスク ID。
                        status:
                          type: string
                          description: >-
                            タスクのステータス。一般的には
                            `queued`、`running`、`succeeded`、`failed` があります。
                        content:
                          type: object
                          properties:
                            video_url:
                              type: string
                              description: 動画結果のURL。
                        video_url:
                          type: string
                          description: 動画結果のURL。
                        error:
                          type: string
                          description: 失敗時のエラーメッセージ。
                        progress:
                          type: string
                          description: タスクの進捗。
      security:
        - BearerAuth: []
components:
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: |-
        Bearer Token を使用して認証します。
        形式: `Authorization: Bearer sk-xxxxxx`

````