Google Veo 3.1 API

Generate cinematic video with Veo 3.1 or Veo 3.1 Fast—one API key, no Google Cloud or Vertex AI setup.

Why use this instead of the Gemini API directly?

  • One API key — no Google Cloud project or service account needed
  • Videos are automatically downloaded and hosted on our CDN as public MP4 URLs
  • Built-in credit management with automatic refunds on failure

Two Veo 3.1 models

Veo 3.1

Premium
model: "veo-3.1"

Highest quality. Best for cinematic scenes, marketing content, and creative projects where quality matters most.

Cost$3.20
Duration4, 6, or 8s
Aspect ratio16:9, 9:16
Speed~3–5 min

Veo 3.1 Fast

Fast
model: "veo-3.1-fast"

Optimized for speed. Same architecture with faster output. Ideal for prototyping, batch workflows, and real-time apps.

Cost$1.20
Duration4, 6, or 8s
Aspect ratio16:9, 9:16
Speed~1–2 min

Start generating in minutes

Request
curl -X POST https://www.ninjachat.ai/api/v1/videos \
  -H "Authorization: Bearer nj_sk_YOUR_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "prompt": "A drone shot soaring over a misty mountain range at golden hour, cinematic lighting",
    "model": "veo-3.1",
    "duration": 8,
    "aspect_ratio": "16:9"
  }'

# Response: { "id": "vid_abc123def456...", "status": "queued", ... }

# Poll for completion:
curl "https://www.ninjachat.ai/api/v1/videos/vid_abc123def456..." \
  -H "Authorization: Bearer nj_sk_YOUR_KEY"
Submit response
json
{
  "id": "vid_abc123def456...",
  "object": "video",
  "status": "queued",
  "model": "veo-3.1"
}
Status response
json
// Processing...
{ "id": "vid_abc123def456...", "object": "video", "status": "processing", "progress": 45 }

// Completed
{
  "id": "vid_abc123def456...",
  "object": "video",
  "status": "completed",
  "video_url": "https://cdn.ninjachat.ai/videos/..."
}

API reference

POST/api/v1/videos
promptrequired
stringVideo description (1–4000 chars).
modelrequired
"veo-3.1" | "veo-3.1-fast"Google Veo model to use.
duration
integerDuration: 4, 6, or 8 seconds. Default: 8
aspect_ratio
"16:9" | "9:16"Aspect ratio. Default: "16:9"
image_url
string (URL)Reference image for image-to-video generation.
GET/api/v1/videos/{id}
idrequired
string (path)The id returned from POST /api/v1/videos.

Status response fields

id
stringJob id.
status
"queued" | "processing" | "completed" | "failed"Current status of the video job.
progress
numberEstimated progress percentage (0–100). Only present while processing.
video_url
stringCDN-hosted MP4 when completed.
error
stringError message when status is failed.

How it works

1

Get an API key

Sign up at ninjachat.ai and grab your key from Developers > API Keys. Works immediately — no Google Cloud setup.

2

Submit a video request

POST to /api/v1/videos with model: "veo-3.1" or "veo-3.1-fast", your prompt, duration, and aspect ratio.

3

Poll for completion

GET /api/v1/videos/{id} with the job id. Progress updates while Veo processes your video.

4

Use your video

When status is completed, video_url is a CDN-hosted MP4 you can download or embed.

Start using Google Veo 3.1 via API

Frequently asked questions

What is Google Veo 3.1?

Google Veo 3.1 is Google DeepMind's most advanced video generation model. It produces cinematic-quality videos with superior motion coherence, photorealistic detail, and precise prompt adherence. Through NinjaChat's API, you can access it with a simple REST call.

What's the difference between Veo 3.1 and Veo 3.1 Fast?

Both use the same architecture. Veo 3.1 prioritizes maximum quality (3-5 min generation). Veo 3.1 Fast is optimized for speed (1-2 min) with slightly lower fidelity — ideal for prototyping and batch workflows.

Do I need a Google Cloud account?

No. NinjaChat handles the Google integration. You only need a NinjaChat API key — no Google Cloud project, no Vertex AI setup, no service accounts.

How does the Google Veo API work?

POST to /api/v1/videos with model set to "veo-3.1" or "veo-3.1-fast". You receive a job id immediately. Poll GET /api/v1/videos/{id} until the video is ready, then use the CDN-hosted MP4 URL.

What durations and aspect ratios does Veo 3.1 support?

Veo 3.1 generates videos at 4, 6, or 8 seconds in either 16:9 (landscape) or 9:16 (portrait) aspect ratios.

Can I generate video from an image?

Yes. Pass an image_url parameter with your reference image and a prompt describing the desired motion. Veo 3.1 will animate the image accordingly.

How much does it cost?

A Veo 3.1 video costs $3.20 and a Veo 3.1 Fast video costs $1.20. Credits are deducted at submission and refunded automatically if generation fails.

Is there a free tier?

You can try Veo 3.1 for free through the NinjaChat web interface at ninjachat.ai/video-generation. API access requires prepaid credits (from $5) with per-video billing.