Generate image
generate_imageTurn text prompts into images with Google's Gemini Nano Banana models. Specify a prompt, model, aspect ratio, and file name; saves the image locally and returns its path.
Instructions
Generate an image from a text prompt using Google's Gemini image models (Nano Banana). Saves the result as a local file and returns its path.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| model | No | Gemini image model id. Defaults to "gemini-2.5-flash-image". | |
| prompt | Yes | Text description of the image to generate | |
| file_name | No | Optional output file name. Defaults to a timestamp. | |
| aspect_ratio | No | Optional aspect ratio, e.g. "1:1", "16:9", "9:16". |