Nano Banana Pro 文生图
google/nano-banana-2/text-to-image
Gemini 3.0 Pro 旗舰版。专为 4K 原生画质打造,支持图像内多语言文字渲染与专业摄影参数控制。
示例



参数
| 名称 | 类型 | 默认 | 约束 | 说明 |
|---|---|---|---|---|
| prompt *提示词 | textarea | — | ≤ 5000 chars | 描述您想要生成的图像。请具体说明主题、风格、颜色和构图。 |
| aspect_ratio宽高比 | select | 16:9 | 1:1 | 3:2 | 2:3 | 3:4 | 4:3 | 4:5 | 5:4 | 9:16 | … | 选择生成图像的宽高比。 |
| resolution分辨率 | select | 1k | 512 | 1k | 2k | 4k | 选择输出图像的分辨率。 |
API
通过统一 REST API 调用本模型;在 API Keys 页获取密钥。
cURL
# 1) Submit — returns { "task_uuid": "..." }
curl -X POST "https://www.namifusion.com/api/v1/marketplace/run/google/nano-banana-2/text-to-image" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": {
"prompt": "A serene mountain landscape at sunrise, with snow-covered peaks and a crystal-clear reflective lake in the foreground. Include vibrant orange and pink hues in the sky, realistic textures, and detailed trees on the slopes.",
"aspect_ratio": "16:9",
"resolution": "1k"
}
}'
# 2) Poll until status is "completed", then read the output URLs
curl "https://www.namifusion.com/api/v1/marketplace/run/tasks/TASK_UUID" \
-H "Authorization: Bearer YOUR_API_KEY"Python
import time, requests
API_KEY = "YOUR_API_KEY"
HEADERS = {"Authorization": f"Bearer {API_KEY}"}
# 1) Submit
resp = requests.post(
"https://www.namifusion.com/api/v1/marketplace/run/google/nano-banana-2/text-to-image",
headers=HEADERS,
json={
"input": {
"prompt": "A serene mountain landscape at sunrise, with snow-covered peaks and a crystal-clear reflective lake in the foreground. Include vibrant orange and pink hues in the sky, realistic textures, and detailed trees on the slopes.",
"aspect_ratio": "16:9",
"resolution": "1k"
}
},
)
resp.raise_for_status() # 401/402/429/5xx stop here instead of polling a bad task
task = resp.json()
# 2) Poll until a terminal state (completed / failed / cancelled).
# This model is allowed up to 300s server-side.
deadline = time.time() + 360
while task.get("status") not in ("completed", "failed", "cancelled"):
if time.time() > deadline:
raise TimeoutError(f"still {task.get('status')} — keep the task_uuid and poll later")
time.sleep(3)
poll = requests.get(f"https://www.namifusion.com/api/v1/marketplace/run/tasks/{task['task_uuid']}", headers=HEADERS)
poll.raise_for_status()
task = poll.json()
print(task["status"], task.get("output"))JavaScript
const API_KEY = "YOUR_API_KEY";
const HEADERS = { Authorization: `Bearer ${API_KEY}` };
// 1) Submit
const resp = await fetch("https://www.namifusion.com/api/v1/marketplace/run/google/nano-banana-2/text-to-image", {
method: "POST",
headers: { ...HEADERS, "Content-Type": "application/json" },
body: JSON.stringify({
"input": {
"prompt": "A serene mountain landscape at sunrise, with snow-covered peaks and a crystal-clear reflective lake in the foreground. Include vibrant orange and pink hues in the sky, realistic textures, and detailed trees on the slopes.",
"aspect_ratio": "16:9",
"resolution": "1k"
}
}),
});
if (!resp.ok) throw new Error(`submit failed: ${resp.status} ${await resp.text()}`);
let task = await resp.json();
// 2) Poll until a terminal state (completed / failed / cancelled).
// This model is allowed up to 300s server-side.
const deadline = Date.now() + 360 * 1000;
while (!["completed", "failed", "cancelled"].includes(task.status)) {
if (Date.now() > deadline) throw new Error(`still ${task.status} — keep the task_uuid and poll later`);
await new Promise((r) => setTimeout(r, 3000));
const poll = await fetch(`https://www.namifusion.com/api/v1/marketplace/run/tasks/${task.task_uuid}`, { headers: HEADERS });
if (!poll.ok) throw new Error(`poll failed: ${poll.status}`);
task = await poll.json();
}
console.log(task.status, task.output);文档
Google Nano Banana 2
专业品质图片生成,闪电般的速度
Google Nano Banana 2(Gemini 3.1 Flash Image)是一款先进的文本生成图片AI模型,专为需要高质量视觉效果且低延迟的创作者设计。支持从512px到4K的分辨率,该模型在生成逼真的图片方面表现卓越,同时具备改进的文本渲染、最多支持五个角色的一致性以及整合真实世界知识的能力。无冷启动,价格实惠,专为专业用途优化。
🚀 核心功能
- 闪电般的生成速度:几秒内生成高质量图片,确保最低延迟。
- 多分辨率支持:支持0.5K、1K、2K和4K分辨率,满足多样化需求。
- 灵活宽高比:支持多种宽高比,包括1:1、16:9、9:16等。
- 增强的文本渲染:生成具有改进文本清晰度和最多支持五个角色一致性的图片。
- 真实世界知识整合:可选启用实时网页和图片搜索以增强输出效果。
- 格式选择:根据需求导出为PNG或JPEG格式。
🛠️ 技术规格
| 规格 | 详情 |
|---|---|
| 模型架构 | Gemini 3.1 Flash Image |
| 输入格式 | 文本提示词 |
| 输出格式 | PNG、JPEG |
| 分辨率 | 0.5K、1K(默认)、2K、4K |
| 宽高比 | 1:1、3:2、2:3、3:4、4:3、4:5、5:4、9:16、16:9、21:9、1:4、4:1、1:8、8:1 |
| 网页搜索 | 可选(默认:禁用) |
| 图片搜索 | 可选(默认:禁用) |
| 延迟 | 闪电般的生成速度 |
示例提示词
- 提示词:"一个未来城市的日落景象,有飞行汽车和霓虹灯。"
- 提示词:"一个身穿全套盔甲的中世纪骑士,站在森林中。"
💰 价格
| 分辨率 | 价格(美元) | 附加功能 |
|---|---|---|
| 0.5K | $0.045 | |
| 1K | $0.07 | |
| 2K | $0.105 | |
| 4K | $0.14 | |
| 网页搜索 | +$0.014 | |
| 图片搜索 | +$0.014 |
💡 最佳使用场景
- 电影级画面:生成具有逼真光效和效果的氛围场景。
- 角色肖像:创建详细且一致的角色插图,用于故事创作。
- 社交媒体内容:为各种平台生成视觉吸引力强的图片。
- 营销与广告:设计专业视觉效果,用于广告活动。
- 概念艺术:通过高质量渲染可视化创意想法。
🔗 相关模型
- Nano Banana Pro Text-to-Image:专业级输出的增强质量。
- Nano Banana Pro Edit:高级图片编辑功能。
- Nano Banana 2 Edit:通过文本指令编辑图片。
相关模型
xAI Grok Imagine Image v2.0 文生图
xAI Grok Imagine Image V2.0 文生图可根据文本提示词生成高质量图片,并支持配置宽高比、分辨率和质量,适用于创意视觉、社交内容、营销素材和生产工作流。提供开箱即用的 REST 推理 API,性能出色,无冷启动,价格实惠。
Qwen Image 3.0 Pro 文生图
Qwen Image 3.0 Pro 是一款专业级文生图模型,具备卓越画质和先进的提示词理解能力。最高支持 2k。提供开箱即用的 REST inference API,性能出色,无冷启动,价格实惠。
OpenAI GPT Image 2 文本生成图片
OpenAI 的 GPT Image 2 文本生成图片模型可根据自然语言提示词生成高质量图片。提供即用型 REST 推理 API,性能最佳,无冷启动,价格实惠。
OpenAI GPT Image 2 Edit 图像编辑
OpenAI 的 GPT Image 2 Edit 可通过自然语言指令结合一张或多张参考图片进行图像编辑。提供即用型 REST 推理 API,性能最佳,无冷启动,价格实惠。
Nami Z-Image T2I Spicy
根据文本提示词生成图片,支持自定义宽高、提示词优化和随机种子。
Nano Banana 文生图
Gemini 2.5 Flash 标准版。轻量极速。兼顾速度与成本,是批量生成与快速原型设计的最佳选择。
Nano Banana Pro 文生图
Gemini 3.0 Pro 旗舰版。专为 4K 原生画质打造,支持图像内多语言文字渲染与专业摄影参数控制。
Google Nano Banana Lite 文生图 API
Google Nano Banana 2 Lite 文生图可根据文本提示词生成高质量图片,具备低延迟、灵活宽高比和快速出图能力,适用于创意与生产工作流。即开即用的 REST 推理 API,性能出色,无冷启动,价格实惠。