Generate an image
generate_imageGenerate or edit images from text prompts or reference images using AI models like Nano Banana and GPT Image. Returns the picture inline.
Instructions
Generate an image with Nano Banana Pro/2 or GPT Image 2. Usually finishes within the tool-call budget and returns the picture inline. Supports image editing and reference-guided generation via reference_images.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| size | No | Pixel size as "WxH", e.g. "1024x1024". | |
| tier | No | Resolution tier. Pricing is per tier — set it explicitly. | |
| model | No | Which image model to use. | nano-banana-pro |
| prompt | Yes | What the image should show. | |
| reference_images | No | HTTPS or data: URLs to edit or take guidance from. |