@usespectra/mcp
v2.3.5
Published
Spectra — AI readiness audit for Figma and Paper design systems. MCP server with 8 tools for scanning, scoring, and auto-fixing design systems.
Maintainers
Readme
@usespectra/mcp
Design system auditor for AI coding tools. Connects your Figma or Paper design system to Claude Code, Cursor, and other AI tools.
Quick Start (2 minutes)
1. Install
claude mcp add spectra -- npx -y @usespectra/mcp2. Install skills (optional)
npx @usespectra/mcp --initThis copies /spectra-scan, /spectra-audit, /spectra-fix, /spectra-link to .claude/skills/.
3. Run your first scan
Paper (Paper Desktop must be running):
"Audit my Paper design system"Figma:
"Audit my design system at https://figma.com/design/YOUR_FILE_ID"4. What you get
.claude/rules/design-system.md— AI rules, component table, design tokens.claude/rules/components.md— Full component reference with import paths
Claude Code reads these rules automatically when editing .tsx/.vue files.
Supported Tools
| Design Tool | Status | Connection |
|-------------|--------|------------|
| Figma | Full support | REST API via personal access token + Figma MCP for auto-fix |
| Paper | Full support | Local MCP server (127.0.0.1:29979/mcp) |
| Framework | Status | Detection |
|-----------|--------|-----------|
| React / Next.js | Full support | Auto-detected from package.json |
| Vue | Full support | Auto-detected from package.json |
8 MCP Tools
| Tool | What it does |
|------|-------------|
| audit_design_file | Full AI-readiness audit — score 0-100, issues, auto-saves rules |
| auto_fix_design | Generate fix scripts for Figma Plugin API or Paper MCP |
| get_fix_suggestions | Prioritized fix roadmap with effort estimates |
| generate_component | Scaffold React/Vue component from design |
| get_design_tokens | Extract colors, typography, spacing as JSON |
| get_design_code_drift | Compare design vs GitHub repo |
| check_score_gate | CI/CD gate — pass/fail against threshold |
| audit_with_context | Enriched audit with Figma MCP data |
4 Skills
| Skill | What it does |
|-------|-------------|
| /spectra-scan | Quick audit + save rules + summary |
| /spectra-audit | Detailed audit with score breakdown |
| /spectra-fix | Auto-fix issues in your design file |
| /spectra-link | Link design components to code components |
How it works
1. Reads your design file (Figma API or Paper MCP)
2. Detects framework (React/Vue) and project structure (src/, frontend/, monorepo)
3. Runs 6 scanners: naming, variants, hardcoded values, auto-layout, duplicates, detached
4. Scores 0-100 with file-type detection (design system vs landing page)
5. Scans your codebase for existing components — fuzzy matches design names to code
6. Auto-saves .claude/rules/ with verified import paths and design tokensWhat the audit checks
| Scanner | Checks | Severity | |---------|--------|----------| | Naming | Generic names (Frame 42, Rectangle) | Critical | | Auto-layout | Missing flexbox/grid layout | Critical | | Variants | Missing component properties | Warning | | Hardcoded | Colors/spacing not using tokens | Warning | | Duplicates | Near-identical components | Warning | | Detached | Frames that should be instances | Warning |
Requirements
- Node.js 18+
- Figma: Personal access token (generate here)
- Paper: Paper Desktop app running with MCP enabled
- Optional: Figma MCP or Paper MCP connected for auto-fix
