Installation
The Barrd MCP server is a standalone binary that runs locally and connects your AI assistant to the Barrd backend. It communicates over stdio using the Model Context Protocol.
Install
Section titled “Install”curl -fsSL https://barrd.com/install.sh | shThe installer detects your OS and architecture, downloads the correct binary, and installs it.
Manual install
Section titled “Manual install”Download the binary for your platform from GitHub Releases:
| Platform | Binary |
|---|---|
| macOS (Apple Silicon) | barrd-mcp-aarch64-apple-darwin |
| macOS (Intel) | barrd-mcp-x86_64-apple-darwin |
| Linux (x86_64) | barrd-mcp-x86_64-unknown-linux-gnu |
| Linux (ARM64) | barrd-mcp-aarch64-unknown-linux-gnu |
chmod +x barrd-mcp-*sudo mv barrd-mcp-* /usr/local/bin/barrd-mcpBuild from source
Section titled “Build from source”git clone https://github.com/barrdlabs/barrd.gitcd barrd/mcp-clientcargo build --release# Binary at target/release/barrd-mcpConnect to Claude Code
Section titled “Connect to Claude Code”One command:
claude mcp add barrd /usr/local/bin/barrd-mcp -e BARRD_API_KEY=your-api-keyGet your API key from the Barrd dashboard under Settings → API Keys.
Claude Desktop
Section titled “Claude Desktop”Add Barrd to your Claude Desktop MCP configuration:
{ "mcpServers": { "barrd": { "command": "/usr/local/bin/barrd-mcp", "env": { "BARRD_API_KEY": "your-api-key" } } }}On macOS, this file lives at ~/Library/Application Support/Claude/claude_desktop_config.json.
Other MCP clients
Section titled “Other MCP clients”Any MCP-compatible client can connect to Barrd. The server uses stdio transport with auto-detected framing:
- Line-delimited — one JSON-RPC message per line (default for most clients)
- Framed — HTTP-style
Content-Lengthheaders (LSP-compatible)
Transport mode is auto-detected from the first message, or can be forced with --transport line or --transport framed.
Configuration
Section titled “Configuration”The server resolves configuration in this order:
BARRD_MCP_CONFIGenv var — path to a JSON config file~/.config/barrd/mcp.json— default config file location- Environment variables —
BARRD_API_KEYand optionallyBARRD_API_URL
For most users, just setting BARRD_API_KEY is enough.
Configuration via environment variables.
BARRD_API_KEY required API key for authentication BARRD_API_URL API base URL. Default: https://api.barrd.com. Override for self-hosted. BARRD_MCP_CONFIG Path to a JSON config file RUST_LOG Log level: debug, info, warn, error Config file
Section titled “Config file”Only needed if you prefer file-based config over environment variables:
{ "api": { "base_url": "https://api.barrd.com", "key": "your-api-key" }}Code intelligence (LSP)
Section titled “Code intelligence (LSP)”Barrd includes LSP integration: go-to-definition, find references, hover info, workspace symbol search. Install the language server for the languages you work with:
# Gogo install golang.org/x/tools/gopls@latest
# Rustrustup component add rust-analyzer
# TypeScript / JavaScriptnpm install -g typescript-language-server typescript
# Pythonnpm install -g pyrightLSP servers start automatically on first use and stay alive for subsequent requests. No additional configuration needed. More languages coming soon.
Go gopls — fully tested Rust rust-analyzer — fully tested TypeScript / JavaScript typescript-language-server — fully tested Python pyright — supported, not extensively tested Debugging
Section titled “Debugging”Enable debug logging to troubleshoot connection or LSP issues:
RUST_LOG=debug barrd-mcp