Skip to main content

Module models

Module models 

Source
Expand description

The messages of the data channel /ws: the subscription requests and the frames that come back.

Every request carries opcode (what to do), guid (an id of ours, repeated in every answer to it) and token (the access token: the channel checks it on every message, so a session writes a fresh one into each request when it sends it). A subscription is answered once with a status frame (httpCode 200), then data frames arrive with the same guid until the subscription is cancelled with unsubscribe.

Structs§

WsSubscribe
A subscription request, without the token (the session adds it when it sends).

Enums§

WsIncoming
A frame of the data channel, parsed.

Constants§

CWS_PATH
The path of the trading channel.
WS_PATH
The path of the data channel on the WebSocket host.

Functions§

parse_incoming
Parses one text frame of the data channel.