Could you please clarify the process for obtaining a Data API token? I’ve followed all the steps, including subscribing to the Data API and generating the token successfully. However, when I attempt to connect to the WebSocket, no data is being received

Could you please clarify the process for obtaining a Data API token? I’ve followed all the steps, including subscribing to the Data API and generating the token successfully. However, when I attempt to connect to the WebSocket, no data is being received. I’d appreciate your guidance on whether I’ve missed any steps or if there’s an issue with the token usage.

Hi @Ashishh_Bhandarri ,

To get your API access token, just log in to web.dhan.co. Go to Profile > My Profile > Dhan HQ Trading APIs, click on New Token, and generate it.

Quick heads-up: The same token works for Trading and Data APIs. If you subscribed to Data APIs after generating the token, you’ll need to re-generate it to access market data.

Also, please refer the docs here - https://dhanhq.co/docs/v2/live-market-feed/ to get an idea for connecting the websocket.