Veo 3.1 API — Access via an AI API Gateway (gemini-veo31)
Veo 3.1 is Google's flagship text-to-video model: high visual fidelity, 1080p support, and a knack for cinematic camera work and lifelike motion. Call it through byesu — an AI API gateway with OpenAI-compatible and Anthropic-native endpoints, where one key covers Claude, GPT-5.6, Grok, Gemini and media models alike, billed pay-as-you-go with no subscription. On the platform its model name is gemini-veo31, served over an official upstream channel (not a reverse-engineered or mirrored one) and billed per second at a unit price of $0.01875/sec (your live billed price and the crossed-out official list price are visible in the console).
OpenAI's Sora API is officially scheduled to shut down on 2026-09-24, making Veo 3.1 one of the leading mainstream alternatives for a text-to-video API. Migrating from Sora through the byesu gateway is a base URL and model-name swap.
In one line: what it is
- Model: Google Veo 3.1 text-to-video, platform model name
gemini-veo31 - Capabilities: text-to-video, image-to-video (first-frame reference, up to 2 images), selectable duration of 4s / 6s / 8s, 1080p support
- Billing: per-second billing at a unit price of $0.01875/sec (e.g. 8 seconds ≈ $0.15); video price = unit price × duration
- Access: OpenAI-compatible async video endpoint at
https://byesu.com/v1; tokens must use themedia / media-gengroup
How to call it (ready to run)
Veo 3.1 runs as an async task in three steps: create task → poll status → download mp4.
Token must use the media group
The token you use to call video models must belong to the media / media-gen group, otherwise you'll get a "no available channel" error. Just create a new token with that group in the console.
1) Create the task (curl)
curl https://byesu.com/v1/videos \
-H "Authorization: Bearer sk-YOUR_TOKEN" \
-H "Content-Type: application/json" \
-d '{
"model": "gemini-veo31",
"prompt": "Waves crashing on rocks, slow motion, cinematic, dusk light",
"seconds": "8",
"size": "1280x720"
}'The response includes the task id and status. Use them to poll:
# Poll status (replace {id})
curl https://byesu.com/v1/videos/{id} \
-H "Authorization: Bearer sk-YOUR_TOKEN"
# Download the mp4 once complete
curl https://byesu.com/v1/videos/{id}/content \
-H "Authorization: Bearer sk-YOUR_TOKEN" -o out.mp42) Full flow (Python)
import requests, time
BASE = "https://byesu.com"
H = {"Authorization": "Bearer sk-YOUR_TOKEN"}
# 1. Create the task
task = requests.post(f"{BASE}/v1/videos", headers=H, json={
"model": "gemini-veo31",
"prompt": "Waves crashing on rocks, slow motion, cinematic, dusk light",
"seconds": "8", # duration (seconds): 4 / 6 / 8
"size": "1280x720", # express aspect ratio via size; 1920x1080 = 1080p
}).json()
# 2. Poll until done (anywhere from tens of seconds to a few minutes is normal)
while task["status"] not in ("completed", "failed"):
time.sleep(5)
task = requests.get(f"{BASE}/v1/videos/{task['id']}", headers=H).json()
# 3. Download the mp4 (failures are auto-refunded, no manual claim needed)
if task["status"] == "completed":
mp4 = requests.get(f"{BASE}/v1/videos/{task['id']}/content", headers=H)
open("out.mp4", "wb").write(mp4.content)
print("Saved out.mp4")3) Image-to-video (use an image as the first frame)
To make a video animate from a still image, switch the create request to multipart/form-data, put the first-frame image in the input_reference file field, and pass the remaining parameters as form fields:
curl https://byesu.com/v1/videos \
-H "Authorization: Bearer sk-YOUR_TOKEN" \
-F model="gemini-veo31" \
-F prompt="Slow push-in shot as wind stirs the leaves in the frame" \
-F seconds="8" \
-F size="1280x720" \
-F input_reference=@first_frame.pngPolling and downloading work exactly the same as text-to-video.
Key parameters
| Parameter | Required | Description |
|---|---|---|
model | ✅ | Always gemini-veo31 |
prompt | ✅ | The prompt. Describe scene + action + camera, e.g. "aerial night cityscape, car-light trails, orbiting camera" |
seconds | Duration (seconds); Veo 3.1 supports 4 / 6 / 8; omit to use the default | |
size | Express aspect ratio via size: 1280x720 (16:9), 720x1280 (9:16), 1920x1080 (1080p) | |
input_reference | First-frame image for image-to-video (up to 2 images); only available on multipart requests |
The status returned by polling can be completed / failed and so on; failed triggers an automatic refund, so you aren't charged.
How per-second billing is calculated
Veo 3.1's unit price is $0.01875/sec. Total = $0.01875 × seconds. For example, 6 seconds ≈ $0.1125, 8 seconds ≈ $0.15. Your live billed price and the crossed-out official list price are shown directly in the generation playground once you pick a duration.
Why use byesu for Veo 3.1
- Official upstream, no degradation: calls go through the official channel, not a reverse-engineered or mirrored one, so quality and capability match the official service and stay reliable.
- One gateway, one key: the same
sk-token also covers Claude, GPT-5.6, Grok, Gemini and image models — mix text and media generation in a single integration. - Transparent per-second pricing: $0.01875/sec is clearly listed, and the console shows your live billed price next to the crossed-out official list price — usage-based charging with no ambiguity.
- Auto-refund on failure: video tasks are async, and if generation fails, the cost is automatically refunded — no manual claim needed.
- OpenAI-compatible endpoint: a standard async video API, callable directly from Python / Node / HTTP in any language.
- Pay-as-you-go, no subscription: top up with USDT, Alipay or WeChat Pay and pay only for what you generate.
- Docs in 6 languages + an online playground: if you'd rather not write code, try the generation playground first to validate the output.
Related links
- 📄 Media generation overview (image / video)
- 🎬 Video generation models and parameters
- 🔧 Calling via the API (full request format)
- 🚀 Quickstart (3-step setup)
- 🎨 Online generation playground
- 🔑 Console sign-up / create a token
FAQ
How do I get Veo 3.1 API access?
Sign up at the byesu console, create a token in the media / media-gen group, and call gemini-veo31 through the OpenAI-compatible async video endpoint at https://byesu.com/v1. byesu is an AI API gateway — the same key also covers Claude, GPT-5.6, Grok and Gemini, billed pay-as-you-go with no subscription. No Google Cloud account is required.
How much does the Veo 3.1 API cost?
On byesu, Veo 3.1 (gemini-veo31) is billed per second at a unit price of $0.01875/sec. Total video price = unit price × duration — for example, 6 seconds is about $0.1125 and 8 seconds is about $0.15. The console shows your live billed price next to the crossed-out official list price, and failed video tasks are automatically refunded.
Does Veo 3.1 support image-to-video?
Yes. When creating the task, use multipart/form-data format and put the first-frame image in the input_reference file field (up to 2 images); the model will animate a video starting from that image. For text-to-video, use a plain JSON request and simply omit the image.
What should I do if calling Veo 3.1 returns "no available channel"?
It's almost always the wrong token group. Video models require a token in the media / media-gen group — create a new token in that group in the console and retry. Also confirm the model name is exactly gemini-veo31, spelled precisely.
How long does it take Veo 3.1 to generate a video?
Video generation is slower than images; anywhere from tens of seconds to a few minutes is normal. It's an async task: after creating the task, poll GET /v1/videos/{id} for its status, and once it becomes completed, download the mp4 from the /content endpoint. Don't create the task repeatedly.
With the Sora API shutting down, is Veo 3.1 a good replacement?
Yes. OpenAI's Sora API is officially scheduled to shut down on 2026-09-24, and Veo 3.1 is one of today's leading mainstream text-to-video alternatives — strong visual quality with 1080p and image-to-video support. byesu provides official upstream access at $0.01875/sec with auto-refund on failure, so migrating from Sora is a base URL and model-name swap.
