ComfyUI Node

Civitai Auth

The one node this whole pack runs on — your Civitai key, minus the pain

By civitai·Created 2 months ago·Updated about a month ago· 42
Civitai Auth
    • api_config
    modeauto
    api_token
    base_url
    allow_mature_contentfalse
    timeout_minutes30

    Every node in this pack is a remote control for Civitai's cloud. None of them run a model on your GPU, and all of them need your account to bill the job. The Civitai Auth node is the single place you drop that credential in, and every other node in the pack has an api_config socket that wants its output. It's the first thing you wire, so it's the first thing worth understanding.

    What it actually does

    It doesn't call anything. It builds a small config object (token, endpoint, timeout, mature-content flag) and hands it to whatever recipe node you wire it into. Think of it as the pack's .env file with sockets.

    The one input that matters is mode, which controls how credentials get found:

    • auto - your api_token field if filled, else the CIVITAI_API_TOKEN environment variable, else stored OAuth. No browser unless nothing else turns up.
    • api_key - same search order, but never opens a browser. This is the mode for headless or remote ComfyUI, where an interactive login would hang the box.
    • oauth - sign in through the browser if no token is found.

    Beyond that: api_token is where you paste a key from civitai.com/user/account (leave empty to fall back to env/OAuth). base_url is an override for the orchestration endpoint - leave it alone unless you're pointed at a dev stack, and honestly most people should just leave it alone. allow_mature_content flips whether mature results come back. And timeout_minutes (default 30, up to 720) is how long a job is allowed to run before the node gives up and cancels it - bump it for slow video or training jobs, not for a quick image.

    Output is one socket: api_config (type CIVITAI_CONFIG). Wire it into any recipe node's api_config input. It's optional everywhere - the pack falls back to the env var, a stored key, or OAuth if you don't use the node at all.

    How to install it

    Same as the whole pack - this isn't a standalone node:

    • ComfyUI Manager: open Manager → Custom Nodes Manager, search Civitai Comfy Nodes (publisher civitai), install, restart. Or with comfy-cli:
      comfy node registry-install civitai-comfy-nodes
    • From source:
      cd ComfyUI/custom_nodes
      git clone https://github.com/civitai/civitai-comfy-nodes.git
      pip install -r civitai-comfy-nodes/requirements.txt   # just requests

    The pack is an early preview and ships ~160 generated nodes, so expect things to move between updates.

    Where people get burned

    The classic is a headless server popping a browser prompt. If ComfyUI is on a box without a display, auto mode's last resort (interactive login) goes nowhere useful. Fix it by setting CIVITAI_API_TOKEN and using api_key mode, or just relying on the env var alone - the README's stated path for headless installs.

    Cost mistakes hit hard. Every call here is metered and billed in Buzz, the same in-site currency from the CivitAI story that's had the community wary since the Clubs paywall. You'll see a 402 error surface as "insufficient Buzz" when the wallet's dry, and 429 when you're rate-limited. Check the raw_json / workflow_id outputs on any recipe node to see what a run actually cost.

    And the security frame matters more than usual here. An API-wrapper node that phones home with your key is exactly the shape of thing that already got weaponized once in this ecosystem (the LLMVISION incident - a fake "LLM vision" captioner that exfiltrated keys). None of that makes this pack suspicious; it's official Civitai, installable from the Comfy Registry. But it means: only install the official pack, and don't paste a key into some fork that asks for it in the same spot.

    One honest tip to close: if every recipe node errors with "No Civitai credentials" and you know you set the env var, check whether the variable is visible to the ComfyUI process - restarting the server after exporting it is the usual fix.

    CategoryCivitai

    Inputs (5)

    NameTypeDefaultDescription
    modeCOMBOautoauto: api_token field > CIVITAI_API_TOKEN env > stored OAuth (no browser). api_key: same, never any browser. oauth: sign in via the browser if no token is found.
    api_tokenoptSTRINGCivitai API token (leave empty to use env/OAuth)
    base_urloptSTRINGOrchestration base URL override (e.g. a local dev stack)
    allow_mature_contentoptBOOLEANfalse
    timeout_minutesoptFLOAT301–720

    Outputs (1)

    NameTypeDescription
    api_configCIVITAI_CONFIG