This endpoint runs in asynchronous mode. Use the returned task_id to query task status.
Generated image links are valid for 24 hours . Save them promptly.
Authorization
All APIs require Bearer Token authentication. Format: Bearer YOUR_API_KEY
Body
model
enum<string>
default: "gemini-3-pro-image-preview"
required
Image generation model name (official channel) with better stability and controllability, suitable for commercial scenarios. Available options: gemini-3-pro-image-preview Example: "gemini-3-pro-image-preview"
Prompt describing the image to be generated, or describing how to edit the input image. Maximum string length: 2000 Example: "A cat playing in the grass"
size
enum<string>
default: "auto"
Aspect ratio of the generated image. Available options: auto, 1:1, 2:3, 3:2, 3:4, 4:3, 4:5, 5:4, 9:16, 16:9, 21:9
Quality of the generated image. Note: 4K quality will incur additional charges. Available options: 1K, 2K, 4K
Reference image URL list for image-to-image and image editing functions. Notes:
Maximum number of input images per request: 10
Maximum image size: 10MB
Supported formats: .jpeg, .jpg, .png, .webp
URLs must be directly accessible by the server (direct-download links recommended)
Maximum of 5 real person images per request
Example: [
"https://example.com/image1.png" ,
"https://example.com/image2.png"
]
HTTPS callback address after task completion. Callback timing:
Triggered when task is completed, failed, or cancelled
Sent after billing confirmation is completed
Security restrictions:
Only HTTPS is supported
Callback to internal IP addresses is prohibited (127.0.0.1, 10.x.x.x, 172.16-31.x.x, 192.168.x.x, etc.)
URL length must not exceed 2048 characters
Callback mechanism:
Timeout: 10s
Maximum 3 retries on failure (after 1s / 2s / 4s)
Returning any 2xx status code is considered successful; otherwise it will retry
Example: "https://your-domain.com/webhooks/image-task-completed"
Response Schema
Image generation task created successfully. Task ID. Use it to query task status.
Task status. Available options: pending, processing, completed, failed
Optional message from the provider.
Task creation timestamp (unix seconds).
Failed response. Returns an OpenAI-compatible error object containing message, type, and code. Error details. Show Show child attributes
curl
python
javascript
go
java
cpp
c
curl -X POST [https://vibetool.ai/v1/images/generations]( https://vibetool.ai/v1/images/generations ) \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"model": "gemini-3-pro-image-preview",
"prompt": "A cat playing in the grass",
"size": "auto",
"quality": "2K",
"image_urls": [],
"callback_url": "https://your-domain.com/webhooks/image-task-completed",
"async_mode": true
}'
200
400
401
402
403
404
409
429
500
503
{
"task_id" : "img_202512301327_4d50e7c6" ,
"status" : "pending" ,
"message" : null ,
"created_at" : 1767072426
}