ArchSmith — Claude Code MCP server for architecture diagrams
ArchSmith lets an agent validate architecture data in JSON and render it as an SVG diagram. Use it when a coding agent needs to create or check an architecture view.
claude mcp add archsmith -- npx -y @archsmith/mcp-serverWhat ArchSmith does
The server gives an agent tools to retrieve the JSON Schema and registries, validate a diagram description, and render an SVG. Validation runs before rendering. It communicates over stdio and calls the renderer functions directly rather than wrapping the CLI.
Font embedding is off by default. With embedFonts enabled, an SVG may exceed 25,000 bytes; the server then returns a resource link, which the host can read with resources/read. Render links live in memory, and older entries can be evicted after 20 newer renders. That matters if an agent needs to fetch a result later.
To connect it to Claude Code, run claude mcp add archsmith -- npx -y @archsmith/mcp-server. The server also supports Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline, Zed, and Gemini CLI.
What it helps with
- validate an architecture diagram described in JSON
- render an architecture description as SVG
- retrieve the current JSON IR schema for an agent
- look up available governed registries
Example prompts for the agent
- Check this JSON architecture description and report validation errors.
- Render an SVG diagram from this architecture description.
- Get the current JSON IR schema and draft an architecture description that follows it.
How to install ArchSmith
Platform CLI
claude mcp add archsmith -- npx -y @archsmith/mcp-serverPlatform CLI
codex mcp add mcp-server -- npx -y @archsmith/mcp-serverConfig file
{
"mcpServers": {
"mcp-server": {
"command": "npx",
"args": [
"-y",
"@archsmith/mcp-server"
]
}
}
}Config file
{
"servers": {
"mcp-server": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@archsmith/mcp-server"
]
}
}
}Platform CLI
gemini mcp add mcp-server npx -y @archsmith/mcp-serverStep by step, with commands for each platform: How to add an MCP server to Claude Code, Codex, Cursor, VS Code, Gemini CLI and more
Questions about ArchSmith
How do I install ArchSmith in Claude Code?
Run claude mcp add archsmith -- npx -y @archsmith/mcp-server. The server connects over stdio.
What does ArchSmith do?
It gives an agent tools to validate JSON architecture descriptions, render SVG diagrams, and retrieve the schema and registries.
What happens when an SVG exceeds 25,000 bytes?
The server returns a resource link instead of embedding the SVG in the tool response. The host can fetch it with resources/read; the in-memory store keeps the latest 20 renders.