Skip to main content
Current release: 0.81.0 · What’s New · Maven Central · GitHub A pure Java implementation of the Agent Client Protocol (ACP), the standard that lets editors such as Zed, JetBrains IDEs and VS Code talk to coding agents. Build agents that any ACP client can connect to, or build clients that drive any ACP agent. Java 17+.

An agent is one annotated class

That is a complete ACP agent. Everything else is derived from the class:
  • initialize is answered for you. agentInfo comes from @AcpAgent, and each handler method advertises the capability it implements. There is no @Initialize method to write.
  • session/new is answered for you with a generated session id, until you add a @NewSession method of your own.
  • A String return is the reply. It is streamed to the client as an agent message, and the turn ends. Return a PromptResponse, a Mono or a CompletionStage when you need more control.
Add a method, gain a capability: @LoadSession, @ListSessions, @ResumeSession, @CloseSession and @Logout each advertise theirs automatically, and @Prompt(image = true) declares the prompt content you accept. Everything else in the protocol is one annotation away too: @Cancel, @Authenticate, @SetSessionConfigOption, and @ExtRequest for methods of your own. Take a SyncPromptContext parameter to stream progress, ask the client for permission, or check for cancellation. Mistakes, such as two @Prompt methods or a parameter nothing can supply, fail when the agent is built, naming the class, the method and the fix. See Clients and Agents for the full model.

The lower-level APIs are still there

When you want to wire every handler yourself, write the same agent with the sync or async builder. All three styles speak the same protocol.

One agent, every Java framework

The same EchoAgent runs on Spring Boot, Micronaut and Quarkus, and in plain Java with no framework at all. The handler class doesn’t change. Only the startup differs: how the framework learns that the class is a bean, and how the application starts. On Quarkus the class is used exactly as written.
No framework and no container: one dependency and a three-line main.
Clients and Agents →
Each of these starts as a stdio agent, the way an editor launches one. To serve the same agent to remote clients over Streamable HTTP and WebSocket, set one property: spring.acp.agent.transport.type=http, acp.agent.transport.type=http or quarkus.acp.agent.transport.type=http. Spring Boot and Micronaut also need the HTTP module their page names. In a Spring Boot web application, and in Quarkus, the agent is mounted on the application’s own server, behind its own security. See Transports for every deployment shape, plain Java included.
This is tested, not just documented. Every release is gated on a framework smoke matrix: one shared handler class, hosted by Spring Boot (servlet and WebFlux), Micronaut and Quarkus, is driven by the TypeScript SDK over stdio, Streamable HTTP and WebSocket. See Cross-SDK Compatibility.

Getting Started

Overview

How ACP works, client and agent quick starts, adding the SDK to your build

Clients and Agents

The annotation model in full, and when to choose sync or async

First Contact

Launch an agent, create a session, send your first prompt

Upgrading from 0.18

Every breaking change in 0.80.0, and how to migrate

Tutorials

Progressive, runnable modules, each with integration tests:

Client Basics

Sessions, prompts, streaming updates, permissions, cancellation, errors

Building Agents

A first agent, handlers, sending updates, in-memory testing, capabilities, MCP servers

Frameworks

The annotated agent on Spring Boot, Micronaut and Quarkus

Remote Agents

Serve an agent over Streamable HTTP and WebSocket, one runtime per connection

Reactive

Async client and agent with Project Reactor

IDE Integration

Run your agent in Zed, JetBrains IDEs and VS Code

Reference

Java API Reference

Client and agent classes, protocol types, transports, error codes

Concepts

Sessions, capabilities, the framework-neutral layer, where handlers run

Source Code

The SDK, including the Spring Boot, Micronaut and Quarkus integrations

Tutorial Code

Every tutorial module, runnable