Veo 3.1
veo-3.1/text-to-video
Google's video generation model: image input can natively generate 8-second videos with ambient sound and dialogue, supporting up to 4K while keeping the subject's appearance consistent
Try veo-3.1/text-to-video
Input
Showcases
View all showcasesOutput
videoPricing
veo-3.1/text-to-video per second
Positioning Overview
Veo 3.1's text-to-video route is designed for developers who need to produce finished clips directly from a single line of text. It generates 4- to 8-second videos on demand at 720p to 4K in landscape or portrait orientation, with an optional native audio track that lets environmental sounds, dialogue, and sound effects described in the prompt be generated in sync with the visuals. You can call it by passing a prompt through the unified HiAPI.ai interface, making it suitable for scenarios that require rapid validation of visual ideas, such as short ads, vertical social media content, and storyboard previsualization.
Key Highlights
- Native audio-visual sync, no separate voiceover needed — when audio generation is enabled, the video comes with its own environmental sounds, dialogue, and sound effects, reducing post-production audio design and mixing work.
- Up to 4K resolution output per generation — resolution can be set to 720p, 1080p, or 4k, meeting different requirements from quick previews to high-quality deliverables.
- Switch between landscape and portrait as needed — aspect_ratio supports 16:9 and 9:16, so the same prompt can directly produce versions suited to feeds or vertical platforms.
- Controllable output with seed and negative prompts — use seed to reproduce generation results and negative_prompt to exclude unwanted elements, making it easy to keep a consistent style in batch production.
Capabilities
Direct text-to-short-video: enter a descriptive prompt (up to 20,000 characters) and directly get a 4-, 6-, or 8-second video clip without preparing any assets.
Native audio track generation: optionally generate native audio; describe environmental sounds, dialogue, or sound effects in the prompt and the finished video comes with synchronized sound, eliminating the separate voiceover process.
Resolution and aspect ratio control: output resolution covers 720p, 1080p, and 4k, and aspect ratio supports 16:9 and 9:16, so you can choose according to the delivery channel.
Reproducibility and negative constraints: a fixed seed allows the same result to be generated repeatedly, and negative_prompt is used to exclude unwanted visual elements, helping maintain consistency in batch output.
Use Cases
- Marketing teams quickly producing short ads — use a prompt describing product selling points to generate an 8-second clip with sound, directly usable for rapid validation of ad assets and first-cut editing.
- Social media operations creating vertical short videos — generate short videos in 9:16 aspect ratio for feeds or short-video platforms, skipping the landscape cropping step.
- Film and TV pre-production storyboard previsualization — turn storyboard descriptions into dynamic clips with sound effects for concept visualization and team communication, reducing trial-and-error costs before live-action shooting.
- Programmatic content production pipelines — developers can submit prompts in batches through the unified interface and connect the generated clips to their own content management systems or automated workflows.
Limitations and Selection Advice
A single generation is capped at 8 seconds; longer content requires multiple generations followed by stitching. Enabling audio or increasing resolution raises the cost per call, so it is recommended to choose specifications according to delivery requirements. This route is text-to-video and cannot upload reference images to maintain consistent character or product appearance; for that need, use the image-to-video route in the same family. If multi-shot continuity and long-form narrative are required, additional manual orchestration and consistency management are still necessary.
Frequently asked questions
View all FAQs →-
What type of video model is Veo 3.1 Text to Video?
It is a pure text-to-video route and does not require an opening image.
-
Which output settings does Veo 3.1 Text to Video support?
4-8 seconds, 720p, 1080p, 4k, and 16:9, 9:16.
-
Can it generate sound or use audio references?
Generated audio enabled by default
-
How is Veo 3.1 Text to Video billed?
Billing follows output duration and the live tier. Resolution, mode, or audio differences are reflected by the page price and task record.
Create a generation task
https://api.hiapi.ai/v1/tasks Headers
AuthorizationstringRequiredAccount API key. Required on every request. Example: Bearer YOUR_HIAPI_API_KEY. Get your API key
Content-TypestringOptionalThe request body is always parsed as JSON; when sent, only application/json (optionally with charset) is accepted — any other value returns 415. Example: application/json.
Idempotency-KeystringOptionalIdempotency key, up to 255 bytes. Retries with the same key from the same account create the task only once; replays return the original taskId.
On network timeouts or client retries, the same key creates the task only once — no double charges (scope: the API key's account). Use a business-unique identifier as the key (e.g. "order-42"); replays return the original taskId, and keys expire 24 hours after the first request. See the Unified Async API overview for the full scenario matrix.
Body
modelstringRequiredCurrent fixed value: veo-3.1/text-to-video
routestringOptionalCurrent fixed value: default
inputobjectRequired
Business parameters for veo-3.1/text-to-video and route default — see the parameter table below.
seedintegerOptionalRandom seed used to reproduce generation results; takes an integer. The same seed combined with the same input reproduces the same output; if not provided, it is randomly generated by the system.
promptstringRequiredminLength 1maxLength 20000Text prompt describing the video content you want to generate; takes a string.
durationintegerRequiredDefault: 8min 4max 8Duration of the video clip in seconds; the cost increases with longer durations. Default is 8 seconds.
468resolutionstringRequiredDefault: "720p"Output video resolution; the higher the resolution, the higher the cost. Default is 720p.
720p1080p4kaspect_ratiostringOptionalDefault: "16:9"Aspect ratio of the output video. Default is 16:9.
16:99:16generate_audiobooleanOptionalDefault: trueWhether to generate a native audio track for the video; enabling this costs more. Default is true.
negative_promptstringOptionalNegative prompt describing content to avoid in the generated video; takes a string.
callbackobjectOptional
Terminal-state notification config. When omitted, no callback is delivered — poll the task yourself. See the callback note below.
Provide callback.url when creating a task and HiAPI POSTs to your service once the task reaches a terminal state — no polling needed. The callback payload mirrors the task detail structure; signature verification, delivery retries and idempotency are documented on the Unified Async API overview page.
urlstringRequiredRequired when callback is present. A POST is sent to this URL once the task reaches a terminal state; must be a valid http(s) URL.
whenstringOptionalDefault: "final"Only final is supported today — notified on both success and fail.
finalstoragestringOptionalDefault: "temp"Artifact storage tier: temp (default, retained about 7 days) or persistent (long-term, billed by size). Insufficient balance or exceeding the storage cap silently downgrades to temp; the effective tier is shown in the task detail response.
temppersistentRequest examples
# Submit an async task; returns a taskId immediately (no waiting for generation)
curl -X POST "https://api.hiapi.ai/v1/tasks" \
-H "Authorization: Bearer $HIAPI_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "veo-3.1/text-to-video",
"input": {
"prompt": "…",
"duration": 8,
"resolution": "720p",
"aspect_ratio": "16:9",
"generate_audio": true
}
}' const res = await fetch("https://api.hiapi.ai/v1/tasks", {
method: "POST",
headers: {
Authorization: `Bearer ${process.env.HIAPI_API_KEY}`,
"Content-Type": "application/json",
},
body: JSON.stringify({
model: "veo-3.1/text-to-video",
input: {
"prompt": "…",
"duration": 8,
"resolution": "720p",
"aspect_ratio": "16:9",
"generate_audio": true
}
}),
});
const task = await res.json();
// { code: 200, message: "success", data: { taskId } } import os, requests
res = requests.post(
"https://api.hiapi.ai/v1/tasks",
headers={"Authorization": f"Bearer {os.environ['HIAPI_API_KEY']}"},
json={
"model": "veo-3.1/text-to-video",
"input": {
"prompt": "…",
"duration": 8,
"resolution": "720p",
"aspect_ratio": "16:9",
"generate_audio": True
}
},
)
print(res.json()) # { code, message, data: { taskId } } 200 OK
{
"code": 200,
"message": "success",
"data": {
"taskId": "tk-hiapi-01HZTQ8BX2N3GM3YFK4Z9D7VQR"
}
} 400 Bad Request
{
"code": 400,
"message": "invalid request",
"data": null,
"error_code": "INVALID_REQUEST"
} Get task detail
https://api.hiapi.ai/v1/tasks/:id Response fields
taskIdstringRequiredTask ID, always prefixed with tk-hiapi-.
modelstringRequiredResolved full model name. Tasks submitted with the route parameter return base@route (e.g. gpt-image-2/text-to-image@ext); otherwise identical to the name passed at creation.
routestringOptionalPresent only when the task was submitted with an explicit route parameter; echoes the submitted value.
statusstringRequiredTask status.
queued Queued, not started yet.
handling Being processed.
archiving Processing finished, artifacts being prepared.
success Terminal: completed, artifacts available (output returned).
fail Terminal: failed (error returned).
After submission, check status: success and fail are terminal, everything else is non-terminal. Poll every 1–3 seconds until terminal. On success, download artifacts from output[].url and transfer them before expireAt; pass storage: "persistent" at creation time when long-term retention is needed.
creatednumberRequiredTask creation time (Unix seconds).
completednumberRequiredUnix seconds when the task reached a terminal state; fixed to 0 while not terminal.
outputarrayOptional
Present only when status == success. Artifact list — always an array; a single task may return multiple types at once (e.g. video + first_frame).
Array [ object ]
Array items
urlstringRequiredArtifact URL, directly downloadable.
typestringRequiredCurrent possible values: video, image, audio, first_frame, last_frame, thumbnail; more may be added later.
expireAtnumberRequiredUnix seconds until which the artifact remains accessible; download or transfer before it expires.
errorobjectOptional
Present only when status == fail.
codestringRequiredBusiness error code.
messagestringRequiredError description.
Response examples
Success
{
"code": 200,
"message": "success",
"data": {
"taskId": "tk-hiapi-01HZTQ8BX2N3GM3YFK4Z9D7VQR",
"model": "happyhorse-1-0",
"status": "success",
"created": 1777282033,
"completed": 1777282099,
"output": [
{
"url": "https://cdn.hiapi.ai/tasks/.../video.mp4",
"type": "video",
"expireAt": 1777886899
}
]
}
} Processing (non-terminal)
{
"code": 200,
"message": "success",
"data": {
"taskId": "tk-hiapi-...",
"model": "happyhorse-1-0",
"status": "archiving",
"created": 1777282033,
"completed": 0
}
} Failed
{
"code": 200,
"message": "success",
"data": {
"taskId": "tk-hiapi-...",
"model": "happyhorse-1-0",
"status": "fail",
"created": 1777282033,
"completed": 1777282099,
"error": {
"code": "TASK_FAILED",
"message": "task failed"
}
}
} Articles
View all articles →Related Models
View all models →Same Type
-
Gemini Omni Google -- -
FLUX 3 Max Black Forest Labs $0.061 /second -
Ray 3.2 Luma $0.214 /video -
Vidu Q3 Vidu $0.149 /second -
Kling 2.5 Kuaishou $0.060 /second -
Gemini Omni 1.1 Flash Google $0.450 /video -
Wan 2.7 Video Alibaba $0.100 /second -
Wan 2.6 Flash Alibaba $0.043 /second -
Grok Imagine 1.5 Lite xAI $0.029 /second -
Hailuo 2.3 MiniMax $0.270 /video -
Runway Gen 4.5 Runway $0.172 /second -
Creatify Boreal Creatify $0.015 /second
Same Provider
-
Nano Banana Pro Google $0.057 /image -
Nano Banana Google $0.021 /image -
Veo 3.1 Lite Google $0.060 /second -
Veo 3.1 Fast Google $0.170 /second -
Gemini Omni 1.1 Flash Google $0.450 /video -
Gemini Omni Google -- -
Lyria 3 Pro Google $0.140 /song -
Imagen 4 Google $0.030 /image -
Google Virtual Try-On Google $0.107 /image -
Lyria 3.5 Google $0.090 /song -
Nano Banana 2 Lite Google $0.033 /image -
Nano Banana 2 Google $0.036 /image