curl --request POST \
--url https://api.modellix.ai/api/v1/google/nano-banana-2 \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"prompt": "A colorful abstract painting with flowing shapes"
}
'{
"code": 0,
"message": "success",
"data": {
"status": "pending",
"task_id": "task-ghi789",
"model_id": "google/nano-banana-2",
"get_result": {
"method": "GET",
"url": "https://api.modellix.ai/api/v1/tasks/task-ghi789"
}
}
}{
"code": 400,
"message": "Invalid parameters: parameter 'prompt' is required"
}{
"code": 401,
"message": "Authentication failed: invalid API key"
}{
"code": 429,
"message": "Rate limit exceeded: 100 requests per minute, retry after 60 seconds"
}{
"code": 500,
"message": "Internal server error"
}Nano Banana 2
[Core Function] Nano Banana 2 (Gemini 3.1 Flash Image) is an extremely fast text-to-image model. [Strengths] It is optimized for high-speed, high-volume visual generation, creative prompting, and rapid stylistic experimentation. [Best For] Highly recommended for: rapid creative iteration, generating large batches of images quickly, and artistic/stylized graphics. [Limitations] Do NOT use this model if you require strict, high-end photorealism; prefer Nano Banana Pro for higher-fidelity creative output. [Routing] Route to this model for ‘fast’, ‘creative’, or ‘stylized’ high-volume requests. For Nano Banana 2.1, use google/nano-banana-2.1.
POST
/
google
/
nano-banana-2
curl --request POST \
--url https://api.modellix.ai/api/v1/google/nano-banana-2 \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"prompt": "A colorful abstract painting with flowing shapes"
}
'{
"code": 0,
"message": "success",
"data": {
"status": "pending",
"task_id": "task-ghi789",
"model_id": "google/nano-banana-2",
"get_result": {
"method": "GET",
"url": "https://api.modellix.ai/api/v1/tasks/task-ghi789"
}
}
}{
"code": 400,
"message": "Invalid parameters: parameter 'prompt' is required"
}{
"code": 401,
"message": "Authentication failed: invalid API key"
}{
"code": 429,
"message": "Rate limit exceeded: 100 requests per minute, retry after 60 seconds"
}{
"code": 500,
"message": "Internal server error"
}Body
application/json