acp library

Shared Agent Client Protocol wire primitives.

Classes

AcpAgent
Stable ACP v1 implementation of the protocol-neutral Agent API.
AcpError
ACP stable-v1 Error.
AcpField<T extends Object>
A wire field that distinguishes absence, an explicit null, and a value.
AcpFieldAbsent<T extends Object>
An AcpField that was not present in the wire object.
AcpFieldNull<T extends Object>
An AcpField that was present with the JSON value null.
AcpFieldValue<T extends Object>
An AcpField that was present with a non-null value.
AcpFileSystemService
AcpTerminalService
AcpTransport
Framed, JSON-value transport used by ACP connections.
AcpTransportDecorator
Advanced launch hook for executors that observe an ACP transport.
AcpV1Connection
AcpV1Methods
AcpV1NotificationRoute<Parameters extends Object>
AcpV1RequestRoute<Parameters extends Object, Result extends Object>
AcpV1Route
AcpV1SessionUpdate
AcpWireErrorDetail
ACK-independent diagnostic detail for a failure at the ACP wire boundary.
AgentAuthCapabilities
ACP stable-v1 AgentAuthCapabilities.
AgentCapabilities
ACP stable-v1 AgentCapabilities.
AgentClientServices
AgentLaunchCommand
AgentNotification
ACP stable-v1 AgentNotification.
AgentRequest
ACP stable-v1 AgentRequest.
AgentResponse
ACP stable-v1 AgentResponse.
AgentResponseError
AgentResponseResult
Annotations
ACP stable-v1 Annotations.
AudioContent
ACP stable-v1 AudioContent.
AuthenticateRequest
ACP stable-v1 AuthenticateRequest.
AuthenticateResponse
ACP stable-v1 AuthenticateResponse.
AuthMethod
ACP stable-v1 AuthMethod.
AuthMethodAgent
ACP stable-v1 AuthMethodAgent.
AuthMethodAgentVariant
AuthMethodId
ACP stable-v1 AuthMethodId.
AvailableCommand
ACP stable-v1 AvailableCommand.
AvailableCommandInput
ACP stable-v1 AvailableCommandInput.
AvailableCommandInputUnstructured
AvailableCommandsUpdate
ACP stable-v1 AvailableCommandsUpdate.
BlobResourceContents
ACP stable-v1 BlobResourceContents.
BooleanConfigOptionCapabilities
ACP stable-v1 BooleanConfigOptionCapabilities.
BooleanPropertySchema
ACP stable-v1 BooleanPropertySchema.
CancelNotification
ACP stable-v1 CancelNotification.
CancelRequestNotification
ACP stable-v1 CancelRequestNotification.
ClientCapabilities
ACP stable-v1 ClientCapabilities.
ClientNotification
ACP stable-v1 ClientNotification.
ClientRequest
ACP stable-v1 ClientRequest.
ClientResponse
ACP stable-v1 ClientResponse.
ClientResponseError
ClientResponseResult
ClientSessionCapabilities
ACP stable-v1 ClientSessionCapabilities.
CloseSessionRequest
ACP stable-v1 CloseSessionRequest.
CloseSessionResponse
ACP stable-v1 CloseSessionResponse.
CompleteElicitationNotification
ACP stable-v1 CompleteElicitationNotification.
ConfigOptionUpdate
ACP stable-v1 ConfigOptionUpdate.
Content
ACP stable-v1 Content.
ContentBlock
ACP stable-v1 ContentBlock.
ContentBlockAudio
ContentBlockImage
ContentBlockResource
ContentBlockText
ContentChunk
ACP stable-v1 ContentChunk.
Cost
ACP stable-v1 Cost.
CreateElicitationRequest
ACP stable-v1 CreateElicitationRequest.
CreateElicitationRequestForm
CreateElicitationRequestUnknown
CreateElicitationRequestUrl
CreateElicitationResponse
ACP stable-v1 CreateElicitationResponse.
CreateElicitationResponseAccept
CreateElicitationResponseCancel
CreateElicitationResponseDecline
CreateElicitationResponseUnknown
CreateTerminalRequest
ACP stable-v1 CreateTerminalRequest.
CreateTerminalResponse
ACP stable-v1 CreateTerminalResponse.
CurrentModeUpdate
ACP stable-v1 CurrentModeUpdate.
DeleteSessionRequest
ACP stable-v1 DeleteSessionRequest.
DeleteSessionResponse
ACP stable-v1 DeleteSessionResponse.
Diff
ACP stable-v1 Diff.
ElicitationAcceptAction
ACP stable-v1 ElicitationAcceptAction.
ElicitationCapabilities
ACP stable-v1 ElicitationCapabilities.
ElicitationContentValue
ACP stable-v1 ElicitationContentValue.
ElicitationContentValueBoolean
ElicitationContentValueInteger
ElicitationContentValueNumber
ElicitationContentValueString
ElicitationContentValueStringArray
ElicitationFormCapabilities
ACP stable-v1 ElicitationFormCapabilities.
ElicitationFormMode
ACP stable-v1 ElicitationFormMode.
ElicitationFormModeRequest
ElicitationFormModeSession
ElicitationId
ACP stable-v1 ElicitationId.
ElicitationPropertySchema
ACP stable-v1 ElicitationPropertySchema.
ElicitationPropertySchemaArray
ElicitationPropertySchemaBoolean
ElicitationPropertySchemaInteger
ElicitationPropertySchemaNumber
ElicitationPropertySchemaString
ElicitationPropertySchemaUnknown
ElicitationRequestScope
ACP stable-v1 ElicitationRequestScope.
ElicitationSchema
ACP stable-v1 ElicitationSchema.
ElicitationSchemaType
ACP stable-v1 ElicitationSchemaType.
ElicitationSchemaTypeObject
ElicitationSessionScope
ACP stable-v1 ElicitationSessionScope.
ElicitationUrlCapabilities
ACP stable-v1 ElicitationUrlCapabilities.
ElicitationUrlMode
ACP stable-v1 ElicitationUrlMode.
ElicitationUrlModeRequest
ElicitationUrlModeSession
EmbeddedResource
ACP stable-v1 EmbeddedResource.
EmbeddedResourceResource
ACP stable-v1 EmbeddedResourceResource.
EmbeddedResourceResourceBlobResourceContents
EmbeddedResourceResourceTextResourceContents
EnumOption
ACP stable-v1 EnumOption.
EnvVariable
ACP stable-v1 EnvVariable.
ErrorCode
ACP stable-v1 ErrorCode.
ErrorCodeAuthenticationRequired
ErrorCodeInternalError
ErrorCodeInvalidParams
ErrorCodeInvalidRequest
ErrorCodeMethodNotFound
ErrorCodeOther
ErrorCodeParseError
ErrorCodeRequestCancelled
ErrorCodeResourceNotFound
ExtNotification
ACP stable-v1 ExtNotification.
ExtRequest
ACP stable-v1 ExtRequest.
ExtResponse
ACP stable-v1 ExtResponse.
FileSystemCapabilities
ACP stable-v1 FileSystemCapabilities.
HttpHeader
ACP stable-v1 HttpHeader.
ImageContent
ACP stable-v1 ImageContent.
Implementation
ACP stable-v1 Implementation.
InitializeRequest
ACP stable-v1 InitializeRequest.
InitializeResponse
ACP stable-v1 InitializeResponse.
IntegerPropertySchema
ACP stable-v1 IntegerPropertySchema.
JsonRpcErrorCodes
KillTerminalRequest
ACP stable-v1 KillTerminalRequest.
KillTerminalResponse
ACP stable-v1 KillTerminalResponse.
ListSessionsRequest
ACP stable-v1 ListSessionsRequest.
ListSessionsResponse
ACP stable-v1 ListSessionsResponse.
LoadSessionRequest
ACP stable-v1 LoadSessionRequest.
LoadSessionResponse
ACP stable-v1 LoadSessionResponse.
LogoutCapabilities
ACP stable-v1 LogoutCapabilities.
LogoutRequest
ACP stable-v1 LogoutRequest.
LogoutResponse
ACP stable-v1 LogoutResponse.
McpCapabilities
ACP stable-v1 McpCapabilities.
McpServer
ACP stable-v1 McpServer.
McpServerHttp
ACP stable-v1 McpServerHttp.
McpServerHttpVariant
McpServerSse
ACP stable-v1 McpServerSse.
McpServerSseVariant
McpServerStdio
ACP stable-v1 McpServerStdio.
McpServerStdioVariant
MessageId
ACP stable-v1 MessageId.
MultiSelectItems
ACP stable-v1 MultiSelectItems.
MultiSelectItemsString
MultiSelectItemsTitled
MultiSelectItemsUnknown
MultiSelectPropertySchema
ACP stable-v1 MultiSelectPropertySchema.
NewSessionRequest
ACP stable-v1 NewSessionRequest.
NewSessionResponse
ACP stable-v1 NewSessionResponse.
NumberPropertySchema
ACP stable-v1 NumberPropertySchema.
PermissionOption
ACP stable-v1 PermissionOption.
PermissionOptionId
ACP stable-v1 PermissionOptionId.
PermissionOptionKind
ACP stable-v1 PermissionOptionKind.
PermissionOptionKindAllowAlways
PermissionOptionKindAllowOnce
PermissionOptionKindRejectAlways
PermissionOptionKindRejectOnce
Plan
ACP stable-v1 Plan.
PlanEntry
ACP stable-v1 PlanEntry.
PlanEntryPriority
ACP stable-v1 PlanEntryPriority.
PlanEntryPriorityHigh
PlanEntryPriorityLow
PlanEntryPriorityMedium
PlanEntryStatus
ACP stable-v1 PlanEntryStatus.
PlanEntryStatusCompleted
PlanEntryStatusInProgress
PlanEntryStatusPending
PromptCapabilities
ACP stable-v1 PromptCapabilities.
PromptRequest
ACP stable-v1 PromptRequest.
PromptResponse
ACP stable-v1 PromptResponse.
ProtocolVersion
ACP stable-v1 ProtocolVersion.
ReadTextFileRequest
ACP stable-v1 ReadTextFileRequest.
ReadTextFileResponse
ACP stable-v1 ReadTextFileResponse.
ReleaseTerminalRequest
ACP stable-v1 ReleaseTerminalRequest.
ReleaseTerminalResponse
ACP stable-v1 ReleaseTerminalResponse.
RequestId
ACP stable-v1 RequestId.
RequestIdNull
RequestIdNumber
RequestIdStr
RequestPermissionOutcome
ACP stable-v1 RequestPermissionOutcome.
RequestPermissionOutcomeCancelled
RequestPermissionOutcomeSelected
RequestPermissionRequest
ACP stable-v1 RequestPermissionRequest.
RequestPermissionResponse
ACP stable-v1 RequestPermissionResponse.
ACP stable-v1 ResourceLink.
ResumeSessionRequest
ACP stable-v1 ResumeSessionRequest.
ResumeSessionResponse
ACP stable-v1 ResumeSessionResponse.
Role
ACP stable-v1 Role.
RoleAssistant
RoleUser
SelectedPermissionOutcome
ACP stable-v1 SelectedPermissionOutcome.
SessionAdditionalDirectoriesCapabilities
ACP stable-v1 SessionAdditionalDirectoriesCapabilities.
SessionCapabilities
ACP stable-v1 SessionCapabilities.
SessionCloseCapabilities
ACP stable-v1 SessionCloseCapabilities.
SessionConfigBoolean
ACP stable-v1 SessionConfigBoolean.
SessionConfigGroupId
ACP stable-v1 SessionConfigGroupId.
SessionConfigId
ACP stable-v1 SessionConfigId.
SessionConfigOption
ACP stable-v1 SessionConfigOption.
SessionConfigOptionBoolean
SessionConfigOptionCategory
ACP stable-v1 SessionConfigOptionCategory.
SessionConfigOptionCategoryMode
SessionConfigOptionCategoryModel
SessionConfigOptionCategoryModelConfig
SessionConfigOptionCategoryOther
SessionConfigOptionCategoryThoughtLevel
SessionConfigOptionsCapabilities
ACP stable-v1 SessionConfigOptionsCapabilities.
SessionConfigOptionSelect
SessionConfigSelect
ACP stable-v1 SessionConfigSelect.
SessionConfigSelectGroup
ACP stable-v1 SessionConfigSelectGroup.
SessionConfigSelectOption
ACP stable-v1 SessionConfigSelectOption.
SessionConfigSelectOptions
ACP stable-v1 SessionConfigSelectOptions.
SessionConfigSelectOptionsGrouped
SessionConfigSelectOptionsUngrouped
SessionConfigValueId
ACP stable-v1 SessionConfigValueId.
SessionDeleteCapabilities
ACP stable-v1 SessionDeleteCapabilities.
SessionId
ACP stable-v1 SessionId.
SessionInfo
ACP stable-v1 SessionInfo.
SessionInfoUpdate
ACP stable-v1 SessionInfoUpdate.
SessionListCapabilities
ACP stable-v1 SessionListCapabilities.
SessionMode
ACP stable-v1 SessionMode.
SessionModeId
ACP stable-v1 SessionModeId.
SessionModeState
ACP stable-v1 SessionModeState.
SessionNotification
ACP stable-v1 SessionNotification.
SessionResumeCapabilities
ACP stable-v1 SessionResumeCapabilities.
SessionUpdate
ACP stable-v1 SessionUpdate.
SessionUpdateAgentMessageChunk
SessionUpdateAgentThoughtChunk
SessionUpdateAvailableCommandsUpdate
SessionUpdateConfigOptionUpdate
SessionUpdateCurrentModeUpdate
SessionUpdatePlan
SessionUpdateSessionInfoUpdate
SessionUpdateToolCall
SessionUpdateToolCallUpdate
SessionUpdateUsageUpdate
SessionUpdateUserMessageChunk
SetSessionConfigOptionRequest
ACP stable-v1 SetSessionConfigOptionRequest.
SetSessionConfigOptionRequestBoolean
SetSessionConfigOptionRequestValueId
SetSessionConfigOptionResponse
ACP stable-v1 SetSessionConfigOptionResponse.
SetSessionModeRequest
ACP stable-v1 SetSessionModeRequest.
SetSessionModeResponse
ACP stable-v1 SetSessionModeResponse.
StdioAcpTransport
StopReason
ACP stable-v1 StopReason.
StopReasonCancelled
StopReasonEndTurn
StopReasonMaxTokens
StopReasonMaxTurnRequests
StopReasonRefusal
StringFormat
ACP stable-v1 StringFormat.
StringFormatDate
StringFormatDateTime
StringFormatEmail
StringFormatUri
StringMultiSelectItems
ACP stable-v1 StringMultiSelectItems.
StringPropertySchema
ACP stable-v1 StringPropertySchema.
Terminal
ACP stable-v1 Terminal.
TerminalExitStatus
ACP stable-v1 TerminalExitStatus.
TerminalId
ACP stable-v1 TerminalId.
TerminalOutputRequest
ACP stable-v1 TerminalOutputRequest.
TerminalOutputResponse
ACP stable-v1 TerminalOutputResponse.
TextContent
ACP stable-v1 TextContent.
TextResourceContents
ACP stable-v1 TextResourceContents.
TitledMultiSelectItems
ACP stable-v1 TitledMultiSelectItems.
ToolCall
ACP stable-v1 ToolCall.
ToolCallContent
ACP stable-v1 ToolCallContent.
ToolCallContentContent
ToolCallContentDiff
ToolCallContentTerminal
ToolCallId
ACP stable-v1 ToolCallId.
ToolCallLocation
ACP stable-v1 ToolCallLocation.
ToolCallStatus
ACP stable-v1 ToolCallStatus.
ToolCallStatusCompleted
ToolCallStatusFailed
ToolCallStatusInProgress
ToolCallStatusPending
ToolCallUpdate
ACP stable-v1 ToolCallUpdate.
ToolKind
ACP stable-v1 ToolKind.
ToolKindDelete
ToolKindEdit
ToolKindExecute
ToolKindFetch
ToolKindMove
ToolKindOther
ToolKindRead
ToolKindSearch
ToolKindSwitchMode
ToolKindThink
UnstructuredCommandInput
ACP stable-v1 UnstructuredCommandInput.
UsageUpdate
ACP stable-v1 UsageUpdate.
WaitForTerminalExitRequest
ACP stable-v1 WaitForTerminalExitRequest.
WaitForTerminalExitResponse
ACP stable-v1 WaitForTerminalExitResponse.
WriteTextFileRequest
ACP stable-v1 WriteTextFileRequest.
WriteTextFileResponse
ACP stable-v1 WriteTextFileResponse.

Properties

acpV1Routes List<AcpV1Route>
final
acpV1RoutesByMethod Map<String, AcpV1Route>
final

Functions

deepFreezeAcpJson(Object? value) Object?
Validates and recursively freezes an ACP JSON value.
deepFreezeAcpJsonMap(Map<Object?, Object?> value) AcpJsonMap
Validates and recursively freezes an ACP JSON object.

Exceptions / Errors

AcpTransportClosedException
AcpTransportException
AcpTransportFormatException
AcpV1ConnectionStateException
AcpWireDecodeException
Thrown when an ACP wire object cannot be decoded.
AcpWireEncodeException
Thrown when an ACP runtime value cannot be encoded to a wire object.
AcpWireException
Base class for failures at the ACP wire boundary.
JsonRpcClosedException
JsonRpcInvalidParamsException
JsonRpcMethodNotFoundException
JsonRpcProtocolException
JsonRpcRemoteException