Figma Context MCP
Give your coding agent access to your Figma data. Implement designs in any framework in one-shot.
作者提供的说明(英文原文)
MCP Server for Optics Design System documentation and token usage.
这三项永远不会合并成一个分数:意见、测量和人气是不同的东西。
我们还没有为它写通俗的介绍。下面是我们从注册中心读取到的事实。
选择你使用的 AI 应用,然后复制设置。
你需要
你用的是哪个应用?
在上方选择你的应用。我们会记住它,下次按钮会显示“安装到 …”。
打开 Claude Desktop → Settings → Developer → Edit Config,把下面的内容粘贴到 claude_desktop_config.json
{
"mcpServers": {
"optics": {
"command": "npx",
"args": [
"-y",
"optics-mcp"
]
}
}
}在终端中运行这条命令
claude mcp add optics -- npx -y optics-mcp粘贴到项目中的 .cursor/mcp.json,或 ~/.cursor/mcp.json
{
"mcpServers": {
"optics": {
"command": "npx",
"args": [
"-y",
"optics-mcp"
]
}
}
}浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。
粘贴到项目中的 .vscode/mcp.json
{
"servers": {
"optics": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"optics-mcp"
]
}
}
}浏览器会先询问是否打开应用,然后应用会显示设置并请你确认。密钥的值会留空,由你自己填写。
这个服务器在你的电脑上运行,而 ChatGPT 只能连接互联网上的服务器。请选择其他应用。
你的选择通过 Cookie 保存在这台设备上,无需账户。
这些设置是根据作者在注册中心的条目生成的。如果 README 的写法不同,请以 README 为准。
它在你的电脑上运行;安装后,工具列表会显示在你的 AI 应用中。
我们检查的是任何人都能看到的信息;我们没有阅读代码。不适用的检查项不计入总数。 · 检查于 2026年11月6日
注册名称已通过 GitHub 账户 RoleModel 验证,该账户拥有此仓库
我们还没有从 GitHub 读取这个仓库
我们还没有从 GitHub 读取这个仓库
它在你的电脑上运行,没有互联网端点
在你的电脑上运行,改用本地设置
它在你的电脑上运行;我们只能读取互联网端点的工具列表
与注册中心里这个分类中所有活跃的服务器比较。只有当发布者拥有该仓库时,星标数才计入。
它在 1 项适用的基础检查中通过了 1 项。我们没有阅读代码。在添加密钥或令牌之前,请先看看这个服务器要求哪些权限,并使用只具备所需权限的密钥。
注册中心没有列出必需的密钥,不过有些服务器会在首次使用时要求你登录。
它在你的电脑上运行。你的 AI 应用会在需要时启动它,数据不会经过作者的服务器(除非它自己调用在线服务)。
GitHub 仓库最后更新于–,最新版本(0.2.6)于11个月前进入注册中心。
支持 MCP 的应用,例如 Claude Desktop、Claude Code、Cursor 和 VS Code。你的电脑上还需要有 Node.js。
同一分类中有:Figma Context MCP, Claude Real Video, Figma MCP Server
同一分类中其他作者的服务器,按星标数排序。
如何看卡片:★ GitHub 星标i三大支柱:评价 · 检查 · 使用情况i更新 = 最新版本发布到注册中心的时间i
Give your coding agent access to your Figma data. Implement designs in any framework in one-shot.
Let any LLM watch a video locally — and search everything it has ever watched.
The Figma MCP server brings Figma design context directly into your AI workflow.
按原文从作者的仓库复制。PopNx MCP 没有审查或背书其内容。HTML、图片和脚本已被移除。链接会离开本站。
A Model Context Protocol (MCP) server for the Optics Design System, enabling LLMs to understand and work with design tokens, components, and documentation from https://docs.optics.rolemodel.design.
If you're an AI agent, read [SYSTEM_OVERVIEW.md](./SYSTEM_OVERVIEW.md) FIRST!
Optics uses a sophisticated HSL-based color system that's different from typical design systems. The system overview explains:
--color-primary token (use --op-color-primary-base instead)Key insight: Optics has 500+ color tokens organized as a predictable scale system, not simple name-value pairs.
This MCP server provides 14 tools and resources for working with the Optics design system:
graph TB
subgraph "MCP Client (AI/LLM)" CLIENT[AI Agent/LLM] end
subgraph "Optics MCP Server" SERVER[MCP Server stdio transport]
subgraph "Resources (13)" SYSTEM[optics://system-overview] DOC_INTRO[optics://documentation/introduction] DOC_START[optics://documentation/getting-started] DOC_TOKENS[optics://documentation/design-tokens] DOC_COLOR[optics://documentation/color-system] DOC_SPACING[optics://documentation/spacing] DOC_TYPO[optics://documentation/typography] DOC_COMP[optics://documentation/components] DOC_A11Y[optics://documentation/accessibility] TOK_ALL[optics://tokens/all] TOK_COLOR[optics://tokens/color] TOK_SPACING[optics://tokens/spacing] TOK_TYPO[optics://tokens/typography] COMP_ALL[optics://components/all] end
subgraph "Core Tools (7)" T1[get_token] T2[search_tokens] T3[get_token_usage_stats] T4[get_component_info] T5[list_components] T6[get_component_tokens] T7[search_documentation] end
subgraph "Advanced Tools (7)" T8[generate_theme] T9[validate_token_usage] T10[replace_hard_coded_values] T11[check_contrast] T12[suggest_token_migration] T13[generate_component_scaffold] T14[generate_sticker_sheet] end
subgraph "Prompts (5)" P1[start-here] P2[get-token-reference] P3[component-guide] P4[theme-customization] P5[migration-guide] end
subgraph "Data Layer" TOKENS[83 Design Tokens HSL colors, spacing, typography, borders, shadows] COMPONENTS[24 Components with token dependencies] DOCS[Documentation Guidelines & best practices] end end
CLIENT -->|JSON-RPC| SERVER SERVER --> SYSTEM SERVER --> DOC_INTRO SERVER --> DOC_START SERVER --> DOC_TOKENS SERVER --> DOC_COLOR SERVER --> DOC_SPACING SERVER --> DOC_TYPO SERVER --> DOC_COMP SERVER --> DOC_A11Y SERVER --> TOK_ALL SERVER --> TOK_COLOR SERVER --> TOK_SPACING SERVER --> TOK_TYPO SERVER --> COMP_ALL SERVER --> T1 SERVER --> T2 SERVER --> T3 SERVER --> T4 SERVER --> T5 SERVER --> T6 SERVER --> T7 SERVER --> T8 SERVER --> T9 SERVER --> T10 SERVER --> T11 SERVER --> T12 SERVER --> T13 SERVER --> T14 SERVER --> P1 SERVER --> P2 SERVER --> P3 SERVER --> P4 SERVER --> P5 T1 --> TOKENS T2 --> TOKENS T3 --> TOKENS T4 --> COMPONENTS T5 --> COMPONENTS T6 --> COMPONENTS T7 --> DOCS T8 --> TOKENS T9 --> TOKENS T10 --> TOKENS T11 --> TOKENS T12 --> TOKENS T13 --> COMPONENTS T14 --> TOKENS T14 --> COMPONENTS P1 --> SYSTEM P2 --> TOKENS P3 --> COMPONENTS P4 --> T8 P5 --> T12
Quick Setup:
{
"servers": { "optics": { "command": "npx", "args": [ "@rolemodel/optics-mcp@latest" ] } } }
Or create .vscode/mcp.json in your workspace with the same config.
Official MCP Registry: Listed at registry.modelcontextprotocol.io ✅
One-Click Install (click to open Cursor):
cursor://anysphere.cursor-deeplink/mcp/install?name=optics&config=eyJvcHRpY3MiOnsiY29tbWFuZCI6Im5weCIsImFyZ3MiOlsiLXkiLCJvcHRpY3MtbWNwIl19fQ==
Or Manual Setup:
{
"servers": { "optics": { "command": "npx", "args": [ "@rolemodel/optics-mcp@latest" ] } } }
The easiest way to use Optics MCP - no installation required!
Add to your MCP configuration:
{
"mcpServers": { "optics": { "command": "npx", "args": [ "@rolemodel/optics-mcp@latest" ] } } }
Add with a single command:
claude mcp add optics -- npx -y optics-mcp
Other useful commands:
# List all MCP servers
claude mcp list
claude mcp remove optics
claude mcp get optics
claude mcp test optics
That's it! The server runs automatically whenever your MCP client needs it.
If you want to modify the server or contribute:
git clone https://github.com/RoleModel/optics-mcp.git
cd optics-mcp npm install npm run build
Then configure with the local path:
{
"mcpServers": { "optics": { "command": "node", "args": ["/absolute/path/to/optics-mcp/dist/index.js"] } } }
npm start
For detailed documentation of all tools, see TOOLS.md.
get_tokenGet detailed information about a specific design token.
search_tokensSearch for design tokens by category or name pattern.
get_token_usage_statsGet statistics about design token usage across the system.
get_component_infoGet detailed information about a component including its design token dependencies.
list_componentsList all available components in the design system.
get_component_tokensGet all design tokens used by a specific component.
search_documentationSearch through Optics documentation.
generate_themeCreate a custom branded theme with CSS variables and Figma Variables JSON.
validate_token_usageFind hard-coded values in code that should use design tokens.
replace_hard_coded_valuesAutomatically replace hard-coded values with design tokens.
check_contrastCheck WCAG color contrast ratios between tokens.
suggest_token_migrationSuggest tokens for legacy code migration.
generate_component_scaffoldGenerate component code with Optics tokens.
generate_sticker_sheetGenerate a visual style guide showing all design tokens and components.
The server exposes the following resources via the optics:// URI scheme:
optics://documentation/introduction - Overview of Opticsoptics://documentation/getting-started - Getting started guideoptics://documentation/design-tokens - Design token documentationoptics://documentation/color-system - Color system guideoptics://documentation/spacing - Spacing system guideoptics://documentation/typography - Typography guideoptics://documentation/components - Component library overviewoptics://documentation/accessibility - Accessibility guidelinesoptics://tokens/all - All design tokensoptics://tokens/color - Color tokens onlyoptics://tokens/spacing - Spacing tokens onlyoptics://tokens/typography - Typography tokens onlyoptics://components/all - All componentsAll components extracted from real Optics SCSS with accurate token dependencies:
Each component specifies which Optics design tokens it uses, making it easy to understand dependencies and maintain consistency.
npm run build
npm run watch
optics-mcp/
├── src/ │ ├── index.ts # MCP server implementation │ └── optics-data.ts # Design tokens and component data ├── dist/ # Compiled JavaScript ├── package.json ├── tsconfig.json └── README.md
The server tracks which design tokens are used by each component, enabling:
只显示了开头部分;其余内容请在仓库中阅读