---
title: "POST /grok/v1/videos/generations"
method: POST
path: "/grok/v1/videos/generations"
---

# POST /grok/v1/videos/generations

`POST /grok/v1/videos/generations`

Grok video generation API. grok-imagine-video supports text-to-video (T2V) and image-to-video (I2V); grok-imagine-video-1.5 only supports image-to-video (I2V), image is required.<br/><br/>**Note: Synced with official rules, content moderation failure will also be charged.**

## Request body

- VideoGenerateRequest
  - `prompt` string, required — Video generation prompt. Required for grok-imagine-video text-to-video; optional for grok-imagine-video-1.5.
  - `model` 'grok-imagine-video' | 'grok-imagine-video-1.5' — Model name to use.
  - `aspect_ratio` '1:1' | '16:9' | '9:16' | '4:3' | '3:4' | '3:2' | '2:3' — Video aspect ratio.
  - `duration` integer — Video duration in seconds. Range: [1, 15]. Default: 8. Accepts both number (8) and string ("8") formats.
  - `image` object — Image object used for image-to-video generation. Required for grok-imagine-video-1.5 (I2V only); optional for grok-imagine-video (T2V when omitted, I2V when provided).
    - `url` string — Public URL or base64-encoded data URL of the image (JPEG, PNG, or WebP). Also accepts `image_url` for compatibility.
  - `reference_images` object[] — Array of reference images used for reference-to-video (R2V). These images serve as style/content references for video generation.
    - `url` string — Public URL or base64-encoded data URL of the image (JPEG, PNG, or WebP). Also accepts `image_url` for compatibility.
  - `resolution` '480p' | '720p' | '1080p' — Video resolution.

## Response `200`

Request successful

- object
  - `request_id` string, required — Request ID

## Other responses

- `400` — Parameter error
- `401` — Authorization failed

---

[API](https://skmtc.net/ttapi/apis/flowmusic-api-docs.md) · [All operations](https://skmtc.net/ttapi/apis/flowmusic-api-docs/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/ttapi/flowmusic-api-docs/versions/f27f8a59dbd0/schema)
