HyprLab ImageGen API Node
Nano Banana in ComfyUI, no Google account required
- image_input
- IMAGE
This node is the fastest way to get Google's "Nano Banana" image model inside a ComfyUI workflow without touching the Gemini app or Google's own API. You pay a small third-party host called HyprLab per image instead, and the results drop straight out as a normal ComfyUI IMAGE tensor. If you've seen the nano-banana image-edit demos that were all over r/StableDiffusion - the "put her in the car with the same pose" crowd - this is the closed-source model behind them, served through an OpenAI-style endpoint.
The catch is upfront: nothing about this runs locally. No model download, no VRAM, no GPU at all. The node is a thin HTTP wrapper. You need a HyprLab account and an API key, and every image you generate is a paid API call, so this is a "some money, no compute" trade, not a free local workflow.
How it works
The node POSTs a JSON payload to https://api.hyprlab.io/v1/images/generations with your key as a Bearer token. The payload carries the model, prompt, resolution, aspect ratio, seed, and asks for response_format: b64_json. When the response comes back it decodes the base64 into a PIL image and converts it to a tensor - so unlike a lot of API wrappers in this pack, you don't need a conversion node after this one. Wire IMAGE straight into Preview Image or Save.
Two niceties worth knowing. First, it retries on flaky connections: three attempts with exponential backoff between 5 and 30 seconds, only for connection errors and timeouts (not for a 401 or a 400). Second, if you feed it an image_input, the node downscales your image to about 1.5 megapixels before base64-encoding it, which keeps uploads fast. That input path is where Nano Banana genuinely shines - it's an editing model, not just a text-to-image one.
The inputs that matter
You'll actually touch maybe five of these:
- api_key - the one that gates everything. Get it from your HyprLab account and paste it in. Default is literally
YOUR_API_KEY_HERE, so the first run will 401 until you set this. - prompt - the main prompt. It's set as
forceInput, so you can wire it from another node (say, the output of an LLM node in this same pack). - model - defaults to
nano-banana-pro. Leave it alone unless your HyprLab plan lists a different model name; using one you don't have is the single most common model error. - resolution -
1K/2K/4K. 4K will cost you more and take longer; start at 1K. - aspect_ratio - eleven choices from
1:1through21:9, plusmatch_input_image, which is the right pick when you're editing an existing image. - seed - an integer, default 0. Set it to reproduce a result; the API should honor it.
The one optional input, image_input, takes any IMAGE tensor - from Load Image or the pack's own Load Image from URL - and sends it along as a reference for guided generation or editing.
Installing it
It ships in the ComfyUI_BillBum_Nodes pack, and all four nodes in this set install together. Easiest path: ComfyUI Manager, search for billbum, install, restart. Or clone it yourself:
cd ComfyUI/custom_nodes
git clone https://github.com/AhBumm/ComfyUI_BillBum_APIset_Nodes.git
pip install -r requirements.txt # tenacity, openai, pillow, requests, numpy, tiktoken, urlextract
Dependencies are all lightweight and there are no model files to download - the whole pack is API calls and string utilities. Just restart ComfyUI after installing.
Troubleshooting
- 401 / auth errors - key is wrong, missing, or the
api_urlgot mangled. Check the key in your HyprLab console, and only change the URL if you know what you're doing. - Model errors - the model you picked isn't available on your plan. This is the pack README's own first bit of advice: make sure model, base URL, and provider actually agree.
- "API did not return any valid images" - the node prints the raw API response to the console before failing; read that, it tells you what the server actually said.
- It cost money - there's no free tier surprise here; confirm the plan and price before running a batch. A 4K edit run adds up fast.
Fair warning: this is a small, community-maintained pack (the HyprLab node barely registers in search traffic), so expect rough edges. If the endpoint shape changes, the README and the nodes4hypr.py source are where the truth lives.
Inputs (8)
| Name | Type | Default | Description |
|---|---|---|---|
| prompt | STRING | The main text prompt | |
| seed | INT | 00–18446744073709550000 | — |
| model | STRING | nano-banana-pro | — |
| api_url | STRING | https://api.hyprlab.io/v1/images/generations | — |
| api_key | STRING | YOUR_API_KEY_HERE | — |
| resolution | COMBO | 1K | 3 options: 1K, 2K, 4K |
| aspect_ratio | COMBO | 1:1 | 11 options: match_input_image, 1:1, 9:16, 16:9, 3:4, 4:3, +5 |
| image_inputopt | IMAGE | Optional input images to guide generation |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| IMAGE | IMAGE | — |