claude-code
claude-code copied to clipboard
Documentation error: SSE server with custom headers
In the documentation for Configure MCP servers it states that environment variables should be used to add an SSE server with custom header.
# Example: Adding an SSE server with custom headers
claude mcp add --transport sse api-server https://api.example.com/mcp -e X-API-Key=your-key
But the correct way for SSE and HTTP transports is to set customer header like this:
claude mcp add --transport sse api-server https://api.example.com/mcp -H "X-API-Key: your-key"