new BTCMarketsWS()
Methods
-
connect()
-
Connects the socket
-
disconnect()
-
Disconnects the socket
-
join(channelName)
-
Joins a specific socket-io channel
Parameters:
Name Type Description channelName
any -
subscribeOrderBook(instrument, currency)
-
Subscribe to the orderbook event
Parameters:
Name Type Description instrument
any currency
any -
subscribeTicker(instrument, currency)
-
Subscribe to the 'ticker' event
Parameters:
Name Type Description instrument
any currency
any -
subscribeTradeEvents(instrument, currency)
-
Subscribe to the trade event
Parameters:
Name Type Description instrument
any currency
any
Events
-
error
-
Ticker event
Type: object
-
orderbook
-
Orderbook event
Type: object
-
ticker
-
Ticker event
Type: object
-
trade
-
Trade event
Type: object