11# MCP (Model Context Protocol) Servers Configuration
22
3- This document describes the MCP servers that have been added to the Claude Code setup .
3+ This document describes the MCP servers that can be configured for Claude Desktop and Claude Code.
44
55## Overview
66
7- The ` setup-claude-mcp.sh ` script now installs and configures both official and community MCP servers to enhance Claude Code's capabilities.
7+ The macbook-dev-setup project includes several scripts to manage MCP servers:
8+
9+ - ` setup-claude-mcp.sh ` - Installs and configures MCP servers for Claude Desktop
10+ - ` setup-claude-code-mcp.sh ` - Configures MCP servers for Claude Code CLI
11+ - ` fix-mcp-servers.sh ` - Repairs MCP configuration with dynamic server selection
12+ - ` debug-mcp-servers.sh ` - Tests and debugs MCP server installations
813
914## Official Servers
1015
@@ -49,12 +54,63 @@ Pieces MCP requires special configuration:
4954
5055## Installation
5156
57+ ### Claude Desktop
58+
59+ ``` bash
60+ # Install all MCP servers
61+ ./scripts/setup-claude-mcp.sh
62+
63+ # Fix/update configuration
64+ ./scripts/fix-mcp-servers.sh
65+
66+ # Exclude servers that need API keys
67+ ./scripts/fix-mcp-servers.sh --no-api-keys
68+
69+ # Only install specific servers
70+ ./scripts/fix-mcp-servers.sh --servers filesystem,memory,git
71+ ```
72+
73+ ### Claude Code
74+
75+ ``` bash
76+ # Add all servers to user scope (global)
77+ ./scripts/setup-claude-code-mcp.sh
78+
79+ # Add to project scope (.mcp.json)
80+ ./scripts/setup-claude-code-mcp.sh --scope project
81+
82+ # Skip servers requiring API keys
83+ ./scripts/setup-claude-code-mcp.sh --no-api-keys
84+
85+ # Add specific servers only
86+ ./scripts/setup-claude-code-mcp.sh --servers context7,playwright
87+ ```
88+
89+ ## Debugging
90+
91+ ``` bash
92+ # Test all MCP servers
93+ ./scripts/debug-mcp-servers.sh
94+ ```
95+
96+ This will:
97+ - Check environment variables for API keys
98+ - Test each server individually
99+ - Verify Claude Desktop configuration
100+ - Check Claude Code configuration
101+
52102Run the setup script to install all servers:
53103
54104``` bash
55105./scripts/setup-claude-mcp.sh
56106```
57107
108+ During installation, you'll be prompted for API keys for servers that require them:
109+ - ** Exa** : Get your API key from https://dashboard.exa.ai/api-keys
110+ - ** Figma** : Get your API key from https://www.figma.com/developers/api#access-tokens
111+
112+ API keys are securely stored in ` ~/.config/zsh/51-api-keys.zsh ` and automatically loaded by your shell.
113+
58114## Usage
59115
60116Once installed, the servers are automatically available in Claude Code. You can:
@@ -69,12 +125,40 @@ Once installed, the servers are automatically available in Claude Code. You can:
69125- Python 3 and uv (for Python servers)
70126- Claude Code CLI
71127- For specific servers:
72- - Figma: Requires Figma API access token
128+ - Exa: Requires API key (will be prompted during setup)
129+ - Figma: Requires API key (will be prompted during setup)
73130 - Semgrep: May require Semgrep CLI installation
74131 - Pieces: Requires PiecesOS running locally
75132
76133## Troubleshooting
77134
135+ ### Connection Issues
136+
137+ To debug MCP connection failures:
138+ 1 . Run ` claude mcp list ` to see connection status
139+ 2 . Use ` ./scripts/debug-mcp-servers.sh ` to test individual servers
140+ 3 . Check API keys are set: ` echo $EXA_API_KEY ` and ` echo $FIGMA_API_KEY `
141+ 4 . Restart Claude after configuration changes: ` osascript -e 'quit app "Claude"' && open -a "Claude" `
142+
143+ ### Common Issues
144+
145+ ** Figma/Exa servers fail to connect:**
146+ - Ensure API keys are set in your shell environment
147+ - Check ` ~/.config/zsh/51-api-keys.zsh ` contains the keys
148+ - Reload your shell or run ` source ~/.zshrc `
149+
150+ ** Playwright server fails:**
151+ - The server may use ` index.js ` instead of ` dist/index.js `
152+ - Check actual file location and update config accordingly
153+
154+ ** Semgrep server fails:**
155+ - Requires Python and uv package manager
156+ - Run ` cd ~/repos/mcp-servers/community/semgrep && uv sync `
157+
158+ ** Configuration gets corrupted:**
159+ - Backup exists at ` ~/.setup-backups/configs/claude-mcp/ `
160+ - Or use ` ./scripts/fix-mcp-servers.sh ` to reset
161+
78162If a server fails to build or install:
791631 . Check that all prerequisites are installed
801642 . Ensure you have internet connectivity for cloning repositories
0 commit comments