Nodes/ComfyUI-Pollinations-BYOP/πŸ”πŸŒΈ Pollinations BYOP Login
ComfyUI Node

πŸ”πŸŒΈ Pollinations BYOP Login

The Pollinations node that logs you in for you β€” and saves the key so nothing else has to

By ChunkyPanda29Β·Created 6 months agoΒ·Updated a day agoΒ· 3
πŸ”πŸŒΈ Pollinations BYOP Login
    • api_key
    • username
    • email
    • balance
    β—„login_triggerfalseβ–Ί
    β—„app_keyβ–Ί

    Pollinations runs on a "Pollen" economy. Anonymous generation is free but heavily rate-limited and slow, and the fix - a personal API key with a weekly free allowance - used to mean hunting through a web dashboard, copy-pasting a sk_... string, and pasting it into every node. πŸ”πŸŒΈ Pollinations BYOP Login kills that entire ritual. It's the "Bring Your Own Pollen" door into the ComfyUI-Pollinations-BYOP pack: one toggle, a code you type into a browser, and your key is saved once and used by every other node automatically.

    That convenience is the whole point of this node. It exists so the rest of the pack feels like an API - no key management in sight.

    How it works

    It implements Pollinations' official device code flow (see byop_auth.py in the pack). Concretely, it:

    1. Requests a device code from enter.pollinations.ai (using your app_key for attribution, or the pack's bundled default pk_iMLHCKZ31UTDgWQr).
    2. Shows you a verification URL and a short user code like ABCD-1234.
    3. Polls the server every ~5 seconds for up to 5 minutes while you authorize on any device.
    4. On success, fetches your profile and - the key part - writes the API key into the pack's pollinations_config.json.

    That config file is exactly what every other Pollinations node reads when you leave their api_key field blank. The resolution order is: node-level field wins β†’ saved config β†’ POLLINATIONS_API_KEY environment variable. So login once and every image/video/audio/text node in the pack just works.

    Inputs and outputs

    • login_trigger - a boolean toggle, rendered as "Click to Login" (off state: "Idle"). Flip it on and the flow starts. When it's off, the node returns empty values, which is fine - it's an output node, so you only run it when you want to (re)authenticate.
    • app_key (optional) - a publishable pk_... key if you want your own branding on the consent screen instead of the pack's default attribution.

    Outputs, all from your Pollinations profile:

    • api_key (STRING) - the key itself, if you want to route it somewhere explicitly.
    • username (STRING), email (STRING) - who you're logged in as.
    • balance (INT) - your current Pollen balance, which is nice to have on a visible output node so you can see when a πŸ’Ž (paid) model run is about to tap your allowance.

    Installing it

    Same as the rest of the pack - ComfyUI Manager (search "Pollinations BYOP") or:

    cd ComfyUI/custom_nodes
    git clone https://github.com/ChunkyPanda29/ComfyUI-Pollinations-BYOP.git
    

    Restart, done. No models, no dependencies beyond what ComfyUI already has.

    Gotchas

    Two things bite people. First, the toggle returns empty strings when idle - don't read "no output" as "broken", that's just the off state. Second, the saved key lives in pollinations_config.json inside the pack's folder: if you reinstall the pack, move machines, or nuke custom_nodes, you're logged out and have to redo the flow. And if you ever want a different key on one specific node, paste it into that node's api_key field - it overrides everything. You can also skip this node entirely and paste a key from enter.pollinations.ai into the ComfyUI Settings β†’ "Pollinations (BYOP)" section; the node just saves you the copy-paste.

    CategoryPollinations/BYOP

    Inputs (2)

    NameTypeDefaultDescription
    login_triggerBOOLEANfalseβ€”
    app_keyoptSTRINGβ€”

    Outputs (4)

    NameTypeDescription
    api_keySTRINGβ€”
    usernameSTRINGβ€”
    emailSTRINGβ€”
    balanceINTβ€”