MCP
Add MCP Servers
Add, edit, enable, disable, and remove MCP servers from Placet, API, or the agent.
Facio exposes MCP management in three ways: Placet settings, the management API, and the agent's own manage_mcp tool.
Agent-managed MCP
The agent can help create MCP servers itself. A typical flow is:
- User asks for a capability, for example GitHub, browser testing, database access, or docs search.
- Agent researches the MCP server command and required credentials.
- Agent asks the user to confirm the exact server name and config.
- If credentials are needed, the agent uses a password/form field so the secret goes into the credential store.
- Agent calls
manage_mcpwith the confirmed config. - Facio writes
mcp.json, connects the server, and registers tools named likemcp_server_tool.
The confirmation step matters. MCP servers can run local commands or access external accounts, so adding one is treated as a sensitive runtime change.
Management API
List servers:
curl http://localhost:8900/api/v1/mcp \
-H "Authorization: Bearer $FACIO_MANAGEMENT_TOKEN"Add a stdio server:
curl -X POST http://localhost:8900/api/v1/mcp \
-H "Authorization: Bearer $FACIO_MANAGEMENT_TOKEN" \
-H 'Content-Type: application/json' \
-d '{
"name": "github",
"type": "stdio",
"command": "npx",
"args": ["-y", "@modelcontextprotocol/server-github"],
"env": {"GITHUB_PERSONAL_ACCESS_TOKEN": "${credentials.GITHUB_TOKEN}"},
"enabledTools": ["*"],
"enabled": true
}'Edit or lifecycle actions:
| Endpoint | Action |
|---|---|
GET /api/v1/mcp/{name} | Read one server summary. |
PATCH /api/v1/mcp/{name} | Update config fields. |
DELETE /api/v1/mcp/{name} | Remove the server. |
POST /api/v1/mcp/{name}/enable | Enable and connect. |
POST /api/v1/mcp/{name}/disable | Disconnect and keep config. |
POST /api/v1/mcp/{name}/restart | Reconnect. |
Server config fields
| Field | Meaning |
|---|---|
type | stdio, sse, or streamableHttp. Omitted type is inferred where possible. |
command / args | Command and arguments for stdio servers. |
env | Extra environment variables for stdio servers. Supports ${credentials.KEY} placeholders. |
url | HTTP/SSE endpoint. |
headers | HTTP/SSE headers. Supports ${credentials.KEY} placeholders. |
toolTimeout | Per MCP tool-call timeout in seconds. |
enabledTools | ['*'] for all tools, a list of raw MCP names, wrapped names, or [] for none. |
enabled | Whether Facio should connect the server at startup. |
What to verify
- The command exists in the Facio container, not only on the host.
- The server package is trusted and maintained.
- Required account scopes are narrow.
- Credentials use placeholders rather than raw values.
- The first connection reports the expected tool list.
- Tool-call policy is configured for high-impact MCP tools.