Runbase

Command Palette

Search for a command to run...

Gemini

Nano Banana Pro

ID :google/nano-banana-pro

API de génération d'images Nano Banana Pro par Google — Gemini 3 Pro avec le rendu de texte le plus net, sortie 4K et fidélité maximale de la famille.

Text to imageÉdition d'imageImages de référence4KRendu de texte

Aperçu

API de génération d'images Nano Banana Pro par Google — Gemini 3 Pro avec le rendu de texte le plus net, sortie 4K et fidélité maximale de la famille.

Authentification

Toutes les requêtes API nécessitent une clé API valide transmise via l'en-tête Authorization avec le schéma Bearer.

Démarrage rapide

Identifiants

Définissez la variable d'environnement RUNBASE_API_KEY.

Shell
export RUNBASE_API_KEY=your-api-key

Créer une exécution

Shell
curl -s https://runbase.net/api/v1/runs \
  -H "Authorization: Bearer $RUNBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "google/nano-banana-pro",
    "input": {
      "prompt": "A cinematic product photo of a ceramic lamp"
    }
  }'

Exécutions

Les exécutions sont traitées de manière asynchrone. Soumettez une requête, puis interrogez le résultat.

Créer une exécution

Shell
curl -s https://runbase.net/api/v1/runs \
  -H "Authorization: Bearer $RUNBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "model": "google/nano-banana-pro",
    "input": { "prompt": "A cinematic product photo of a ceramic lamp" }
  }'

Obtenir le statut d'exécution

Shell
curl -s https://runbase.net/api/v1/runs/RUN_ID \
  -H "Authorization: Bearer $RUNBASE_API_KEY"

Obtenir le résultat

Interrogez l'endpoint de statut jusqu'à ce que status soit "succeeded", puis lisez output.urls dans la réponse.

Schéma d'entrée

ParamètreTypeRequisDescription
promptstringRequisPrompt
aspect_ratiostringOptionnelAspect ratioOptions : 1:12:33:23:44:34:55:49:1616:921:9auto
resolutionstringOptionnelResolutionOptions : 1K2K4K
image_urlsstring[]OptionnelReference images

Schéma de sortie

ChampTypeDescription
urlsstring[]URLs des résultats générés

Erreurs

L'API utilise les codes de statut HTTP standard pour indiquer le succès ou l'échec.

Code de statutDescription
400Request không hợp lệ - thiếu hoặc sai định dạng tham số
401Xác thực thất bại - thiếu hoặc sai khóa API
402Không đủ tín dụng
403Bị từ chối - IP không được phép hoặc khóa API vượt giới hạn chi tiêu
404Không tìm thấy lượt chạy
429Vượt giới hạn tốc độ
500Lỗi máy chủ nội bộ