In this article, we will introduce ComfyUI’s API Nodes and related information.
API Nodes are ComfyUI’s new way of calling closed-source models through API requests, providing ComfyUI users with access to external state-of-the-art AI models without complex API key setup.
API Nodes are a set of special nodes that connect to external API services, allowing you to use closed-source or third-party hosted AI models directly in your ComfyUI workflows. These nodes are designed to seamlessly integrate the capabilities of external models while maintaining the open-source nature of ComfyUI’s core.
Currently supported models include:
To use API Nodes, the following requirements must be met:
Please update your ComfyUI to the latest version, as we may add more API support in the future, and corresponding nodes will be updated, so please keep your ComfyUI up to date.
Please note the distinction between nightly and release versions. We recommend using the nightly
version (which is the latest code commit), as the release version may not be updated in a timely manner.
This refers to the development version and the stable version, and since we are still rapidly iterating, this document may not be updated promptly, so please pay attention to the version differences.
You need to be logged into your ComfyUI with a Comfy account and have a credit balance of credits greater than 0.
Log in via Settings
-> User
:
Go to Settings
-> Credits
to purchase credits
Please refer to the corresponding documentation for account and credits to ensure this requirement:
User
section in the settings menu to log in.API access requires that your current requests are based on a secure network environment. The current requirements for API access are as follows:
127.0.0.1
or localhost
, and you can directly use the login function.https
environment to ensure the security of the requests.Accessing in an insecure context poses significant risks, which may result in the following consequences:
Even if we open this restriction in the future, we strongly advise against accessing API services through insecure network requests due to the high risks involved.
Add to Workflow: Add the API node to your workflow just like you would with other nodes. Run: Set the parameters and then run the workflow.
Currently, we have set up a whitelist to restrict the websites where you can log in to your ComfyUI account. If you need to log in to your ComfyUI account on some non-whitelisted websites, please refer to the account management section to learn how to log in using an API Key. In this case, the corresponding website does not need to be on our whitelist.
Learn how to log in with ComfyUI API Key
Currently, we support accessing our services through ComfyUI API Key Integration to call paid model API nodes. Please refer to the API Key Integration section to learn how to use API Key Integration to call paid model API nodes.
Please refer to the API Key Integration section to learn how to use API Key Integration to call paid model API nodes
API Nodes provide several important advantages for ComfyUI users:
Please refer to the pricing page for the corresponding API pricing
It’s important to note that API Nodes are completely optional. ComfyUI will always remain fully open-source and free for local users. API nodes are designed as an “opt-in” feature, providing convenience for those who want access to external SOTA (state-of-the-art) models.
A powerful application of API Nodes is combining the output of external models with local nodes. For example:
wan
nodeThis flexibility makes ComfyUI a truly universal generative AI interface, integrating various AI capabilities into a unified workflow, opening up more possibilities
Why can't I find the API nodes?
Please update your ComfyUI to the latest version (the latest commit or the latest desktop version). We may add more API support in the future, and the corresponding nodes will be updated, so please keep your ComfyUI up to date.
Please note that you need to distinguish between the nightly version and the release version.
In some cases, the latest release
version may not be updated in time compared to the nightly
version.
Since we are still iterating quickly, please ensure you are using the latest version when you cannot find the corresponding node.
Why can't I use / log in to the API Nodes?
API access requires that your current request is based on a secure network environment. The current requirements for API access are as follows:
127.0.0.1
or localhost
, which may mean that you cannot use the API Nodes in a ComfyUI service started with the --listen
parameter in a LAN environment.Why can't I use API node even after logging in, or why does it keep asking me to log in while using?
127.0.0.1
or localhost
access is supported.Can API Nodes be used for free?
API Nodes require credits for API calls to closed-source models, so they do not support free usage.
How to purchase credits?
Please refer to the following documentation:
User
section in the settings menu to log in.Settings
→ Credits
. We use a prepaid system, so there will be no unexpected charges.Are unused credits refundable?
Currently, we do not support refunds for credits. If you believe there is an error resulting in unused balance due to technical issues, please contact support.
Can credits go negative?
Credits cannot go negative, so please ensure you have enough credits before making the corresponding API calls.
Where can I check usage and expenses?
Please visit the Credits menu after logging in to check the corresponding credits.
Is it possible to use my own API Key?
Currently, the API Nodes are still in the testing phase and do not support this feature yet, but we have considered adding it.
Do credits expire?
No, your credits do not expire.
Can credits be transferred or shared?
Can I use the same account on different devices?
We do not limit the number of devices that can log in; you can use your account anywhere you want.
How can I request for my account or information to be deleted??
Email a request to support@comfy.org and we will delete your information