Expand description
Wire-protocol types for the browser bridge.
Three layers share these structs. The control plane accepts a
ControlRequest body on POST /__bridge/request (and synthesises one for
the transparent proxy). The WebSocket plane serialises a Command to
the browser and deserialises a BrowserReply back. The control plane then
returns a ResponseEnvelope to the caller. Every frame is newline-free
JSON correlated by a monotonic integer id assigned by the server; the
browser echoes it back unchanged.
Structs§
- Browser
Frame - Browser → server frame: a superset of
BrowserReplyplus the streaming fields (stream/chunk/seq/done). - Browser
Reply - Browser → server reply frame.
- Cancel
Command - Server → browser cancellation frame.
- Command
- Server → browser command frame.
- Control
Request - A request as supplied by a control-plane caller (the
POST /__bridge/requestbody, or synthesised from the path/method/headers of a transparent-proxy request). - Response
Envelope - Control-plane response envelope returned to the caller of
POST /__bridge/request. - Status
Response GET /__bridge/statusresponse body.- TabInfo
- One connected tab, as reported by
GET /__bridge/status.
Enums§
- Reply
Outcome - Classified outcome of a
BrowserReply. - Stream
Item - One item of a streamed browser response, derived from a
BrowserFramewhen the registered waiter is a stream. - Stream
Line - One NDJSON line of a streamed
POST /__bridge/requestresponse.