* Delivery WebSocket bookTicker * @param {symbol} symbol name or false. can also be a callback * @param {function} callback - callback function * @return {string} the websocket endpoint
(symbol?: string, callback = console.log)
| 6014 | * @return {string} the websocket endpoint |
| 6015 | */ |
| 6016 | deliveryBookTickerStream(symbol?: string, callback = console.log) { |
| 6017 | const reconnect = () => { |
| 6018 | if (this.Options.reconnect) this.deliveryBookTickerStream(symbol, callback); |
| 6019 | }; |
| 6020 | const endpoint = symbol ? `${symbol.toLowerCase()}@bookTicker` : '!bookTicker'; |
| 6021 | const subscription = this.deliverySubscribeSingle(endpoint, data => callback(this.dBookTickerConvertData(data)), { reconnect }); |
| 6022 | return (subscription as any).url; |
| 6023 | } |
| 6024 | |
| 6025 | /** |
| 6026 | * Websocket delivery klines |
no test coverage detected