Skip to content

Deployment

For Claude Code, Claude Desktop, and Cursor — the MCP server communicates over stdio:

Terminal window
npx drawmode --stdio

Configure your client:

{
"mcpServers": {
"drawmode": {
"command": "npx",
"args": ["drawmode", "--stdio"]
}
}
}

Streamable HTTP server on port 3001:

Terminal window
npx drawmode

Useful for development and testing with HTTP-based MCP clients.

Deploy the worker/ directory to Cloudflare Workers for remote MCP access:

Deploy to Cloudflare

Terminal window
cd worker
npx wrangler deploy

The Worker requires these compatibility flags in wrangler.toml:

  • nodejs_compat — Node.js API compatibility
  • unsafe_eval — required for new Function() code execution

PNG and SVG export is built-in — no browser or external dependencies needed. Both local and Worker deployments use the same pipeline:

  1. linkedom (pure JS DOM shim) runs Excalidraw’s exportToSvg() server-side
  2. SVG: The SVG string is returned directly
  3. PNG: The SVG is passed to PlutoSVG WASM (svgToPng) which renders at 2x retina resolution

Fonts (Virgil, Assistant) are embedded in the WASM binary via @embedFile.

Terminal window
npm publish

Users install via npx drawmode.

Publish to registry.modelcontextprotocol.io for auto-indexing by PulseMCP and Smithery.