🎨通用图像编辑API (测试版) @炮老师的小课堂
Aspect, HD presets, style presets, and a built-in upscaler
- 🖼️ 图像1
- 🖼️ 图像2
- 🖼️ 图像3
- 🖼️ 图像4
- image
- response
- image_url
- raw_json
Some nodes are opinionated about the vendor. ImageEditAPINode ("🎨通用图像编辑API (测试版) @炮老师的小课堂") is opinionated about the workflow instead: it wraps a chat-completions-style multimodal image edit API - the kind Gemini 3 / Nano Banana 2 use - and layers on a pile of quality controls: aspect ratio, output resolution, quality presets, style presets, and an AI upscale stage with nine different upscale models. It's marked 测试版 (beta), and it shows: the default endpoint is a third-party relay (api.tu-zi.com), the model default is gemini-3-pro-image-preview, and the README points at a wiki page for that model. This is a "point it at whatever speaks this dialect" node with extra frosting.
The controls that matter
- 💬 提示词 - the edit instruction. Plus 🎯 系统角色 if the endpoint supports it.
- 🌐 API地址 / 🔑 API密钥 / 🤖 模型名称 - the trinity. Default model is
gemini-3-pro-image-preview(Nano Banana 2 class), which is where the node's feature list makes most sense. - 📡 请求方法 / 🔐 密钥位置 / 📝 密钥字段名 - POST default, key in Header, field
Authorization. Same flexible auth pattern as the universal API node. - 🖼️ 图像1–4 - up to four reference images for the edit.
- 📐 宽高比 - Auto plus ten ratios.
- 📊 响应模式 -
TEXT_AND_IMAGEorIMAGE_ONLY. - 🖥️ 输出分辨率 - Auto / 1K / 2K / 4K. Tooltip is explicit: only supported by Nano Banana 2 (Gemini 3) models. On other models, leave it at Auto or you'll get a rejected call.
- 🎨 画质预设 - standard / hd / ultra_hd / ai_enhanced / ai_ultra.
- 🎭 风格预设 - vivid / natural / artistic / cinematic / photographic.
- 🔍 放大倍数 - 1x (不放大) / 2x / 4x / 6x, with 🧩 放大模型 (High Fidelity, Standard, Art & CG, Lines, Very Compressed, Low Resolution, Text & Shapes, Redefine, Recover). The upscale runs as part of the same call.
Optional plumbing: 🎯 响应提取路径 (jq-style path into the response JSON), ⏱️ 超时时间, 📋 额外Headers, **📦 额外Body参数`. Outputs are the useful quartet: image (IMAGE), response (STRING), image_url, raw_json.
The honest picture
This node is a good example of the reseller ecosystem in action - it ships pointed at a relay, because that's how many people in this space reach Nano Banana 2 outside Google's own billing. That's fine, but it's exactly the scenario the KB's external-API essay flags: a node that holds your key and phones out by design. So treat the default endpoint as a suggestion, check what you're actually sending where, and remember the beta label means the mapping of presets to endpoints can change without notice. On the practical side: the 输出分辨率 field will bite you first - leave it on Auto unless you're certain the model supports 2K/4K. And if a call fails, raw_json is where the endpoint tells you what it didn't like.
Install
cd ComfyUI/custom_nodes/
git clone https://github.com/paolaoshi/ComfyUI-dapaoAPI.git
cd ComfyUI-dapaoAPI
pip install -r requirements.txt
Restart ComfyUI. No models download - the "models" here live on the endpoint you configure.
Inputs (23)
| Name | Type | Default | Description |
|---|---|---|---|
| 💬 提示词 | STRING | 请根据这些图片进行专业的图像编辑 | — |
| 🌐 API地址 | STRING | https://api.tu-zi.com/v1/chat/completions | — |
| 🔑 API密钥 | STRING | — | |
| 🤖 模型名称 | STRING | gemini-3-pro-image-preview | — |
| 📡 请求方法 | COMBO | POST | 3 options: POST, GET, PUT |
| 🔐 密钥位置 | COMBO | Header | 3 options: Header, Query, Body |
| 📝 密钥字段名 | STRING | Authorization | — |
| 🖼️ 图像1opt | IMAGE | — | |
| 🖼️ 图像2opt | IMAGE | — | |
| 🖼️ 图像3opt | IMAGE | — | |
| 🖼️ 图像4opt | IMAGE | — | |
| 📐 宽高比opt | COMBO | Auto | 11 options: Auto, 1:1, 2:3, 3:2, 3:4, 4:3, +5 |
| 📊 响应模式opt | COMBO | TEXT_AND_IMAGE | 2 options: TEXT_AND_IMAGE, IMAGE_ONLY |
| 🖥️ 输出分辨率opt | COMBO | Auto (Model Default) | 仅支持 Nano Banana 2 (Gemini 3) 模型 |
| 🎨 画质预设opt | COMBO | hd | 5 options: standard, hd, ultra_hd, ai_enhanced, ai_ultra |
| 🎭 风格预设opt | COMBO | natural | 5 options: vivid, natural, artistic, cinematic, photographic |
| 🔍 放大倍数opt | COMBO | 1x (不放大) | 4 options: 1x (不放大), 2x, 4x, 6x |
| 🧩 放大模型opt | COMBO | High Fidelity | 9 options: High Fidelity, Standard, Art & CG, Lines, Very Compressed, Low Resolution, +3 |
| 🎯 系统角色opt | STRING | — | |
| 🎯 响应提取路径opt | STRING | — | |
| ⏱️ 超时时间opt | INT | 1801–300 | — |
| 📋 额外Headersopt | STRING | {} | — |
| 📦 额外Body参数opt | STRING | {} | — |
Outputs (4)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |
| response | STRING | — |
| image_url | STRING | — |
| raw_json | STRING | — |