HappyHorse 1.1 参考生视频(r2v)

happyhorse-1.1-r2v 以多张参考图作为内容主体与风格依据生成视频,参考图必须提供。按生成秒数 × 分辨率档位计费,采用异步任务模式。

接口地址
POST /api/openai/videosGenerations

支持的模型

模型名支持分辨率
happyhorse-1.1-r2v480P / 720P / 1080P

参考输入参数

参数类型必填上限说明
promptstring是—视频描述
image_url / image_urlsstring / array是9参考图(主体 / 风格)

其他参数:duration(秒,默认5)、size(如 1280*720)或 resolution(480P/720P/1080P)。

请求示例

多参考图

POST /api/openai/videosGenerations
Authorization: Bearer sk-xxxxxxxx
Content-Type: application/json

{
  "model": "happyhorse-1.1-r2v",
  "prompt": "参考图片中的角色在森林中奔跑",
  "image_urls": [
    "https://example.com/ref1.jpg",
    "https://example.com/ref2.jpg"
  ],
  "duration": 5,
  "resolution": "1080P"
}

单张参考图(也可用 image_url 单值)

{
  "model": "happyhorse-1.1-r2v",
  "prompt": "让图片中的猫动起来,看向镜头",
  "image_url": "https://example.com/cat.jpg",
  "duration": 5,
  "size": "1280*720"
}

成功返回

{
  "code": 200,
  "msg": "success",
  "data": {
    "task_id": 76,
    "provider_task_id": "c0f4277d-...",
    "status": "pending"
  }
}

提交后通过 Video Task 查询接口 轮询,成功返回 video_url。

容错提示

  • 未提供参考图时返回:{"code":400,"msg":"该模型必须提供 参考图(参数 image_url)"}
  • 参考图最多 9 张,超出部分自动截断
  • 不支持的分辨率返回友好提示(支持 480P/720P/1080P)