ModelSell Docs
VideosGeneric Video

创建视频生成任务

POST
/v1/video/generations

创建视频生成任务。该通用接口覆盖 HappyHorse、Seedance、Veo、万相等 /v1/video/generations 提供商。

使用 Seedance 2.0 时,通用字段会转换为官方 content[] 格式:prompt 转为文本内容,imageimages 转为参考图片,metadata.video_url 转为参考视频,metadata.audio_url 转为参考音频,size 转为 resolutionmetadata.ratio 转为 ratio。创建成功后保存返回的任务 ID,并通过 GET /v1/video/generations/{task_id} 轮询结果。

Authorization

bearerAuth
AuthorizationBearer <token>

使用 Authorization Bearer API Key 进行鉴权。

In: header

Request Body

application/json

TypeScript Definitions

Use the request body type in TypeScript.

Response Body

application/json

application/json

curl -X POST "https://example.com/v1/video/generations" \  -H "Content-Type: application/json" \  -d '{    "model": "doubao-seedance-2-0-260128",    "prompt": "一只金色柴犬在樱花树下奔跑,镜头缓缓上升",    "duration": 5,    "size": "480p",    "metadata": {      "ratio": "16:9",      "watermark": false,      "generate_audio": true    }  }'
{
  "id": "task_123456",
  "task_id": "task_123456",
  "object": "video.generation",
  "status": "succeeded",
  "model": "string",
  "created_at": 0,
  "updated_at": 0,
  "completed_at": 0,
  "expires_at": 0,
  "seconds": "string",
  "size": "string",
  "progress": 0,
  "url": "http://example.com",
  "video_url": "http://example.com",
  "content_url": "http://example.com",
  "remixed_from_video_id": "string",
  "output": [
    {}
  ],
  "error": {}
}
{
  "error": {
    "code": "string",
    "message": "string",
    "request_id": "string"
  }
}