Skip to main content
POST
Nano Banana 2 — Text to Image
Generate images from text descriptions with Google’s Nano Banana 2 model. Supports multiple aspect ratios and resolution tiers.

Request Body

model
string
required
Model slug. Use google/nano-banana-2/text-to-image for text-to-image generation.
input
object
required
Input parameters for text-to-image generation.
webhookUrl
string
HTTPS URL to receive a webhook notification when the job completes or fails.

Pricing

Base cost: 134,000 micro-cents per request ($0.134)
Default cost: 1k resolution = 134,000 × 1 = 134,000 micro-cents ($0.134)4k cost: 134,000 × 1.8 = 241,200 micro-cents ($0.2412)

Response

jobId
string
Unique identifier for the submitted job.
status
string
Initial job status. Always "pending" on successful submission.
estimatedCompletionTime
string
ISO 8601 timestamp of the estimated completion time.
costMicroCents
number
The cost of the job in micro-cents.

Code Examples