Comfpod OpenAI API
Comfpod's fork of ComfyUI nodes for language and vision models using OpenAI-compatible chat completion APIs.
Nodes (10)
Twenty Captions, One Node, No Copy-Paste
Put an LLM or VLM Inside the Graph and Actually Use It
The Node That Doesn't Need an OpenAI Account
Many Prompts, Many Conditionings, One CLIP Model
Hand Every Request a Different Set of Images
Look Before You Spend
One Request Per Image (Which Is Usually What You Wanted)
Turn a Text File of Prompts Into a Batch
Every Dial on Your API Call, Behind a Switch — and Why Sending Nothing Is the Default
One Prompt, N Requests, No Guessing the Count
comfpod-openai-api
The canonical home of this repository is at https://git.colorized.life/comfyui-openai-api/
ComfyUI nodes for text and image chat through OpenAI-compatible APIs, forked from ComfyUI OpenAI API.
# Use ComfyUI's Python interpreter (Python 3.13+).
cd /path/to/ComfyUI/custom_nodes
git clone https://git.colorized.life/comfyui-openai-api.git
cd comfyui-openai-api
/path/to/ComfyUI/.venv/bin/python -m pip install -r requirements.txt
# Restart ComfyUI.
Nodes
Find these under OpenAI API. Connect Client → Chat Completion; connect an Options node to its Options input as needed.
| Display name | Node ID | Purpose |
| --- | --- | --- |
| OpenAI API - Client | Comfpod_OpenAPI_Client | Set the API base URL, key, timeout, and retries |
| OpenAI API - Chat Completion | Comfpod_OpenAPI_ChatCompletion | Send text, images, or both; return a response and conversation history |
| OpenAI API - Batched Chat Completion | Comfpod_OpenAPI_BatchedChatCompletion | Run independent completions sequentially and return responses in input order |
| OpenAI API - Options | Comfpod_OpenAPI_Options | Set the seed, temperature, max tokens, top P, frequency and presence penalties, instruction message role, and custom request body parameters |
| OpenAI API - Multiline String to List | Comfpod_OpenAPI_MultilineStringToList | Split multiline text into a STRING execution list |
| OpenAI API - Image Batch List | Comfpod_OpenAPI_ImageBatchList | Collect images and batches into one list while preserving each batch |
| OpenAI API - Image Batch to List | Comfpod_OpenAPI_ImageBatchToList | Create one group per source image, optionally prepend or append common images without resizing, and output the group count |
| OpenAI API - Repeat String to List | Comfpod_OpenAPI_RepeatStringToList | Repeat a complete prompt into a STRING execution list; connect the image group count to match prompt counts |
| OpenAI API - Image Batch List to Images | Comfpod_OpenAPI_ImageBatchListToImages | Expose all image groups or one selected invocation as an IMAGE execution list for Preview Image, preserving image order and original sizes |
| OpenAI API - CLIP Text Encode List | Comfpod_OpenAPI_CLIPTextEncodeList | Encode each prompt separately with one shared CLIP model and return complete CONDITIONING objects as an execution list in prompt order |
Internal node IDs use the Comfpod_OpenAPI_ prefix to avoid registration collisions
with the upstream OpenAI API nodes. Saved workflows using this fork's old
OAIAPI_* node IDs need migration: update those nodes' type values (or
class_type values in API-format prompts) to Comfpod_OpenAPI_*, keeping the
suffix unchanged. Only migrate nodes intended to use this fork; upstream nodes
keep their existing IDs. Old-ID aliases are not registered.
Options: Each numeric setting is sent only when its Use switch is on.
Instructions Role selects the system or developer role. Extra Body takes a
JSON object whose keys override the named settings; leave it empty to add none.
Chain another Options node into Options to merge them; the later node's
switched-on settings, role, and Extra Body take precedence. Options replaces the
Seed, Temperature, Max Tokens, Top P, Frequency Penalty, Presence Penalty,
Developer Role, and Extra Body nodes, which are no longer registered. In saved
workflows, replace each chain of those nodes with one Options node and switch on
the matching settings.
Image Batch List to Images: Connect Image Batches from Image Batch List or
Image Batch to List, then connect Images to Preview Image. Invocation Index is
-1 for all invocations in order, 0 for the first, 1 for the second, and so on.
Each image is a separate execution-list entry, preserving its original size;
common images appear again for each invocation that includes them.
CLIP Text Encode List: Connect a single CLIP model and a STRING execution list (such as Responses from Batched Chat Completion). Each prompt produces its own complete conditioning, including scheduled entries, in the original prompt order.
License
This fork is distributed under the GNU Affero General Public License, version 3 only (AGPL-3.0-only); see LICENSE.
The upstream code at commit efb68c42291ae77df665423e02d6885a3f556bd1 is copyright © 2025 Edouard Hur and remains available under the MIT License; see LICENSE-MIT.
Original additions and modifications made for this fork after that baseline are licensed under AGPL-3.0-only. Pre-existing upstream portions retain their MIT licensing, including those within subsequently modified files. Third-party material retains its applicable licenses and notices.
See COPYRIGHT for upstream and fork attribution.