---
title: "Generate video"
method: POST
path: "/api/v1/ai/video"
tags: ["AI"]
---

# Generate video

`POST /api/v1/ai/video`

## Request

- Base URL: `https://core.blink.new`
- URL: `https://core.blink.new/api/v1/ai/video`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer

Generate video from text or an image using fal.ai. Billed per second of generated video under `ai:video`. Pass `x-blink-agent-id` for per-agent usage.

## Request body

- object
  - `prompt` string, required: Prompt describing the desired video.
  - `model` string: Video model to use (defaults to `fal-ai/veo3.1/fast`)
  - `duration` string: Desired video duration (model-dependent, e.g. `"5s"`, `"10s"`)
  - `image_url` string, uri: Starting image for image-to-video generation (when supported by the model)
  - `aspect_ratio` string: Aspect ratio of the output video (model-dependent)

## Response `200`

Video generated successfully

- object
  - `result` object
    - `video` object
      - `url` string, uri: Public CDN URL of the generated video
      - `content_type` string
      - `file_name` string, nullable
      - `file_size` integer, nullable
    - `seed` integer: Generation seed (when supported by the model)
    - `thumbnail` object, nullable
      - `url` string, uri
  - `metadata` object
    - `model` string
    - `provider` string
    - `timestamp` string, date-time
  - `durationSeconds` number: Duration of the generated video in seconds
  - `usage` object
    - `creditsCharged` number: Blink credits deducted
    - `costUSD` number: Upstream cost in USD

## Other responses

- `401`: Authentication required or invalid API key
- `500`: Video generation service not configured

---

[API](https://skmtc.dev/blink/apis/blink-apis.md) - [All operations](https://skmtc.dev/blink/apis/blink-apis/llms.txt) - [OpenAPI document](https://skmtc.dev/blink/apis/blink-apis/revisions/4c59c706078e?raw)
