The Nano Banana Pro API harnesses the Gemini 3 Pro Image model for premium, high-fidelity image generation from text prompts. It delivers superior image quality with support for 1K and 2K resolutions.
taskId.taskId to retrieve the generated images.Enum: application/json
Bearer authentication token. Example: Bearer {{APIKey}}.
The model identifier. Must be set to gemini-3-pro-image for Nano Banana Pro.
The text prompt describing the image to generate. Example: "The kitten is eating".
The output image resolution. Supported values for Nano Banana Pro: "1K", "2K". Default: "1K".
The aspect ratio of the generated image. Example: "16:9", "1:1", "4:3".
An array of reference image URLs for image-to-image generation. Can be empty or omitted.
Returns 0 for success, or a specific error code.
Returns "success" or a descriptive error message.
The unique identifier for the task. Use this ID with the Polling API to retrieve the generated output.
Use the Polling API to retrieve the processing results.
Alternatively, you can enable Callback to receive task results automatically upon completion.
{
"code": 0,
"message": "success",
"data": {
"task": {
"taskId": "API-605f75923ff64b998955ba46f13915f2",
"status": 3,
"executionTime": 26446,
"expire": 1778593345400,
"taskType": "google_gemini_image"
},
"images": [
{
"imageUrl": "https://dreamface-resource.oss-us-east-1.aliyuncs.com/df-ability-tmp/0a2f83e6-21e7-47c7-ab50-74457845d628.jpeg",
"imageType": "png"
}
]
}
}curl -X POST 'https://api.newportai.com/api/async/google_gemini_image' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer {{APIKey}}' \
-d '{
"model": "gemini-3-pro-image",
"text": "The kitten is eating",
"aspectRatio": "16:9",
"imageSize": "1K",
"images": [
"https://d2t5pyzt5qvy2d.cloudfront.net/api/static_resource/prod/default/INj5UrnnrKIzCR1uYBWv0.png"
]
}'{
"code": 0,
"message": "success",
"data": {
"taskId": "API-605f75923ff64b998955ba46f13915f2"
}
}