Loading...
Loading...
Add an MCP server to pi. Use when asked to "add mcp server", "configure mcp", "add mcp", "new mcp server", "setup mcp", "connect mcp server", or "register mcp server". Handles both global and project-local configurations.
npx skill4agent add hazat/pi-config add-mcp-serverpi-mcp-adapter| Scope | Config File | When to Use |
|---|---|---|
| Global | | Server used across all projects |
| Project | | Server specific to one project |
{
"mcpServers": {
"server-name": {
"command": "npx",
"args": ["-y", "package-name@latest"],
"env": { "KEY": "value" }
}
}
}{
"mcpServers": {
"server-name": {
"url": "http://localhost:8080/mcp",
"headers": { "Authorization": "Bearer token" }
}
}
}commandurl| Field | Type | Description |
|---|---|---|
| string | Executable to run (stdio) |
| string[] | Command arguments (stdio) |
| object | Environment variables (stdio) |
| string | Working directory (stdio) |
| string | Server URL (HTTP) |
| object | HTTP headers (HTTP) |
| | Auth method (HTTP) |
| string | Static bearer token |
| string | Env var name for bearer token |
| | Connection strategy (default: |
| number | Minutes before idle disconnect |
| boolean | Show server stderr |
mcpServers{
"mcpServers": {
"server-name": { ... }
}
}/reloadmcp({ connect: "server-name" })mcp({ server: "server-name" })