Skip to main content
POST

Authentication

string
required
All requests require Bearer Token authentication.Get an API key:Visit the API Key management page to get your API key.Add the following header when making requests:

Request Parameters

string
required
Video generation model name. Must be gemini-omni-flash-preview.
string
required
Text instruction. For Text-to-Video, it is a scene description; for Image/Video-to-Video, it is an action / style / editing instruction.
prompt and reference materials (image_urls / video_urls) — provide at least one of them.
array<string>
Reference images, up to 16. Each item is an http(s):// URL.Supports JPEG / PNG. For multiple subjects (e.g. “cat + ball of yarn”), you can pass multiple images and describe how they interact in the prompt.
array<string>
Reference / video to be edited, at most 1 (multiple video references are not supported). Can be an http(s):// direct link or data:video/....
  • Reference videos are 1-24 seconds; the official recommendation is ≤3 seconds.
  • video_urls and extend_from_task_id are mutually exclusive; provide only one of them, not both at the same time.
string
default:"16:9"
Video aspect ratio, which actually controls the output frame orientation.Supported values only:
  • 16:9 - landscape (default)
  • 9:16 - portrait
Other values are treated as 16:9.
string
default:"720p"
Video resolution. Currently only 720p is supported.
string
Previous task ID: fill in the ** task_id** of the previous generation task.
extend_from_task_id and video_urls are mutually exclusive; provide only one of them, not both at the same time.

Response

integer
Response status code. Successful requests return 200.
array
Returned task array.

Query Task Result

Video generation is asynchronous. After submission, the API returns a task_id. Use the Get task status endpoint to query progress and results.

Successful Result Example

Use Cases

Scenario 1: Text-to-Video

Scenario 2: Image-to-Video

Scenario 3: Video-to-Video