Skip to content
Docs
xAI logo

Grok Imagine Video 1.5 Preview

Image-to-VideoxAI

xAI's next-generation video generation model. Generates, edits, and extends videos from text and image inputs. Supports multiple aspect ratios and resolutions with improved quality over the previous generation.

Model Info
Terms and Licenselink
More informationlink
PricingView pricing in the Cloudflare dashboard

Usage

TypeScript
const response = await env.AI.run(
'xai/grok-imagine-video-1.5-preview',
{
prompt: 'Generate a slow and serene time-lapse',
image: { url: 'https://docs.x.ai/assets/api-examples/video/milkyway-still.png' },
duration: 12,
},
)
console.log(response)

Parameters

_operation
stringenum: generate, edit, extend
aspect_ratio
stringenum: 1:1, 16:9, 9:16, 4:3, 3:4, 3:2, 2:3
duration
integermaximum: 15minimum: 1
prompt
string
resolution
stringenum: 480p, 720p
size
stringenum: 848x480, 1696x960, 1280x720, 1920x1080
user
string

API Schemas (Raw)

Input
Output