Fyers Websocket API reconnection

I using Fyers Websocket API node sdk for checking the live price. Due to network slowness, websocket connection gets close.
To fix this I have added a method where I call following code.

        fyersdata = FyersSocket.getInstance(`${secretKey}:${token.access_token}`)

        // console.log("fyersData Instance",fyersdata);
        if (!fyersdata) {
            fyersdata = new FyersSocket(`${secretKey}:${token.access_token}`); 
        }
        fyersdata.connect();     // Reconnect
        fyersdata.autoreconnect(50);



After this I get Subcribed message but not receiving any price tick data?

1 reply