tl-draw-mcp
tl-draw-mcp
Claudeがプロンプトからライブのtldrawキャンバスに描画できるようにするMCPサーバー + Claude Codeスキルです。
ブラウザで
http://localhost:3030を開くと、Claudeの描画がリアルタイムで表示されます。4つのツール:
create_shape、update_shape、delete_shape、get_canvas。純粋なJS、MITライセンス、Windows優先。
1. インストール
git clone <this repo> tl-draw-mcp
cd tl-draw-mcp
npm install
cd packages\web && npm run build
cd ..\server && npm run buildRelated MCP server: Excalidraw MCP Server
2. Claude Codeへの組み込み
ワンライナー(推奨 — JSONの編集は不要):
claude mcp add tldraw --scope user -- cmd /c node "D:/path/to/tl-draw-mcp/packages/server/dist/index.js"確認:
claude mcp listtldraw がリストに表示されるはずです。Claude Codeを再起動してください。
3. スキルのインストール
Claudeがいつ描画すべきかを認識できるように、スキルフォルダーをコピーします:
xcopy /E /I .claude\skills\tldraw %USERPROFILE%\.claude\skills\tldraw4. 使用方法
任意のプロジェクトでClaude Codeを起動します。
最初のツール呼び出しでサーバーが起動します —
http://localhost:3030を開いてください。右下のバッジに
tldraw MCP · connectedと表示されます。プロンプト:
ログインフローのフローチャートを描いて。
5. 開発
cd packages\server && npm test :: 12 handler tests
cd packages\server && npm run dev :: stdio + WS bridge on :3030
cd packages\web && npm run dev :: Vite HMR on :51736. レイアウト
packages/server MCP stdio server, WS bridge, static host, tool handlers
packages/web Vite + React + tldraw browser app (builds into server/public)
.claude/skills/ SKILL.md for Claude Code
examples/ sample MCP config (if you prefer JSON over the CLI)7. トラブルシューティング
症状 | 解決策 |
バッジは | :3030でサーバーがスタックしています。 |
ブラウザでTldrawの検証エラーが発生する | IndexedDBをクリア(F12 → Application → IndexedDB → |
ポート :3030 が使用中 | サーバーは自動的に :3031 などにフォールバックします。 |
|
|
設計メモについては plan.md を、MITライセンス条項については LICENSE を参照してください。
This server cannot be deployed
Maintenance
Related MCP Connectors
Whiteboard where any shape opens into another canvas. Claude Code and Codex plugins render plans on it.
Give Claude a whiteboard: notes, links, images and diagrams on a board you both see and edit.
Create and edit architecture diagrams from your AI agent; get an SVG and a live editable canvas.
Create, edit, share and export hand-drawn LetDraw diagrams, from code or a prompt.
Related MCP Servers
- AlicenseNot gradedqualityCmaintenanceEnables AI agents to read, write, and search local tldraw (.tldr) files, providing a persistent visual scratchpad for diagramming and note organization. It supports full CRUD operations on canvas shapes and metadata management for local canvas files.23 npm3MIT
- AlicenseAqualityCmaintenanceEnables AI agents to programmatically generate, edit, and view Excalidraw diagrams with real-time browser synchronization. It provides a suite of tools for adding shapes, text, and arrows to diagrams through natural language interactions.114,221 npm101MIT
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to programmatically control a live Excalidraw canvas through element-level CRUD operations and real-time synchronization. It allows agents to iteratively build, inspect, and refine diagrams while providing visual feedback via screenshots and scene descriptions.4,412 npmMIT
- AlicenseNot gradedqualityDmaintenanceEnables AI agents to programmatically control a live Excalidraw canvas with element-level CRUD operations and real-time synchronization. It supports iterative diagramming through scene descriptions, screenshots, and advanced layout tools for collaborative AI-human workflows.4,412 npm2MIT