Nodes/ComfyUI_AgnesAI_Nodes/🔧 Agnes AI Config
ComfyUI Node

🔧 Agnes AI Config

The Key That Opens the Rest of the Agnes Nodes

By Watchcats211·Created 3 months ago·Updated 3 months ago· 2
🔧 Agnes AI Config
    • config
    api_key
    base_urlhttps://apihub.agnes-ai.com/v1

    This node does exactly one job, and it does it before your graph even runs: it hands your Agnes API key to the other four nodes in this pack. Agnes_Text2Image, Agnes_Text2Video, and Agnes_Image2Video all have a config input socket that only accepts the AGNES_CONFIG type this node emits. No Config node, no generation - they just sit there with nowhere to get credentials from.

    What it actually is

    Agnes AI is a cloud image and video API. You pay for (or get a free tier of) inference that runs on their servers, and your ComfyUI stays a thin client - all the heavy lifting happens at apihub.agnes-ai.com. That's the whole point of the pack: ComfyUI's node graph as a front-end for a hosted service, which is great if you don't own a GPU that can chew through a 13-second video clip. The Config node is where you park your credentials for that service.

    The inputs are the two you'd expect:

    • api_key - your Agnes key. Leave it blank and the node falls back to the AGNES_API_KEY environment variable, which is honestly the better habit for reasons covered below.
    • base_url - defaults to https://apihub.agnes-ai.com/v1 and you almost never need to touch it. Leave it blank and it falls back to AGNES_BASE_URL, then to the default.

    It outputs a single config value of type AGNES_CONFIG, which is just a small dictionary bundling api_key and base_url. Wire it into the config socket on any of the generation nodes.

    How it works

    When the graph executes, this node builds that config dict and then does something a lot of config nodes skip: it pings the API. It sends a GET to {base_url}/videos with your key as a Bearer token, so you get an early "your key is bad" signal instead of discovering it 30 seconds into a generation. The result shows up in the ComfyUI console - a green ✓ Agnes Config: Connected or a red ✗ Agnes Config: Auth failed (HTTP 401) - not as a visible widget, so check the terminal if you're not sure your key took.

    Install

    This pack is tiny. Either grab it through ComfyUI Manager (search "AgnesAI"), or:

    cd ~/ComfyUI/custom_nodes
    git clone https://github.com/Watchcats211/ComfyUI_AgnesAI_Nodes.git
    

    Then restart ComfyUI. There's no requirements.txt - the pack leans on torch, numpy, and Pillow, which any working ComfyUI already has. The Config node itself needs nothing else.

    Common issues

    • Red ✗ in the console with HTTP 401/403 - wrong or expired key. Double-check you didn't paste a space, and confirm you actually have an Agnes account with API access enabled.
    • "Connection failed" - network problem, or the API is having a bad day. Agnes is young (it's been showing up in r/comfyui only since early 2026), so outages aren't unheard of.
    • The key that got away: if you type your API key into the widget and save the workflow, the key is baked into the workflow JSON - and since ComfyUI embeds workflow metadata in PNGs, it can end up in an image you share. The pack ships a scripts/sanitize_release.py that scrubs keys before publishing workflows, and the README tells you to keep them blank and use AGNES_API_KEY instead. Do that. For a $0-impression pack, leaking a key because it rode along in a PNG is an annoyingly easy way to lose your credits.
    CategoryAgnesAI

    Inputs (2)

    NameTypeDefaultDescription
    api_keySTRINGYour Agnes.ai API key. Leave blank to use AGNES_API_KEY from the environment.
    base_urlSTRINGhttps://apihub.agnes-ai.com/v1Agnes.ai API base URL

    Outputs (1)

    NameTypeDescription
    configAGNES_CONFIG