Nano Banana
Génération d'images rapide avec prise en charge du texte vers l'image et de l'image vers l'image
Fonctionnalités
- Génération d'images à partir de texte
- Transformation d'image à image
- Multiples formats d'image
- Génération rapide (~5 s)
Tarification
4 (~$0.04)Per image
Point de terminaison
POST
/api/v1/images/generateParamètres
| Paramètre | Type | Obligatoire | Description |
|---|---|---|---|
| model | string | Obligatoire | Must be "nano-banana" |
| prompt | string | Obligatoire | Text description of the image to generate |
| negative_prompt | string | Facultatif | What to avoid in the image |
| aspect_ratio | string | Facultatif | "1:1", "16:9", "9:16", "4:3", "3:4" |
| input_image | string | Facultatif | URL or base64 for image-to-image |
| num_images | number | Facultatif | Must be 1 |
Exemple de Demande
{
"model": "nano-banana",
"prompt": "A futuristic city at night with neon lights",
"aspect_ratio": "16:9"
}Exemple de réponse
{
"success": true,
"data": {
"task_id": "task_abc123",
"credits_used": 4,
"remaining_credits": 496,
"model": "nano-banana"
}
}Exemples de Code
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"
}'