loading…
Search for a command to run...
loading…
Enables creating, manipulating, and managing Mermaid diagrams with automatic saving and multi-format conversion from JSON, CSV, Python, Markdown, and plain text
Enables creating, manipulating, and managing Mermaid diagrams with automatic saving and multi-format conversion from JSON, CSV, Python, Markdown, and plain text.
A powerful Model Context Protocol (MCP) server for creating, manipulating, and managing Mermaid diagrams with automatic saving and integrated multi-format support. Built with enterprise-grade persistence and designed for seamless AI workflow integration.
/diagrams directoryNote: If there is a syntax error converting a diagram remove any () in the underlined code error.



Add to your Claude Desktop MCP configuration:
{
"mcpServers": {
"diagram-server": {
"command": "uv",
"args": [
"--directory",
"/your-path-to/mcp-diagram-server",
"run",
"main.py"
],
"env": {
"LOG_LEVEL": "INFO"
}
}
}
}
cd /mcp-diagram-server
uv venv --python 3.12 --seed
source .venv/bin/activate
uv add -e .
uv add playwright
uv run playwright install chromium
create_diagram - Create new diagrams with optional templatesupdate_diagram - Modify existing diagram content (auto-saves)get_diagram - Retrieve diagrams from memory or disklist_diagrams - Browse your diagram librarydelete_diagram - Remove diagrams from memoryconvert_format_to_diagram - Universal format converter with auto-detectionjson_to_flowchart - Convert JSON structures to flowchartscsv_to_org_chart - Convert CSV data to organizational/relationship chartspython_to_class_diagram - Convert Python code to class diagramsmarkdown_to_mindmap - Convert structured markdown to mind mapsdetect_file_format - Smart format detection with conversion recommendationssave_diagram - Manual save to custom locationslist_templates - Browse available diagram templatesconvert_format_to_diagram(
content='{"api": {"users": ["get", "post"], "orders": ["get", "create"]}}',
target_type="flowchart",
name="APIStructure"
)
Result: Auto-saved flowchart showing API structure hierarchy
json_to_flowchart(
json_content='{"system": {"frontend": "React", "backend": "FastAPI", "db": "PostgreSQL"}}',
name="SystemArchitecture"
)
Result: Visual flowchart of system components and relationships
csv_to_org_chart(
csv_content="Name,Role,Department\nAlice,Director,Engineering\nBob,Engineer,Engineering",
name="TeamStructure"
)
Result: Organizational chart showing team hierarchy
python_to_class_diagram(
python_code='''
class DatabaseManager:
def __init__(self):
self.connection = None
def connect(self):
pass
def query(self, sql):
pass
''',
name="DatabaseDesign"
)
Result: UML class diagram from Python code structure
detect_file_format(
content='class User:\n def __init__(self):\n pass',
filename="models.py"
)
Result: Format identification with conversion recommendations
create_diagram(diagram_type="sequence", use_template=True, name="UserFlow")
Result: Auto-saved sequence diagram template ready for customization
/diagrams directory with metadata.mmd file + _metadata.jsonsave_diagram).mmd file + _metadata.jsonBoth systems work together - Auto-save maintains your library while manual save provides flexibility.
diagrams/
├── SystemArchitecture_converted_20250824_120000.mmd
├── SystemArchitecture_converted_20250824_120000_metadata.json
├── TeamStructure_converted_20250824_130000.mmd
├── TeamStructure_converted_20250824_130000_metadata.json
├── UserFlow_diagram_20250824_140000.mmd
└── UserFlow_diagram_20250824_140000_metadata.json
The integrated conversion system handles multiple input formats:
Perfect for:
MIT License - See LICENSE file for details
Contributions welcome! The codebase follows modern Python patterns with comprehensive error handling and robust process management.
For issues or questions, please open an issue on GitHub.
System Requirements: Python 3.10+ | Compatible with Claude Desktop and MCP-enabled clients
🚀 Ready to convert any format to diagrams? Start creating visual representations from JSON, CSV, Python code, and more with automatic saving!
Выполни в терминале:
claude mcp add mcp-diagram-server -- npx Безопасность
Низкий рискАвтоматическая эвристика по публичным данным — не гарантия безопасности.