Your platform API key (same header as the Gemini-compatible API). See Authentication.
Video Generation (Veo)
Generate a short video (MP4, up to 8 seconds) with veo-3.1-generate-001. Returns
202 Accepted with a job_id — poll GET /jobs/{job_id} until the
job is done or failed. On success, result.image_url is a direct link to the MP4 file.
POST /api/gemini/v1beta/interactionsHeaders
Section titled “Headers”x-goog-api-key string requiredmodel string requiredAlways veo-3.1-generate-001.
instances array requiredExactly one object with a prompt field — the video description.
parameters.durationSeconds integerVideo length, 1–8 seconds. Default 4.
Response
Section titled “Response”Returns 202 Accepted.
job_id stringUUID of the created job.
status stringAlways queued on creation.
status_url stringRelative path to poll for status and result.
curl -s -X POST https://api.moonez.ai/api/gemini/v1beta/interactions \ -H "x-goog-api-key: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "model": "veo-3.1-generate-001", "instances": [{"prompt": "a cat walking through a neon city at night"}], "parameters": {"durationSeconds": 4} }'import requests
resp = requests.post( "https://api.moonez.ai/api/gemini/v1beta/interactions", headers={"x-goog-api-key": API_KEY}, json={ "model": "veo-3.1-generate-001", "instances": [{"prompt": "a cat walking through a neon city at night"}], "parameters": {"durationSeconds": 4}, },)print(resp.json())Unified jobs API
Section titled “Unified jobs API”Veo is also available through the platform’s own jobs API — the same
POST /api/v1/generations endpoint used for image and text models. Add
duration_seconds (4–8) to the body:
curl -s -X POST https://api.moonez.ai/api/v1/generations \ -H "Authorization: Bearer *** \ -H "Content-Type: application/json" \ -d '{ "model": "veo-3.1-generate-001", "prompt": "a cat walking through a neon city at night", "aspect_ratio": "16:9", "resolution": "720p", "duration_seconds": 4 }'Returns 202 Accepted with a job_id — poll GET /jobs/{job_id}
until done; result.image_url is a direct link to the MP4 file. Billing is the same as
all video generations: per second of video (price per second × duration).
Resolution
Section titled “Resolution”Veo supports three resolutions, exactly like Google: 720p, 1080p and 4k
(1K is accepted as a legacy alias for 720p). Each resolution has its own
per-second price, configurable in the admin panel and shown to clients.
720p— 4–8 second videos.1080p,4k— 8-second videos only (Google’s limit); requesting them with a shorter duration returns400.
Billing
Section titled “Billing”- Billed per second of video (like Google’s own Veo billing): the price shown in your
panel is per second, and a generation is charged
price_per_second(resolution) × duration_seconds. Each resolution has its own rate. - A reservation is placed when the job is created and charged on success; on failure it is released automatically.