Claude Code Now Has a Remote Control API

FEB 25DEV4 MIN READ272165 COMMENTS

Anthropic just made Claude Code significantly more interesting for anyone building automated development pipelines.

The short version: Claude Code now has a remote control API. Instead of only operating interactively through the CLI — where a human sits at a terminal, types requests, and reviews output — you can now drive Claude Code instances programmatically. You send it tasks via API, it executes them autonomously, and you get results back. The documentation lives at code.claude.com/docs/en/remote-control.

CI/CD and Agent-to-Agent Orchestration

The use cases this unlocks are straightforward and immediately useful. The most obvious is CI/CD integration: instead of Claude Code being a tool you use during development, it becomes a step in your pipeline. A PR comes in, your CI system spins up a Claude Code instance, asks it to review the diff for security issues or test coverage gaps, and posts the results as a comment — no human in the loop. You've seen this pattern with static analysis tools for years. Claude Code is now pluggable into the same slots, but with the ability to reason about code rather than just pattern-match against rules.

The more interesting case is agent-to-agent orchestration. One AI system can now programmatically control Claude Code as a sub-agent. If you're building an autonomous development workflow — say, an orchestrator that breaks down a feature request, assigns subtasks, and coordinates execution across multiple specialized agents — Claude Code becomes a composable component rather than a standalone tool. Your orchestrator doesn't need to know how to write code. It just needs to know how to write a task description and hand it off.

The Trust Model Changes

This is worth thinking about carefully, because it changes the trust model. When a human drives Claude Code interactively, there's a review loop at every meaningful decision point. When another AI drives Claude Code programmatically, that loop is either automated or absent entirely. You're trusting the orchestrator's judgment about what to ask Claude Code to do, and you're trusting Claude Code's judgment about how to do it, and those errors can compound before a human sees the output. The controls you put around the remote API — what permissions the Claude Code instance has, what it can touch in your repo, how changes are staged before commit — matter a lot more in this mode.

From a practical standpoint, the API enables patterns that developers have been hacking together manually for a while. People have been scripting Claude Code via CLI wrappers and expect-style automation for months. A proper API with documented behavior and stable interfaces is a significant upgrade over that. The broader trajectory is clear: AI coding tools are moving from interactive assistants to autonomous pipeline components.

Sandboxing and Permissions Matter

The sandboxing question is the one engineering teams should think through before adopting the remote API in earnest. A human-driven Claude Code session has implicit scope limits — the developer sees what Claude is doing and can interrupt. A programmatically-driven instance needs explicit scope: which directories can it read, which can it write, can it run shell commands, can it install packages, can it make network requests. These defaults need to be tighter than what you'd use interactively, because there's no human in the loop to catch something going sideways.

The teams that will get the most out of this are the ones who treat Claude Code instances like any other service: with minimal permissions, clearly defined inputs and outputs, logging at every step, and a human review gate before anything merges. The remote API is additive if you have that discipline. It's a liability if you treat it as a fire-and-forget code generation machine. The pattern that will work is: AI generates, automated tests validate, human reviews summary and diff, CI merges. Claude Code fits cleanly into step one of that pipeline.

// ENGLISH
KEY POINTS:

- Claude Code now controllable via remote API (not just interactive CLI)
- Enables CI/CD pipelines with Claude Code as an autonomous review/coding step
- Agent-to-agent orchestration: one AI can drive Claude Code as a sub-agent
- Trust model changes significantly — human review loop becomes optional
- Replaces months of CLI wrapper hacks with a stable documented API
- Documented at code.claude.com/docs/en/remote-control
- AI coding tools moving from interactive assistants to pipeline components