Skip to main content

Module protocol

Module protocol 

Source
Expand description

Public protocol namespace. Use it for the documented protocol API surface; prefer crate-root re-exports for common imports. Module items must preserve the toolkit ownership and side-effect boundaries described in this file. JSON-RPC protocol primitives and line-transport helpers.

Scripted ACP/MCP conformance harnesses live under agent_sdk_toolkit::testing, so production-facing wire types stay separate from deterministic test-kit behavior.

Structs§

JsonRpcErrorObject
JSON-RPC error object embedded in an error response. It carries protocol failure details only; constructing it does not log, publish, or send the error.
JsonRpcLineCodec
Protocol json rpc line codec value used by toolkit JSON-RPC adapters. Constructing the value prepares protocol data; endpoint and transport methods own transcript or I/O effects.
JsonRpcLineEndpoint
Protocol json rpc line endpoint value used by toolkit JSON-RPC adapters. Constructing the value prepares protocol data; endpoint and transport methods own transcript or I/O effects.
JsonRpcNotification
JSON-RPC notification frame sent for one-way protocol messages. Notifications have no id and do not receive responses; sending still mutates the chosen line endpoint transcript or transport.
JsonRpcRequest
JSON-RPC request frame sent when a client expects a response. Constructing the value only prepares serialized protocol data; transport effects occur when a line endpoint sends the frame.
JsonRpcResponse
JSON-RPC response frame for a completed request. A response contains exactly one of result or error; sending it is handled by the endpoint or transport layer.

Enums§

JsonRpcFrame
Parsed JSON-RPC frame used by line transports and scripted protocol fakes. Matching on the frame is side-effect free; endpoint methods own any transcript or transport mutation.
JsonRpcId
Identifier carried by JSON-RPC requests and responses. Use numbers or strings for ordinary correlated calls; Null is reserved for parse errors or protocol failures where JSON-RPC requires an id but no valid request id exists.