Dhan - Historical data


Dhan API Docs

Hi,
As Dhan now supports historical data upto years, can you please provide an updated codebase for the same. Thank you.

Hi @SathwikN ,

Currently Dhan is providing only last 90 days data.

HI Priya,
Can you please sahre the code for the 90 days.

Hi @SathwikN ,

To get the last 90 days data from dhan api, make the changes in Dhan_Tradehull file get_start_date() function.

start_date = df.iloc[-2]['timestamp'] # change -2 to -90