Nanobanana 2 Lite Image Generation Agent Skill and API Guide
Install the EvoLink agent skill first, then run Nanobanana 2 Lite Image Generation through the API.
Menu • Install • Agent Auto-Install • API Quick Start • Showcase • Get API Key
AI Agent? Start here: install the skill with
npx, then read llms-install.md for agent-specific setup.
Menu
- Agent Skill First
- Installation
- Agent Auto-Install
- Getting an API Key
- API Quick Start
- Full First-Run Flow
- API Reference
- Showcase
- Troubleshooting
- Compatibility
- Community
- License
Agent Skill First
This repository is designed for agents and developers who want a one-line install path. The primary workflow is to install the skill with npx, let the agent read SKILL.md, and only then call the EvoLink API.
| Skill slug | NPM package | Model ID | Primary env var |
|---|---|---|---|
| nanobanana-2-lite-image | evolink-nanobanana-2-lite | gemini-3.1-flash-lite-image |
EVOLINK_API_KEY |
Installation
Install into your agent skills directory. Use npm for Claude Code, Codex, OpenClaw, and Hermes; OpenClaw users can also install directly from GitHub.
OpenClaw
openclaw skills add https://github.com/Evolink-AI/nanobanana-2-lite-image-generate-api-skill
Install via npm (Recommended)
npx evolink-nanobanana-2-lite@latest
npx evolink-nanobanana-2-lite@latest -y
npx evolink-nanobanana-2-lite@latest -y --path ~/.claude/skills
npx evolink-nanobanana-2-lite@latest "Create a short Nanobanana 2 Lite Image Generation demo"
Manual Install
git clone https://github.com/Evolink-AI/nanobanana-2-lite-image-generate-api-skill.git
cd nanobanana-2-lite-image-generate-api-skill
npm install
node bin/cli.js -y --path ~/.claude/skills
Agent Auto-Install
Use the copy-paste prompts in the next section when an agent needs to install the skill by itself.
Agent Auto-Install
Claude Code
Install the Nanobanana 2 Lite Image Generation skill by running:
npx evolink-nanobanana-2-lite@latest -y --path ~/.claude/skills
After installation, set EVOLINK_API_KEY, read ~/.claude/skills/nanobanana-2-lite-image/SKILL.md, then run one dry run before calling the real API.
Codex
Install the Nanobanana 2 Lite Image Generation skill by running:
npx evolink-nanobanana-2-lite@latest -y --path ~/.codex/skills
After installation, set EVOLINK_API_KEY, read ~/.codex/skills/nanobanana-2-lite-image/SKILL.md, then run one dry run before calling the real API.
OpenClaw
Install the Nanobanana 2 Lite Image Generation skill by running:
npx evolink-nanobanana-2-lite@latest -y --path ~/.openclaw/skills
After installation, set EVOLINK_API_KEY, read ~/.openclaw/skills/nanobanana-2-lite-image/SKILL.md, then run one dry run before calling the real API.
One-Liner
EVOLINK_API_KEY=your_key_here npx evolink-nanobanana-2-lite@latest "Create a blue ceramic cup on a white table"
Getting an API Key
- Create or open your EvoLink account.
- Create an API key in the EvoLink dashboard.
- Export the key as
EVOLINK_API_KEY. - Run a dry run before spending credits on a real generation.
API Quick Start
Use the same API key with the image generation endpoint.
export EVOLINK_API_KEY="your_key_here"
curl --request POST \
--url https://api.evolink.ai/v1/images/generations \
--header "Authorization: Bearer ${EVOLINK_API_KEY}" \
--header "Content-Type: application/json" \
--header "X-EvoLink-Source: skill" \
--header "X-EvoLink-Skill: nanobanana-2-lite-image" \
--header "X-EvoLink-Package: evolink-nanobanana-2-lite" \
--header "X-EvoLink-Campaign: nanobanana-2-lite-image" \
--header "X-EvoLink-Touchpoint: first_run" \
--data '{
"model": "gemini-3.1-flash-lite-image",
"prompt": "Create a short demo with Nanobanana 2 Lite Image Generation"
}'
Example response:
{
"id": "task_example",
"status": "pending"
}
Full First-Run Flow
- Create a task with
POST /v1/images/generations. - Store the returned task ID.
- Poll
GET /v1/tasks/{task_id}until the task iscompleted, or passcallback_url. - Save the final media URL from
resultsorresult_databefore it expires.
API Reference
What Is Nanobanana 2 Lite Image Generation?
Nanobanana 2 Lite Image Generation is an EvoLink image generation endpoint for text-to-image, image-to-image, and image editing workflows through the gemini-3.1-flash-lite-image model.
Endpoints
| Purpose | Method | Path |
|---|---|---|
| Create task | POST |
/v1/images/generations |
| Query task | GET |
/v1/tasks/{task_id} |
Request Parameters
| Parameter | Type | Required | Notes |
|---|---|---|---|
model |
string | yes | Use gemini-3.1-flash-lite-image. |
prompt |
string | yes | Prompt describing the image to generate or how to edit input images. Maximum 2000 tokens. |
size |
string | no | Aspect ratio. Defaults to auto; supported values include 1:1, 16:9, 9:16, 4:3, 3:4, 3:2, 2:3, 21:9, and more. |
quality |
string | no | Image quality. Default and supported value: 1K. |
image_urls |
string array | no | Reference images for image-to-image or editing. Up to 14 images, each under 20MB, using .jpeg, .jpg, .png, or .webp. |
model_params |
object | no | Model extension parameters. |
callback_url |
string | no | HTTPS callback URL for task completion, failure, or cancellation. |
Pricing and Billing
EvoLink returns usage details in the task creation response. The official example uses billing_rule: "per_call" and credits_reserved: 8.7; check the returned usage object and the EvoLink dashboard for the current account-specific charge before high-volume use.
Documentation
- Read the API reference
- Read the task lifecycle guide
- Read the response schema
- Read error handling guidance
- Read callback and webhook guidance
- Read pricing and billing notes
Showcase
| Example | Result |
|---|---|
| First successful API call | Polls until completed and prints the final URL / text / file. |
| Agent skill install | Installs SKILL.md, _meta.json, scripts/, and references. |
| Dry run | Prints the request payload without spending API credits. |
Troubleshooting
| Issue | Fix |
|---|---|
EVOLINK_API_KEY is missing |
Export EVOLINK_API_KEY before running the script. |
| Skill installed but agent cannot see it | Re-run with the correct --path for Claude Code, Codex, OpenClaw, or Hermes. |
jq or curl is missing |
Install the missing binary, then rerun the npx command. |
API returns 401 or 403 |
Verify the EvoLink key and account access. |
| Polling times out | Keep the task ID, inspect the dashboard, and avoid blind resubmission. |
Compatibility
| Agent | Install command |
|---|---|
| Claude Code | npx evolink-nanobanana-2-lite@latest -y --path ~/.claude/skills |
| Codex | npx evolink-nanobanana-2-lite@latest -y --path ~/.codex/skills |
| OpenClaw | npx evolink-nanobanana-2-lite@latest -y --path ~/.openclaw/skills |
| Hermes | npx evolink-nanobanana-2-lite@latest -y --path ~/.hermes/skills |
Community
- Read the official EvoLink Nanobanana 2 Lite API docs
- View this repository on GitHub
- Open the EvoLink signup page
License
MIT
Powered by EvoLink