Skip to content

创建视频 ​

提交 MiniMax-H3 官方格式多模态视频生成任务,并支持 H3-Context-IR 提示词增强与视频再生成。

http
POST /v2/video_generation

当前可用模型 ​

请求头 ​

名称类型必填说明
string是请求身份认证。使用 Bearer Token,示例值:。
string是请求内容类型,必须设置为 。

请求体 ​

名称类型必填说明
string是模型名称,可选值见上方「当前可用模型」。
array<object>否多模态输入数组,顺序影响角色分配,子字段见下方各行。
string是内容类型:、、、。
string否当 时必填,提示词文本。
object否当 时使用,须包含 :图片公网 URL。支持 JPG、JPEG、PNG、WEBP、HEIC、HEIF;单文件不超过 30 MB;宽高范围为 256~5760 px;长宽比范围为 0.4~2.5。首帧 ≤ 1 张、尾帧 ≤ 1 张、参考图 ≤ 9 张。
object否当 时使用,须包含 :参考视频公网 URL。支持 MP4、MOV,编码为 H.264/AVC、H.265/HEVC;单文件不超过 50 MB;个数 ≤ 3;单段 2~15 秒、总时长不超过 15 秒;宽高范围为 256~5760 px;长宽比范围为 0.4~2.5;帧率范围为 23.976~60。
object否当 时使用,须包含 :参考音频公网 URL。支持 WAV、MP3;单文件不超过 15 MB;个数 ≤ 3;单段 2~15 秒、总时长不超过 15 秒。
string否媒体角色: - :首帧(图片) - :尾帧(图片) - :参考图 - :参考视频 - :参考音频
integer是目标视频时长(秒),范围 。
string否视频宽高比:、、、、、、。
string否任务完成后的回调地址。
integer否视频时长(秒),范围 ,默认 。
string否视频分辨率: 或 ,默认 。
boolean否是否在生成视频中添加 AIGC 标识水印,默认 。
string否任务完成后的回调地址。
array<object>否本接口可选(覆盖上方公共定义),按源视频时必填,多模态内容数组需包含 类型的源视频项。
string否按任务 ID 时必填,源任务 ID。
string是视频分辨率,再生成固定为 。
boolean否是否在生成视频中添加 AIGC 标识水印。
string否任务完成后的回调地址。

请求示例 ​

bash
curl --location --request POST 'https://octopusx.ai/v2/h3_context_ir' \
  --header 'Authorization: Bearer <token>' \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --data-raw '{
    "model": "MiniMax-H3",
    "content": [
        {
            "type": "text",
            "text": "史诗级太空歌剧院线预告:女舰长独自站在巨大观景窗前,最后一支舰队正在集结并跃迁离去,强光爆闪、舰桥震动,她被留在原地。"
        }
    ],
    "duration": 5,
    "ratio": "16:9"
}'
bash
curl --location --request POST 'https://octopusx.ai/v2/h3_context_ir' \
  --header 'Authorization: Bearer <token>' \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --data-raw '{
    "model": "MiniMax-H3",
    "content": [
        {
            "type": "text",
            "text": "Pull focus to the people in the background and add more steam to the ramen bowl."
        },
        {
            "type": "image_url",
            "image_url": {
                "url": "https://example.com/image.png"
            },
            "role": "first_frame"
        }
    ],
    "duration": 5,
    "ratio": "adaptive"
}'
bash
curl --location --request POST 'https://octopusx.ai/v2/h3_context_ir' \
  --header 'Authorization: Bearer <token>' \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --data-raw '{
    "model": "MiniMax-H3",
    "content": [
        {
            "type": "text",
            "text": "角色说话:Follow the wind, live free. Leave worries behind, enjoy the moment,音色参考音频1"
        },
        {
            "type": "video_url",
            "video_url": {
                "url": "https://example.com/reference.mp4"
            },
            "role": "reference_video"
        },
        {
            "type": "audio_url",
            "audio_url": {
                "url": "https://example.com/reference.mp3"
            },
            "role": "reference_audio"
        }
    ],
    "duration": 5,
    "ratio": "adaptive"
}'
bash
curl --location --request POST 'https://octopusx.ai/v2/video_generation' \
  --header 'Authorization: Bearer <token>' \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --data-raw '{
    "model": "MiniMax-H3",
    "content": [
        {
            "type": "text",
            "text": "一只可爱的橘猫在弹钢琴"
        }
    ],
    "duration": 5,
    "resolution": "2K",
    "aigc_watermark": true
}'
bash
curl --location --request POST 'https://octopusx.ai/v2/video_generation' \
  --header 'Authorization: Bearer <token>' \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --data-raw '{
    "model": "MiniMax-H3",
    "content": [
        {
            "type": "text",
            "text": "镜头缓慢推进,猫咪开始弹奏"
        },
        {
            "type": "image_url",
            "image_url": {
                "url": "https://example.com/cat.jpg"
            },
            "role": "first_frame"
        }
    ],
    "duration": 5,
    "resolution": "768P"
}'
bash
curl --location --request POST 'https://octopusx.ai/v2/video_regeneration' \
  --header 'Authorization: Bearer <token>' \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --data-raw '{
    "model": "MiniMax-H3",
    "content": [
        {
            "type": "text",
            "text": "让猫咪弹得更快一些"
        },
        {
            "type": "video_url",
            "video_url": {
                "url": "https://example.com/original.mp4"
            }
        }
    ],
    "resolution": "2K"
}'
bash
curl --location --request POST 'https://octopusx.ai/v2/video_regeneration' \
  --header 'Authorization: Bearer <token>' \
  --header 'Accept: application/json' \
  --header 'Content-Type: application/json' \
  --data-raw '{
    "model": "MiniMax-H3",
    "source_task_id": "426586401755526",
    "resolution": "2K"
}'

响应示例 ​

json
{
  "task_id": "426586401755526"
}
json
{
  "task_id": "426586401755527"
}
json
{
  "task_id": "426586401755528"
}

响应字段 ​

名称类型说明
string任务 ID,用于 查询任务(官方格式)。

相关接口 ​