curl --request POST \
--url https://toapis.com/v1/videos/generations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"model": "veo3.1-fast",
"prompt": "Dolphins jumping in the blue ocean",
"duration": 8,
"aspect_ratio": "16:9",
"image_urls": ["https://example.com/start-frame.jpg", "https://example.com/end-frame.jpg"],
"metadata": {
"generation_type": "frame",
"resolution": "1080p",
"enable_gif": false
}
}'
import requests
response = requests.post(
"https://toapis.com/v1/videos/generations",
headers={
"Authorization": "Bearer your-ToAPIs-key",
"Content-Type": "application/json"
},
json={
"model": "veo3.1-fast",
"prompt": "Dolphins jumping in the blue ocean",
"duration": 8,
"aspect_ratio": "16:9",
"image_urls": ["https://example.com/start-frame.jpg", "https://example.com/end-frame.jpg"],
"metadata": {
"generation_type": "frame",
"resolution": "1080p",
"enable_gif": False
}
}
)
task = response.json()
print(f"Task ID: {task['id']}")
print(f"Status: {task['status']}")
const response = await fetch('https://toapis.com/v1/videos/generations', {
method: 'POST',
headers: {
'Authorization': 'Bearer your-ToAPIs-key',
'Content-Type': 'application/json'
},
body: JSON.stringify({
model: 'veo3.1-fast',
prompt: 'Dolphins jumping in the blue ocean',
duration: 8,
aspect_ratio: '16:9',
image_urls: ['https://example.com/start-frame.jpg', 'https://example.com/end-frame.jpg'],
metadata: {
generation_type: 'frame',
resolution: '1080p',
enable_gif: false
}
})
});
const task = await response.json();
console.log(`Task ID: ${task.id}`);
console.log(`Status: ${task.status}`);
{
"id": "video_01K8SGYNNNVBQTXNR4MM964S7K",
"object": "generation.task",
"model": "veo3.1-fast",
"status": "queued",
"progress": 0,
"created_at": 1768380224,
"metadata": {
"aspect_ratio": "16:9"
}
}
Veo3
Veo3 비디오 생성
Generate high-quality videos using Google Veo3 model, supports async task management
POST
/
v1
/
videos
/
generations
curl --request POST \
--url https://toapis.com/v1/videos/generations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"model": "veo3.1-fast",
"prompt": "Dolphins jumping in the blue ocean",
"duration": 8,
"aspect_ratio": "16:9",
"image_urls": ["https://example.com/start-frame.jpg", "https://example.com/end-frame.jpg"],
"metadata": {
"generation_type": "frame",
"resolution": "1080p",
"enable_gif": false
}
}'
import requests
response = requests.post(
"https://toapis.com/v1/videos/generations",
headers={
"Authorization": "Bearer your-ToAPIs-key",
"Content-Type": "application/json"
},
json={
"model": "veo3.1-fast",
"prompt": "Dolphins jumping in the blue ocean",
"duration": 8,
"aspect_ratio": "16:9",
"image_urls": ["https://example.com/start-frame.jpg", "https://example.com/end-frame.jpg"],
"metadata": {
"generation_type": "frame",
"resolution": "1080p",
"enable_gif": False
}
}
)
task = response.json()
print(f"Task ID: {task['id']}")
print(f"Status: {task['status']}")
const response = await fetch('https://toapis.com/v1/videos/generations', {
method: 'POST',
headers: {
'Authorization': 'Bearer your-ToAPIs-key',
'Content-Type': 'application/json'
},
body: JSON.stringify({
model: 'veo3.1-fast',
prompt: 'Dolphins jumping in the blue ocean',
duration: 8,
aspect_ratio: '16:9',
image_urls: ['https://example.com/start-frame.jpg', 'https://example.com/end-frame.jpg'],
metadata: {
generation_type: 'frame',
resolution: '1080p',
enable_gif: false
}
})
});
const task = await response.json();
console.log(`Task ID: ${task.id}`);
console.log(`Status: ${task.status}`);
{
"id": "video_01K8SGYNNNVBQTXNR4MM964S7K",
"object": "generation.task",
"model": "veo3.1-fast",
"status": "queued",
"progress": 0,
"created_at": 1768380224,
"metadata": {
"aspect_ratio": "16:9"
}
}
중국 본토 사용자 안내: 중국 본토 사용자는
https://toapis.cn 를 API 엔드포인트(Base URL)로 사용해 주세요. 본 문서의 예시에서 https://toapis.com 을 https://toapis.cn 로 바꿔 주세요.- Asynchronous processing mode, returns task ID for subsequent queries
- Supports multiple generation modes including text-to-video and image-to-video
- Generated video links are valid for 24 hours, please save them promptly
Important Change: For better performance and cost control, we no longer support passing base64 image data directly in
image_urls. Please use the Upload 이미지 API first to upload images and get URLs, then call this endpoint.Authorizations
string
필수
All endpoints require Bearer Token authenticationGet your API Key from the API Key Management PageAdd to request header:
Authorization: Bearer YOUR_API_KEY
Body
string
기본값:"veo3.1-fast"
필수
Video generation model nameAvailable models:
veo3.1-fast- Fast generation model, suitable for quick preview and iterationveo3.1-quality- High-quality generation model, suitable for final productionveo3.1-lite- Lightweight generation model, suitable for lower-cost fast generation
"veo3.1-fast"string
필수
Text description for video generation
integer
Video duration (seconds)Fixed value:
8 (VEO3 only supports 8-second duration)string
Video resolutionSupported formats:
16:9(landscape)9:16(portrait)
string[]
Array of reference image URLs for image-to-video generation⚠️ URL format only (base64 no longer supported)
- Publicly accessible image URL (http:// or https://)
- You can use the Upload 이미지 API to upload local images and get URLs
- Maximum file size: 10MB
- Supported formats: .jpeg, .jpg, .png, .webp
object
VEO3-specific extended parameters
표시 Show metadata fields
표시 Show metadata fields
string
Video generation typeSupported types:
frame- Frame-to-video (FL mode)reference- Reference image-to-video
veo3.1-quality model does not support reference modestring
Video resolutionSupported values:
720p(default)1080p4k
boolean
Enable GIF output format. Default:
falseNote: GIF cannot be used with 1080p or 4k resolution응답
string
Unique task identifier for status queries
string
Object type, always
generation.taskstring
모델 name used
string
Task status
queued- Queued for processingin_progress- Processingcompleted- Successfully completedfailed- Failed
integer
Task progress percentage (0-100)
integer
Task creation timestamp (Unix timestamp)
object
Task metadata
curl --request POST \
--url https://toapis.com/v1/videos/generations \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '{
"model": "veo3.1-fast",
"prompt": "Dolphins jumping in the blue ocean",
"duration": 8,
"aspect_ratio": "16:9",
"image_urls": ["https://example.com/start-frame.jpg", "https://example.com/end-frame.jpg"],
"metadata": {
"generation_type": "frame",
"resolution": "1080p",
"enable_gif": false
}
}'
import requests
response = requests.post(
"https://toapis.com/v1/videos/generations",
headers={
"Authorization": "Bearer your-ToAPIs-key",
"Content-Type": "application/json"
},
json={
"model": "veo3.1-fast",
"prompt": "Dolphins jumping in the blue ocean",
"duration": 8,
"aspect_ratio": "16:9",
"image_urls": ["https://example.com/start-frame.jpg", "https://example.com/end-frame.jpg"],
"metadata": {
"generation_type": "frame",
"resolution": "1080p",
"enable_gif": False
}
}
)
task = response.json()
print(f"Task ID: {task['id']}")
print(f"Status: {task['status']}")
const response = await fetch('https://toapis.com/v1/videos/generations', {
method: 'POST',
headers: {
'Authorization': 'Bearer your-ToAPIs-key',
'Content-Type': 'application/json'
},
body: JSON.stringify({
model: 'veo3.1-fast',
prompt: 'Dolphins jumping in the blue ocean',
duration: 8,
aspect_ratio: '16:9',
image_urls: ['https://example.com/start-frame.jpg', 'https://example.com/end-frame.jpg'],
metadata: {
generation_type: 'frame',
resolution: '1080p',
enable_gif: false
}
})
});
const task = await response.json();
console.log(`Task ID: ${task.id}`);
console.log(`Status: ${task.status}`);
{
"id": "video_01K8SGYNNNVBQTXNR4MM964S7K",
"object": "generation.task",
"model": "veo3.1-fast",
"status": "queued",
"progress": 0,
"created_at": 1768380224,
"metadata": {
"aspect_ratio": "16:9"
}
}