替代谷歌财经API [英] Alternative to google finance api
问题描述
我想使用谷歌财经的API来获取有关公司股票的数据,但自2011/26/05此API德precated。
I wanted to use Google Finance API to get stock data about company but this API is deprecated since 2011/26/05.
所以我的问题很简单:)
So my question is simple :)
你用什么免费API来获取实时股票数据?
What do you use as free API to get stock data in real time?
推荐答案
尝试雅虎财经API。
雅虎财经网址
这里是 previous计算器讨论的链接。另外一个替代链接,雅虎财经API 例如张贴在谷歌code
Yahoo Finance URL Here is a link to previous stackoverflow discussion. Also an alternate link to Yahoo Finance API example posted on Google Code
对于初学者,您可以生成一个CSV一个简单的API调用:
For beginners, you can generate a CSV with a simple API call:
http://finance.yahoo.com/d/quotes.csv?s=AAPL+GOOG+MSFT&f=sb2b3jk
(这将生成并保存一个CSV为AAPL,GOOG和MSFT)
(this will generate and save a CSV for AAPL, GOOG and MSFT)
请注意,您必须格式附加到查询字符串( F = ..
)。对于所有的格式的概述看到,访问这个页面
Note that you must append the format to the query string (f=..
). For an overview of all of the formats see, visit this page
有关更多例如访问这里
有关 XML
和 JSON
根据数据,你可以做以下
For XML
and JSON
based data you can do the following
1。使用YQL(雅虎查询语言)
例如:
http://developer.yahoo.com/yql/console/?q=select%20*%20from%20yahoo.finance
.quotes%20where%20symbol%20in%20(%22YHOO%22%2C%22AAPL%22%2C%22GOOG%22%2C%22
MSFT%22)%0A%09%09&env=http%3A%2F%2Fdatatables.org%2Falltables.env
2。使用web服务。
例如:(来获取所有股票报价)(在 XML
)
For example: (to get all stock quotes) (in XML
)
http://finance.yahoo.com/webservice/v1/symbols/allcurrencies/quote
(在 JSON
)---只需要添加格式= JSON
在网址的结尾
(in JSON
) --- just add format=JSON
in the end of the url
http://finance.yahoo.com/webservice/v1/symbols/allcurrencies/quote?format=json
替代
1。 财经内容API
Alternatives:
1. Financial Content API
这个API的文档是很不错的。
The documentation for this api is very good.
2。 开放汇率
2. Open Exchange Rates
3。 OANDA API
3. Oanda API
4。 XE API
4. XE API
5。 Xignite API
5. Xignite API
6. currencylayer API
7。在<一个讨论的其他API href=\"http://www.programmableweb.com/news/25-finance-apis/2008/04/24\">programmableWeb
这篇关于替代谷歌财经API的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!