Skip to main content
POST

Authorizations

Authorization
string
header
required

##All endpoints require authentication using a Bearer Token##

Get your API Key:

Visit the API Key management page to obtain your API Key

Add it to the request header:

Body

application/json
model
enum<string>
default:gemini-omni-1.2-flash-video-extend
required

Model name, fixed to gemini-omni-1.2-flash-video-extend

Available options:
gemini-omni-1.2-flash-video-extend
Example:

"gemini-omni-1.2-flash-video-extend"

prompt
string
required

Text prompt describing what should happen after the input video ends.

Supports Chinese and English. For more stable results, describe the desired action and changes clearly. Write negative requirements directly in prompt, such as No dialogue or No text; there is no separate negative prompt parameter.

The prompt is required and must not be empty or contain only whitespace.

Minimum string length: 1
Pattern: \S
Example:

"The person continues walking forward and slowly exits the frame."

video_urls
string<uri>[]
required

Exactly one directly reachable HTTP/HTTPS MP4, no longer than 30 seconds.

Required array length: 1 element
Example:
image_urls
string<uri>[]

Optional reference image array, up to 10 images. It may be used with the video being extended to constrain subjects, style, or elements.

Input requirements:

  • HTTP/HTTPS image URLs only
  • Supported formats: png, jpeg, webp

Billing: Every reference image contributes input tokens.

Required array length: 1 - 10 elements
Example:
duration
integer
default:3

Appended video duration in seconds; default 3.

Notes:

  • Accepts any integer from 3 to 10
  • Specifies how many seconds are generated after the input video, not the total output duration
  • Total output duration = input video duration + duration
  • Appended duration directly affects billing
Required range: 3 <= x <= 10
Example:

3

quality
enum<string>
default:auto

Output video resolution; default auto.

  • 360p: short edge 360.
  • 720p: short edge 720.
  • 1080p: short edge 1080.
  • 4k: short edge 2160.
  • auto: follows the input resolution; this is the default.

Choosing an explicit value can raise or lower output resolution.

Billing: Output video tokens increase with output resolution. Input video also contributes tokens; higher resolution costs more.

Available options:
360p,
720p,
1080p,
4k,
auto
Example:

"auto"

aspect_ratio
enum<string>
default:auto

Only auto is accepted and it is the default. Output aspect ratio follows the input video.

Available options:
auto
Example:

"auto"

seed
integer

Random seed; random by default.

  • Range: 0–4294967295.
  • Fixing the seed reduces variation from parameter changes when tuning prompts and improves reproducibility.
Required range: 0 <= x <= 4294967295
Example:

42

callback_url
string<uri>

HTTPS callback URL to notify when the task completes

Callback timing:

  • Triggered when the task completes (completed), fails (failed), or is cancelled (cancelled)
  • Sent after billing is confirmed

Security restrictions:

  • HTTPS protocol only
  • Callbacks to internal IP addresses are forbidden (127.0.0.1, 10.x.x.x, 172.16-31.x.x, 192.168.x.x, etc.)
  • URL length must not exceed 2048 characters

Callback mechanism:

  • Timeout: 10 seconds
  • Up to 3 retries on failure (retried 1s / 2s / 4s after each failure respectively)
  • The callback body format matches the response of the task query endpoint
  • A 2xx status code from the callback URL is treated as success; other status codes trigger a retry
Example:

"https://your-domain.com/webhooks/video-task-completed"

Response

Video task created successfully

created
integer

Task creation timestamp

Example:

1757169743

id
string

Task ID

Example:

"task-unified-1757169743-7cvnl5zw"

model
string

The model name actually used

Example:

"gemini-omni-1.2-flash-video-extend"

object
enum<string>

The specific type of the task

Available options:
video.generation.task
progress
integer

Task progress percentage (0-100)

Required range: 0 <= x <= 100
Example:

0

status
enum<string>

Task status. The create endpoint always returns processing; the internal pending state is also exposed to clients as processing.

Available options:
pending,
processing,
completed,
failed
Example:

"processing"

task_info
object

Detailed video task information

type
enum<string>

The output type of the task

Available options:
text,
image,
audio,
video
Example:

"video"

usage
object

Usage and billing information