Skip to content

MCP Server

The OpenFlowKit MCP server gives AI clients diagramming skills without adding another AI provider. Claude Desktop, Cursor, Windsurf, and other MCP clients already have an LLM; OpenFlowKit supplies the local tools that make that model good at diagrams.

The package is @openflowkit/mcp-server. It runs locally over the standard MCP stdio transport.

Use it directly with npx:

Terminal window
npx -y @openflowkit/mcp-server

Or install it globally:

Terminal window
npm install -g @openflowkit/mcp-server
openflowkit-mcp

The server requires Node 18 or newer.

Add the server to your Claude Desktop config:

{
"mcpServers": {
"openflowkit": {
"command": "npx",
"args": ["-y", "@openflowkit/mcp-server"]
}
}
}

For Cursor, Windsurf, and other MCP clients, use the same command and args in that client’s MCP settings.

OpenFlowKit MCP is agent-native:

  1. The agent reads openflowkit://docs/dsl-cheatsheet.
  2. The agent writes OpenFlow DSL itself.
  3. The agent calls find_icon when it needs exact cloud or developer icon slugs.
  4. The agent calls validate_openflow_dsl.
  5. The agent fixes any diagnostics.
  6. The agent calls create_viewer_url.
  7. The agent returns editable DSL and a viewer link.

No API keys are required for MCP diagram generation.

The current server exposes 8 provider-free tools:

ToolWhat it does
validate_openflow_dslLint DSL with structured diagnostics
create_viewer_urlCreate a shareable OpenFlowKit viewer URL from DSL
analyze_codebaseDetect platforms, services, top-level structure, and language mix from a local repo
find_iconSearch 1,600+ provider and developer icons for exact archProvider and archResourceType values
list_starter_templatesBrowse built-in templates
get_starter_templateFetch a template’s DSL
list_diagram_node_typesReturn DSL node and edge reference data
server_infoReturn version and capability metadata

The server exposes five resources:

URIDescription
openflowkit://docs/dsl-cheatsheetOpenFlow DSL syntax reference
openflowkit://templatesStarter template catalog
openflowkit://templates/{name}DSL for a named starter template
openflowkit://iconsFull architecture icon catalog
openflowkit://icons/{provider}Icons for one provider pack (aws, azure, gcp, cncf, or developer)

Clients can also surface three prompt templates: flowchart_from_description, convert_mermaid_to_openflow, and architecture_from_codebase.

Paste this into a connected MCP client:

Using the openflowkit MCP server: read openflowkit://docs/dsl-cheatsheet, then write an OpenFlow DSL flowchart for a checkout flow (cart → shipping → promo-code decision → payment → Stripe webhook → confirm). Call validate_openflow_dsl on your output, fix any errors, then call create_viewer_url. Show me the final DSL and viewer URL.

For codebases:

Using openflowkit: call analyze_codebase on /path/to/project, read openflowkit://docs/dsl-cheatsheet, use find_icon for exact architecture icons, write OpenFlow DSL, validate it, then create a viewer URL.

The server does not store diagrams, require an OpenFlowKit account, ask for provider keys, or phone home. Local tools run on your machine. Codebase analysis only reads the directory you explicitly pass to analyze_codebase.