Skip to main content
GoogleFastHigh

Nano Banana (Edit)

Dedicated edit endpoint for Nano Banana, Google's Gemini 2.5 Flash-based image model. Pass input image URLs to perform conversational editing with character consistency and multi-image fusion.

117 credits
per image
Edit-mode endpoint optimized for image inputs
Multimodal editing with character consistency
Multi-image fusion
Conversational editing instructions
Multiple aspect ratio support

Run it right now

Test this model instantly in the Console Playground โ€” no code required

Sign in to try

Use with AI Assistant

Copy usage instructions for Claude, ChatGPT, or other AI

llms.txt

Quick Start

curl -X POST "https://api.core.today/v1/predictions" \
  -H "Content-Type: application/json" \
  -H "X-API-Key: cdt_your_api_key" \
  -d '{
  "model": "fal-ai/nano-banana/edit",
  "input": {
    "prompt": "Make the colors more vibrant and add a sunset glow",
    "image_urls": [
      "https://example.com/input-image.jpg"
    ],
    "aspect_ratio": "match_input_image",
    "output_format": "png",
    "safety_tolerance": "2",
    "num_images": 1
  }
}'

Parameters

ParameterTypeRequiredDefaultDescription
promptstringYes-How you want to edit the image
image_urlsarrayYes-Input image URLs to edit (required for edit mode)
aspect_ratiostringNomatch_input_imageOutput aspect ratio
match_input_image1:12:33:23:44:34:55:49:1616:921:9
output_formatstringNopngOutput image format
pngjpg
safety_tolerancestringNo2Safety tolerance level (1 strictest, 6 most permissive)
123456
num_imagesintegerNo1Number of images to generate

How to Provide File Input

There are 3 ways to provide files for the image_urls parameter:

Recommended

Direct Upload (Multipart)

Attach files directly to POST /v1/predictions/upload. No separate upload step needed.

curl -X POST "https://api.core.today/v1/predictions/upload" \
  -H "X-API-Key: cdt_your_api_key" \
  -F "model=fal-ai/nano-banana/edit" \
  -F 'input={"prompt":"your prompt here"}' \
  -F "file:image_urls=@your_file.png"

Image URL

Pass a publicly accessible URL directly. You can also use file_url from the Storage API.

{
  "model": "fal-ai/nano-banana/edit",
  "input": {
    "prompt": "your prompt here",
    "image_urls": ["https://example.com/image.jpg"]
  }
}
See the File Upload docs for more upload methods including Presigned URLs.

Common Parameters

Common parameters used when calling POST /v1/predictions.

ParameterTypeRequiredDefaultDescription
modelstringYes-Model identifier
inputobjectYes-Object containing the model-specific parameters from the table above
output_folderstringNo-Folder path for output files (max 256 chars, '..' not allowed)
webhook_urlstringNo-Webhook URL to call on completion
is_publicbooleanNofalseIf true, output files are also available via permanent public URLs

Examples

Lighting Edit

Apply a sunset glow to an existing photo

curl -X POST "https://api.core.today/v1/predictions" \
  -H "Content-Type: application/json" \
  -H "X-API-Key: cdt_your_api_key" \
  -d '{
  "model": "fal-ai/nano-banana/edit",
  "input": {
    "prompt": "Make the colors more vibrant and add a sunset glow",
    "image_urls": [
      "https://example.com/input-image.jpg"
    ],
    "aspect_ratio": "match_input_image",
    "output_format": "png",
    "safety_tolerance": "2",
    "num_images": 1
  }
}'

Tips & Best Practices

1Use this endpoint when you have one or more input images to edit
2Pass multiple image_urls to fuse subjects from different photos
3match_input_image keeps the original aspect ratio
4For pure text-to-image generation, use the base google/nano-banana model instead

Use Cases

Conversational photo retouching
Brand-consistent character variations
Multi-image scene composition
Iterative editing workflows