Yahoo Finance API changes (2017)

2019-01-10 22:50发布

Requesting data from Yahoo Finance seems to have changed or is now blocked. The request below for commodity data no longer works as of May 2017. Does anyone know if there is a new way to make this request?

http://chartapi.finance.yahoo.com/instrument/1.0/GCQ17.CMX/chartdata;type=quote;range=10d/csv/

3条回答
地球回转人心会变
2楼-- · 2019-01-10 23:40

As Ashley Davis mentioned in the comments section of the question above, the new way to go is through Alpha Vantage, at least when one is looking for free historical data. Their web service is very well documented and straight forward.

For those of you who are looking to import the data into Excel, I have written an api that I make available for free. Here is the Excel spreadsheet

Addendum as of Aug 2018: Current version of Deriscope supports retrieval of both historical data and live feeds from YF.

查看更多
淡お忘
3楼-- · 2019-01-10 23:40

For Australian investors, here is an alternative to yahoo finance api:

www.biglion.com.au

查看更多
够拽才男人
4楼-- · 2019-01-10 23:50

First, the old Yahoo finance iChart download is gone for good. In one of the forum posts, a Yahoo employee has confirmed that the free EOD data has been terminated, and will not be reintroduced. Check out this thread and look for reply from Nixon. Yahoo is recently acquired by Verizon, and it must be the new direction.

However, if you check the Yahoo financial page, the CSV download link works, though differently now. It is through a new API that uses an authentication token "crumb" that is linked to a cookie when you access the page.

So there is a work-around to get the same CSV download as before through this new API. I have put together some quick Python3 code. Please check out GitHub for source code yahoo_quote_download.

查看更多
登录 后发表回答