Supports running ComfyUI in Docker containers, with configuration examples for connecting to containerized ComfyUI instances.
Supports configuration through environment variables loaded from .env files for setting ComfyUI connection parameters.
Provides a Python-based API for interacting with ComfyUI, allowing for image generation, workflow execution, and queue management.
Mentioned as a planned feature for logo generation with vector-style outputs and future SVG conversion support.
ComfyUI MCP Server - Enhanced Edition
A Model Context Protocol (MCP) server that enables Claude to interact with ComfyUI for AI image generation using Stable Diffusion - now with full API control!
Overview
This enhanced MCP server provides a comprehensive bridge between Claude and ComfyUI, allowing you to:
- Generate images with full control over models, samplers, and schedulers
- Build custom workflows programmatically
- Execute and manage saved ComfyUI workflows
- Upload images for img2img workflows
- List and use LoRAs, embeddings, and custom nodes
- Manage the generation queue
- Retrieve generated images
Special Focus: Optimized workflows for Crisis Corps logo and branding generation!
New Features in v0.2.0
- Model Swapping: Change checkpoints on the fly
- Workflow Builder: Create workflows programmatically without the UI
- Advanced Sampling: Control samplers and schedulers
- LoRA Support: List and use LoRA models (coming soon)
- Node Discovery: Get all available node types from ComfyUI
- Image Upload: Upload images for img2img and ControlNet workflows
- Queue Management: Clear queue, check status, interrupt generations
- Workflow Saving: Save custom workflows for reuse
Features
- Platform Agnostic: Works with any ComfyUI installation (local, remote, containerized)
- Full API Access: Complete control over ComfyUI's capabilities
- Workflow Support: Load, execute, build, and save complex workflows
- Queue Management: Monitor and control generation progress
- Flexible Output: Return images as base64 or file paths
- Logo Optimized: Includes pre-built workflows for logo generation
Prerequisites
- ComfyUI installed and running (see Setup Guide)
- Python 3.10+
- MCP SDK
Installation
Quick Start
1. Start ComfyUI
2. Configure MCP
3. Add to Claude Desktop
Available Tools
generate_image
Generate an image with full control over all parameters.
build_workflow
Create a custom workflow programmatically.
save_workflow
Save a workflow for future use.
execute_workflow
Run a saved ComfyUI workflow with custom inputs.
list_models
Get all available model checkpoints.
list_samplers
Get available sampling methods.
list_schedulers
Get available noise schedulers.
get_node_types
Discover all available ComfyUI nodes.
upload_image
Upload an image for img2img workflows.
list_workflows
Get all available workflow files.
get_queue_status
Check the current generation queue.
get_history
Retrieve recent generation history.
get_image
Retrieve a generated image by ID.
interrupt_generation
Stop the current generation.
clear_queue
Clear all pending generations.
Logo Generation Examples
Generate Crisis Corps Logo with Different Models
Build Custom Logo Workflow
Pre-Built Workflows
The workflows/
directory contains optimized workflows for Crisis Corps branding:
- logo_generator.json - General purpose logo creation
- crisis_corps_logo.json - Specific Crisis Corps branding (4 variations)
- robot_emblem.json - Military-style badges and emblems (6 variations)
- text_logo_variations.json - Typography-focused designs
See workflows/README.md for detailed documentation.
Brand Guidelines
For consistent Crisis Corps branding, see examples/brand_guidelines.md which includes:
- Color codes (#FF6B35 orange, #004E98 blue)
- Typography guidelines
- Prompt engineering tips
- Style references
Architecture
Error Handling
The server includes comprehensive error handling:
- Connection errors to ComfyUI
- Invalid workflow specifications
- Generation failures
- Timeout handling
- Model/sampler validation
Security Notes
- Never expose ComfyUI directly to the internet
- Use API keys if implementing authentication
- Validate all inputs before passing to ComfyUI
- Consider rate limiting for production use
Contributing
Contributions are welcome! Please:
- Fork the repository
- Create a feature branch
- Make your changes
- Submit a pull request
TODO
- Add LoRA support implementation
- Implement ControlNet workflows for consistent shapes
- Add image-to-image generation for logo variations
- Support for SDXL specific features
- Batch processing optimizations
- Caching for frequently used workflows
- Auto-background removal for logos
- SVG conversion support
- Custom node support
- Workflow validation improvements
License
MIT License - see LICENSE file for details
Acknowledgments
- ComfyUI by comfyanonymous
- Model Context Protocol by Anthropic
- Crisis Corps branding examples included with permission
This server cannot be installed
hybrid server
The server is able to function both locally and remotely, depending on the configuration or use case.
A Model Context Protocol server that bridges Claude with ComfyUI, enabling AI image generation using Stable Diffusion through text prompts and custom workflows.
Related MCP Servers
- -securityAlicense-qualityA Model Context Protocol server that integrates Claude with Blender, enabling users to analyze and interact with IFC (Industry Foundation Classes) building models through natural language commands.Last updated -9PythonMIT License
Letz AI MCPofficial
AsecurityFlicenseAqualityA Model Context Protocol server that enables Claude to generate and upscale images through the Letz AI API, allowing users to create images directly within Claude conversations.Last updated -21JavaScript- -securityAlicense-qualityA Model Context Protocol server that enables Claude to interact directly with Contentful CMS, allowing the AI to fetch content types and entries from a Contentful space.Last updated -1TypeScriptMIT License
- -security-license-qualityA modular, extensible Model Context Protocol server framework designed for Claude Desktop that uses convention-based automatic module discovery to easily extend AI application functionality without modifying core code.Last updated -1Python