Badgr Generate Image
SDXL or Flux on someone else's GPU, with the bill capped
- image
- job_id
There are two reasons a workflow leaves your machine: the model has no weights to download, or the model is open and you just don't have the card. Badgr Generate Image is the second one. It takes a prompt, ships it to a Badgr-hosted ComfyUI install on a rented GPU, and hands back an image tensor like nothing unusual happened.
That puts it in the "rent a GPU" bucket next to Runware, fal, Replicate and Comfy Cloud - except the pitch is narrower and, if you've ever forgotten to shut down a pod, more appealing. There's a hard dollar cap per run, and a timeout or an interrupt cancels the job server-side so it stops billing.
What you're actually buying
Prompt-only. The workflow dropdown has two choices - sdxl-basic and flux-basic - and both are Badgr's own prebuilt graphs, defined on their side. You don't pick the checkpoint, the sampler, the step count or the resolution; the client sends a job type, a workflow id and a one-element prompt list, and nothing else about your graph travels.
So if you came here to push a LoRA stack and ControlNet rig through a big card, this won't do it - arbitrary graphs aren't uploaded, and the README says so plainly. What it is: a decent SDXL or Flux image out of a laptop that would melt, or a way to prototype prompts before committing to a local build.
The inputs that matter
Four required fields, and three of them are housekeeping.
prompt is the entire creative surface - the whole control you get over the image.
workflow picks the model family. flux-basic for prompt understanding and general quality; sdxl-basic when you want the SDXL look or a cheaper job.
max_cost_usd (default 0.5, floor 0.01, ceiling 50) is the hard cap, and the one field worth thinking about. That number is your entire exposure on the run.
timeout_seconds (default 900, range 60–3600) is how long the node waits. It also derives a server-side limit of timeout // 60 + 1 minutes, so 900s tells the backend to stop at 16. Both ends give up on you.
The outputs
image is an IMAGE tensor - RGB, float32, 0–1, batch dimension present - that you wire into Preview Image, Save Image or anything downstream, same as a local sampler. It's forced to RGB on the way in, so alpha and embedded metadata are gone.
job_id you probably won't wire anywhere. Keep it anyway for reconciling a bill.
Install
ComfyUI Manager, search the pack title "Badgr" (publisher aibadgr), or:
cd ComfyUI/custom_nodes
git clone https://github.com/AiBadgr/ComfyUI-Badgr
Then set the key before starting ComfyUI, from that same shell:
export BADGR_API_KEY=...
python main.py
On Windows, set BADGR_API_KEY=... in that same shell, or setx and a new terminal - a variable set while ComfyUI is already running won't be seen.
There's nothing to pip install: pyproject.toml declares no dependencies, the HTTP is stdlib, and numpy/Pillow already ship with ComfyUI. No model downloads, no CUDA build to match. The source also honors BADGR_BASE_URL if you need a different endpoint, which the README doesn't mention.
Where it bites
"BADGR_API_KEY is not set." The most common failure by far, and always the same story - key exported after launch, or in a different terminal. Restart from the shell that has it.
Queueing twice returns the identical image, for free. ComfyUI caches node execution and this one has no IS_CHANGED override, so with all four inputs unchanged the second queue reuses the cached tensor and never calls the API. Nudge any input if you actually want to spend money.
Nothing shows up. This isn't an output node. Leave image unconnected and you've built a graph with no outputs, so the prompt never runs.
The error barfs a number like 401 or 402. HTTP failures get wrapped with the server's own text, so the message usually names the problem - bad key, no credits. Read it before assuming the node is broken.
Interrupt gave you an error instead of a clean stop. Expected: cancel-then-raise is how the billing stops. Same on timeout, so raise timeout_seconds if you keep clipping it.
One caution. A node whose whole purpose is to hold a key and call the network is the riskiest shape a custom node takes, and this pack is brand new - 0.1.0, one commit, one publisher. The upside is that it's a couple hundred readable lines, and the key lives in your environment rather than in a node field, so a workflow you share can't leak it.
If you've got the VRAM, do it locally - it's cheaper and you keep control. If you've got a laptop and a deadline, cap the cost and let it rip.
Inputs (4)
| Name | Type | Default | Description |
|---|---|---|---|
| prompt | STRING | — | |
| workflow | COMBO | 2 options: sdxl-basic, flux-basic | |
| max_cost_usd | FLOAT | 0.500.01–50 | — |
| timeout_seconds | INT | 90060–3600 | — |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| image | IMAGE | — |
| job_id | STRING | — |