Client setup
Introduction
Section titled “Introduction”Every MCP client runs the server the same way: it spawns npx -y @piprail/mcp over stdio and
hands it configuration through an env block. What differs per client is only where the
config file lives, the top-level JSON key, and whether you can interpolate
${env:…} rather than pasting the raw key.
This page is one row per client. For what goes inside env, see
Configuration; for the wallet key format your chain expects, see
Wallets by family.
The invocation is identical everywhere
Section titled “The invocation is identical everywhere”command and args never change — only the config wrapper around them does:
{ "command": "npx", "args": ["-y", "@piprail/mcp"], "env": { "PIPRAIL_PRIVATE_KEY": "0xYOUR_PRIVATE_KEY", "PIPRAIL_CHAIN": "base" }}Clients at a glance
Section titled “Clients at a glance”| Client | Config file | Top-level key | ${env:…} |
|---|---|---|---|
| Claude Desktop | ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) · %APPDATA%\Claude\claude_desktop_config.json (Windows) | mcpServers | No — file is a secret |
| Cursor | .cursor/mcp.json (project) · ~/.cursor/mcp.json (global) | mcpServers | Yes |
| Claude Code | .mcp.json (project) · ~/.claude.json (user) | mcpServers | Yes |
| Windsurf | ~/.codeium/windsurf/mcp_config.json | mcpServers | Yes |
| VS Code (Copilot) | .vscode/mcp.json | servers | Yes |
| Cline | cline_mcp_settings.json (edited from the MCP Servers panel) | mcpServers | Yes |
Claude Desktop
Section titled “Claude Desktop”Open Settings → Developer → Edit Config, or edit the file directly. Claude Desktop does not
interpolate ${env:…}, so the key goes in the file — keep it out of version control.
{ "mcpServers": { "piprail": { "command": "npx", "args": ["-y", "@piprail/mcp"], "env": { "PIPRAIL_PRIVATE_KEY": "0xYOUR_PRIVATE_KEY", "PIPRAIL_CHAIN": "base", "PIPRAIL_MAX_AMOUNT": "0.10", "PIPRAIL_MAX_TOTAL": "10.00", "PIPRAIL_TOKENS": "USDC" } } }}Restart Claude Desktop and the piprail_* tools appear.
Cursor
Section titled “Cursor”Project config at .cursor/mcp.json, or global at ~/.cursor/mcp.json. Cursor interpolates
${env:…}, so export the key to your shell and reference it:
{ "mcpServers": { "piprail": { "command": "npx", "args": ["-y", "@piprail/mcp"], "env": { "PIPRAIL_PRIVATE_KEY": "${env:PIPRAIL_PRIVATE_KEY}", "PIPRAIL_CHAIN": "base" } } }}Claude Code
Section titled “Claude Code”Project config at .mcp.json (commit-safe with ${env:…}); user config across all projects
lives in ~/.claude.json. Same shape, same ${env:…} support. You can also add it from the
CLI — claude mcp add piprail --scope user --env PIPRAIL_CHAIN=base -- npx -y @piprail/mcp —
which writes the same block for you.
{ "mcpServers": { "piprail": { "command": "npx", "args": ["-y", "@piprail/mcp"], "env": { "PIPRAIL_PRIVATE_KEY": "${env:PIPRAIL_PRIVATE_KEY}", "PIPRAIL_CHAIN": "base" } } }}Windsurf
Section titled “Windsurf”Config at ~/.codeium/windsurf/mcp_config.json:
{ "mcpServers": { "piprail": { "command": "npx", "args": ["-y", "@piprail/mcp"], "env": { "PIPRAIL_PRIVATE_KEY": "${env:PIPRAIL_PRIVATE_KEY}", "PIPRAIL_CHAIN": "base" } } }}VS Code (Copilot)
Section titled “VS Code (Copilot)”Config at .vscode/mcp.json. Note the top-level key is servers, not mcpServers:
{ "servers": { "piprail": { "command": "npx", "args": ["-y", "@piprail/mcp"], "env": { "PIPRAIL_PRIVATE_KEY": "${env:PIPRAIL_PRIVATE_KEY}", "PIPRAIL_CHAIN": "base" } } }}Cline stores servers in cline_mcp_settings.json. Open it from the MCP Servers icon →
Configure → Configure MCP Servers, then add the same mcpServers block:
{ "mcpServers": { "piprail": { "command": "npx", "args": ["-y", "@piprail/mcp"], "env": { "PIPRAIL_PRIVATE_KEY": "${env:PIPRAIL_PRIVATE_KEY}", "PIPRAIL_CHAIN": "base" } } }}More than one chain
Section titled “More than one chain”Each server instance is one wallet on one chain. To give an agent several rails, register the server once per chain — each entry is namespaced, so the agent gets all of them:
{ "mcpServers": { "piprail-base": { "command": "npx", "args": ["-y", "@piprail/mcp"], "env": { "PIPRAIL_PRIVATE_KEY": "0xYOUR_EVM_KEY", "PIPRAIL_CHAIN": "base" } }, "piprail-solana": { "command": "npx", "args": ["-y", "@piprail/mcp"], "env": { "PIPRAIL_PRIVATE_KEY": "YOUR_SOLANA_SECRET_BASE58", "PIPRAIL_CHAIN": "solana" } } }}