Generate AI images using Nano Banana models. Supports text-to-image generation with nano-banana-2 (4 credits) and image-to-image editing with google/nano-banana-edit (2 credits).
The generation is asynchronous — poll GET /images/{taskId} to check status and retrieve the image URL when ready.
Use your API key from the RawUGC dashboard. Include as: Authorization: Bearer YOUR_API_KEY
Image generation model. 'google/nano-banana-edit' for image editing (2 credits), 'nano-banana-2' for text-to-image (4 credits).
google/nano-banana-edit, nano-banana-2 Text description of the image to generate or the edit to apply.
1 - 20000Image URLs. Required for google/nano-banana-edit (source images to edit). Optional for nano-banana-2 (reference images, max 14). Must be publicly accessible HTTP/HTTPS URLs.
14Aspect ratio for google/nano-banana-edit model.
1:1, 9:16, 16:9, 3:4, 4:3, 3:2, 2:3, 5:4, 4:5, 21:9, auto Output image format. Defaults to jpg for nano-banana-2, png for nano-banana-edit.
png, jpeg, jpg Aspect ratio for nano-banana-2 model. Defaults to auto.
1:1, 1:4, 1:8, 2:3, 3:2, 3:4, 4:1, 4:3, 4:5, 5:4, 8:1, 9:16, 16:9, 21:9, auto Use Google Web Search grounding to generate images based on real-time information (nano-banana-2 only). Defaults to false.
Output resolution for nano-banana-2 model. Defaults to 1K.
1K, 2K, 4K Image generation initiated
Unique image identifier (img_xxx format)
Image model used for generation
Current generation status
pending, processing, completed, failed Number of credits deducted for this generation
Remaining credit balance after deduction
Estimated time until image is ready (human-readable)
Timestamp when generation was initiated (milliseconds since epoch)