Skip to content

Generate a Video

POST/v1/videos/generations

Overview

Create one text-to-video job using a direct xAI or Google Veo model.

Routing and provider details

Requires videos.write, an Idempotency-Key, funded credits and VIDEOS_ENABLED. Also available under /api/v1. A committed request authorizes exactly one native generation. Repeat the same request and idempotency key to read its status without generating again. The response contains an AudioLab job ID. Poll its status, then download content.

Prompts are limited to 1024 UTF-8 bytes. xAI admits 1–15 seconds at 480p square; Veo admits 4, 6 or 8 seconds at 720p 16:9. No input media, edits or provider options. A hold covers the reviewed provider maximum. xAI reports native monetary usage; Veo uses completed output seconds at the frozen published tariff. AudioLab charges 15% less than that tariff. An ambiguous dispatch retains its hold for reconciliation. Closing the client does not cancel provider generation. Content URLs expire; download promptly. Generation never restarts because content expired.

Authorization

Authorizationstring · headerRequired

AudioLab API key sent as Bearer <token>. Authentication guide

Parameters

Idempotency-Keyheader · stringRequired

Request Body

application/json
providerobject

Provider preferences for a single-endpoint product.

Show nested fields
data_regionstring | string[]

Route only to endpoints documented as processing in this region: us, eu (which includes EU member states), or a country code such as nl, sg, in or cn. A list matches any of its regions. Endpoints whose region is global or unknown never match; global on its own means no requirement. The request's region narrows the workspace's Data Region and a named router's region policy, and never widens them. Fallbacks keep to it. When no endpoint qualifies, the request is refused with 400 data_region_unavailable, param provider.data_region.

Show nested fields
Option 1: string

string

Option 2: string[]

See the OpenAPI schema for this nested object.

modelstringRequired

Values: "xai/grok-imagine-video""xai/grok-imagine-video-1.5""xai/grok-imagine-video-1.5-preview""xai/grok-imagine-video-1.5-2026-05-30"

promptstringRequired
durationintegerRequired

Minimum 1 · Maximum 15

resolutionstring

Default: "480p"

aspect_ratiostring

Default: "1:1"

Responses

200Previously completed video request; no regeneration.
202Generation accepted; poll the Location header for status.
400Missing or malformed idempotency key.
401Invalid API key.
402Insufficient credits for the hold.
403Scope, privacy, key-expiry or spending restriction.
409Idempotency key conflicts with another request.
422Unsupported model, media or generation options.
429Workspace concurrency or generation limit reached.
503Disabled model or unresolved provider response; inspect job status.