> ## Documentation Index
> Fetch the complete documentation index at: https://docs.toapis.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Gemini Omni Flash Video Generation

> Generate videos with Gemini Omni Flash, supporting text-to-video plus 0, 1, or 3 reference images

* Use `gemini_omni_flash` in the `model` field
* Supports text-to-video, single-image video generation, and 3-image reference fusion
* Supports 4 / 6 / 10 second durations
* Default resolution is 720P; `1080p` is landscape 1080P and only supports `16:9`
* Async task API: submit a task, then query by task ID

<Warning>
  Upload local images with the [Upload Image API](/docs/en/api-reference/uploads/images) first, then pass the returned URLs in `image_urls`. Do not pass base64 image data directly.
</Warning>

## Authorizations

<ParamField header="Authorization" type="string" required>
  Use Bearer Token authentication:

  ```
  Authorization: Bearer YOUR_API_KEY
  ```
</ParamField>

## Body

<ParamField body="model" type="string" default="gemini_omni_flash" required>
  Model name. Use `gemini_omni_flash`.
</ParamField>

<ParamField body="prompt" type="string" required>
  Text prompt for video generation.
</ParamField>

<ParamField body="duration" type="integer" default="6">
  Video duration. Supported values: `4`, `6`, `10`.
</ParamField>

<ParamField body="aspect_ratio" type="string" default="16:9">
  Video aspect ratio:

  * `16:9` landscape
  * `9:16` portrait
</ParamField>

<ParamField body="resolution" type="string" default="720P">
  Video resolution:

  * `720P` default resolution
  * `1080p` landscape 1080P, only supported with `aspect_ratio: "16:9"`
</ParamField>

<ParamField body="image_urls" type="string[]">
  Optional reference image URL array. Only these three cases are supported:

  * Omit the field or pass an empty array: text-to-video
  * `1` image: single-image video generation
  * `3` images: reference-image fusion

  Passing `2` images is not supported.

  The backend normalizes `image_urls` into the upstream reference-image parameter.
</ParamField>

## Response

<ResponseField name="id" type="string">
  Task ID for status polling.
</ResponseField>

<ResponseField name="object" type="string">
  Object type, usually `generation.task`.
</ResponseField>

<ResponseField name="model" type="string">
  Model name used for the request.
</ResponseField>

<ResponseField name="status" type="string">
  Task status: `queued`, `in_progress`, `completed`, or `failed`.
</ResponseField>

<ResponseField name="created_at" type="integer">
  Task creation timestamp.
</ResponseField>

<ResponseField name="video_url" type="string">
  Generated video URL when the task completes.
</ResponseField>

## Examples

<RequestExample>
  ```bash cURL theme={null}
  curl --request POST \
    --url https://toapis.com/v1/videos/generations \
    --header 'Authorization: Bearer YOUR_API_KEY' \
    --header 'Content-Type: application/json' \
    --data '{
      "model": "gemini_omni_flash",
      "prompt": "A blue pump bottle slowly rotates in a clean white studio, commercial product video",
      "duration": 6,
      "aspect_ratio": "9:16",
      "resolution": "720P",
      "image_urls": ["https://example.com/reference.jpg"]
    }'
  ```

  ```bash cURL (1080p Landscape) theme={null}
  curl --request POST \
    --url https://toapis.com/v1/videos/generations \
    --header 'Authorization: Bearer YOUR_API_KEY' \
    --header 'Content-Type: application/json' \
    --data '{
      "model": "gemini_omni_flash",
      "prompt": "Cinematic product showcase with a slow camera push-in",
      "duration": 4,
      "aspect_ratio": "16:9",
      "resolution": "1080p"
    }'
  ```
</RequestExample>

<ResponseExample>
  ```json 200 theme={null}
  {
    "id": "video_01JZEXAMPLE",
    "object": "generation.task",
    "model": "gemini_omni_flash",
    "status": "queued",
    "created_at": 1779247407
  }
  ```
</ResponseExample>

## Query Task

The generation endpoint returns a task ID. Use the common video task status endpoint to fetch status and results:

```bash theme={null}
curl --request GET \
  --url https://toapis.com/v1/videos/generations/{task_id} \
  --header "Authorization: Bearer YOUR_API_KEY"
```
