Skip to content
هذه الصفحة غير متاحة بلغتك بعد، لذا تُعرض باللغة الإنجليزية.
Google · Nano Banana

Nano Banana 2 API

Generate images from text or reference images at up to 4K with Nano Banana 2 on APISea.

إنشاء الصورالصورمهمة غير متزامنة
معرّف النموذج
gemini-3.1-flash-image-preview

تسعير API لنموذج Nano Banana 2

جميع الأسعار بالدولار الأمريكي (USD). مقارنة أسعار APISea بالسعر الرسمي المعلن للوحدة نفسها.

الخيارAPISeaرسميوفّر
افتراضيافتراضي$0.0165$0.067−75%
0.5K$0.0165$0.045−63%
1K$0.0132$0.067−80%
2K$0.0154$0.101−85%
4K$0.0198$0.151−87%

الأسعار لكل صورة.

ما هو Nano Banana 2؟

Nano Banana 2 is Google's image generation model in the Nano Banana family, available on APISea as gemini-3.1-flash-image-preview. It supports text-to-image and image-to-image workflows for teams building visual content tools. Supply a text prompt, optionally add reference images, and choose an output resolution up to 4K. Controls include standard and extreme aspect ratios, optional prompt and input-image moderation, and Google text or image search enhancement. Up to 14 reference images can help guide style and character consistency.

Call the model through APISea's image generation endpoint using one API key and the OpenAI-compatible base URL https://api.apisea.ai/v1. The equivalent alias nano-banana-2-ext is also accepted. Billing is pay-as-you-go, with charges only for successful requests. The APISea Default configuration costs $0.0165 per image, about 75% below the provider list price; resolution-specific rates vary, so choose the output tier explicitly when planning costs.

أبرز مزايا Nano Banana 2

Text and image inputs

Generate images from a text prompt or provide reference images for image-to-image generation. Use up to 14 references to guide style and character consistency.

Resolution and aspect controls

Choose 0.5K, 1K, 2K, or 4K output. Aspect ratios include square, widescreen, vertical, and extreme formats such as 1:8 and 8:1.

Google Search enhancement

Enable Google text search to assist generation with real-world information. Google image search enhancement can also supply visual references.

Optional moderation and fallback

Enable moderation to review prompts and input images before submission. The standard route also offers an optional official-channel fallback.

كيفية استدعاء API الخاص بـ Nano Banana 2 في 4 خطوات

  1. 01

    احصل على API key

    سجّل الدخول إلى APISea، واشحن رصيدك بدءًا من $50، وأنشئ مفتاح sk-sea من وحدة التحكم.

  2. 02

    اضبط عنوان URL الأساسي

    استخدم https://api.apisea.ai/v1 عنوانًا أساسيًا في SDK أو عميل HTTP.

  3. 03

    أرسل الطلب

    استدعِ POST /v1/images/generations مع "model": "gemini-3.1-flash-image-preview" والمعلمات أدناه.

  4. 04

    تعامل مع الاستجابة

    تتضمن الاستجابة task_id. أرسل طلبات GET /v1/tasks/{task_id} دوريًا حتى تصبح الحالة completed، ثم نزّل روابط النتائج.

# model can be "gemini-3.1-flash-image-preview", or the compatible alias "nano-banana-2-ext"
curl --request POST \
  --url https://api.apisea.ai/v1/images/generations \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '{
    "model": "gemini-3.1-flash-image-preview",
    "prompt": "Cyberpunk cityscape at night with neon lights",
    "size": "16:9",
    "resolution": "2K",
    "n": 1
  }'

المعلمات

المعلمةالنوعمطلوبافتراضيالوصف
modelstringمطلوبgemini-3.1-flash-image-previewImage generation model name
nsfw_checkbooleanاختياريfalseWhether to run content moderation before submitting the image task.
promptstringمطلوب—Text description for image generation
sizestringاختياري—Image aspect ratio
resolutionstringاختياري1KOutput image resolution
nintegerاختياري—Number of images to generate
official_fallbackbooleanاختياريfalseWhether to use the official channel fallback
image_urlsarrayاختياري—Reference image URL list for image-to-image generation
google_searchbooleanاختياريfalseEnable Google text search enhancement
google_image_searchbooleanاختياريfalseEnable Google image search enhancement

ما الذي يمكنك إنشاؤه باستخدام Nano Banana 2

Campaign asset generators

Build tools that generate square social assets, vertical covers, and wide banners from campaign prompts, with explicit aspect ratio controls.

Reference-guided visual workflows

Let teams supply character and object references to guide related images toward a consistent style or character appearance.

Real-world illustration tools

Offer optional Google text and image search enhancement for image requests that depend on real-world information or visual references.

Preview-to-final production tools

Let users choose low-resolution previews or outputs up to 4K, with resolution-specific pricing shown before submission.

نصائح للحصول على نتائج أفضل

  • 01

    Specify the aspect ratio

    Set the size parameter rather than relying on auto. For text-to-image, auto defaults to 1:1 or 16:9; image-to-image follows the upstream response.

  • 02

    Choose resolution by cost

    Set resolution explicitly; the documented default is 1K. APISea 1K costs $0.0132 per image, while APISea 4K costs $0.0198 per image.

  • 03

    Prepare valid references

    Provide publicly accessible image URLs or full Base64 Data URIs in image_urls. Use jpeg, png, or webp files no larger than 10MB each.

  • 04

    Keep requests single-image

    Set n to the plain number 1, not a quoted string. Enable google_search or google_image_search only when the request calls for real-world information or visual references.

القيود ومعلومات مهمة

  • Each request supports only one generated image: n must be 1.

  • Reference inputs are limited to 14 images, with a maximum size of 10MB per image.

  • The model is labeled preview and may change.

الأسئلة الشائعة حول API الخاص بـ Nano Banana 2

How much does Nano Banana 2 cost on APISea?

APISea Default costs $0.0165 per image, about 75% below the provider list price of $0.067 per image. Resolution-specific prices are APISea 0.5K: $0.0165 per image; APISea 1K: $0.0132 per image; APISea 2K: $0.0154 per image; and APISea 4K: $0.0198 per image. APISea bills only successful requests.

How do I call the Nano Banana 2 API?

Send a POST request to https://api.apisea.ai/v1/images/generations with Bearer Token authentication using your APISea key. Include model set to gemini-3.1-flash-image-preview and a required prompt; the equivalent alias nano-banana-2-ext produces identical results.

Does Nano Banana 2 support image-to-image generation?

Yes. Supply reference images through image_urls as publicly accessible URLs or full Base64 Data URIs. You can include up to 14 images in jpeg, png, or webp format, each no larger than 10MB.

What resolutions and aspect ratios can I choose?

Supported resolution values are 0.5K, 1K, 2K, and 4K, with 1K as the documented default. The size parameter supports standard formats such as 1:1, 16:9, and 9:16, plus extreme ratios including 1:4, 4:1, 1:8, and 8:1.

How does the standard route differ from the official version?

This page covers gemini-3.1-flash-image-preview, also callable as nano-banana-2-ext. The separate official version is gemini-3.1-flash-image-preview-official, with alias nano-banana-2. The standard route supports official_fallback; that parameter cannot be used with the official version.

Can I use Nano Banana 2 images commercially?

Commercial use is subject to the provider's terms. Review Google's applicable terms and any rights associated with reference images before using generated outputs commercially.

نماذج ذات صلة

العمق: أكثر من 250 نموذجًا · الحد الأدنى لشحن الرصيد $50

ابدأ التطوير باستخدام Nano Banana 2

مفتاح واحد، وادفع حسب الاستخدام بدءًا من $50؛ ولا تُحتسب الرسوم إلا على الطلبات الناجحة.