---
title: "Generate a video"
method: POST
path: "/v1/videos"
---

# Generate a video

`POST /v1/videos`

## Request

- Base URL: `https://api.octen.ai`
- URL: `https://api.octen.ai/v1/videos`
- Auth: one of:
  - HTTP bearer
  - API key in header `x-api-key`

Generates a video from a text prompt, optionally guided by reference images.

## Request body

- VideoGenerationRequest: JSON request body for the Video Generation API.
  - `model` 'minimax/minimax-h3' | 'bytedance/seedance-2.5' | 'google/veo-3.1' | 'google/veo-3.1-fast' | 'google/veo-3.1-lite', required: The model to use.
  - `prompt` string, required: The text description of the video.
  - `duration` integer: Video length in seconds. When omitted, the model default applies.
  - `resolution` '480p' | '720p' | '768p' | '1080p' | '2K': Output resolution. When omitted, the model default applies.
  - `aspect_ratio` '16:9' | '4:3' | '1:1' | '3:4' | '9:16' | '21:9' | 'adaptive': Aspect ratio. `adaptive` lets the model follow the input. When omitted, the model default applies.
  - `frame_images` VideoFrameImage[]: Images to use as the first and last frames of the video.
    - `image` string, required: Image URL or base64 data.
    - `frame_type` 'first_frame' | 'last_frame', required: Whether the image is the first or the last frame.
  - `input_references` VideoInputReference[]: Reference images that guide generation without locking specific frames.
    - `image` string, required: Image URL or base64 data.
  - `generate_audio` boolean: Whether to generate audio along with the video.
  - `seed` integer: Random seed, for more reproducible results.
  - `extra_params` object: Vendor-specific parameters, passed through to the upstream model without validation. Keys that duplicate a unified parameter, or that control upstream storage, notification, sample count, or platform behavior, are rejected.

## Response `200`

Successful video generation response. The task starts in `queued`.

- VideoGenerationResponse
  - `id` string, required: Unique task id, used to download the video.
  - `model` string, required: The model used for this task.
  - `status` 'queued', required: Task state.
  - `created` integer, required: Unix timestamp in seconds when the task was created.

## Other responses

- `400`: Missing or invalid parameter
- `401`: Invalid API Key
- `403`: Insufficient balance in account
- `404`: Model or resource not found
- `429`: Exceeding the rate limit
- `500`: Internal error

---

[API](https://skmtc.dev/octen/apis/octen-api.md) - [All operations](https://skmtc.dev/octen/apis/octen-api/llms.txt) - [OpenAPI document](https://skmtc.dev/octen/apis/octen-api/revisions/aaa6caaf46b0?raw)
