My application fetches historic data from the yahoo finance using HTTParty.get in ruby on rails.
previously I used the following url
data_source = "http://chart.finance.yahoo.com/table.csv?s=#{ticker}&a=5&b=15&c=2001&d=#{end_date.month - 1}&e=#{end_date.day}&f=#{end_date.year}&g=1d&ignore=.csv"
I found its not working from couple of days and got not found error. So I checked Yahoo finance and updated it accordingly
data_source = "https://query1.finance.yahoo.com/v7/finance/download/#{ticker}?period1=#{start_date}&period2=#{end_date}&interval=1d&events=history&crumb=.zG6G1yJSmP"
After updating I am getting Unauthorized error. Could any one help me out of this.
Regards,
Sreeraj