{"owner":"grab","repo":"cursor-talk-to-figma-mcp","hasSkills":true,"hasMcp":true,"mcpConfig":{"mcpServers":{"cursor-talk-to-figma-mcp":{"command":"npx","args":["-y","@modelcontextprotocol/server-cursor-talk-to-figma-mcp"]}}},"found":["AGENTS.md","CLAUDE.md"],"skills":{"AGENTS.md":"# AGENTS.md\n\nThis file provides guidance to Claude Code agents (claude.ai/code) when working with code in this repository.\n\n## Project Overview\n\nMCP (Model Context Protocol) server that bridges AI agents (Cursor, Claude Code) with Figma. Three components communicate in a pipeline:\n\n```\nClaude Code / Cursor ←(stdio)→ MCP Server ←(WebSocket)→ WebSocket Relay ←(WebSocket)→ Figma Plugin\n```\n\n## Build & Development Commands\n\n```bash\nbun install              # Install dependencies\nbun run build            # Build MCP server (tsup → dist/)\nbun run dev              # Build in watch mode\nbun socket               # Start WebSocket relay server (port 3055)\nbun run start            # Run built MCP server\nbun setup                # Full setup (install + write .cursor/mcp.json + .mcp.json)\n```\n\nThere is no test suite or linter configured.\n\n## Architecture\n\n### MCP Server (`src/talk_to_figma_mcp/server.ts`)\nThe main server implementing the MCP protocol via `@modelcontextprotocol/sdk`. Exposes 50+ tools (create shapes, modify text, manage layouts, export images, etc.) and several AI prompts (design strategies). Communicates with the AI agent over stdio and with the WebSocket relay via `ws`. Each request gets a UUID, is tracked in a `pendingRequests` Map with timeout/promise callbacks, and resolves when the plugin responds.\n\n### WebSocket Relay (`src/socket.ts`)\nLightweight Bun WebSocket server on port 3055 (configurable via `PORT` env). Routes messages between MCP server and Figma plugin using channel-based isolation. Clients call `join` to enter a channel; messages broadcast only within the same channel.\n\n### Figma Plugin (`src/cursor_mcp_plugin/`)\nRuns inside Figma. `code.js` is the plugin main thread handling 30+ commands via a dispatcher. `ui.html` is the plugin UI for WebSocket connection management. `manifest.json` declares permissions (dynamic-page access, localhost network). The plugin is **not built/bundled** — `code.js` is written directly as the runtime artifact.\n\n## Key Patterns\n\n- **Colors**: Figma uses RGBA 0-1 range. The MCP tools accept 0-1 floats and the filter converts to hex for display.\n- **Logging**: All logs go to stderr. Stdout is reserved for MCP protocol messages.\n- **Timeouts**: 30s default per command. Progress updates from the plugin reset the inactivity timer.\n- **Chunking**: Large operations (scanning 100+ nodes) are chunked with progress updates to prevent Figma UI freezing.\n- **Reconnection**: WebSocket auto-reconnects after 2 seconds on disconnect.\n- **Zod validation**: All tool parameters are validated with Zod schemas.\n\n## Setup\n\n1. Run `bun setup` — installs dependencies and writes MCP config for both Cursor (`.cursor/mcp.json`) and Claude Code (`.mcp.json`)\n2. `bun socket` in one terminal (WebSocket relay on port 3055)\n3. In Figma: Plugins → Development → Link existing plugin → select `src/cursor_mcp_plugin/manifest.json`\n4. Run plugin in Figma, join a channel, then use tools from Cursor or Claude Code\n\nThe MCP config written by `bun setup` uses the published package:\n\n```json\n{\n  \"mcpServers\": {\n    \"TalkToFigma\": {\n      \"command\": \"bunx\",\n      \"args\": [\"cursor-talk-to-figma-mcp@latest\"]\n    }\n  }\n}\n```\n\nYou can also add it manually for Claude Code via the CLI:\n\n```bash\nclaude mcp add TalkToFigma -- bunx cursor-talk-to-figma-mcp@latest\n```\n\n## Agent Notes\n\n- Always call `join_channel` before issuing any Figma commands\n- Call `get_document_info` first to understand the design structure\n- Use `read_my_design` or `get_selection` before making modifications\n- Batch operations (`set_multiple_text_contents`, `delete_multiple_nodes`, `set_multiple_annotations`) are preferred over repeated single-node calls for performance\n- All MCP tool parameters are Zod-validated; invalid inputs return structured errors\n- The plugin and relay must both be running before any tool calls succeed\n","CLAUDE.md":"# CLAUDE.md\n\nThis file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.\n\n## Project Overview\n\nMCP (Model Context Protocol) server that bridges Cursor AI IDE with Figma. Three components communicate in a pipeline:\n\n```\nCursor AI ←(stdio)→ MCP Server ←(WebSocket)→ WebSocket Relay ←(WebSocket)→ Figma Plugin\n```\n\n## Build & Development Commands\n\n```bash\nbun install              # Install dependencies\nbun run build            # Build MCP server (tsup → dist/)\nbun run dev              # Build in watch mode\nbun socket               # Start WebSocket relay server (port 3055)\nbun run start            # Run built MCP server\nbun setup                # Full setup (install + write .cursor/mcp.json + .mcp.json)\n```\n\nThere is no test suite or linter configured.\n\n## Architecture\n\n### MCP Server (`src/talk_to_figma_mcp/server.ts`)\nThe main server implementing the MCP protocol via `@modelcontextprotocol/sdk`. Exposes 50+ tools (create shapes, modify text, manage layouts, export images, etc.) and several AI prompts (design strategies). Communicates with Cursor over stdio and with the WebSocket relay via `ws`. Each request gets a UUID, is tracked in a `pendingRequests` Map with timeout/promise callbacks, and resolves when the plugin responds.\n\n### WebSocket Relay (`src/socket.ts`)\nLightweight Bun WebSocket server on port 3055 (configurable via `PORT` env). Routes messages between MCP server and Figma plugin using channel-based isolation. Clients call `join` to enter a channel; messages broadcast only within the same channel.\n\n### Figma Plugin (`src/cursor_mcp_plugin/`)\nRuns inside Figma. `code.js` is the plugin main thread handling 30+ commands via a dispatcher. `ui.html` is the plugin UI for WebSocket connection management. `manifest.json` declares permissions (dynamic-page access, localhost network). The plugin is **not built/bundled** — `code.js` is written directly as the runtime artifact.\n\n## Key Patterns\n\n- **Colors**: Figma uses RGBA 0-1 range. The MCP tools accept 0-1 floats and the filter converts to hex for display.\n- **Logging**: All logs go to stderr. Stdout is reserved for MCP protocol messages.\n- **Timeouts**: 30s default per command. Progress updates from the plugin reset the inactivity timer.\n- **Chunking**: Large operations (scanning 100+ nodes) are chunked with progress updates to prevent Figma UI freezing.\n- **Reconnection**: WebSocket auto-reconnects after 2 seconds on disconnect.\n- **Zod validation**: All tool parameters are validated with Zod schemas.\n\n## Setup\n\n1. Run `bun setup` — installs dependencies and writes MCP config for both Cursor (`.cursor/mcp.json`) and Claude Code (`.mcp.json`)\n2. `bun socket` in one terminal (WebSocket relay)\n3. In Figma: Plugins → Development → Link existing plugin → select `src/cursor_mcp_plugin/manifest.json`\n4. Run plugin in Figma, join a channel, then use tools from Cursor or Claude Code\n\nThe MCP config written by `bun setup` uses the published package:\n\n```json\n{\n  \"mcpServers\": {\n    \"TalkToFigma\": {\n      \"command\": \"bunx\",\n      \"args\": [\"cursor-talk-to-figma-mcp@latest\"]\n    }\n  }\n}\n```\n\nYou can also add it manually for Claude Code via the CLI:\n\n```bash\nclaude mcp add TalkToFigma -- bunx cursor-talk-to-figma-mcp@latest\n```\n"},"files":{"AGENTS.md":"# AGENTS.md\n\nThis file provides guidance to Claude Code agents (claude.ai/code) when working with code in this repository.\n\n## Project Overview\n\nMCP (Model Context Protocol) server that bridges AI agents (Cursor, Claude Code) with Figma. Three components communicate in a pipeline:\n\n```\nClaude Code / Cursor ←(stdio)→ MCP Server ←(WebSocket)→ WebSocket Relay ←(WebSocket)→ Figma Plugin\n```\n\n## Build & Development Commands\n\n```bash\nbun install              # Install dependencies\nbun run build            # Build MCP server (tsup → dist/)\nbun run dev              # Build in watch mode\nbun socket               # Start WebSocket relay server (port 3055)\nbun run start            # Run built MCP server\nbun setup                # Full setup (install + write .cursor/mcp.json + .mcp.json)\n```\n\nThere is no test suite or linter configured.\n\n## Architecture\n\n### MCP Server (`src/talk_to_figma_mcp/server.ts`)\nThe main server implementing the MCP protocol via `@modelcontextprotocol/sdk`. Exposes 50+ tools (create shapes, modify text, manage layouts, export images, etc.) and several AI prompts (design strategies). Communicates with the AI agent over stdio and with the WebSocket relay via `ws`. Each request gets a UUID, is tracked in a `pendingRequests` Map with timeout/promise callbacks, and resolves when the plugin responds.\n\n### WebSocket Relay (`src/socket.ts`)\nLightweight Bun WebSocket server on port 3055 (configurable via `PORT` env). Routes messages between MCP server and Figma plugin using channel-based isolation. Clients call `join` to enter a channel; messages broadcast only within the same channel.\n\n### Figma Plugin (`src/cursor_mcp_plugin/`)\nRuns inside Figma. `code.js` is the plugin main thread handling 30+ commands via a dispatcher. `ui.html` is the plugin UI for WebSocket connection management. `manifest.json` declares permissions (dynamic-page access, localhost network). The plugin is **not built/bundled** — `code.js` is written directly as the runtime artifact.\n\n## Key Patterns\n\n- **Colors**: Figma uses RGBA 0-1 range. The MCP tools accept 0-1 floats and the filter converts to hex for display.\n- **Logging**: All logs go to stderr. Stdout is reserved for MCP protocol messages.\n- **Timeouts**: 30s default per command. Progress updates from the plugin reset the inactivity timer.\n- **Chunking**: Large operations (scanning 100+ nodes) are chunked with progress updates to prevent Figma UI freezing.\n- **Reconnection**: WebSocket auto-reconnects after 2 seconds on disconnect.\n- **Zod validation**: All tool parameters are validated with Zod schemas.\n\n## Setup\n\n1. Run `bun setup` — installs dependencies and writes MCP config for both Cursor (`.cursor/mcp.json`) and Claude Code (`.mcp.json`)\n2. `bun socket` in one terminal (WebSocket relay on port 3055)\n3. In Figma: Plugins → Development → Link existing plugin → select `src/cursor_mcp_plugin/manifest.json`\n4. Run plugin in Figma, join a channel, then use tools from Cursor or Claude Code\n\nThe MCP config written by `bun setup` uses the published package:\n\n```json\n{\n  \"mcpServers\": {\n    \"TalkToFigma\": {\n      \"command\": \"bunx\",\n      \"args\": [\"cursor-talk-to-figma-mcp@latest\"]\n    }\n  }\n}\n```\n\nYou can also add it manually for Claude Code via the CLI:\n\n```bash\nclaude mcp add TalkToFigma -- bunx cursor-talk-to-figma-mcp@latest\n```\n\n## Agent Notes\n\n- Always call `join_channel` before issuing any Figma commands\n- Call `get_document_info` first to understand the design structure\n- Use `read_my_design` or `get_selection` before making modifications\n- Batch operations (`set_multiple_text_contents`, `delete_multiple_nodes`, `set_multiple_annotations`) are preferred over repeated single-node calls for performance\n- All MCP tool parameters are Zod-validated; invalid inputs return structured errors\n- The plugin and relay must both be running before any tool calls succeed\n","CLAUDE.md":"# CLAUDE.md\n\nThis file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.\n\n## Project Overview\n\nMCP (Model Context Protocol) server that bridges Cursor AI IDE with Figma. Three components communicate in a pipeline:\n\n```\nCursor AI ←(stdio)→ MCP Server ←(WebSocket)→ WebSocket Relay ←(WebSocket)→ Figma Plugin\n```\n\n## Build & Development Commands\n\n```bash\nbun install              # Install dependencies\nbun run build            # Build MCP server (tsup → dist/)\nbun run dev              # Build in watch mode\nbun socket               # Start WebSocket relay server (port 3055)\nbun run start            # Run built MCP server\nbun setup                # Full setup (install + write .cursor/mcp.json + .mcp.json)\n```\n\nThere is no test suite or linter configured.\n\n## Architecture\n\n### MCP Server (`src/talk_to_figma_mcp/server.ts`)\nThe main server implementing the MCP protocol via `@modelcontextprotocol/sdk`. Exposes 50+ tools (create shapes, modify text, manage layouts, export images, etc.) and several AI prompts (design strategies). Communicates with Cursor over stdio and with the WebSocket relay via `ws`. Each request gets a UUID, is tracked in a `pendingRequests` Map with timeout/promise callbacks, and resolves when the plugin responds.\n\n### WebSocket Relay (`src/socket.ts`)\nLightweight Bun WebSocket server on port 3055 (configurable via `PORT` env). Routes messages between MCP server and Figma plugin using channel-based isolation. Clients call `join` to enter a channel; messages broadcast only within the same channel.\n\n### Figma Plugin (`src/cursor_mcp_plugin/`)\nRuns inside Figma. `code.js` is the plugin main thread handling 30+ commands via a dispatcher. `ui.html` is the plugin UI for WebSocket connection management. `manifest.json` declares permissions (dynamic-page access, localhost network). The plugin is **not built/bundled** — `code.js` is written directly as the runtime artifact.\n\n## Key Patterns\n\n- **Colors**: Figma uses RGBA 0-1 range. The MCP tools accept 0-1 floats and the filter converts to hex for display.\n- **Logging**: All logs go to stderr. Stdout is reserved for MCP protocol messages.\n- **Timeouts**: 30s default per command. Progress updates from the plugin reset the inactivity timer.\n- **Chunking**: Large operations (scanning 100+ nodes) are chunked with progress updates to prevent Figma UI freezing.\n- **Reconnection**: WebSocket auto-reconnects after 2 seconds on disconnect.\n- **Zod validation**: All tool parameters are validated with Zod schemas.\n\n## Setup\n\n1. Run `bun setup` — installs dependencies and writes MCP config for both Cursor (`.cursor/mcp.json`) and Claude Code (`.mcp.json`)\n2. `bun socket` in one terminal (WebSocket relay)\n3. In Figma: Plugins → Development → Link existing plugin → select `src/cursor_mcp_plugin/manifest.json`\n4. Run plugin in Figma, join a channel, then use tools from Cursor or Claude Code\n\nThe MCP config written by `bun setup` uses the published package:\n\n```json\n{\n  \"mcpServers\": {\n    \"TalkToFigma\": {\n      \"command\": \"bunx\",\n      \"args\": [\"cursor-talk-to-figma-mcp@latest\"]\n    }\n  }\n}\n```\n\nYou can also add it manually for Claude Code via the CLI:\n\n```bash\nclaude mcp add TalkToFigma -- bunx cursor-talk-to-figma-mcp@latest\n```\n"},"items":[{"name":"AGENTS.md","path":"AGENTS.md","title":"AGENTS.md","content":"# AGENTS.md\n\nThis file provides guidance to Claude Code agents (claude.ai/code) when working with code in this repository.\n\n## Project Overview\n\nMCP (Model Context Protocol) server that bridges AI agents (Cursor, Claude Code) with Figma. Three components communicate in a pipeline:\n\n```\nClaude Code / Cursor ←(stdio)→ MCP Server ←(WebSocket)→ WebSocket Relay ←(WebSocket)→ Figma Plugin\n```\n\n## Build & Development Commands\n\n```bash\nbun install              # Install dependencies\nbun run build            # Build MCP server (tsup → dist/)\nbun run dev              # Build in watch mode\nbun socket               # Start WebSocket relay server (port 3055)\nbun run start            # Run built MCP server\nbun setup                # Full setup (install + write .cursor/mcp.json + .mcp.json)\n```\n\nThere is no test suite or linter configured.\n\n## Architecture\n\n### MCP Server (`src/talk_to_figma_mcp/server.ts`)\nThe main server implementing the MCP protocol via `@modelcontextprotocol/sdk`. Exposes 50+ tools (create shapes, modify text, manage layouts, export images, etc.) and several AI prompts (design strategies). Communicates with the AI agent over stdio and with the WebSocket relay via `ws`. Each request gets a UUID, is tracked in a `pendingRequests` Map with timeout/promise callbacks, and resolves when the plugin responds.\n\n### WebSocket Relay (`src/socket.ts`)\nLightweight Bun WebSocket server on port 3055 (configurable via `PORT` env). Routes messages between MCP server and Figma plugin using channel-based isolation. Clients call `join` to enter a channel; messages broadcast only within the same channel.\n\n### Figma Plugin (`src/cursor_mcp_plugin/`)\nRuns inside Figma. `code.js` is the plugin main thread handling 30+ commands via a dispatcher. `ui.html` is the plugin UI for WebSocket connection management. `manifest.json` declares permissions (dynamic-page access, localhost network). The plugin is **not built/bundled** — `code.js` is written directly as the runtime artifact.\n\n## Key Patterns\n\n- **Colors**: Figma uses RGBA 0-1 range. The MCP tools accept 0-1 floats and the filter converts to hex for display.\n- **Logging**: All logs go to stderr. Stdout is reserved for MCP protocol messages.\n- **Timeouts**: 30s default per command. Progress updates from the plugin reset the inactivity timer.\n- **Chunking**: Large operations (scanning 100+ nodes) are chunked with progress updates to prevent Figma UI freezing.\n- **Reconnection**: WebSocket auto-reconnects after 2 seconds on disconnect.\n- **Zod validation**: All tool parameters are validated with Zod schemas.\n\n## Setup\n\n1. Run `bun setup` — installs dependencies and writes MCP config for both Cursor (`.cursor/mcp.json`) and Claude Code (`.mcp.json`)\n2. `bun socket` in one terminal (WebSocket relay on port 3055)\n3. In Figma: Plugins → Development → Link existing plugin → select `src/cursor_mcp_plugin/manifest.json`\n4. Run plugin in Figma, join a channel, then use tools from Cursor or Claude Code\n\nThe MCP config written by `bun setup` uses the published package:\n\n```json\n{\n  \"mcpServers\": {\n    \"TalkToFigma\": {\n      \"command\": \"bunx\",\n      \"args\": [\"cursor-talk-to-figma-mcp@latest\"]\n    }\n  }\n}\n```\n\nYou can also add it manually for Claude Code via the CLI:\n\n```bash\nclaude mcp add TalkToFigma -- bunx cursor-talk-to-figma-mcp@latest\n```\n\n## Agent Notes\n\n- Always call `join_channel` before issuing any Figma commands\n- Call `get_document_info` first to understand the design structure\n- Use `read_my_design` or `get_selection` before making modifications\n- Batch operations (`set_multiple_text_contents`, `delete_multiple_nodes`, `set_multiple_annotations`) are preferred over repeated single-node calls for performance\n- All MCP tool parameters are Zod-validated; invalid inputs return structured errors\n- The plugin and relay must both be running before any tool calls succeed\n","category":"root","tokens":967},{"name":"CLAUDE.md","path":"CLAUDE.md","title":"CLAUDE.md","content":"# CLAUDE.md\n\nThis file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.\n\n## Project Overview\n\nMCP (Model Context Protocol) server that bridges Cursor AI IDE with Figma. Three components communicate in a pipeline:\n\n```\nCursor AI ←(stdio)→ MCP Server ←(WebSocket)→ WebSocket Relay ←(WebSocket)→ Figma Plugin\n```\n\n## Build & Development Commands\n\n```bash\nbun install              # Install dependencies\nbun run build            # Build MCP server (tsup → dist/)\nbun run dev              # Build in watch mode\nbun socket               # Start WebSocket relay server (port 3055)\nbun run start            # Run built MCP server\nbun setup                # Full setup (install + write .cursor/mcp.json + .mcp.json)\n```\n\nThere is no test suite or linter configured.\n\n## Architecture\n\n### MCP Server (`src/talk_to_figma_mcp/server.ts`)\nThe main server implementing the MCP protocol via `@modelcontextprotocol/sdk`. Exposes 50+ tools (create shapes, modify text, manage layouts, export images, etc.) and several AI prompts (design strategies). Communicates with Cursor over stdio and with the WebSocket relay via `ws`. Each request gets a UUID, is tracked in a `pendingRequests` Map with timeout/promise callbacks, and resolves when the plugin responds.\n\n### WebSocket Relay (`src/socket.ts`)\nLightweight Bun WebSocket server on port 3055 (configurable via `PORT` env). Routes messages between MCP server and Figma plugin using channel-based isolation. Clients call `join` to enter a channel; messages broadcast only within the same channel.\n\n### Figma Plugin (`src/cursor_mcp_plugin/`)\nRuns inside Figma. `code.js` is the plugin main thread handling 30+ commands via a dispatcher. `ui.html` is the plugin UI for WebSocket connection management. `manifest.json` declares permissions (dynamic-page access, localhost network). The plugin is **not built/bundled** — `code.js` is written directly as the runtime artifact.\n\n## Key Patterns\n\n- **Colors**: Figma uses RGBA 0-1 range. The MCP tools accept 0-1 floats and the filter converts to hex for display.\n- **Logging**: All logs go to stderr. Stdout is reserved for MCP protocol messages.\n- **Timeouts**: 30s default per command. Progress updates from the plugin reset the inactivity timer.\n- **Chunking**: Large operations (scanning 100+ nodes) are chunked with progress updates to prevent Figma UI freezing.\n- **Reconnection**: WebSocket auto-reconnects after 2 seconds on disconnect.\n- **Zod validation**: All tool parameters are validated with Zod schemas.\n\n## Setup\n\n1. Run `bun setup` — installs dependencies and writes MCP config for both Cursor (`.cursor/mcp.json`) and Claude Code (`.mcp.json`)\n2. `bun socket` in one terminal (WebSocket relay)\n3. In Figma: Plugins → Development → Link existing plugin → select `src/cursor_mcp_plugin/manifest.json`\n4. Run plugin in Figma, join a channel, then use tools from Cursor or Claude Code\n\nThe MCP config written by `bun setup` uses the published package:\n\n```json\n{\n  \"mcpServers\": {\n    \"TalkToFigma\": {\n      \"command\": \"bunx\",\n      \"args\": [\"cursor-talk-to-figma-mcp@latest\"]\n    }\n  }\n}\n```\n\nYou can also add it manually for Claude Code via the CLI:\n\n```bash\nclaude mcp add TalkToFigma -- bunx cursor-talk-to-figma-mcp@latest\n```\n","category":"root","tokens":818}]}