Gia don gian va minh bach
Chi tra tien cho nhung gi ban su dung. Khong phi dang ky va khong chi phi an.
Nano Banana 2 API
$0.06-$0.12/img moi anh
Developer-ready API access
Vi sao chon Gemini 2.5 Flash Image API?
Trai nghiem the he tao anh AI moi toi uu cho toc do, chat luong va chi phi.
Tao anh sieu nhanh
Gemini 2.5 Flash tao anh chat luong cao chi trong vai giay.
Gia hop ly
Chi $0.03 moi anh va toi da 4 anh trong mot yeu cau.
Cong nghe AI tien tien
Tan dung Gemini 2.5 Flash voi kha nang hieu prompt va chat luong hinh anh tot.
Nhieu dinh dang dau ra
Lua chon JPEG hoac PNG theo nhu cau cua ban.
Workspace khong can code
Thu nghiem va tao anh tren giao dien web truoc khi tich hop.
API than thien voi lap trinh vien
REST API ro rang, tai lieu day du va vi du thuc te.
Ha tang dang tin cay
Ha tang cloud on dinh voi kha nang tu dong mo rong.
Ho tro webhook
Nhan thong bao khi qua trinh tao anh hoan tat.
Su dung thuong mai
Su dung anh da tao trong san pham va du an thuong mai.
Integrate in Minutes
Create your API key
Sign up and grab an API key from the PiAPI workspace — free credits are included on sign-up.
Top up credits
Add credits on the billing page when you are ready to scale beyond the free tier.
Call the API
POST your first task following the API docs, then poll the task until the result is ready.
Iterate in the playground
Prototype prompts and settings in the the playground above before wiring them into your product.
curl -X POST 'https://api.piapi.ai/api/v1/task' \
-H 'X-API-Key: YOUR_API_KEY' \
-H 'Content-Type: application/json' \
-d '{
"model": "gemini",
"task_type": "nano-banana-2",
"input": {
"prompt": "A modern smartphone on a reflective surface with water droplets.",
"resolution": "1K"
}
}'
# → { "task_id": "9d5a…", "status": "pending" }curl 'https://api.piapi.ai/api/v1/task/{task_id}' \
-H 'X-API-Key: YOUR_API_KEY'
# poll until status = completed
{
"data": {
"status": "completed",
"output": {
"image_url": "https://img.theapi.app/ephemeral/…"
}
}
}$ npm install -g piapi-cli $ piapi run nano-banana-2 \ prompt="A modern smartphone on a reflective surface with water droplets." \ resolution=1K ✓ Task completed! https://img.theapi.app/ephemeral/…
Cau hoi thuong gap
Gemini 2.5 Flash Image API la gi?
Gemini 2.5 Flash la mo hinh tao anh moi nhat cua Google, duoc toi uu ve toc do va chat luong.
Chi phi tao anh la bao nhieu?
Muc gia la $0.03 moi anh, toi da 4 anh cho moi yeu cau.
Ho tro nhung dinh dang anh nao?
Chung toi ho tro JPEG va PNG.
Toc do tao anh nhanh den muc nao?
Phan lon hinh anh duoc tao trong duoi 10 giay.
Toi co the su dung anh cho muc dich thuong mai khong?
Co. Anh da tao co the duoc dung cho muc dich thuong mai.
Workspace khong can code la gi?
Workspace khong can code cua chung toi tai piapi.ai/workspace/nano-banana cho phep ban thu prompt va tao anh ngay trong trinh duyet.
Co ho tro webhook khong?
Co. Ban co the nhan thong bao khi anh da san sang.
Lam sao de tich hop API vao ung dung cua toi?
Tich hop rat don gian voi REST API cua chung toi. Xem tai lieu API.
Prompt nao cho ket qua tot nhat?
Prompt chi tiet cho ket qua tot hon. Hay them phong cach, bo cuc, anh sang va khong khi.
Co gioi han tao anh khong?
Khong co gioi han tong the nghiem ngat, nhung moi yeu cau ho tro toi da 4 anh.
Lam sao de lien he voi doi ngu?
Hay gui email toi support@piapi.ai va chung toi se san long ho tro.
More questions? See the API docs.
Our blog
Nano Banana 2 API



