> ## Documentation Index
> Fetch the complete documentation index at: https://lab.pollack.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# What's New 0.83.0

> The caller in _meta, the signed-in user reaching @AcpAgent handlers, queued turns, the forwarder, and a separate timeout for the requests that wait for a person

ACP Java SDK 0.83.0 (2026-12-02) carries who is asking through an agent: the signed-in user reaches the agent's
handlers per message in Spring Boot, Micronaut and Quarkus, a client names the person a request is
for in `_meta`, and an agent that is the client of another agent passes both on. Breaking changes are
marked **Breaking**; pre-1.0, they come without compatibility shims. The source of every statement
here is the [`v0.83.0` changelog](https://github.com/agentclientprotocol/java-sdk/blob/v0.83.0/CHANGELOG.md).

## The caller in `_meta`

A client names the person a request or response is for in its `_meta`, under
`"agentclientprotocol.com/java-sdk/caller"` (`AcpCaller.META_KEY`), as
`{"id":...,"name":...,"attributes":{...}}`; `name` and `attributes` are left out when empty. The wire
format beyond `_meta` does not change. `AcpCaller` is in acp-core, package
`com.agentclientprotocol.sdk.spec`:

* `caller.addToMeta(meta)` returns a new `_meta` with the caller added, and `AcpCaller.fromMeta(meta)`
  reads one back, leniently: a missing or malformed caller is empty, never an error.
* **A prompt turn passes its caller on.** During a turn whose `PromptRequest` names a caller, every
  permission request (`askPermission`, `askChoice`, `client().requestPermission`) and elicitation
  (`client().createElicitation`) the agent sends through its `PromptContext` or `SyncPromptContext`
  carries that caller, unless the request names one itself. File, terminal and extension requests go
  as given.
* **The answerer may be someone else.** The answer's `_meta` is the client's: read who answered with
  `AcpCaller.fromMeta(response.meta())`.
* **`PromptContext.getCaller()` and `SyncPromptContext.getCaller()`** return the turn's caller, or null.
* **The caller is derived from the signed-in user.** A client that sends with an identity adds
  `AcpCaller.of(identity)`, `{"id": subject, "attributes": {"issuer": ...}}` and nothing else of the
  identity, to the `_meta` of `session/new`, `session/load`, `session/resume`, `session/fork` and
  `session/prompt`, and of a permission or elicitation answer, unless the message names a caller. So
  the user reaches a downstream agent or an agentic CLI, whose processes the identity cannot enter.

A caller stays the client's claim: there is no "verified" flag, and it is never authentication.

## The signed-in user reaches `@AcpAgent` handlers

An `AcpIdentity` (acp-core, `com.agentclientprotocol.sdk.identity`) is a subject, a nullable issuer,
the user's authorities, and the security framework's own object for the user. The SDK carries it
beside each message inside the JVM, never on the wire: the in-memory transport and the HTTP endpoint
hand each inbound message to the agent with its own identity, notifications included. Over stdio,
and for an unauthenticated request, there is none and nothing changes.

A handler method of an `@AcpAgent` can take:

* an `AcpIdentity` or `java.security.Principal` parameter: the message's signed-in user, or null (the
  `Principal` is the framework's own object when it is one);
* an `AcpCaller` parameter: the request's declared caller, or null. The SDK does not reconcile the
  caller with the identity.

A handler also reads the identity from `PromptContext.getIdentity()` or `SyncPromptContext.getIdentity()`,
from its Reactor context (`AcpIdentityContext.read(ctx)`), or on a synchronous handler's thread from
`AcpIdentityContext.current()`.

| Framework | What 0.83.0 adds, with its security framework on the classpath |
| - | - |
| Spring Boot | `AcpSecurityAutoConfiguration` maps each HTTP request's `Authentication` (servlet and WebFlux) to its message's identity, captures the sending request's user for the in-process client, and runs each handler with that `Authentication` in the `SecurityContextHolder`, so `@PreAuthorize` on the agent bean works (with `@EnableMethodSecurity`). Handler methods take `Authentication` or `@AuthenticationPrincipal` parameters. |
| Quarkus | Each handler runs in a CDI request context of its own whose `CurrentIdentityAssociation` holds the message's `SecurityIdentity`, so `@RolesAllowed` on the agent bean and an injected `SecurityIdentity` work. `AcpSecurityIdentityMapper` maps the principal's name, roles and a JWT's `iss`. |
| Micronaut | `AcpSecurityBeans` map each request's `Authentication`, and `AcpSecurityService` answers `SecurityService.username()`, `getAuthentication()` and `hasRole(..)` with the message's user inside a handler. Handler methods take an `Authentication` parameter. `@Secured` guards routes, not agent methods. |

In process, the client captures the user when it sends (`AcpClient.sync(..).identityCapture(capture)`,
or `async`): one client connection serves every user of the application, and each message goes as
the user of the request that sent it.

With identities, **sessions belong to their creator.** The default `AcpSessionAccess.ownerOnly()`
answers `-32002` (Resource not found) to a session-scoped request on another user's session and
drops such a `session/cancel`; `session/list` lists only the sessions the caller may use. An
application whose users share sessions sets `sessionAccess(AcpSessionAccess.anyone())`, or a
membership check of its own. See the breaking changes below.

## Queued turns: `acp-turn-queue`

A new optional module, `com.agentclientprotocol:acp-turn-queue`, for applications where several
people share one session. `AcpTurnQueue` (`com.agentclientprotocol.sdk.client.queue`) queues prompt
turns per session over an `AcpSyncClient` or `AcpAsyncClient`:

* `submit(PromptRequest)` returns a `QueuedTurn` whose `response()` is a
  `CompletableFuture<PromptResponse>`. A session's turns are sent one at a time, in submission order,
  each once the agent has answered the one before; sessions do not wait for each other, and the queue
  starts no thread.
* Each turn is sent as the request that was submitted, so its `_meta` and caller reach the agent
  unchanged, and as the user who submitted it, however long it waited.
* A prompt that should reflect what happened while it waited is submitted as a supplier,
  `submit(sessionId, caller, () -> request)`, called once when the turn starts.
* At most `maxWaitingTurns` (default 32) wait per session; one more is refused with
  `TurnQueueFullException` before anything is sent.
* `QueuedTurn.cancel()` removes a waiting turn, or stops the running one with `session/cancel`;
  `cancelAll(sessionId)` and `close()` do the same for a session and for the whole queue.
* For chat UIs: `waitingTurns(sessionId)`, `turns(sessionId)`, and a `TurnListener` with
  `turnStarted(turn)` and `turnFinished(turn, response, error)`, called after the turn's `response()`
  has completed and before the session's next turn starts.

The module depends on acp-core only and is not part of the ACP specification; the core's single-turn
rule is unchanged. The framework integrations do not create a queue: declare it as a bean.

## The forwarder: an agent that is the client of another agent

`AcpForwarder` (acp-core, `com.agentclientprotocol.sdk.forward`) forwards an upstream turn to a
downstream agent. Build the downstream client with `forwarder.sessionUpdateHandler()` and
`forwarder.requestPermissionHandler()` (or `syncSessionUpdateHandler()` and
`syncRequestPermissionHandler()`), and prompt it from the upstream prompt handler with
`forwarder.forward(context, downstream, request)`, for a `PromptContext` and an `AcpAsyncClient`, or a
`SyncPromptContext` and an `AcpSyncClient`, from a builder agent or an `@AcpAgent` alike. For that call:

* the downstream session's updates go to the upstream client through the upstream turn, in order;
* its permission requests go through the upstream context, with the upstream session ID and the
  upstream turn's caller, and the answer, with the answerer's caller, goes back down unchanged;
* the downstream prompt is sent as the upstream turn's user (an in-process downstream agent sees the
  identity; any downstream gets the derived caller);
* cancelling the upstream turn sends the downstream agent `session/cancel`.

One forwarder serves concurrent sessions. `AcpForwarder.create(Consumer, Audit)` takes an audit hook
that hears of each forwarded prompt and permission answer (`AcpForwarder.Event`: kind, the upstream
and downstream session IDs, the identity and the caller). Choosing the downstream process,
credentials and workspace per user stays the application's: use `context.getIdentity()` to pick the
downstream client.

## `userResponseTimeout`: a separate timeout for requests that wait for a person

`userResponseTimeout` bounds how long the agent waits for an answer to `session/request_permission`
and `elicitation/create`, so a person can take minutes while a file read, a terminal call or an
extension request still fails at `requestTimeout`. Unset, these requests wait for `requestTimeout`, as
before; `0` waits without a limit. This limit is Java SDK policy; ACP defines none.

| Where | Setting |
| - | - |
| Builders | `userResponseTimeout(..)` on `AcpAgent.AsyncAgentBuilder`, `AcpAgent.SyncAgentBuilder`, `AcpAgentSupport.Builder` and `AcpAgentSettings.Builder` |
| Spring Boot | `spring.acp.agent.user-response-timeout` |
| Micronaut | `acp.agent.user-response-timeout` |
| Quarkus | `quarkus.acp.agent.user-response-timeout` |

Once set on the synchronous builder, `AcpSyncAgent.requestPermission` and `createElicitation` are no
longer also cut off by that agent's 5-minute block timeout.

## Breaking changes, and what to do

| Change | Upgrade step |
| - | - |
| **An HTTP connection is bound to the user who opened it.** A later POST, GET or DELETE on the connection whose identity differs (by issuer and subject) is refused with 403. | Send a user's requests only on a connection that user opened. |
| **A session-scoped request for another user's session is refused** with `-32002`, where messages carry identities. | An application whose users share sessions sets `sessionAccess(AcpSessionAccess.anyone())`, or `sessionOwners(new AcpSessionOwners(AcpSessionAccess.anyone()))` on `AcpAgentSupport.Builder`, or a membership check. |
| **Micronaut serves ACP over HTTP on its own HTTP server**, behind its filters, at `acp.agent.transport.http.path` on `micronaut.server.port`. The `acp.agent.transport.http.listener.*` properties and `AcpAgentRuntime.port()` are removed. | Add `micronaut-http-server-netty`, `micronaut-websocket` and `micronaut-serde-jackson` in place of `acp-streamable-http-jetty`. Read the port from `EmbeddedServer.getPort()`. See [Micronaut](https://lab.pollack.ai/docs/acp-java-sdk/micronaut.md). |
| **`AcpAgentSettings` has a new component, `userResponseTimeout`**, after `requestTimeout`. | Code that calls the record's constructor adds the argument (`null` keeps the SDK default). `AcpAgentSettings.builder()` is unaffected. |
| **`PromptContext.getCaller()` and `SyncPromptContext.getCaller()` are new abstract methods** (source only). | A hand-written test double of either interface adds one. |
| **`ExtensionParamsResolver.isConnectionType(Class)` is removed.** It checked a parameter's type against a fixed set of three types. The check is now made per parameter (`AcpMethodParameter`): `ExtensionParamsResolver.surroundings()` returns the built-in resolvers whose values an extension method can take besides its params (`CapabilitiesResolver`, `AgentResolver`, `AcpCallerResolver`, `AcpIdentityResolver` and `PrincipalResolver`), and the params are the parameter none of them, and none of the agent's custom resolvers, supplies. The agent's own custom resolvers now work on extension methods, because the runtime asks them before `surroundings()`. An extension method with more than one params parameter is now refused with `IllegalStateException` when the agent is built, not when the bean is added. | To ask whether the runtime, rather than the params, fills a parameter: `new ArgumentResolverComposite().addResolvers(ExtensionParamsResolver.surroundings()).supportsParameter(parameter)`. |

Also changed, without an upgrade step:

* **In process, messages are handed over on a thread of the SDK's own**, one delivery thread per
  direction, in the order sent, inheriting no `InheritableThreadLocal`; on JDK 21 and later they are
  virtual threads. A handler no longer runs with the MDC, locale or request context of the thread that
  sent its message. A send now returns before the message is delivered.
* **Quarkus: a handler never joins its caller's JTA transaction.** A handler that needs a transaction
  starts its own (`@Transactional`).
* **A notification without a handler is logged at WARN once per method**, then at DEBUG.
* **Fixed: a `CancellationSignal` cancelled the moment the prompt's answer arrives sends nothing.** `prompt(request, stop)`
  stopped watching the signal only after it had passed the answer on, so cancelling the signal on the answer could still
  send a `session/cancel` for a finished turn. The client now stops watching the signal first.

## Known issues

* **Spring WebFlux on Jetty:** Jetty's connection idle timeout still closes an ACP WebSocket after 30
  seconds without traffic. Set `server.jetty.connection-idle-timeout` (for example `30m`), or use
  Reactor Netty, the default for WebFlux.
* The outbound queues of the stdio transports and the WebSocket client are still unbounded. Bounded
  outbound queues are planned for a later release.
* **Session ownership:** `AcpSessionOwners` keeps each owner in memory until `session/delete`; a
  session loaded but never created by this agent admits any user unless the application records its
  owner (`AcpSessionOwners.record`); in process, where one connection serves every user,
  `$/cancel_request` is not checked against the user of the request it cancels (over HTTP a connection
  belongs to one user).

For the previous release, see [What's New 0.82.0](https://lab.pollack.ai/docs/acp-java-sdk/whats-new-0.82.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.