Skip to main content
POST
生成视频

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json
prompt
string
required

视频描述提示词(最大 1000 字符)

Maximum string length: 1000
Example:

"小猫在吃鱼"

model
enum<string>
required

视频模型

Available options:
grok-imagine-video,
grok-imagine-video-1.5
Example:

"grok-imagine-video"

duration
enum<number>
default:6

视频时长(秒)

Available options:
6,
10,
12,
16,
20
aspectRatio
enum<string>

视频宽高比

Available options:
2:3,
3:2,
1:1,
9:16,
16:9
resolution
enum<string>
default:720P

视频分辨率。1080P 仅 grok-imagine-video-1.5 支持;grok-imagine-video 最高 720P

Available options:
480P,
720P,
1080P
images
string[]

参考图片 URL(图生视频,最多 5 张;提供后视频尺寸跟随图片,aspectRatio 和 resolution 将被忽略)

Maximum array length: 5

Response

200 - application/json
taskId
string
required

任务 ID,用于后续查询结果