API documentation
The VEO Studio API makes the same videos and images as the Video Generation and Image Generation pages of this website, from your own code or from tools such as n8n and Make. You send a prompt (and images, if you want), you get an id back at once, and you ask for that id until the video or image is ready.
Quick start
- Log in and open API keys. Press Generate API key and copy the key. It is shown only once.
- Ask for a video:
curl -X POST https://api.veostudio.net/v1/videos \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "veo-3.1-lite",
"prompt": "A red fox runs through fresh snow at sunrise, slow motion, cinematic",
"aspect_ratio": "16:9"
}'{
"success": true,
"video": {
"id": "3f6c1b1e-8a52-4d0f-9d3c-2b7f5c1a9e10",
"object": "video",
"model": "veo-3.1-lite",
"mode": "text_to_video",
"prompt": "A red fox runs through fresh snow at sunrise, slow motion, cinematic",
"aspect_ratio": "16:9",
"status": "queued",
"done": false,
"success": false,
"progress": "Waiting",
"error": null,
"video_url": null,
"download_url": null,
"created_at": "2026-11-14T10:15:02.000Z"
}
}- Ask for the video by its
idevery few seconds untildoneistrue:
curl https://api.veostudio.net/v1/videos/VIDEO_ID \
-H "Authorization: Bearer YOUR_API_KEY"{
"success": true,
"video": {
"id": "3f6c1b1e-8a52-4d0f-9d3c-2b7f5c1a9e10",
"status": "completed",
"done": true,
"success": true,
"video_url": "https://…/video.mp4?…",
"download_url": "https://…/video.mp4?…",
"duration_seconds": 8,
"width": 1280,
"height": 720,
"finished_at": "2026-11-14T10:16:21.000Z",
"expires_at": "2026-11-14T16:16:21.000Z"
}
}download_url is a direct link to the MP4 file. Save the file on your side: the link and the file are kept for a limited time (see expires_at).
Your API key
- Every request carries the key in a header:
Authorization: Bearer YOUR_API_KEY. The headerX-API-Key: YOUR_API_KEYis accepted as well. - API access is a permission of its own on your plan. If the API keys page says it is not switched on, see the API plans.
- You can have up to 5 keys. Use one per tool, so that revoking one does not stop the others.
- Revoking a key on the API keys page stops it within seconds. A revoked key cannot be brought back; make a new one.
- Keep the key on your server. Never put it in a web page, a mobile app or a public repository: anyone who has it can use your plan. If a key leaks, revoke it.
- One key may send up to 240 requests per minute.
Models and modes
| Model | Length | Modes | Images |
|---|---|---|---|
| veo-3.1-lite | 8 seconds | text_to_video, image_to_video, ingredients, first_last_frame | up to 3 ingredients |
| omni-10 | 10 seconds | text_to_video, image_to_video, ingredients | up to 10 ingredients |
Which models your account may use depends on your plan. GET /models gives the list for your key, with allowed true or false for each one, and the qualities you may ask for. Videos are 16:9 or 9:16, in 720p; veo-3.1-lite can also be asked for in 1080p.
| Mode | What it does | What you send |
|---|---|---|
| text_to_video | A video from the prompt alone. | prompt |
| image_to_video | The video starts from your image. | prompt, image |
| first_last_frame | The video starts from one image and ends on another. | prompt, first_frame, last_frame |
| ingredients | Your images show who or what should be in the video (characters, objects, a place). | prompt, images |
You do not have to send mode: it follows from the image fields you send. If you do send it and it does not fit the images, the request is refused with BAD_MODE.
Make a video
POST/videosStarts one video and answers at once with its id.
| Field | Type | Meaning |
|---|---|---|
| prompt | text, required | What should happen in the video. 3 to 2000 characters. |
| model | text | veo-3.1-lite (used when left out) or omni-10. |
| aspect_ratio | text | 16:9 (used when left out) or 9:16. When the video starts from your image, send an image of the same shape. |
| quality | text | 720p (used when left out) or 1080p. 1080p is for veo-3.1-lite, needs its own permission on your plan, and takes longer. If the 1080p copy cannot be made you still get the 720p video, and the reply says 720p. |
| image | image id | Image to video: the first frame. |
| first_frame, last_frame | image ids | First and last frame. Both are needed. |
| images | list of image ids | Ingredients (reference images). |
| image_names | list of text | Optional name for each ingredient, in the same order (for example ["Zara", "Momo"]). Use the same names in the prompt. |
| mode | text | Optional. One of the four modes above. |
| auto_rewrite | true or false | Optional, off when left out. When the safety filter refuses the wording of your prompt, we reword it and try again, up to 3 times. See When a video or image fails. |
{
"model": "veo-3.1-lite",
"prompt": "The woman turns to the camera and smiles",
"image": "IMAGE_ID"
}{
"model": "veo-3.1-lite",
"prompt": "The camera flies from the beach up to the lighthouse",
"first_frame": "FIRST_IMAGE_ID",
"last_frame": "LAST_IMAGE_ID"
}{
"model": "veo-3.1-lite",
"prompt": "Zara and her cat Momo walk through a night market",
"images": ["IMAGE_ID_1", "IMAGE_ID_2"],
"image_names": ["Zara", "Momo"],
"aspect_ratio": "9:16"
}One request makes one video. To make many, send many requests: your plan decides how many may be in progress at the same time (see Account and limits). When that number is reached the reply is 429 TOO_MANY_ACTIVE; wait for one to finish and send the next.
Images
POST/uploadsStores one image and gives back its id.
- Send JSON with
image_base64: the file's bytes in base64 (adata:image/…;base64,prefix is accepted). - PNG, JPG or WebP, up to 8 MB each.
- An uploaded image is kept for 24 hours and can be used in any number of videos during that time. It belongs to your account only.
curl -X POST https://api.veostudio.net/v1/uploads \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d "{\"image_base64\": \"$(base64 -w0 photo.jpg)\"}"{ "success": true, "id": "0b7e2c4a-5d1f-4e8a-9c3b-7a6d5e4f3c2b.jpg", "expires_in_hours": 24 }Wait for the video
GET/videos/{id}The video as it is now.
| status | done | Meaning |
|---|---|---|
| queued | false | Waiting for its turn. |
| running | false | Being made. progress says where it is (Waiting, Preparing, Generating video, Finishing). |
| completed | true | Ready. success is true; video_url plays it, download_url saves it. |
| failed | true | Not made. error says why in plain words, error_code is the same reason as a fixed word, and retryable says whether sending the same request again can help. A failed video is not counted against your limits. |
| canceled | true | You canceled it before it started. |
| expired | true | It was made, but its file has been removed since. |
- Stop your loop on
done, then look atsuccess. A loop that only waits forcompletednever ends when a video fails. - Ask every 5 seconds or so. A video usually takes one to three minutes; at busy times it can wait longer in line.
- The links are signed and change with time. Use the ones from your latest reply, and download the file soon after it is ready.
Make an image
POST/imagesStarts one image and answers at once with its id. Text to image, or image to image when you send images.
| Model | Thinking levels | Images you may send |
|---|---|---|
| nano-banana-lite (used when left out) | none | up to 5 |
| nano-banana-2.1 | low (used when left out), medium, high | up to 5 |
| nano-banana-pro | none | up to 5 |
| Field | Type | Meaning |
|---|---|---|
| prompt | text, required | What the image should show, or what should change in your image. 3 to 2000 characters. |
| model | text | One of the three models above. |
| aspect_ratio | text | 16:9 (used when left out), 9:16, 1:1, 4:3 or 3:4. |
| thinking | text | For nano-banana-2.1 only: low, medium or high. A higher level takes longer and follows a detailed prompt more closely. Sending it with another model is refused with BAD_THINKING. |
| image or images | image id, or a list of ids | Image to image: ids from POST /uploads. Leave them out for text to image. |
curl -X POST https://api.veostudio.net/v1/images \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "nano-banana-2.1",
"prompt": "A red fox asleep in fresh snow at sunrise, soft light, photo",
"aspect_ratio": "1:1",
"thinking": "low"
}'{
"model": "nano-banana-pro",
"prompt": "The same woman, now in a rainy street at night, neon light",
"images": ["IMAGE_ID"],
"aspect_ratio": "9:16"
}GET/images/{id}The image as it is now. The fields status, done, success, progress, error, error_code and retryable mean the same as for a video; an image usually takes 10 to 30 seconds, so ask every 2 or 3 seconds.
{
"success": true,
"image": {
"id": "8b1d2f0a-6c3e-4a57-9f10-5d2c7e9a1b34",
"object": "image",
"model": "nano-banana-2.1",
"mode": "text_to_image",
"aspect_ratio": "1:1",
"thinking": "low",
"status": "completed",
"done": true,
"success": true,
"image_url": "https://…",
"download_url": "https://…",
"finished_at": "2026-11-15T10:16:21.000Z",
"expires_at": "2026-11-15T16:16:21.000Z"
}
}GET/imagesThe images made with your keys, newest first (?limit=, ?before= as for videos).
POST/images/{id}/cancelStops an image that has not started yet.
DELETE/images/{id}Removes a finished, failed or canceled image for good.
- Images need the image permission on your plan and have their own daily and monthly count. They do not use your video count.
GET /modelslists the image models too, withtype: "image".
List, cancel, delete
GET/videosThe videos made with your keys, newest first. ?limit= 1 to 100 (20 when left out); ?before= a created_at value, for the next page.
POST/videos/{id}/cancelStops a video that has not started yet. One that is already being made cannot be stopped (409 CANNOT_CANCEL).
DELETE/videos/{id}Removes a finished, failed or canceled video and its file for good.
Account and limits
GET/accountYour plan, how many videos may be in progress at once, today's and this month's counts, and the models you may use.
GET/modelsThe models, their modes, and whether your account may use each one.
- Videos made with a key count toward the same plan limits as videos made on the website. They also appear in your Library.
- Your account may have its own limit for API videos per day or per month, on top of the plan's limits.
- Daily counts start again at midnight Pakistan time; a reply that refuses a request for the daily limit carries
resets_at.
Errors
A refused request has success: false, a sentence in error that you can show to a person, and a fixed word in errorCode that your code can test.
{
"success": false,
"error": "You have reached today's limit of 50 videos.",
"errorCode": "DAILY_LIMIT_REACHED",
"daily_limit": 50,
"resets_at": "2026-11-14T19:00:00.000Z"
}| HTTP | errorCode | What to do |
|---|---|---|
| 401 | API_KEY_REQUIRED, API_KEY_INVALID | Send the header; check the key was not revoked. |
| 403 | API_ACCESS_REQUIRED | API access is not on for the account. Contact support. |
| 403 | MODEL_NOT_ALLOWED, ACCESS_EXPIRED, QUOTA_EXHAUSTED | The plan does not cover this model, has ended, or has no videos left. Renew or upgrade. |
| 400 | PROMPT_REQUIRED, PROMPT_TOO_LONG, BAD_MODE, BAD_ASPECT, BAD_THINKING, MODEL_UNAVAILABLE, MODE_UNAVAILABLE, QUALITY_UNAVAILABLE | Fix the request; the sentence in error says what is wrong. |
| 400 | IMAGE_REQUIRED, BAD_REF, TOO_MANY_REFS, BAD_IMAGE, FILE_TOO_LARGE | An image is missing, expired (upload it again), too many, not PNG/JPG/WebP, or over 8 MB. |
| 429 | TOO_MANY_ACTIVE | As many videos as your plan allows are in progress. Wait for one to finish. |
| 429 | DAILY_LIMIT_REACHED, MONTHLY_LIMIT_REACHED | Stop sending until resets_at (daily) or until the limit is renewed (monthly). |
| 429 | RATE_LIMITED | Too many requests in a minute. Wait the seconds in the Retry-After header. |
| 404 | NOT_FOUND | No video with this id on your account. |
| 500 | none | Our side. Try again after a short wait. |
When a video or image fails
A video or image that was accepted and then could not be made is not an HTTP error. The reply to GET /videos/{id} (or /images/{id}) is a normal 200 with status failed and three fields that say why:
{
"success": true,
"video": {
"id": "3f6c1b1e-8a52-4d0f-9d3c-2b7f5c1a9e10",
"status": "failed",
"done": true,
"success": false,
"error": "The prompt was flagged as dangerous content. (PUBLIC_ERROR_DANGER_FILTER)",
"error_code": "PUBLIC_ERROR_DANGER_FILTER",
"retryable": false,
"video_url": null,
"download_url": null
}
}error: a sentence you can show to a person.error_code: a fixed word your code can test (the table below).retryable:truemeans the same request may work if you send it again;falsemeans it will fail the same way until you change the prompt or the image.- A failed video or image is never counted against your daily, monthly or plan limits.
| error_code | retryable | Meaning and what to do |
|---|---|---|
| PUBLIC_ERROR_SEXUAL, PUBLIC_ERROR_VIOLENCE, PUBLIC_ERROR_DANGER_FILTER, PUBLIC_ERROR_DANGEROUS, PUBLIC_ERROR_HATE_SPEECH, PUBLIC_ERROR_HARASSMENT, PUBLIC_ERROR_DECEPTIVE, PUBLIC_ERROR_TOXIC, PUBLIC_ERROR_POLICY | false | The safety filter refused what the prompt describes. Change the wording. |
| PUBLIC_ERROR_PROMINENT_PEOPLE, PUBLIC_ERROR_PROMINENT_PEOPLE_FILTER_FAILED, PUBLIC_ERROR_CELEBRITY, PUBLIC_ERROR_PERSON, PUBLIC_ERROR_PERSON_FILTER | false | The prompt or an image shows or names a real or well-known person. Remove the name, or use another image. |
| PUBLIC_ERROR_MINOR, PUBLIC_ERROR_CSAM | false | The prompt or an image involves a child or teenager. Change it. |
| PUBLIC_ERROR_PERSON_UPLOAD, PUBLIC_ERROR_MINOR_UPLOAD, PUBLIC_ERROR_IP_INPUT_IMAGE | false | The image you uploaded was refused (a real person, a minor, or copyrighted material). Other words will not help: use another image. |
| PUBLIC_ERROR_IP | false | The prompt names copyrighted or trademarked material (a brand, a film character). Describe it without the name. |
| PUBLIC_ERROR_UNSAFE_GENERATION, PUBLIC_ERROR_AUDIO_FILTERED | false | The prompt was accepted, but the finished video, image or its sound was blocked. Soften the prompt. |
| POLICY | false | Refused by the safety filter, with no more exact reason. Change the prompt or the image. |
| REF_EXPIRED | false | An uploaded image was removed before the video started. Upload it again and send a new request. |
| NO_CAPACITY | true | All servers were busy for too long. Send it again in a few minutes. |
| TIMEOUT | true | It took too long to make. Send it again. |
| NO_VIDEO, WRONG_SHAPE, FAILED | true | It could not be made this time. Send it again; if it keeps failing, change the prompt. |
Test retryable first and treat an error_code you do not know like FAILED: new reasons may be added.
Let us reword a refused prompt
Send auto_rewrite: true with POST /videos and a prompt whose wording the safety filter refuses is reworded and tried again by us, up to 3 times, before the video is reported as failed. It is off unless you ask for it, and it is for videos only.
{
"model": "veo-3.1-lite",
"prompt": "A soldier fires a rifle across a burning street",
"auto_rewrite": true
}{
"success": true,
"video": {
"status": "completed",
"done": true,
"success": true,
"auto_rewrite": true,
"prompt": "A soldier fires a rifle across a burning street",
"revised_prompt": "A soldier in uniform moves through a smoky street at dusk, tense atmosphere, cinematic",
"download_url": "https://…/video.mp4?…"
}
}promptis always what you sent.revised_promptis the wording the video was really made with, ornullwhen nothing was changed.- It stays one video in your counts, however many times it was reworded.
- An uploaded image that was refused is not reworded (other words cannot help), and a video that still fails after 3 rewordings is reported as
failedwith the last reason. - Rewording takes extra time: each try is a full new attempt.
Code examples
const BASE = "https://api.veostudio.net/v1";
const KEY = process.env.VEO_STUDIO_API_KEY;
const headers = { Authorization: `Bearer ${KEY}`, "Content-Type": "application/json" };
async function makeVideo(prompt) {
const made = await fetch(`${BASE}/videos`, {
method: "POST",
headers,
body: JSON.stringify({ model: "veo-3.1-lite", prompt, aspect_ratio: "16:9" }),
}).then((r) => r.json());
if (!made.success) throw new Error(`${made.errorCode}: ${made.error}`);
// Ask every 5 seconds until the video is done.
for (;;) {
await new Promise((r) => setTimeout(r, 5000));
const { video } = await fetch(`${BASE}/videos/${made.video.id}`, { headers }).then((r) => r.json());
if (!video.done) continue;
// error_code names the reason; retryable says whether sending the same request again can help.
if (!video.success) throw Object.assign(new Error(video.error), { code: video.error_code, retryable: video.retryable });
return video.download_url;
}
}
makeVideo("A paper boat sails down a rainy street, macro shot").then(console.log);import base64, os, time, requests
BASE = "https://api.veostudio.net/v1"
HEADERS = {"Authorization": f"Bearer {os.environ['VEO_STUDIO_API_KEY']}"}
def upload(path):
with open(path, "rb") as f:
data = base64.b64encode(f.read()).decode()
r = requests.post(f"{BASE}/uploads", headers=HEADERS, json={"image_base64": data}).json()
if not r["success"]:
raise RuntimeError(r["error"])
return r["id"]
def make_video(body):
r = requests.post(f"{BASE}/videos", headers=HEADERS, json=body).json()
if not r["success"]:
raise RuntimeError(f"{r.get('errorCode')}: {r['error']}")
video_id = r["video"]["id"]
while True:
time.sleep(5)
video = requests.get(f"{BASE}/videos/{video_id}", headers=HEADERS).json()["video"]
if video["done"]:
if not video["success"]:
# error_code names the reason; retryable says whether the same request may work if sent again
raise RuntimeError(f"{video['error_code']}: {video['error']} (retryable: {video['retryable']})")
return video["download_url"]
# image to video
print(make_video({
"model": "veo-3.1-lite",
"prompt": "The woman turns to the camera and smiles",
"image": upload("photo.jpg"),
}))n8n and Make
- HTTP Request node, method POST, URL
https://api.veostudio.net/v1/videos, headerAuthorization=Bearer YOUR_API_KEY, body JSON withprompt(and the other fields you need). - Wait node: 5 seconds.
- HTTP Request node, method GET, URL
https://api.veostudio.net/v1/videos/{{ $json.video.id }}, same header. - IF node on
{{ $json.video.done }}: false goes back to the Wait node; true goes on. - A second IF on
{{ $json.video.success }}: true uses{{ $json.video.download_url }}; false reads{{ $json.video.error }}.
If two branches feed the same “make a video” node, it runs once per incoming item and makes two videos. Chain the steps one after another, or join the branches with a Merge node first.