ナノバナナ2

高速な画像生成を実現。テキストから画像への生成、および画像から画像への変換に対応。

機能
  • テキストから画像生成
  • 画像から画像への変換
  • 複数のアスペクト比
  • 高速生成(約5秒)
料金設定
4 (~$0.04)Per image
エンドポイント
POST/api/v1/images/generate
パラメータ
パラメータタイプ必須説明
modelstring必須Must be "nano-banana"
promptstring必須Text description of the image to generate
negative_promptstringオプションWhat to avoid in the image
aspect_ratiostringオプション"1:1", "16:9", "9:16", "4:3", "3:4"
input_imagestringオプションURL or base64 for image-to-image
num_imagesnumberオプションMust be 1
リクエストの例
{
  "model": "nano-banana",
  "prompt": "A futuristic city at night with neon lights",
  "aspect_ratio": "16:9"
}
レスポンス例
{
  "success": true,
  "data": {
    "task_id": "task_abc123",
    "credits_used": 4,
    "remaining_credits": 496,
    "model": "nano-banana"
  }
}
コード例
curl -X POST https://gateway.nanobananapro.site/api/v1/images/generate \
  -H "Authorization: Bearer sk-your-api-key" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "nano-banana",
    "prompt": "A futuristic city at night with neon lights",
    "aspect_ratio": "16:9"
  }'
Nano Banana Pro API