Expand description
Op-in API in crates/protocol (issue #5261).
The TUI engine already had an internal channel (Op in
crates/tui/src/core/ops.rs with tx_op / rx_op and tx_steer).
This protocol file formalizes that channel so TUI, CLI, app-server, and
tests share one serializable API. The wire is OpEnvelope + Op;
transports that already speak JSON (app-server, tests) can send the
envelope directly, while in-process callers continue to use the typed
enum.
Structs§
- OpEnvelope
- Every
Opis paired with the ids that route it. This is theOp-in half of theOp-in /EventMsg-out contract.
Enums§
- Op
- Operations that can be submitted to the core engine. This is the
protocol view of
crates/tui/src/core/ops::Op— same lifecycle, same provenance gate — but serializable and free ofmpsc/oneshotfields. In-process callers convert at the boundary; out-of-process callers send the JSON directly.
Functions§
- headless_
send_ message_ op - Build a headless
SendMessageenvelope with fresh ids. This is the one-line helper every headless caller (CLIexec, app-server, tests) uses so TUI and headless start a session identically.