Research Brief · Prepared by Chief · March 12, 2026
Topics: Claude Code CLI · MCP Protocol · Remote Control · System Management · Security
Claude Code is Anthropic's agentic CLI — a terminal-based AI coding assistant that goes well beyond autocomplete. It reads your entire codebase, executes shell commands, modifies files, manages git workflows, and can spawn up to 10 parallel sub-agents to work on problems in isolated contexts.
As of early 2026, 4% of all public GitHub commits (~135,000/day) are authored by Claude Code — a 42,896× growth in 13 months. 90% of Anthropic's own code is AI-written using it.
We already use Claude Code via OpenClaw for spawning coding tasks. But Claude Code has grown well beyond a coding tool — it's becoming a general system management interface with MCP, hooks, and remote control features that are directly relevant to how we run our infrastructure.
Claude Code's power comes from five layered systems that most people never touch:
| System | What It Does | Relevance to Us |
|---|---|---|
| Configuration | CLAUDE.md / settings.json files at project and global level control behavior, model choice, and defaults | High — define rules per repo (provider-search, cms-data, enterprise-assistant) |
| Permission System | Granular allow/block rules for tools and bash commands. --permission-mode can range from plan-only to full bypass |
Critical — prevents runaway commands on production servers; essential for CI/CD spawns |
| Hook System | Shell commands that fire deterministically on specific events (pre-tool, post-tool, stop, notification). Hooks always execute regardless of model behavior | High — auto-lint, format, test on every edit. Hooks > prompts for things that must always happen |
| MCP Protocol | Model Context Protocol — connects Claude to external services. Claude Code can both consume MCP servers AND be an MCP server | Epic — see dedicated section below |
| Subagents | Spawn up to 10 parallel agents in isolated contexts. Each returns only a summary to the main session — keeps context clean | High — already using via OpenClaw; better delegation = less context bloat |
claude remote-control in your local terminal → scan a QR code → your entire local session (same conversation, same context, same files, same MCP servers) is now live on your phone or Claude.ai in the browser.
How it works: Claude Code opens a tunnel to Anthropic's relay servers. Your phone connects through the Claude iOS/Android app or claude.ai/code. Everything is end-to-end — the code still executes locally on your machine, you just control it from anywhere.
This is where things get genuinely interesting for our stack. MCP works two ways with Claude Code:
Claude Code connects to external tools and services during a session. No copy-paste, no context switching. One command to add:
claude mcp add github \ --transport http \ https://mcp.github.com
3,000+ integrations available: GitHub, Postgres, Sentry, Linear, Figma, Slack, and more.
Run Claude Code as an MCP server so other tools can call into it:
claude mcp serve
This means your enterprise assistant in Azure can make tool calls directly to a running Claude Code session on your local machine or a server.
Launched alongside Remote Control: tools like Sentry, Linear, and Figma can now connect directly to Claude Code over HTTP — no local server process needed at all. Just add the remote URL and you're live.
Here's the vision you were hinting at — using Claude Code CLI as the management layer for our infrastructure:
| Use Case | How | Status |
|---|---|---|
| Manage Hetzner servers (CMS pipeline, provider search) | SSH into server → run claude with MCP connected to Postgres/DuckDB → natural language queries and operations |
Ready to try |
| Manage Azure resources (enterprise assistant) | Add Azure MCP server: claude mcp add azure --transport http <azure-mcp-endpoint> → manage Container Apps, check logs, restart services by talking to Claude |
Needs MCP setup |
| GitHub ops (PRs, CI, issues) | GitHub MCP already exists → claude mcp add github --transport http https://mcp.github.com |
One command |
| Database management (DuckDB / Postgres / Supabase) | Postgres MCP → natural language queries, schema inspection, data operations without raw SQL | Supported |
| Enterprise assistant as MCP client | Your Azure agent could call claude mcp serve on a server — effectively using Claude Code as a tool-execution engine |
Architecture play |
| OpenClaw + Claude Code bridge | OpenClaw already calls Claude Code via ACP. But with claude mcp serve, OpenClaw could call specific Claude Code capabilities as discrete tool calls |
Future exploration |
| Mode | What Happens | Best For |
|---|---|---|
--permission-mode plan |
Claude can only plan and read — no writes, no commands | Reviewing PRs, exploring unfamiliar codebases |
--permission-mode default |
Asks before every sensitive operation | Normal interactive work |
--permission-mode acceptEdits |
Auto-accepts file edits, still asks for bash | Trusted coding sessions |
--permission-mode bypassPermissions |
No prompts at all — fully autonomous | CI/CD, overnight coding agents (what we use via spawn script) |
For managed deployments (e.g., we want to configure Claude Code across client environments), there's a managed-mcp.json system designed for IT admins — system-wide MCP config that users can't override. This is interesting for selling to health systems: we could pre-configure Claude Code with their internal tools and lock down what it can access.
Hooks are deterministic shell commands tied to events in a Claude Code session. Unlike prompts (which Claude can ignore), hooks always execute.
| Hook Event | Fires When | Example Use |
|---|---|---|
PreToolUse |
Before any tool call | Block certain commands; log every operation; validate inputs |
PostToolUse |
After a tool call completes | Run linter after every file edit; auto-format; trigger tests |
Stop |
Session ends | Git commit changes; send completion notification; clean up |
Notification |
Claude wants to alert you | Route to Telegram instead of terminal; custom sound; log to file |
"Use hooks for anything that must always execute. Hooks guarantee execution; prompts do not."
This is exactly the pattern we've been doing manually with our spawn-agent.sh wrapper script. Hooks could formalize that: auto-git-commit after session, auto-notify Telegram on stop, auto-test after file edits.
# Basic sessions claude # interactive claude -p "fix the auth bug" # one-shot, exits claude -c # resume last session # MCP management claude mcp add github --transport http https://mcp.github.com claude mcp add postgres --transport stdio -- npx -y @modelcontextprotocol/server-postgres claude mcp list # see what's connected claude mcp serve # expose THIS instance as MCP server # Remote Control (new Feb 2026) claude remote-control # scan QR → control from phone/claude.ai # Agents claude agents # list configured subagents # Auth claude auth status # check login state claude auth login --sso # enterprise SSO login # Permission modes claude --permission-mode plan # read-only, planning only claude --permission-mode bypassPermissions # fully autonomous (CI/CD)
claude remote-control on your Mac once, scan with Claude app on phone. Just to see it workSources: code.claude.com/docs (official Claude Code documentation, March 2026) · blakecrosley.com/guides/claude-code (comprehensive CLI guide, updated March 11, 2026) · claudefa.st/blog/guide/development/remote-control-guide (Remote Control feature overview) · releasebot.io/updates/anthropic/claude-code (release notes) · builder.io/blog/claude-code-mcp-servers (MCP setup guide)
Report prepared by Chief · March 12, 2026 · Internal use only