mcp-comfyui-flux: Command for Claude Code

.claude/commands/mcp-setup.md

mcp-setup is a command for Claude Code from dhofheinz/mcp-comfyui-flux. It costs 19 tokens per session (1,979 once invoked), scanned A, original, MIT.

A command for installing, checking, repairing, and testing an MCP-ComfyUI-FLUX setup using Docker. ComfyUI is a visual system for running image-generation workflows, and Docker runs software in isolated containers.

In plain words
What is it for?
Use `verify`, `install`, `repair`, or `validate` to manage the setup, with options for dry runs, forced changes, project names, and detailed output.
Why use it?
It helps diagnose setup problems and keeps installation, hook settings, container names, and Claude Desktop integration consistent.

Command for Claude Code

Written for Claude Code: argument-hint in frontmatter.

This is dhofheinz/mcp-comfyui-flux's own configuration. It tells Claude Code how to work on mcp-comfyui-flux itself, so it is not a mod to install elsewhere. Copy it as a starting point and replace the rules that are about this project. Everything mcp-comfyui-flux configures →

Needs its repository: it runs a file that does not travel with it, so clone the repository first. The line is "cd /home/[user]/projects/tools/mcp-comfyui-flux && docker exec -i [container-name] node /app/src/index.js".

Reuse

Borrowing it

Nothing to install: this file belongs to dhofheinz/mcp-comfyui-flux. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.

Copy the file
curl -O https://raw.githubusercontent.com/dhofheinz/mcp-comfyui-flux/main/.claude/commands/mcp-setup.md
Clone the repo
git clone --depth 1 https://github.com/dhofheinz/mcp-comfyui-flux

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for mcp-setup

README.md
[![agentmods](https://agentmods.dev/badge/commands/dhofheinz/mcp-comfyui-flux/mcp-setup/github.svg)](https://agentmods.dev/commands/dhofheinz/mcp-comfyui-flux/mcp-setup)
Your own site
<a href="https://agentmods.dev/commands/dhofheinz/mcp-comfyui-flux/mcp-setup"><img src="https://agentmods.dev/badge/commands/dhofheinz/mcp-comfyui-flux/mcp-setup/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for mcp-setup

Your own site · 80×15
<a href="https://agentmods.dev/commands/dhofheinz/mcp-comfyui-flux/mcp-setup"><img src="https://agentmods.dev/badge/commands/dhofheinz/mcp-comfyui-flux/mcp-setup.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 19 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 1,979 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00019 $0.01979
Opus 5 $0.00010 $0.00989
Sonnet 5 $0.00004 $0.00396
Haiku 4.5 $0.00002 $0.00198

Measured 11d ago against content hash 663d46e86b03, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-11, from the pricing page.

Security

Grade A, and why

mcp-setup scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 11d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/commands/mcp-setup.md · 284 lines

How it starts

The opening of the file, as written. The whole thing — 284 lines — stays where its author put it; the contents beside it link to each section on GitHub.

MCP-ComfyUI Setup Command

Orchestrates the mcp-comfyui-setup-guardian agent to ensure proper installation, configuration, and maintenance of the MCP-ComfyUI-FLUX system with consistent container naming and Claude Desktop integration.

Command Argument Parsing

Parse the $ARGUMENTS variable to extract the action and options:

  1. Extract the action (first non-flag argument):

    • verify - Perform comprehensive verification of current setup without making changes
    • install - Complete installation from scratch with hook configuration
    • repair - Fix existing installation issues while preserving customizations
    • validate - Test end-to-end functionality of the system
    • If no action is provided, default to verify
  2. Parse optional flags (can appear in any order):

    • --project-name <name> - Extract the next token as the project name to use instead of directory name
    • --dry-run - Set flag to show proposed changes without applying them
    • --force - Set flag to skip user confirmations and backup creation
    • --verbose - Set flag to enable detailed debugging output
  3. Handle edge cases:

    • If $ARGUMENTS is empty, run verify action with default options
    • If unknown action is provided, show error and list valid actions
    • If --project-name is provided without a value, show error
    • Ignore extra whitespace and handle quoted project names properly

Execution Process

When the user invokes /mcp-setup, execute the following methodical process using the mcp-comfyui-setup-guardian agent:

Phase 1: Discovery & Assessment

  1. Environment Detection

    • Detect current working directory and derive project name
    • Check for existing .env file and COMPOSE_PROJECT_NAME
    • Identify OS platform (Windows/WSL2/Linux)
    • Locate Claude Desktop config path
  2. Container State Analysis

    • Run docker ps -a --filter "name=comfyui" --filter "name=mcp"
    • Extract actual container names and states
    • Compare against expected naming patterns
    • Document any discrepancies

Read the full file on GitHub · 284 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 11d ago First seen · 284 lines · 0 tokens per session scan A 663d46e86b03

Subscribe to this mod's changes

mcp-setup is a command published in the GitHub repository dhofheinz/mcp-comfyui-flux (4 stars, last pushed 1y ago), licensed MIT. It adds 19 tokens to every session and 1,979 once invoked, about $0.0001 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.