Skip to content
English

Veo 3.1 Fast API

POST /v1/tasks

All models are called through the Unified Async API POST /v1/tasks endpoint; only the input fields differ (see input parameters below).

Model summary

Model name veo-3.1-fast/text-to-video
Type Video generation (text-to-video)
Endpoint POST /v1/tasks
Pricing See HiAPI Pricing

Google Veo 3.1 Fast text-to-video API with native audio and up to 4K resolution. Generates 4 / 6 / 8-second clips that balance quality and speed for fast sound-on short videos.

Production guidance

Production guidance
  • For production, pass callback.url at the top level of the request body so HiAPI can notify your service when the task reaches a terminal state.
  • GET /v1/tasks/:id is better for local debugging, low-volume jobs, or fallback reconciliation if a callback is missed.
  • Use callback.when=final. Both success and fail are terminal states, so your service should deduplicate by taskId.

Best suited for

Sound-on short videos

Generate visuals and native audio in one call, skipping post-production scoring. Good for social shorts and ad intros.

promptgenerate_audio
Fast creative validation

4 / 6 / 8-second clips return quickly, ideal for storyboard checks, batch test shots, and creative drafts.

durationresolution
Up to 4K delivery

Supports 720p / 1080p / 4K so you can pick the resolution your placement needs.

resolution
Landscape and portrait

One prompt adapts to 16:9 feeds and 9:16 vertical shorts.

aspect_ratio

Request parameters

model string required

Fixed value veo-3.1-fast/text-to-video.

example veo-3.1-fast/text-to-video
input object required

Business parameters. Put Veo 3.1 Fast-specific configuration here.

prompt string required

Text prompt describing the video to generate.

aspect_ratio enum optional

Output video aspect ratio.

default 16:9 enum: 16:99:16
resolution enum required

Output video resolution. Higher resolution costs more.

default 720p enum: 720p1080p4k
duration enum required

Clip length in seconds. Cost scales with duration.

default 8 enum: 468
generate_audio boolean optional

Generate a native audio track. Pricing is higher when enabled; set false when you do not need sound.

default true
negative_prompt string optional

Describe what to avoid in the generated video.

seed integer optional

Random seed for reproducible generation.

callback object optional

Optional callback configuration. When set, HiAPI notifies your service when the task reaches a terminal state.

url string required

Required when callback is set; HTTPS URL that receives terminal task notifications.

example https://your-domain.com/hiapi/callback
when enum optional

Callback trigger timing. Use final.

default final enum: final

Example requests

Cinematic clip with audio

Audio on by default, 1080p / 8s, for sound-driven narrative shots.

Request body
{
  "model": "veo-3.1-fast/text-to-video",
  "input": {
    "prompt": "A golden retriever running on the beach at sunset, slow motion, gentle waves, warm cinematic light",
    "aspect_ratio": "16:9",
    "resolution": "1080p",
    "duration": 8,
    "generate_audio": true
  }
}
Vertical short (audio off saves cost)

9:16 vertical, 720p / 4s, audio off — for cost-sensitive batch vertical content.

Request body
{
  "model": "veo-3.1-fast/text-to-video",
  "input": {
    "prompt": "A neon street at night after rain, reflections on the ground, cyberpunk mood",
    "aspect_ratio": "9:16",
    "resolution": "720p",
    "duration": 4,
    "generate_audio": false
  }
}
4K high-resolution clip

4K / 8s with audio, for high-resolution delivery.

Request body
{
  "model": "veo-3.1-fast/text-to-video",
  "input": {
    "prompt": "A snow mountain lake in morning mist, camera slowly pushing in, calm and vast",
    "aspect_ratio": "16:9",
    "resolution": "4k",
    "duration": 8,
    "generate_audio": true
  }
}

Getting the result

  1. The response returns a taskId immediately without waiting for generation to finish.
  2. In production, prefer waiting for callback.url to receive the terminal notification. For local debugging, poll GET /v1/tasks/:id.
  3. When status=success, download the generated video from output[].url.
  4. When status=fail, fix the request based on the returned error instead of retrying the same invalid payload.

FAQ

Which resolutions and durations does Veo 3.1 Fast support?

Resolutions 720p / 1080p / 4K and durations 4 / 6 / 8 seconds. Pricing is billed by resolution and duration (per second); 4K and audio cost more. See the live pricing page for current rates. View pricing

How does generate_audio affect price?

Native audio (generate_audio=true) costs more per second. Set it to false when you do not need sound to noticeably reduce cost. See the pricing page for per-second rates. View pricing

How do I get the generated video?

The response returns a taskId immediately. When the task reaches a terminal state, download the video from output[].url. In production, pass callback.url at the top level to receive terminal notifications and avoid polling.

Does it support image-to-video or reference images?

veo-3.1-fast/text-to-video is text-to-video only. It accepts text prompts and does not take reference image input.

Next steps