Skip to main content

Module client_events

Module client_events 

Source
Expand description

Payloads of the broker events agentmux-bashwrap publishes through srv’s POST /agentmux/wps/publish. srv declares the same types for these events (backend::mps_events), refuses a publish whose data isn’t one of them, and generates them for the frontend, so the three can’t drift (docs/specs/SPEC_CODEGEN_REMAINING_GAPS_2026_10_13.md, step 2).

The TypeScript derives are behind the ts feature, which only srv turns on.

Structs§

CompactionStarted
The compaction_started event: the PreCompact hook fired, so Claude Code is compacting. camelCase on the wire, like srv’s AgentEvent.

Enums§

CompactionTrigger
How compaction was triggered. Auto = context filled up and Claude Code compacted automatically; Manual = the user (or the agent itself) ran /compact.
ToolChunk
The tool_chunk event, published to block:<id> while a Bash call runs. The call’s tool_use_id rides in the payload, not the event name, so the pane opens one subscription per block and routes by tool_id (SPEC_STREAMING_BASH_RUNNER_2026_05_11.md §6).
ToolChunkKind
Where a tool_chunk line came from.