Yahoo finance webservice API

I don’t know where the definitive documentation might be but for your particular example try appending &view=detail to your URL.

http://finance.yahoo.com/webservice/v1/symbols/COALINDIA.NS/quote?format=json&view=detail

This will at least give you the year_high and year_low that you asked after.

Now, even though the following won’t work for your COALINDIA.NS symbol (I suspect the exchange is not supported), it might be worth exploring the following two examples:

Example 1: As before, but for Apple and Yahoo symbols, with &view=detail appended:

http://finance.yahoo.com/webservice/v1/symbols/YHOO,AAPL/quote?format=json&view=detail

Example 2: And now using a completely different url, resulting in much more response data. One key caveat is this data is delayed by 15 minutes:

http://query.yahooapis.com/v1/public/yql?q=select%20*%20from%20yahoo.finance.quotes%20where%20symbol%20IN%20(%22YHOO%22,%22AAPL%22)&format=json&env=http://datatables.org/alltables.env

If you discover the major differences between those two options and what impact they might have then please do let us all know; I’d be interested in finding out more.

Leave a Comment