Source: https://www.tokenify.dev/veo-api/

# Veo code, on MiniMax H3: the same Gemini API call

Tokenify does not serve Veo: it takes the Gemini API's long-running video call on the same paths, so a Veo request runs on MiniMax H3 by changing the base URL, the key and the model in the path. From **$0.024/s at 720p**, prices as of 2026-11-29.

[Get API key](https://www.tokenify.dev/app/signup) Use in your agent 

Connect the Tokenify MCP server

Paste this into the agent’s chat:

Claude Code

Add the Tokenify MCP server for all my projects by running: claude mcp add --transport http --scope user tokenify https://api.tokenify.dev/mcp — then tell me to start a new conversation, where you will ask me to sign in.

Codex

Add the Tokenify MCP server by running: codex mcp add tokenify --url https://api.tokenify.dev/mcp — then tell me to restart Codex and sign in with Authenticate next to tokenify in Settings > MCP servers (in a terminal: codex mcp login tokenify).

In Claude (claude.ai or the desktop app): open Connectors, choose Add custom connector and enter https://api.tokenify.dev/mcp. Claude opens Tokenify to sign in. On a Team or Enterprise plan an owner adds it for the organisation.

A browser opens to sign in and pick the project to spend from. The agent quotes each generation and, by default, asks you before one that costs $1 or more.

In a terminal instead 

Claude Code

```
claude mcp add --transport http tokenify https://api.tokenify.dev/mcp
```

Codex

```
codex mcp add tokenify --url https://api.tokenify.dev/mcp
codex mcp login tokenify
```

No MCP in your client? Paste a prompt instead 

With a key in TOKENIFY\_API\_KEY

Read https://www.tokenify.dev/agents.md — it describes the Tokenify API, at https://api.tokenify.dev. Use it to generate video with minimax/minimax-h3-economy, with the key in my TOKENIFY\_API\_KEY environment variable. Tell me the price before each call, and ask me first if this task's total could reach $1 or more, or if you cannot work out what a call will cost. Save every result into this project: decode an image that comes back inline, and download anything returned as a link, because links expire after 7 days.

## What happened

**Google shut its three Veo 3.1 Preview models — standard, Fast and Lite — down on 22 October 2026** and names Gemini Omni 1.2 Flash as their replacement. Its Python SDK no longer generates video in Gemini Developer API mode. Veo itself is still sold on Google's enterprise platform.

- A `predictLongRunning` request naming `veo-3.1-generate-preview`, its Fast or its Lite variant fails at the Gemini API: the models are gone.
- `client.models.generate_videos(…)` in `google-genai` 3.6.1 raises before it sends anything in Developer API mode.
- The REST call it wraps still works — here, against our models, with the base URL, the key and the model changed.

## The change

Before

```bash
curl -s "https://generativelanguage.googleapis.com/v1beta/models/veo-3.1-generate-preview:predictLongRunning" \
  -H "x-goog-api-key: $GEMINI_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "instances": [{"prompt": "A paper boat on still water"}],
    "parameters": {"aspectRatio": "16:9", "resolution": "720p", "durationSeconds": "8"}
  }'
```

After

```bash
curl -s "https://api.tokenify.dev/v1beta/models/minimax/minimax-h3-economy:predictLongRunning" \
  -H "x-goog-api-key: $TOKENIFY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "instances": [{"prompt": "A paper boat on still water"}],
    "parameters": {"aspectRatio": "16:9", "resolution": "720p", "durationSeconds": "8"}
  }'
```

The base URL, the key and the model in the path. The body and the polling are the same.

## What maps, and what is refused

| Field                                                   | Gemini API Veo 3.1 Preview                                                 | Here                                                                                                            |                                                            |
| ------------------------------------------------------- | -------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------- | ---------------------------------------------------------- |
| aspectRatio                                             | "16:9" \| "9:16"                                                           | The same                                                                                                        |                                                            |
| resolution                                              | "720p" \| "1080p", and "4k" except on Lite; 1080p and 4k only at 8 seconds | One of the model's own bands; a band it does not make is refused, not substituted. Omitted, 720p                |                                                            |
| durationSeconds                                         | "4" \| "6"                                                                 | "8"                                                                                                             | A string or a number, in the model's own range. Omitted, 8 |
| instances\[0\].image                                    | A first frame, inline                                                      | The same                                                                                                        |                                                            |
| instances\[0\].video                                    | A video to extend, returned joined to its continuation                     | A reference video, on the models that take one, at the lower video-input rate. The result is the new clip alone |                                                            |
| numberOfVideos                                          | 1                                                                          | 1; anything above is refused rather than served once                                                            |                                                            |
| instances\[0\].lastFrame                                | A last frame                                                               | Refused by name                                                                                                 |                                                            |
| referenceImages, personGeneration, seed, negativePrompt | Accepted                                                                   | Refused by name: none of them would be honoured, and a setting quietly ignored is worse                         |                                                            |
| fileData / fileUri                                      | Their Files API                                                            | Refused: send the bytes as inlineData                                                                           |                                                            |

A value this endpoint cannot honour is refused by name rather than quietly adjusted, so a request is never answered as though your setting had been used when it was not. [The full guide](https://www.tokenify.dev/docs/video/veo/) has every field.

## What to move to, and what it costs

| Model                                                                     | Where                                                                 | Per second |
| ------------------------------------------------------------------------- | --------------------------------------------------------------------- | ---------- |
| Gemini Omni 1.2 Flash                                                     | Google, its named replacement for Veo 3.1 Preview, about this at 720p | $0.070     |
| [MiniMax H3 Economy](https://www.tokenify.dev/models/minimax-h3-economy/) | Here, 720p                                                            | $0.024     |

Their rates as published, checked 2026-11-24\. Ours is the cheapest model here that makes 720p from a prompt; [every video model](https://www.tokenify.dev/video/) is on one page.

Prices updated 2026-11-29, from the catalogue the gateway bills from.

## The whole call

**Gemini API (Veo)**

```bash
curl -s "https://api.tokenify.dev/v1beta/models/minimax/minimax-h3-economy:predictLongRunning" \
  -H "x-goog-api-key: $TOKENIFY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "instances": [{"prompt": "A paper boat on still water, dawn light"}],
    "parameters": {"aspectRatio": "16:9", "resolution": "720p", "durationSeconds": "4"}
  }'

# poll the operation it returns until "done" is true
curl -s "https://api.tokenify.dev/v1beta/models/minimax/minimax-h3-economy/operations/OPERATION_ID" \
  -H "x-goog-api-key: $TOKENIFY_API_KEY"
```

**curl**

```bash
curl https://api.tokenify.dev/contents/generations/tasks \
  -H "Authorization: Bearer $TOKENIFY_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "minimax/minimax-h3-economy",
    "resolution": "480p",
    "duration": 4,
    "ratio": "16:9",
    "content": [{"type": "text", "text": "A paper boat on still water, dawn light"}]
  }'

# poll until the status is terminal
curl https://api.tokenify.dev/contents/generations/tasks/TASK_ID \
  -H "Authorization: Bearer $TOKENIFY_API_KEY"
```

## Questions people ask before signing up

Do you serve Veo? 

No. We serve the Gemini API's video protocol — predictLongRunning and the operation it returns — in front of other video models, so code written for Veo keeps working with a different base URL, key and model. Veo itself is still sold on Google's enterprise platform.

Can I keep using the google-genai SDK? 

Not for video. In google-genai 3.6.1, generate\_videos in Gemini Developer API mode raises before it sends anything, and its enterprise mode sends to a different host and path, which is not served here. The REST call the Developer API mode wraps is, and that is what this page shows.

What happens if I send a Veo model id here? 

It is refused by name, with a pointer to the model list. The model in the path is one of ours; answering under the name you asked for would put a model we did not run on your bill.

Does my polling change? 

No. The submit returns an operation name and you poll it until done, exactly as their sample does. A failed job is refunded in full.

Can I extend a video I already have? 

On the models that take one, a video sent inline is a reference the new clip works from, charged at the lower rate for video input. The result is the new clip alone — not your clip with the continuation joined on, as Veo returned — so a pipeline that expects the joined video has to join them itself.

Why MiniMax H3 Economy? 

It is the cheapest model here that makes 720p — what a request with no resolution gets — from a prompt alone. Every video model takes the same request shape, but the resolution has to be one of that model's own bands; the video page lists them.

Can I use the free credit for video? 

No. Video needs a project that has paid in at least $5 of top-ups and kept it, and a balance that covers the job when it is submitted. Until then a request is refused with a link to the billing page.

Last updated 2026-11-24\. Prices come from the live catalogue at the time this page was built.
