generate_video
Create videos from text descriptions, animate images, or edit existing videos using Grok Imagine's AI capabilities within the MCP server.
Instructions
Generate or edit videos with Grok Imagine.
Text-to-video by default. Provide an image to animate (image-to-video), or
a source video to edit. Only one mode per call. Generation polls
synchronously (xAI's default timeout is 10 minutes).
Args:
prompt: Video description, or the edit instruction for video editing.
model: Video model (default `grok-imagine-video`).
image_path: Local image to use as the starting frame.
image_url: Public image URL to use as the starting frame.
video_path: Local video to edit (max 20 MB, .mp4, ≤ 8.7s).
video_url: Public video URL to edit (.mp4, ≤ 8.7s).
duration: Video length in seconds (1–15, ignored when editing).
aspect_ratio: Aspect ratio like `"16:9"` or `"9:16"` (ignored when editing).
resolution: `"480p"` or `"720p"` (ignored when editing).
Returns:
Markdown block with the generated video URL and actual duration.Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | ||
| model | No | grok-imagine-video | |
| image_path | No | ||
| image_url | No | ||
| video_path | No | ||
| video_url | No | ||
| duration | No | ||
| aspect_ratio | No | ||
| resolution | No |