Nano Banana 2
nano_banana_2
Google Nano Banana 2 provides image generation through the Gemini API, supporting text-to-image, image editing, and multi-image composition.
Эндпоинты
Заголовок раздела «Эндпоинты»POST /v1/queue/nano_banana_2 # Создать задачуGET /v1/queue/nano_banana_2/requests/{request_id}/status # Проверить статусGET /v1/queue/nano_banana_2/requests/{request_id}/response # Получить результатPUT /v1/queue/nano_banana_2/requests/{request_id}/cancel # Отменить задачуПараметры запроса
Заголовок раздела «Параметры запроса»curl --location "https://odirouter.ai/model/v1/queue/nano_banana_2" \ --header "Authorization: Bearer YOUR_API_KEY" \ --header "Content-Type: application/json" \ --data '{ "prompt": "A red apple on a white table, clean studio lighting, simple background.", "image_urls": [ "https://example.com/reference-image.webp" ] }'Image generation prompt
For realistic scenes, use photography terms such as camera angle, lens type, lighting, and detail level
For stylized illustrations, stickers, icons, or assets, clearly describe the style and ask for a transparent background when needed
For text inside the image, state the exact text, font style, and overall design
For product mockups and commercial photography, describe a clean professional product shot suitable for ecommerce, ads, or branding
For minimal layouts and negative space, describe where text or marketing content should be overlaid later
Length: 1 - 2500 characters
Input image URLs used as reference images or visual context, with up to 3 images supported
Output image aspect ratio
Allowed values: 1:8, 1:4, 1:1, 2:3, 3:2, 3:4, 4:1, 4:3, 4:5, 5:4, 8:1, 9:16, 16:9, 21:9
Output image size tier
Allowed values: 512, 1K, 2K, 4K
Output image resolution
Allowed values: 0.5K, 1K, 2K, 4K
Default: 1K
Controls which response modalities the model returns
By default, the model returns text and image responses: ["Text", "Image"]; pass ["Image"] to return only images without text
Параметры ответа
Заголовок раздела «Параметры ответа»{ "request_id": "mmsu_01hxyz...", "response_url": "https://odirouter.ai/model/v1/queue/nano_banana_2/requests/mmsu_01hxyz.../response", "status_url": "https://odirouter.ai/model/v1/queue/nano_banana_2/requests/mmsu_01hxyz.../status", "cancel_url": "https://odirouter.ai/model/v1/queue/nano_banana_2/requests/mmsu_01hxyz.../cancel", "queue_position": 0}| Поле | Тип | Описание |
|---|---|---|
request_id | string | Идентификатор задачи, используемый во всех последующих операциях. |
response_url | string | URL для получения итогового результата. |
status_url | string | URL для проверки статуса задачи. |
cancel_url | string | URL для отмены задачи. |
queue_position | int | Текущая позиция в очереди. |