General
What is best way to call breeze.unsubscribe_feeds() function?
On subscribing to feeds, the callback is supposed to listen to any incoming data packets until the websocket is disconnected.
If we wish to stop feeds after a certain time , we can use time.sleep and then call unsubscribe_feeds .
#Connect to websocket
api.ws_connect()
# Callback to receive ticks. def on_ticks(ticks): print("Ticks: {}".format(ticks))
api.on_ticks = on_ticks
api.subscribe_feeds(stock_token="13.1!1050")
time.sleep(500)
api.unsubscribe_feeds(stock_token="13.1!1050")