Describe a diagram. Your AI draws it.

Add dgmo to Claude Code, Codex, Cursor or Claude Desktop with one command, or run your Claude Code or Codex inside the Diagrammo app.

Two ways in

The same diagrams either way. Pick where you already work.

The Diagrammo app with Claude Code in a pane under the code, adding a cache box to the open diagram

In the Diagrammo app

Your own Claude Code or Codex runs beside the open diagram and edits it while you watch. Nothing else to install if you already have one of them.

Get the desktop app →
> /dgmo how does checkout work?
● suggest_chart_type → sequence
● validate_diagram · 0 errors
✓ wrote docs/checkout.dgmo

In your AI tool

Add dgmo to Claude Code, Codex, Cursor or Claude Desktop with one command. It draws diagrams wherever you already ask it things.

Set it up below ↓

Set up dgmo in your AI tool

Works on macOS and Linux, with Claude Code, Codex, Cursor and Claude Desktop.

1.Run one command

bash
npm install -g @diagrammo/dgmo-cli && dgmo install

It sets up every AI tool it finds. Restart the tool afterwards. Prefer Homebrew or pacman? See /dev.

Just one tool? Add its name to the end:

dgmo install claude-code the /dgmo skill and the MCP server
dgmo install codex the Diagrammo plugin — the dgmo-diagramming skill and the MCP server; refresh it with codex plugin marketplace upgrade diagrammo
dgmo install cursor the MCP server in ~/.cursor/mcp.json and a .cursorrules guide; add --scope project for one repo
dgmo install claude-desktop the MCP server in Claude Desktop’s config

2.Ask for a diagram

In Codex, Cursor or Claude Desktop, start with Use dgmo to … instead of /dgmo.

No install at all? Point your model at diagrammo.app/llms.txt. It can write DGMO from that, but it cannot draw, check or share it.

What you can ask for

  • Describe it

    Plain words in. It picks the right chart from 55 types and draws it.

    /dgmo what do our customers order?

  • Diagram your code

    Claude Code, Codex and Cursor read your project and draw how it works.

    /dgmo diagram this service

  • Change it by asking

    The diagram is text, so a follow-up edits it. No dragging boxes.

    /dgmo add a cache before the database

  • It checks its work

    Every diagram is validated, and errors are fixed before you see them.

    /dgmo fix the errors in this file

  • Share a link

    The diagram travels inside the link, so anyone can open it — nothing is uploaded, no account needed.

    /dgmo give me a link to this

  • Bundle a report

    Several diagrams on one HTML page with a table of contents.

    /dgmo report on our architecture

  • Report on a whole codebase

    For onboarding: it measures your repo — sizes, languages, history, imports — reads the code, and writes 10 to 15 diagrams with a few sentences each, built into one report.html. Publishing it is a question it asks at the end, never a default.

    In Claude Code, add the Diagrammo plugin, then ask: make a codebase report of this repo

    /plugin marketplace add diagrammo/skills
    /plugin install diagrammo@diagrammo

Reference — the MCP server

MCP tools

On its own, an AI model can only write diagram text and hope it is right. The @diagrammo/dgmo-mcp MCP (Model Context Protocol) server gives it tools to pick the right chart, learn the syntax, check its work, draw the picture and hand it to you.

Boxes and lines diagram of 8 boxes, You, AI agent, /dgmo skill, dgmo MCP server, SVG or PNG and 3 more, with 7 lines.Where the MCP server fitsYouAI agentClaude Code · Codex· Cursor · ClaudeDesktop/dgmo skillteaches the agentDGMO and when tocall the toolsdgmo MCP serverpicks the chart ·checks it · drawsitSVG or PNGShare linkDesktop appHTML reportasksfollowscallsdrawssharesopensbundlesRoleYouAIdgmoResult
boxes-and-lines Where the MCP server fits

tag Role as r
  You blue
  AI purple
  dgmo teal
  Result green

You r: You
AI agent r: AI, description: Claude Code · Codex · Cursor · Claude Desktop
/dgmo skill r: dgmo, description: teaches the agent DGMO and when to call the tools
dgmo MCP server r: dgmo, description: picks the chart · checks it · draws it
SVG or PNG r: Result
Share link r: Result
Desktop app r: Result
HTML report r: Result

You -asks-> AI agent
AI agent -follows-> /dgmo skill
AI agent -calls-> dgmo MCP server
dgmo MCP server -draws-> SVG or PNG
dgmo MCP server -shares-> Share link
dgmo MCP server -opens-> Desktop app
dgmo MCP server -bundles-> HTML report

Your AI calls these for you — you never type their names. Here is the order it uses them in:

  1. 1

    Pick the chart

    A request like “show who reports to whom” could be several charts. This step settles which one fits, or asks you when it is unclear.

    • suggest_chart_type ranks the chart types against your request
    • list_chart_types lists every chart type dgmo can draw
  2. 2

    Learn the syntax

    Models half-remember syntax. These hand over the exact rules and real examples for the one chart being written.

    • get_language_reference the syntax for one chart type, or all of them
    • get_examples real diagrams from the gallery to copy from
  3. 3

    Check its work

    Mistakes are caught and fixed before you ever see them, instead of you finding a broken diagram.

    • validate_diagram checks the diagram and reports each error by line
  4. 4

    Draw it

    Turns the text into a picture you can look at, paste into a doc or commit next to your code.

    • render_diagram draws it as SVG or PNG
    • preview_diagram opens a preview in your browser, light and dark your machine
  5. 5

    Hand it to you

    The diagram leaves the chat in whatever form you need next: a link, an editor or a report.

    • share_diagram a diagrammo.app link anyone can open
    • open_in_app opens it in the Diagrammo desktop app (macOS) your machine
    • check_app_installed sees whether the desktop app is there first your machine
    • generate_report several diagrams on one HTML page with a table of contents your machine

your machine These open a browser window or the desktop app, so they only make sense on your own computer. When the server runs somewhere else they are left out — see MCP server over HTTP.

MCP server over HTTP

The setups above start the MCP server on your own machine, next to your AI tool. When the agent runs somewhere else, start the server as a web endpoint instead and point the agent at its URL. The same endpoint also works on one machine, when you want a single server always running for every AI tool you use.

When you need it

  • Hosted agent platformsDify and similar, which only take a URL
  • A containerthe server in Docker, the agent outside it
  • One server for a teameach request stands alone, so many agents can share it
  • Always on, one machineone background server that every AI tool on the machine points at

Set it up

  1. 1

    Start the server with --http

    bash
    dgmo mcp --http                    # with the dgmo command installed
    npx -y @diagrammo/dgmo-mcp --http  # without it

    It listens on http://127.0.0.1:3333/mcp. Every option below also works as an environment variable.

  2. 2

    Point your agent at the URL

    Add it as a streamable-HTTP MCP server in the platform's settings.

  3. 3

    Put your own sign-in in front of it

    The server has no authentication of its own. It only listens on this machine and refuses hostnames it was not told about — fine inside one machine or container. Before anything on a wider network can reach it, add your own authentication in front, and pass --allow-host the hostname it will be reached by.

Keep it running

Run the server as a background service so it starts when you log in and restarts if it stops. Change the dgmo path to what which dgmo prints.

Linux — systemd user service

ini
# ~/.config/systemd/user/dgmo-mcp.service
[Unit]
Description=Diagrammo MCP server over HTTP
After=network.target

[Service]
ExecStart=%h/.local/bin/dgmo mcp --http
Environment=PATH=%h/.local/bin:/usr/local/bin:/usr/bin:/bin
Restart=on-failure
RestartSec=3

[Install]
WantedBy=default.target
bash
systemctl --user daemon-reload
systemctl --user enable --now dgmo-mcp

macOS — launchd agent, saved as ~/Library/LaunchAgents/app.diagrammo.mcp.plist

xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
  <key>Label</key><string>app.diagrammo.mcp</string>
  <key>ProgramArguments</key>
  <array>
    <string>/opt/homebrew/bin/dgmo</string><string>mcp</string><string>--http</string>
  </array>
  <key>EnvironmentVariables</key>
  <dict><key>PATH</key><string>/opt/homebrew/bin:/usr/local/bin:/usr/bin:/bin</string></dict>
  <key>RunAtLoad</key><true/>
  <key>KeepAlive</key><true/>
</dict>
</plist>
bash
launchctl bootstrap gui/$(id -u) ~/Library/LaunchAgents/app.diagrammo.mcp.plist

Options

  • --http MCP_TRANSPORT=http serve over HTTP instead of stdio default off
  • --port <n> MCP_PORT port to listen on default 3333
  • --host <addr> MCP_HOST network interface to bind default 127.0.0.1
  • --path <path> MCP_PATH path the endpoint answers on default /mcp
  • --allow-host <h> MCP_ALLOWED_HOSTS extra Host headers to accept, repeatable default loopback
  • --allow-origin <o> MCP_ALLOWED_ORIGINS Origin headers to accept, repeatable default unset

your machine Tools with this badge are left out over HTTP — they would open a browser or the desktop app on the server, not on yours. Run npx -y @diagrammo/dgmo-mcp --help to see the options for the version you have.