LLM Reference
OpenRouter

Using Nano Banana 2 (Gemini 3.1 Flash Image) on OpenRouter

Implementation guide · Gemini 3.1 · Google DeepMind

Serverless

OpenRouter exposes Nano Banana 2 (Gemini 3.1 Flash Image) through model ID google/gemini-3.1-flash-image. Use the setup steps, sourced pricing, capabilities, and official provider links below to validate this route before deployment.

Last refreshed 2026-06-15. Next refresh: weekly.

Quick Start

  1. 1
    Create an account at OpenRouter and generate an API key.
  2. 2
    Use the OpenRouter SDK or REST API to call google/gemini-3.1-flash-image — see the documentation for request format.
  3. 3
    You'll be billed $0.50/1M input, $3.00/1M output tokens. See full pricing.

Code Examples

See OpenRouter documentation for integration details.

Pricing on OpenRouter

TypePrice (per 1M)
Input tokens$0.50
Output tokens$3.00

Capabilities

VisionMultimodalReasoningBatch API

About Nano Banana 2 (Gemini 3.1 Flash Image)

Nano Banana 2 is the GA Gemini 3.1 Flash Image model for image generation and editing through the Gemini API. It accepts text, image, PDF, and video inputs, adds video-to-image generation for thumbnails, posters, and infographics, returns text and images, supports search grounding and thinking, and replaces the gemini-3.1-flash-image-preview model retiring on 2026-06-25.

Model Specs

Released2026-05-28
Context131k
ArchitectureDecoder Only
Knowledge cutoff2025-01

Provider

OpenRouter
OpenRouter

OpenRouter, Inc.

New York, NY, USA