grok-imagine-video (Official)

由 xAI 提供视频

通过官方渠道设置提示词、宽高比、时长和分辨率,生成后可查询结果或续写 Grok 视频。

更新于:
输入提示词文本
模型1款可用
返回方式异步结果链接
价格3 quota官方渠道 480P 输出
视频示例2:3 portrait 预览
视频示例

static telephoto shot of a coastal apartment building at dusk, sea in the background, subtle wind and warm window light

文生视频 · 官方渠道 · 6s · 1152 × 1744 · 2:3 portrait · 24 fps
生成示例

从提示词到成片

01 · 浪花翻涌文生视频
文生视频 · 无参考图
提示词

The wave crests fully and pitches forward, the translucent green crest folding and crashing down onto the dark rocks with tremendous force. White foam explodes upward and outward. Sound: the deep boom of a heavy swell hitting rock, the hiss and rush of water pulling back across stone, low wind across an open coastline, and sea spray on a microphone.

02 · 曼谷晨跑文生视频
文生视频 · 无参考图
提示词

The camera tracks alongside runners in Bangkok as all four sprint in perfect lockstep, breath visible in the cool morning air. Shopfront shutters, parked motorbikes, and pedestrians streak past in heavy horizontal motion blur. Sound: running shoes on pavement, synchronized breathing, a distant scooter, and an early street-market ambience.

03 · 静谧午后文生视频
文生视频 · 无参考图
提示词

The figure slowly lowers the phone from their ear, exhales, and turns almost imperceptibly toward the room. Dust motes drift through golden light while a cat lifts its head and curtains move in a slow breeze. Sound: distant city traffic, a kitchen tap dripping, the soft hum of an old TV, and a creaking wood floor.

模型能力

grok-imagine-video (Official) 能做什么

根据提示词生成

提交简洁提示词,通过一个 TTAPI 任务获取视频结果。

常用参数

设置提示词、模型、输出参数和回调即可接入。

异步查询

通过轮询或 Webhook 接收结果,避免耗时生成阻塞界面。

接入产品

官方 grok-imagine-video 的输出可以展示、保存或交给后续流程处理。

计费

按操作计费,单位为 quota

按模型、操作和输出设置扣除 quota。

官方渠道价格官方定价
Input / output价格计费单位
输入图像0.12 quota / 张
480P output3 quota / 秒
720P output4.2 quota / 秒
API 请求

grok-imagine-video (Official) 操作和请求字段

使用 TTAPI 密钥,按下方字段向接口发送请求。

官方渠道生成POST
/grok/v1/videos/generations

使用 duration、image、reference_images 和 resolution 提交官方渠道 Grok 任务。

查看接口文档
查询官方任务GET
/grok/v1/videos/{request_id}

通过 request_id 查询官方 Grok 视频结果。

查看接口文档
官方渠道续写POST
/grok/v1/videos/extensions

通过提示词、源视频、时长和模型续写官方渠道的 Grok 视频。

查看接口文档
POSThttps://api.ttapi.io/grok/v1/videos/generations

请求头

TT-API-KEYstring必填

填写 TTAPI API 密钥。

Content-Typestring必填

使用 application/json。

请求体

promptstring按条件填写

grok-imagine-video 文生视频必填,grok-imagine-video-1.5 图生视频选填。

modelenum选填

默认 grok-imagine-video-1.5,可选 grok-imagine-video 或 grok-imagine-video-1.5。

aspect_ratioenum选填

可选 1:1、16:9、9:16、4:3、3:4、3:2 或 2:3。

durationinteger | string选填

默认 8 秒,接受 1 至 15 的数字或数字字符串。

imageobject按条件填写

图生视频的图像对象。grok-imagine-video-1.5 必填,基础版选填。

reference_imagesobject[]选填

参考素材生成视频使用的参考图对象。

resolutionenum选填

可选 480p、720p 或 1080p。

voice_idenum选填

视频音频的角色音色 ID,可选 carina、zagan、helix、orion、luna、iris、altair 或 zenith。

查看 TTAPI 接入文档
接入示例

发送请求并获取结果

复制当前模型的请求地址、鉴权请求头和请求体。

curl --request POST \
  --url https://api.ttapi.io/grok/v1/videos/generations \
  --header "TT-API-KEY: $TTAPI_KEY" \
  --header 'Content-Type: application/json' \
  --data '{"prompt":"static telephoto shot of a coastal apartment building at dusk","model":"grok-imagine-video","aspect_ratio":"2:3","duration":6,"resolution":"720p","voice_id":"luna"}'