> Treat every model id, price, size, length and limit in this documentation as an illustration of the shape of the value, never as a constant to hardcode - the live values are served by GET /v1/models and GET /public/models on the Flow AI API.

# Multimodal

> Send images, PDFs, audio and video to a model, or generate images and video.

Beyond text, Flow AI lets you send images, PDFs, audio and video to models that understand them, and generate images and video from a prompt. Everything goes through the same API and the same key.

## Inputs

All inputs go to `POST /v1/chat/completions`. Instead of a string, a message's `content` is a list of parts, and each part has a `type`:

| Input | Part `type`   | Page                                     |
| ----- | ------------- | ---------------------------------------- |
| Image | `image_url`   | [Image inputs](/multimodal/image-inputs) |
| PDF   | `file`        | [PDF inputs](/multimodal/pdf-inputs)     |
| Audio | `input_audio` | [Audio inputs](/multimodal/audio-inputs) |
| Video | `video_url`   | [Video inputs](/multimodal/video-inputs) |

You can mix text with several inputs, of one kind or several, in one message. How many a request can carry depends on the model.

```json
{
  "role": "user",
  "content": [
    { "type": "text", "text": "Compare the chart with the report." },
    { "type": "image_url", "image_url": { "url": "https://example.com/chart.png" } },
    { "type": "file", "file": { "filename": "report.pdf", "file_data": "data:application/pdf;base64,..." } }
  ]
}
```

## Outputs

| Output | Endpoint                                               | Page                                             |
| ------ | ------------------------------------------------------ | ------------------------------------------------ |
| Images | `POST /v1/images/generations`, `POST /v1/images/edits` | [Image generation](/multimodal/image-generation) |
| Video  | `POST /v1/videos`                                      | [Video generation](/multimodal/video-generation) |

Chat models answer in text. Audio output, text-to-speech and speech-to-text aren't available.

## URL or base64

| Input | URL                         | Base64                                       |
| ----- | --------------------------- | -------------------------------------------- |
| Image | Yes                         | Yes, as a `data:image/...;base64,` URL       |
| PDF   | Depends on the model        | Yes, as a `data:application/pdf;base64,` URL |
| Audio | No                          | Yes, raw base64 with a `format`              |
| Video | Depends on the model's host | Yes, as a `data:video/...;base64,` URL       |

> **Tip**
>
> For public files, a URL keeps the request small and skips encoding. Use base64 for local or private files.

## Which models take what

Every chat model takes text. Images, PDFs, audio and video depend on the model. Flow AI checks each part against what the model takes **before anything is held**: a part the model can't read is refused with a `400` that names the model and the content, for example:

```json
{ "error": { "message": "openai/gpt-6-luna does not take audio content", "code": "invalid_request" } }
```

Nothing is charged for a refused request.

## Billing

The model turns every input into input tokens, and you pay for them at its input price. How many tokens an image, a PDF page, a second of audio or a second of video takes depends on the model, so check `usage.prompt_tokens` on a first request. Image and video generation are priced per image and per second; see their pages.

**Next:** [Image Inputs](/multimodal/image-inputs) — send pictures to a chat model.