Skip to main content
POST
/
v1
/
videos
/
generations
Create video generation
curl --request POST \
  --url https://api.infery.ai/v1/videos/generations \
  --header 'Authorization: <api-key>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "model": "<string>",
  "prompt": "<string>",
  "duration": 123,
  "resolution": "<string>",
  "aspect_ratio": "<string>",
  "n": 1,
  "image_url": "<string>",
  "person_generation": "allow_all"
}
'
{
  "id": "vgen_01HYJ8F3K9QT2X5Z7N1V6W3B4R",
  "status": "queued",
  "progress": 0,
  "created": 1713204900,
  "model": "veo-3-1-fast"
}
Video generation is asynchronous. Submit → receive job_id → poll the status endpoint until complete.

Submit a job

curl https://api.infery.ai/v1/videos/generations \
  -H "Authorization: Bearer $INFERY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "veo-3-1-fast",
    "prompt": "A cat surfing on a banana at sunset, cinematic",
    "duration_seconds": 4,
    "resolution": "720p",
    "aspect_ratio": "16:9"
  }'
Response:
{
  "job_id": "vgen_...",
  "status": "queued",
  "created_at": 1713204900,
  "model": "veo-3-1-fast"
}

Image-to-video

Pass a reference image via image_url or image_base64:
{
  "model": "veo-3-1-fast",
  "prompt": "Animate this photo with gentle camera pan",
  "image_base64": "<base64 of source image>"
}

Supported models

Google Veo (3 and 2), OpenAI Sora, xAI (Grok Video), Alibaba Wan. See Models catalog.

Storage

Completed videos are auto-mirrored to GCS — the returned url is signed and persists past the upstream provider’s ephemeral URLs. To reference a generated video later, use our GET /v1/files/:id/content pattern or keep the signed URL.

Authorizations

Authorization
string
header
required

API key in format: Bearer inf_***

Body

application/json
model
string
required

Model ID to use for generation

prompt
string
required

Text prompt describing the video to generate

duration
number

Duration in seconds (model-specific, see /v1/models)

resolution
string

Video resolution (model-specific, see /v1/models)

aspect_ratio
string

Video aspect ratio (model-specific, see /v1/models)

n
integer
default:1

Number of videos to generate

image_url
string

Reference image URL for image-to-video

person_generation
enum<string>
default:allow_all

Person generation policy (Google Veo models)

Available options:
dont_allow,
allow_adult,
allow_all

Response

Video generation job submitted. Poll GET /v1/videos/generations/{jobId} until status === "succeeded".

id
string

Job ID to poll for status

Example:

"vgen_01HYJ8F3K9QT2X5Z7N1V6W3B4R"

status
enum<string>
Available options:
queued,
processing,
succeeded,
failed
Example:

"queued"

progress
integer

Progress percentage (0-100)

Example:

0

created
integer
Example:

1713204900

model
string
Example:

"veo-3-1-fast"