ComfyUI Builder MCP server
io.github.MIt9/comfy-ui-builder·v2.4.1·3 starsComfyUI MCP server: knowledge base, workflow builder, real-time execution, models, plugins.
3 stars102 downloads/wk
Reviews
Write oneNobody has reviewed ComfyUI Builder yet.
If you have run it, two minutes of your experience saves the next person an afternoon.
ComfyUI Builder tools (60, 10 write)
write = sends, deletes, buys or postsRead from the package source without running it. The installed server may list more.
add_nodeAdd a node to a dynamic workflow. Returns the new node id (e.g. "1", "2").
apply_templateApply parameter values to a workflow template. Returns workflow JSON ready to execute or save. Use create_template to build a template, then apply_template with values.
build_workflowBuild a ComfyUI workflow from a template and parameters. Returns workflow JSON ready to execute or save. For txt2img_flux, call get_system_resources first and use only when flux_ready is true (FLUX needs ~12GB+ VRAM).
check_compatibilityCheck if output of one node can connect to input of another (using node-compatibility.json).
check_model_existsCheck if a model exists on the ComfyUI server (in object_info model lists). Requires COMFYUI_HOST.
check_workflow_modelsCheck which models required by a workflow exist on the ComfyUI server. Returns ready (boolean), missing, and found lists. Requires COMFYUI_HOST.
clear_queueClear ComfyUI queue: remove all pending and stop/clear running. Requires COMFYUI_HOST.
connect_nodesConnect an output of one node to an input of another in a dynamic workflow.
create_templatewrite actionCreate a parameterized workflow template from a workflow and parameter definitions. Returns template JSON for use with apply_template or validate_template_params. Parameters bind to node inputs via nodeBindings (nodeId, inputName).
create_workflowwrite actionCreate a new empty workflow context. Returns workflow_id to use with add_node, connect_nodes, get_workflow_json, validate_workflow, finalize_workflow, execute_workflow.
delete_queue_itemswrite actionRemove specific items from ComfyUI queue by prompt_id. Use list_queue to get prompt_ids. Requires COMFYUI_HOST.
discover_nodes_liveGet all node definitions from the running ComfyUI instance (GET /object_info). Returns class names and categories. Requires ComfyUI to be running at COMFYUI_HOST.
download_all_outputsDownload all output files for a prompt into a directory. Returns list of saved paths. Requires COMFYUI_HOST.
download_by_filenameDownload an output file by filename (no prompt_id needed). Uses GET /view. Use when you have filename from get_history or get_last_output. If return_base64 is true, file is not written to disk; returns base64 data. When size > 800 KB, automatically converts to WebP to stay under 1MB base64 limits. Requires COMFYUI_HOST.
download_outputDownload a single output file to a local path. Use list_outputs to get file info. Requires COMFYUI_HOST.
execute_batchwrite actionExecute multiple workflows in batch. Submits each workflow and waits for completion (polling). Optional concurrency and stop_on_error. Requires COMFYUI_HOST.
execute_chainwrite actionExecute a chain of workflows in sequence. Each step runs after the previous completes. Use inputFrom and outputTo to pass the output image from one step to the next (e.g. txt2img → upscale → img2img). Steps can use workflow JSON or saved workflow name. Prefer saved workflow name (string) for large workflows to avoid ENAMETOOLONG in some clients. Requires COMFYUI_HOST.
execute_workflowwrite actionSubmit a ComfyUI workflow to run. Returns prompt_id. Use get_execution_status(prompt_id) to check result. Requires COMFYUI_HOST and ComfyUI running.
execute_workflow_streamwrite actionExecute workflow with streaming real-time progress updates. Requires WebSocket support. Returns result and progress event history. Use for monitoring execution progress. Requires COMFYUI_HOST and WebSocket connection.
execute_workflow_syncwrite actionSubmit a ComfyUI workflow and wait until execution completes with real-time progress (WebSocket if available, polling fallback). Returns prompt_id, status (completed/failed/timeout), and outputs. When timeout_ms is omitted, uses recommended_timeout_ms from get_system_resources (higher on MPS/Apple). Use when you need the result before continuing. Requires COMFYUI_HOST.
finalize_workflowGet the workflow JSON for a dynamic workflow (same as get_workflow_json). Use with execute_workflow or save_workflow.
get_error_detailsGet full error details for a prompt (node_id, exception_type, exception_message, full traceback). Use when execute_workflow_sync failed or get_execution_status shows errors. Returns structured errors from ComfyUI history status.messages. Requires COMFYUI_HOST.
get_execution_progressGet real-time execution progress for a prompt (WebSocket if available, polling fallback). Returns status, current_node, progress%, queue_position, and outputs. Requires COMFYUI_HOST.
get_execution_statusGet execution status and outputs for a prompt. Returns status, image filenames, and view URLs. Requires COMFYUI_HOST.
get_generation_recommendationsGet recommendations for image generation: system resources (max resolution, model size, batch) and, if the user prompt suggests text/letters in the image, advice on models and settings. Many base models (SD 1.5, SD XL) render text poorly; FLUX, SD 3, or checkpoints trained for text work better. Call when planning a txt2img or img2img workflow; pass the user's image description as prompt to get tex
get_historyGet ComfyUI execution history (GET /history) without prompt_id. Returns last N prompts with prompt_id, status, outputs (filenames), elapsed. Use when execute_workflow_sync did not return prompt_id (e.g. WebSocket timeout) to find the latest run and its outputs. Requires COMFYUI_HOST.
get_last_outputGet info for the most recent prompt that has image output (skips failed prompts). Use when prompt_id was lost (e.g. execute_workflow_sync timed out). Returns prompt_id, filename, subfolder, view_url. Then use download_by_filename to save the file. Requires COMFYUI_HOST.
get_model_infoGet info for a model by name and type. Returns name, type, path; null if not found. Requires COMFYUI_HOST.
get_node_infoGet full node information for a ComfyUI node by its class name. Uses live ComfyUI when COMFYUI_HOST is set, otherwise knowledge base.
get_node_inputsGet detailed input definitions for a node (required and optional). Uses live ComfyUI if available, otherwise knowledge base.
get_node_outputsGet output types and names for a node. Uses live ComfyUI if available, otherwise knowledge base.
get_system_resourcesGet ComfyUI station resources (GPU/VRAM/RAM) and recommendations for model size, resolution, and batch size. Returns flux_ready (FLUX needs ~12GB+ VRAM) and platform_hints (e.g. Apple Silicon: M-Flux, ComfyUI-MLX). Call this first before building or executing workflows to avoid OOM. Requires COMFYUI_HOST.
get_workflow_jsonGet the current workflow JSON for a dynamic workflow (for execute_workflow or save_workflow).
get_workflow_modelsExtract required models from a workflow (loader nodes: CheckpointLoaderSimple, LoraLoader, VAELoader, ControlNetLoader, UpscaleModelLoader, etc.). Returns list of { name, type, nodeId, nodeClass, inputName }. No ComfyUI connection needed.
insert_macrowrite actionInsert a macro (sub-workflow) into a dynamic workflow. Connects macro input ports to existing nodes. Returns nodeIdMap and outputPorts so you can connect macro outputs. Use workflow_id from create_workflow.
install_custom_nodeInstall one or more custom nodes via ComfyUI-Manager cm-cli (e.g. ComfyUI-Blip, WAS-Node-Suite). Requires COMFYUI_PATH and ComfyUI-Manager installed in custom_nodes. ComfyUI-Manager cm-cli requires Python package "rich" (pip install rich in your ComfyUI Python environment). Restart ComfyUI after install to load new nodes.
install_modelDownload and install a model (checkpoint, LoRA, VAE, etc.) by URL. Requires COMFYUI_PATH. Uses comfy-cli if available (pip install comfy-cli), otherwise fetches the file directly. model_type: checkpoint, lora, vae, controlnet, clip, embeddings, hypernetwork, upscale_models, clip_vision, unet, diffusers.
interrupt_executionStop the currently running workflow on ComfyUI. Optionally pass prompt_id to interrupt only that prompt. If cleanup_after_ms is set (and prompt_id given), after interrupt the tool will poll the queue and remove the prompt from queue if it is still there (frees GPU for next job). Requires COMFYUI_HOST.
list_macrosList available workflow macros (built-in sub-workflows). Returns id, name, description, inputs, outputs.
list_modelsList models available on the ComfyUI server (from object_info). Optionally filter by type: checkpoint, lora, vae, controlnet, upscale, embedding, clip. Requires COMFYUI_HOST.
list_node_categoriesList all node categories from live ComfyUI and knowledge base (merged, unique).
list_node_typesList ComfyUI node types from the knowledge base. Optionally filter by category or priority.
list_outputsList all output files (images, gifs) for a completed prompt. Returns prompt_id, node_id, type, filename, url. Requires COMFYUI_HOST.
list_pluginsList loaded plugins (from plugins/*/plugin.json) and counts of macros/templates contributed by each.
list_queueList current ComfyUI queue (running and pending prompts). Requires COMFYUI_HOST.
list_saved_workflowsList saved workflows (names and paths) from workflows/ directory.
list_templatesList available workflow template ids (e.g. txt2img). No ComfyUI connection needed.
load_workflowLoad a saved workflow by name (from workflows/<name>.json) or by path. Returns workflow JSON for use with execute_workflow or save_workflow.
prepare_image_for_workflowFetch the first output image from a completed prompt and upload it to ComfyUI input folder. Returns the filename to use in LoadImage for a follow-up workflow (e.g. image caption / verification). Use after get_execution_status confirms the prompt finished with image output. Requires COMFYUI_HOST.
reload_comfyuiRestart ComfyUI so that newly installed custom nodes are loaded, then optionally sync them to the knowledge base. Requires COMFYUI_PATH (ComfyUI installation directory) and uses COMFYUI_HOST for the port. Kills the process on the ComfyUI port and starts main.py from COMFYUI_PATH. After restart, call sync_nodes_to_knowledge to pick up custom nodes (or set sync_after_restart to true).
reload_pluginsReload plugins from plugins/*/plugin.json and refresh macro registry.
remove_nodewrite actionRemove a node from a dynamic workflow. Does not fix references (validation will report dangling refs).
save_workflowSave a workflow JSON to file (workflows/<name>.json). Returns path. Use after build_workflow to persist for later load_workflow or execute_workflow.
search_nodesSearch nodes by query string and optional filters (category, input_type, output_type). Searches both live ComfyUI and knowledge base; live overrides KB for same class.
set_node_inputSet a literal input on a node in a dynamic workflow (overwrites existing value or link).
suggest_nodesSuggest ComfyUI nodes for a task (search by description/use_cases) or by output type they produce.
suggest_template_for_checkpointSuggest workflow template (txt2img_flux or txt2img) from checkpoint filename. FLUX checkpoints (e.g. flux1-dev-fp8.safetensors) use txt2img_flux; SD XL / SD 1.5 use txt2img. Call before build_workflow when the user did not specify a template.
sync_nodes_to_knowledgeSync node definitions from running ComfyUI to the knowledge base. Adds only nodes that are not already in base-nodes.json. Creates knowledge/ if missing (or set COMFYUI_KNOWLEDGE_DIR to point to the knowledge directory). Requires ComfyUI to be running.
validate_template_paramsValidate that parameter values satisfy a workflow template (required params, types).
validate_workflowValidate a dynamic workflow: checks that all node references exist and output indices are valid.
Public scan report
scanner v0.1.10 · 2026-09-28 · same rubric, same numbers if you re-run it
- Code scan52 source files scanned13/25
- –Live reliabilityno gateway calls yet and no remote to proben/a
- –Tool poisoningtools not inspected (local package is not executed); not countedn/a
- Auth qualitylocal package, no credentials required12/15
- Maintenancelast push 5 days ago15/15
- Maintainer identityregistry namespace matches repository owner; GitHub account older than a year8/10
Findings (1)
- highShell command built from a string (injection risk)
exec.shell-concatdist/manager-cli.js: … === 'win32') { const out = execSync(`netstat -ano | findstr :${port}`, { encoding: 'utf8', stdio: ['pip…
How ComfyUI Builder compares
Against every graded MCP server, from our own scans and uptime checks. Updated after each scan run.
- Safety score
- 74/100
- higher than 40% of 48,255 servers
- Tools
- 60
- the typical server has 7
- Tools that change things
- 17%
- typical: 0%. Fewer write tools means less an agent can break
- GitHub stars
- 3
- more than 80% of 28,688 servers
- Downloads a week
- 102
- more than 63% of 12,191 servers with a package
What its tools let an agent do: 43 read · 5 create · 2 change · 2 delete · 8 run or deploy
Install ComfyUI Builder in Claude Code, Cursor or VS Code
Runs npx -y mcp-comfy-ui-builder on your machine. Read the scan report first; the gateway never runs local packages.
claude mcp add comfy-ui-builder -- npx -y mcp-comfy-ui-builder
What the publisher says
From the ComfyUI Builder repository's README, as published. We do not edit it. Read it on GitHub
mcp-comfy-ui-builder
Control ComfyUI from Claude or Cursor — 50+ MCP tools for node discovery, dynamic workflow building, real-time WebSocket execution, and model management. No JSON editing required.
Tell your AI assistant what image to generate — it builds and runs the ComfyUI workflow for you. Works with Claude Desktop, Cursor, and any MCP-compatible client.
Publishable to the MCP Registry via server.json and mcpName.
What is this
- Knowledge base: Seed knowledge/base-nodes.json and node-compatibility.json from bundled data (62 seed nodes; 100–600+ after sync). No external services required for suggest/build.
- Sync: Custom packs from ComfyUI-Manager; nodes from running ComfyUI via sync-nodes CLI or on MCP startup.
- MCP server (50+ tools): Node discovery, dynamic workflow builder, 9 templates (txt2img, txt2img_flux, img2img, …), WebSocket real-time execution, batch/chain, model management, plugin system.
- Real-time execution: Sub-second progress via WebSocket with automatic polling fallback; ~90% less network traffic for batch runs.
Install
npm install mcp-comfy-ui-builderOr from source: git clone https://github.com/MIt9/mcp-comfy-ui-builder.git && cd mcp-comfy-ui-builder && npm install
Quick start
- Build (postbuild fills knowledge from seed)
npm run build
npm run mcp- Use knowledge in code
import baseNodes from './knowledge/base-nodes.json' assert { type: 'json' };Commands
Documentation
Single entry point — task-oriented navigation:
- doc/README.md — where to start, task-based navigation
- doc/INDEX.md — complete list of documents and links
- doc/QUICK-REFERENCE.md — commands, examples, troubleshooting
- doc/GETTING-STARTED.md — quick start
- doc/MCP-SETUP.md — connect MCP in Cursor/Claude
- doc/DOCKER-SETUP.md — docker pull siniidrozd/mcp-comfy-ui-builder | docker-compose for MCP + ComfyUI
- Knowledge base: knowledge/README.md, doc/knowledge-base-usage-guide.md
- Workflow Builder: doc/workflow-builder.md — templates, params, save/load, ComfyUI format
- Planning: ROADMAP.md, NEXT-STEPS.md, TODO.md — current v2.3.x, next Phase 10 (QoL)
- Contributing: CONTRIBUTING.md
- MCP Registry: server.json and mcpName in package.json; see MCP Registry quickstart to publish after npm publish.
Requirements
- Node.js 18+
MCP Server (Cursor / Claude)
Server provides 50+ tools across 9 categories:
Core Features
Shortened. The full README is on GitHub.
Nothing above is checked by us. What we check is on the safety report.
ComfyUI Builder: common questions
- Is ComfyUI Builder MCP server safe?
- Mostly: it is graded B (74/100). Read the ComfyUI Builder safety report
- How do I install ComfyUI Builder?
- It runs on your machine. Copy the Claude Code, Cursor, VS Code or Claude Desktop config from the install section.
- Does ComfyUI Builder need an API key?
- No secret keys are declared. It reads 3 settings from the environment.
- Is ComfyUI Builder maintained?
- The last commit was 42 days ago (2026-09-23). The latest release is v2.4.1.
- What can I use instead of ComfyUI Builder?
- Servers from other publishers that do the same job: Comfyui MCP server.
- How does ComfyUI Builder compare with other MCP servers?
- safety score 74/100 (higher than 40% of 48,255 servers); tools 60 (the typical server has 7); tools that change things 17% (typical: 0%. Fewer write tools means less an agent can break). Full comparison.
Alternatives to ComfyUI Builder
Same job from other publishers: the closest match first, then the best rated.
- ComfyuiMCP server + Claude Code plugin for ComfyUI: run workflows, generate images, manage models & VRAM.not reviewedEstablishedB