If you are building on-top of Nash and using Node.Js, please upgrade the TypeScript client to the latest version (5.2.3). It introduces a few changes under the hood that makes life much easier for developers:
- Now on the first update to orderbook subscriptions the full current status of the orderbook is sent, removing the need to a
getOrderBookcall before the subscription.
The subscriptions connection management was improved and with it we would like to introduce a new preferred pattern:
const client = new Nash.Client() const sub = client.createSocketConnection() sub.onUpdatedOrderbook( ... )
const client = new Nash.Client() client.subscriptions.onUpdatedOrderbook(...)
this should improve the speed of clients and robustness of connections.
All the best!