MCP Server Setup
The Reoclo CLI ships with a built-in Model Context Protocol server. Any MCP-compatible client (Claude Code, Cursor, VS Code, Zed, JetBrains AI, Cline, and so on) can drive Reoclo through it: servers, applications, deployments, domains, logs, monitors, status pages, scheduled operations.
There are no API keys to mint or paste. Authentication is handled by reoclo login (OAuth device flow). The MCP server reads the resulting credentials from your CLI profile each time it starts.
Prerequisites
Section titled “Prerequisites”- Reoclo CLI. Install it once:
Terminal window npm i -g @reoclo/cli# or use npx and skip the global install - Authenticate. This runs an OAuth device flow in your browser:
See CLI Authentication for profile management and headless options.
Terminal window reoclo login - Node.js 18+. Required to run the CLI via
npx.
Once reoclo whoami confirms you are authenticated, you are ready to wire up your editor.
Claude Code
Section titled “Claude Code”CLI (recommended)
Section titled “CLI (recommended)”claude mcp add reoclo -- npx -y @reoclo/cli mcpThis registers the server immediately. Restart Claude Code to pick it up.
Config file
Section titled “Config file”Add to .mcp.json in your project root (or ~/.claude/mcp.json for global access):
{ "mcpServers": { "reoclo": { "command": "npx", "args": ["-y", "@reoclo/cli", "mcp"] } }}Verify
Section titled “Verify”In Claude Code, type:
/mcpYou should see reoclo listed with its tools. Try asking: “List my servers” or “Show recent deployments”.
Cursor
Section titled “Cursor”Add to .cursor/mcp.json in your project root:
{ "mcpServers": { "reoclo": { "command": "npx", "args": ["-y", "@reoclo/cli", "mcp"] } }}Restart Cursor. The MCP server appears in Settings > MCP once connected.
Windsurf
Section titled “Windsurf”Add to ~/.codeium/windsurf/mcp_config.json:
{ "mcpServers": { "reoclo": { "command": "npx", "args": ["-y", "@reoclo/cli", "mcp"] } }}Restart Windsurf. Cascade picks up the server and lists available tools automatically.
VS Code (GitHub Copilot)
Section titled “VS Code (GitHub Copilot)”VS Code supports MCP servers through GitHub Copilot Chat (agent mode). Add to .vscode/mcp.json in your project root:
{ "servers": { "reoclo": { "command": "npx", "args": ["-y", "@reoclo/cli", "mcp"] } }}After saving, open Copilot Chat in agent mode. The Reoclo tools become available.
Add to your Zed settings (~/.config/zed/settings.json):
{ "context_servers": { "reoclo": { "command": { "path": "npx", "args": ["-y", "@reoclo/cli", "mcp"] } } }}Restart Zed. The server appears in the Assistant panel’s context server list.
JetBrains (IntelliJ, WebStorm, PyCharm and others)
Section titled “JetBrains (IntelliJ, WebStorm, PyCharm and others)”JetBrains IDEs support MCP through AI Assistant. Add to .idea/mcp.json in your project root:
{ "mcpServers": { "reoclo": { "command": "npx", "args": ["-y", "@reoclo/cli", "mcp"] } }}Restart the IDE. The MCP server appears in the AI Assistant tool window.
Add via the Cline MCP settings UI (Cline > MCP Servers > Add), or edit ~/Library/Application Support/Code/User/globalStorage/saoudrizwan.claude-dev/settings/cline_mcp_settings.json (macOS) directly:
{ "mcpServers": { "reoclo": { "command": "npx", "args": ["-y", "@reoclo/cli", "mcp"] } }}After saving, Cline shows a connection indicator next to the server name. Click it to verify the tools loaded.
Other MCP clients
Section titled “Other MCP clients”Any MCP-compatible client can use the server. Run it directly:
npx -y @reoclo/cli mcpThe server communicates over stdio. Point your client at this command and it discovers tools automatically.
Available tools
Section titled “Available tools”The MCP server exposes the same surface as the CLI. Permissions match the OAuth-authenticated user’s tenant role: a viewer role will only see read tools, a developer role gets read + write, and so on.
Server setup and hardening need root on the server, so nothing runs from the MCP server itself. create_server_setup_script returns a script for someone to run on the new server, and plan_server_hardening reports the ports the firewall would block and returns the reoclo servers harden command to run. decommission_server requires the server’s slug as confirmation.
| Category | Tools |
|---|---|
| Servers | list_servers, get_server, get_server_metrics, get_server_health, check_server_health, list_containers, inspect_container, restart_container, port_scan, create_server_setup_script, plan_server_hardening, get_server_network_access, set_server_network_access, reapply_server_network_access, decommission_server |
| Applications | list_applications, get_application, get_app_config, update_app_config, trigger_deploy |
| Deployments | list_deployments, get_deployment, get_deployment_logs, get_deployment_stages, get_deployment_build_log |
| Stacks | list_application_groups, get_application_group, list_group_deployments, get_group_deployment, deploy_application_group, redeploy_group_service, run_group_task, list_group_task_runs |
| Domains | list_domains, get_domain, get_dns_overview, check_domain_health, add_domain, verify_domain |
| Logs | search_logs, live_logs, get_system_logs, get_log_usage, get_server_log_sources, get_log_stats |
| Findings | list_findings, get_finding (log watcher findings; open ones by default) |
| Monitors | list_monitors, get_monitor, create_monitor, update_monitor |
| Status Pages | list_status_pages, get_status_page, create_incident, update_incident |
| Dashboards | dashboards_list, dashboard_get, dashboard_catalog, dashboard_templates, dashboard_validate, dashboard_create, dashboard_update, dashboard_delete, dashboard_assign, dashboard_unassign, dashboard_set_default |
| Scheduled Ops | list_scheduled_operations, get_scheduled_operation, create_scheduled_operation, trigger_scheduled_operation |
| Secrets | list_secret_projects, update_secret_project, duplicate_secret_project (project metadata only; keys and values are never exposed to the model) |
| Other | whoami, list_repositories, list_env_vars, set_env_var, get_dashboard, get_audit_log |
Building dashboards
Section titled “Building dashboards”An agent can build and manage the dashboards in your organization with the dashboard tools. For what dashboards are, their panels and the permissions involved, see Dashboards. The API’s permissions and visibility apply unchanged: reading needs the dashboard permission at read, and creating, replacing, deleting, assigning and setting the default need it at write. An API key needs dashboard at write to change anything.
dashboard_cataloglists the panel types the caller may add. Each has asettings_schema, a JSON Schema that the panel’sconfigmust satisfy, and anareathat groups it in the editor.dashboard_templateslists the templates that fit the organization, each with the panels it starts with.dashboard_createstarts a dashboard blank, from a template (template_id), as a copy (duplicate_of), or from a fullpanelslist.dashboard_updatereplaces the whole dashboard. Anything you leave out is reset, so start fromdashboard_getand send the full result back with your changes.dashboard_validateis a dry run of a create or an update that saves nothing. Call it before a write to get every problem in one pass.
Panels sit on a 12-column grid, placed with x, y, w and h, and must not overlap. A panel sent without layout is placed by the server. An organization holds at most 20 dashboards. A dashboard is visible to "everyone" or to {"roles": [role ids]}.
When Reoclo refuses a write because the dashboard has problems, the tool returns an error with a problems list. Each problem has a path into the request, for example panels[2].layout, a code and a message, so the agent can fix every one and retry.
dashboard_assign gives a role a dashboard, optionally locked so its members cannot pick another. dashboard_unassign removes it. dashboard_set_default sets the organization default, or clears it when the dashboard is null.
Configuration
Section titled “Configuration”The MCP server reads its configuration from your CLI profile. Optional overrides:
| Variable | Description |
|---|---|
REOCLO_PROFILE | Use a specific CLI profile (defaults to the active one) |
REOCLO_API_URL | Override the API endpoint (defaults to the profile’s api_url) |
There is no REOCLO_API_KEY variable. Credentials come from reoclo login, not env vars.
Troubleshooting
Section titled “Troubleshooting”Server not appearing
Section titled “Server not appearing”- Verify Node.js 18+ is installed:
node --version - Test the server manually:
npx -y @reoclo/cli mcp(it should print MCP protocol JSON on stdin/stdout) - Make sure your editor restarted after config changes
”Not authenticated” error
Section titled “”Not authenticated” error”Run reoclo whoami. If it errors, run reoclo login to refresh credentials.
Wrong tenant
Section titled “Wrong tenant”If you belong to multiple tenants, the MCP server uses the profile’s active tenant. Either:
- Set
REOCLO_PROFILEin the MCPenvblock to a profile that points at the right tenant, or - Run
reoclo profile use <name>to change the default profile.
No tools listed
Section titled “No tools listed”The tool set is filtered by the OAuth-authenticated user’s role. Confirm with reoclo whoami that the active profile is on the expected tenant with the expected role.
Token refresh failed
Section titled “Token refresh failed”OAuth tokens refresh automatically. If you see a session-expired error, run reoclo login once to restart the device flow.
Next steps
Section titled “Next steps”- CLI Authentication: profiles, keyring storage, headless flows
- CLI Getting Started: common commands and conventions
- API Keys: Automation Keys for CI/CD pipelines