Skip to main content

Overview

ACP is the Agent Client Protocol, a JSON-RPC based protocol for communication between clients and AI coding agents. When using Broker with the ACP protocol, Broker will launch your agent binary and exchange bidirectional JSON-RPC messages over stdin / stdout. For the full specification and official TypeScript SDK: Open source agents that support ACP include OpenCode and Goose.

Getting started

To try out fully working code examples, check out the axon-broker-agents example repo. Clone the repo and run the test commands. The example will create a Devbox with OpenCode and start a “hello world” conversation by publishing an Axon event.

Broker mount configuration

Create a Devbox with a broker_mount to bind an Axon stream to the ACP adapter:

How Broker uses ACP

  1. Broker launches your registered binary with arguments
  2. Your client initializes and sets up the agent for the interaction
  3. Your client starts and initiates the session by publishing ACP session events to the Axon
  4. Broker forwards those messages to your running agent
  5. Agent output streams back through Axon as <update_type> events

Send a simple message to an ACP agent

Create a Devbox with an ACP Broker mount and send a ‘hello world’ message to the agent.
1

Create Devbox with Broker

Create an Axon for communication and launch a Devbox with an ACP-compatible agent (OpenCode) mounted via Broker:
2

Initialize and Create Session

Send the ACP initialize and session/new requests to set up the agent:
3

Prepare Prompt

Prepare the prompt value so you can register timeline listeners before calling prompt() in the next step:
4

Stream Agent Response

Subscribe to the Axon stream and print agent responses:

Cancel a turn

Often, you’ll want to interrupt an in-progress turn or conversation.

Handling agent plans and permissions

ACP agents can propose plans for structured, multi-step work. Agents also request permissions for actions like file access or command execution. Currently, Broker automatically accepts all ACP permission requests, allowing agents to proceed with their planned operations.

Building a complete integration

The examples above cover the basics of launching an ACP agent and exchanging messages. To build a production-ready integration, you should become familiar with the full ACP state machine — understanding how sessions transition between states like idle, working, and completed will help you handle edge cases and build reliable orchestration logic. ACP also supports advanced features beyond simple prompting, including: All of these capabilities are fully supported over ACP + Broker. See the ACP specification for complete protocol details.