Added
- Stable
session/delete:Agent.DeleteSessionis now required,(*ClientSideConnection).DeleteSessionis exported, and advertised viaAgentCapabilities.SessionCapabilities.Delete(#98). - New
acp.SchemaVersionconstant ("1.13.7") andacp.ProtocolMethodCancelRequest("$/cancel_request"); SDK semver is now decoupled from the schema pin (#90). - Stable
MessageIdtype on message chunks; stableusage_updatedoc comments;Meta map[string]anyadded toCost,Usage,UnstableElicitationSchema, and unstable NES/provider/document types (#98). - Scoped elicitation constructors:
NewUnstableCreateElicitationRequestFormSession/Requestand…UrlSession/Request(#95).
Fixed
- Data race on
Connection.logger: field is now anatomic.Pointer[slog.Logger](#59 by @dimetron). - Inbound requests now wait for notifications that arrived earlier on the same wire (#56 by @abietic).
- Notification handlers can now make requests on their own connection without deadlocking — pass the handler's context (#68).
- Closed the cancel-lost and nested-request deadlock gaps opened by the barrier work, with bounded cancel-marker state (#71).
session/cancelnow only cancels prompts sent before it, the newer of two overlapping prompts wins, and both the notification and request forms ofsession/cancelare ordered on one clock (#86, #88, #89).- Generated
UnmarshalJSONhonorsx-deserialize-default-on-error,-skip-invalid-items, and-default-on-nullhints; required arrays encode as[]instead ofnull(#94). - Structs with defaults decode in place, and type errors now name the struct and JSON path (e.g.
InitializeResponse.agentCapabilities.loadSession) (#93). - Unions keep
_meta,annotations, and their own properties across a JSON round trip; decoding starts from an empty wrapper (#95). - Unions dispatch on their discriminator value: unknown discriminators are errors (not a silent first-variant match),
ToolKindreads unknown kinds asother, and catch-all structs preserve unknown keys inAdditionalProperties(#97). ErrorCodedecodes to the variant matching its numeric code (-32601→MethodNotFound); unknown codes →Other. Previously every code setParseError(#100).example/agent: prompt turn ends when the request is cancelled (#67);example/client,example/claude-code, andexample/geminiprint tool-call status instead of a pointer and cancel permission prompts on EOF (#66); examples share one stdin reader so piped input no longer loses permission answers (#77).
Changed
- Tracks ACP schema 1.13.7 (was 0.13.5) (#98).
- Build tooling:
make versionis replaced bymake generate;make release VERSION=<sdk> [SCHEMA=<schema>]prepares a release PR; schema assets for 1.x are fetched fromschema-v<version>tags (#90). example/claude-codenow starts@agentclientprotocol/claude-agent-acp(#90).
Removed
UnstableDeleteSessionRequest,UnstableDeleteSessionResponse,AgentExperimental.UnstableDeleteSession, and(*ClientSideConnection).UnstableDeleteSession— superseded by the stablesession/deleteAPI (#98).- Unstable
ClientCapabilities.PlanCapabilities(renamed toPlan),PromptRequest.MessageId, andPromptResponse.UserMessageId(#98). NewUnstableCreateElicitationRequestFormandNewUnstableCreateElicitationRequestUrl— replaced by scoped constructors (#95).