Skip to content

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.

Terminal
curl -fsSL https://barrd.com/install.sh | sh

The installer detects your OS and architecture, downloads the correct binary, and installs it.

Download the binary for your platform from GitHub Releases:

PlatformBinary
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
Terminal
chmod +x barrd-mcp-*
sudo mv barrd-mcp-* /usr/local/bin/barrd-mcp
Terminal
git clone https://github.com/barrdlabs/barrd.git
cd barrd/mcp-client
cargo build --release
# Binary at target/release/barrd-mcp

One command:

Terminal
claude mcp add barrd /usr/local/bin/barrd-mcp -e BARRD_API_KEY=your-api-key

Get your API key from the Barrd dashboard under Settings → API Keys.

Add Barrd to your Claude Desktop MCP configuration:

claude_desktop_config.json
{
"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.

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-Length headers (LSP-compatible)

Transport mode is auto-detected from the first message, or can be forced with --transport line or --transport framed.

The server resolves configuration in this order:

  1. BARRD_MCP_CONFIG env var — path to a JSON config file
  2. ~/.config/barrd/mcp.json — default config file location
  3. Environment variables — BARRD_API_KEY and optionally BARRD_API_URL

For most users, just setting BARRD_API_KEY is enough.

Environment variables

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

Only needed if you prefer file-based config over environment variables:

~/.config/barrd/mcp.json
{
"api": {
"base_url": "https://api.barrd.com",
"key": "your-api-key"
}
}

Barrd includes LSP integration: go-to-definition, find references, hover info, workspace symbol search. Install the language server for the languages you work with:

Language servers
# Go
go install golang.org/x/tools/gopls@latest
# Rust
rustup component add rust-analyzer
# TypeScript / JavaScript
npm install -g typescript-language-server typescript
# Python
npm install -g pyright

LSP servers start automatically on first use and stay alive for subsequent requests. No additional configuration needed. More languages coming soon.

Supported languages
Go gopls — fully tested
Rust rust-analyzer — fully tested
TypeScript / JavaScript typescript-language-server — fully tested
Python pyright — supported, not extensively tested

Enable debug logging to troubleshoot connection or LSP issues:

Terminal
RUST_LOG=debug barrd-mcp