dgmo-mcp
Official@diagrammo/dgmo-mcp
用于渲染 DGMO 图表的 MCP 服务器。适用于 Claude Desktop、Claude Code 以及任何兼容 MCP 的 AI 工具。
工具
工具 | 描述 |
| 将 DGMO 标记渲染为 SVG 或 PNG |
| 生成可分享的 diagrammo.app URL |
| 在 Diagrammo 桌面应用中打开图表(如果未安装,则回退到浏览器) |
| 列出所有支持的图表类型 |
| 获取 DGMO 语法文档 |
| 渲染一个或多个图表并在浏览器中打开 HTML 预览 |
| 生成包含多个图表、目录和可选源代码的精美 HTML 报告 |
preview_diagram
将一个或多个 DGMO 图表渲染为 SVG,并在默认浏览器中打开一个独立的 HTML 页面。该页面包含亮色/暗色主题切换和响应式 SVG 布局。
参数 | 类型 | 默认值 | 描述 | |
|
| (必填) | 要预览的一个或多个图表 | |
| `'light' | 'dark'` |
| 渲染 SVG 的颜色主题 |
|
|
| 调色板 | |
|
|
| 在可折叠块中显示 DGMO 源代码 |
单个图表将渲染为简单的预览页面。多个图表将生成报告样式的布局,并带有目录(当超过 3 个部分时)。如果某些图表渲染失败,成功的图表将显示,失败的图表将显示错误占位符。
generate_report
生成精美的多部分 HTML 报告,并可选择在浏览器中打开。包含标题、可选副标题、自动生成的目录、各部分描述以及时间戳页脚。适用于将项目分析打包成可分享的文档。
参数 | 类型 | 默认值 | 描述 | |
|
| (必填) | 报告标题 | |
|
| — | 可选副标题 | |
|
| (必填) | 报告部分,每一部分包含一个图表 | |
| `'light' | 'dark'` |
| 渲染 SVG 的颜色主题 |
|
|
| 调色板 | |
|
|
| 在可折叠块中显示 DGMO 源代码 | |
|
|
| 在浏览器中打开报告 |
Related MCP server: drawio
设置
Claude Code
添加到项目的 .claude/settings.local.json 中:
{
"mcpServers": {
"dgmo": {
"command": "npx",
"args": ["-y", "@diagrammo/dgmo-mcp"]
}
}
}Claude Desktop
添加到 ~/Library/Application Support/Claude/claude_desktop_config.json 中:
{
"mcpServers": {
"dgmo": {
"command": "npx",
"args": ["-y", "@diagrammo/dgmo-mcp"]
}
}
}保存后重启 Claude Desktop。工具将自动出现。
开发
pnpm install
pnpm build
pnpm typecheck若要针对 ../dgmo 中检出的未发布 @diagrammo/dgmo 进行迭代,请在安装后使用工作区符号链接覆盖 npm 解析的依赖项:
pnpm install
pnpm link ../dgmo # symlink node_modules/@diagrammo/dgmo → ../dgmo
pnpm --filter @diagrammo/dgmo build # ensure dist/ is up to datepnpm install 会撤销该链接,因此如果依赖项发生变化,请重新运行 pnpm link ../dgmo。
发布
发布通过 .github/workflows/release.yml 进行标签驱动:
提升所有三个文件中的版本号(必须完全匹配 — 工作流会进行验证):
package.json→versionmanifest.json→versionserver.json→version以及packages[0].version
提交并打标签:
git commit -am "Release vX.Y.Z" git tag vX.Y.Z git push && git push --tags工作流将运行类型检查 + 构建,发布带有来源证明的 npm 包,打包
.mcpb,通过 GitHub OIDC 发布到 MCP 注册表,并将.mcpb附加到 GitHub 发布版本中。
所需密钥
NPM_TOKEN— 作用域为@diagrammo/*写入权限的 npm 精细访问令牌。设置 → Secrets and variables → Actions → New repository secret。
MCP 注册表身份验证会自动使用 GitHub OIDC(无需令牌),因为仓库位于 diagrammo 组织下,且服务器命名空间为 io.github.diagrammo/*。
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceMCP server that generates Mermaid diagrams with live browser preview, supports real-time rendering and SVG/PNG export.12
- AlicenseAqualityAmaintenanceMCP server for creating and editing diagrams using draw.io. Allows generating diagrams from Mermaid or XML, searching shapes, and opening them in draw.io for export.20Apache 2.0
- AlicenseAqualityDmaintenanceMCP server for generating diagrams, charts, and visualizations using Gemini image generation on Vertex AI. Supports auto-detection of diagram types, multiple style modes, and iterative refinement.3161MIT
- AlicenseNot gradedqualityBmaintenanceMCP server that enables AI assistants to create, parse, render, and validate Draw.io diagrams programmatically.1MIT
Related MCP Connectors
Diagrams, badges, charts and QR codes as plain image URLs you can paste into Markdown.
Generate cloud architecture diagrams, flowcharts, and sequence diagrams.
Official Miro MCP server - Supports context to code and creating diagrams, docs, and data tables.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/diagrammo/dgmo-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server