PlantUML-MCP-Server
MCP server that provides PlantUML diagram generation capabilities
PlantUML MCP Server
A Model Context Protocol (MCP) server that provides PlantUML diagram generation capabilities for Claude Desktop and Claude Code.
Available Tools
generate_plantuml_diagram- Generate diagrams and get embeddable URLs (SVG/PNG)encode_plantuml- Encode PlantUML code for URL sharingdecode_plantuml- Decode PlantUML from encoded strings
Available Prompts
plantuml_error_handling- Guidelines for handling PlantUML syntax errors and implementing auto-fix workflows
This prompt provides Claude instances with comprehensive instructions on how to:
- Detect PlantUML syntax errors using native server validation
 - Implement intelligent auto-fix workflows for common syntax issues
 - Parse structured error responses and apply appropriate corrections
 - Handle validation failures gracefully with retry logic
 
The prompt enables Claude to automatically detect and fix common PlantUML errors like missing tags, invalid arrow syntax, typos in keywords, and missing quotes, making PlantUML diagram generation more reliable and user-friendly.
Quick Setup
For Claude Code
# Using default PlantUML server
claude mcp add plantuml --scope user --env PLANTUML_SERVER_URL=https://www.plantuml.com/plantuml -- npx plantuml-mcp-server
For Claude Desktop
Add this to your Claude Desktop MCP configuration (~/Library/Application Support/Claude/claude_desktop_config.json on macOS):
{
  "mcpServers": {
    "plantuml": {
      "command": "npx",
      "args": ["plantuml-mcp-server"],
      "env": {
        "PLANTUML_SERVER_URL": "https://www.plantuml.com/plantuml"
      }
    }
  }
}
To use your own PlantUML server, change the PLANTUML_SERVER_URL environment variable.
Then restart Claude Desktop/Code to activate the MCP server.
What You Can Do
After setup, you can ask Claude to:
- Generate PlantUML diagrams and get embeddable SVG/PNG URLs
 - Create sequence diagrams, class diagrams, architecture diagrams
 - Use advanced PlantUML features like 
!includedirectives and external libraries - Encode/decode PlantUML for URL sharing
 
Examples
C4 diagram for plantuml-mcp-server
> add c4 diagram for this project in readme 'C4 diagram for plantuml-mcp-server' section
Sequence diagram for plantuml-mcp-server
> add sequence diagram in readme in architecture section
OAuth2 Authorization Code Flow Diagram
> show me basic oauth2 flow png, open it in browser
Development Setup
Prerequisites
- Node.js 18+
 - npm
 
Local Installation
# Clone and setup
git clone https://github.com/mzagar/plantuml-mcp-server.git
cd plantuml-mcp-server
make setup
Development Commands
# Building & Running
make build        # Clean build TypeScript to JavaScript
make dev          # Development mode with watch
make run          # Build and run the server locally
# Testing
make test         # Basic server functionality test
make test-mcp     # Comprehensive testing with mcptools CLI
make test-ci      # Fast CI tests (no external dependencies)
# Setup & Installation  
make install      # Install npm dependencies
make setup        # Full setup (install + build + Claude Code config)
make setup-claude # Show Claude Code MCP configuration instructions
# Release Management
make release-patch  # Create patch release (0.1.0 → 0.1.1)
make release-minor  # Create minor release (0.1.0 → 0.2.0) 
make release-major  # Create major release (0.1.0 → 2.0.0)
# Utilities
make clean        # Clean build directory
make help         # Show all available commands
Environment Variables
# Optional: Use custom PlantUML server
export PLANTUML_SERVER_URL=https://your-server.com/plantuml
# Then run any command
make test-mcp
License
MIT License - see LICENSE file for details.
Related Servers
Azure MCP Server
All Azure MCP tools in a single server. The Azure MCP Server implements the MCP specification to create a seamless connection between AI agents and Azure services. Azure MCP Server can be used alone or with the GitHub Copilot for Azure extension in VS Code.
AWS CodePipeline MCP Server
Integrates with AWS CodePipeline to manage continuous integration and delivery pipelines.
Headless Terminal (ht) MCP
A high-performance MCP server for the headless terminal (ht), implemented in Rust.
Local Context MCP
A collection of reference implementations for the Model Context Protocol (MCP), giving LLMs secure access to tools and data.
MCP Jenkins Intelligence
AI-powered Jenkins pipeline intelligence platform with natural language interface. Provides comprehensive pipeline analysis, failure prediction, optimization suggestions, and automated Jenkinsfile reconstruction using Model Context Protocol (MCP) integration.
Gentoro
Gentoro generates MCP Servers based on OpenAPI specifications.
LaTeX PDF MCP Server
Converts LaTeX source code into professionally formatted PDF documents.
Swift MCP Server - JavaScript Version
Answers Swift and SwiftUI questions based on the '100 Days of SwiftUI' course using a local SQLite database.
LLM API Benchmark MCP Server
Benchmark LLM APIs for throughput and Time To First Token (TTFT) under various concurrency levels.
Flame MCP Server
Provides live, up-to-date documentation for the Flame game engine.