Is there an API for searching Stock Symbols based on Company Names? [closed]
Asked Answered
T

3

12

This is a similar question to Stock ticker symbol lookup API however that was never answered to the standard I think is needed for a commercial application.

The problem is this: Given a company name, partial name, or stock symbol, return a list of possible symbol matches.

So for example:

"microsoft" => "MSFT", "...",  ...  
"aapl" => "AAPL", "...", ...  
"goo" => "GOOG", "...", ...  

I have used "..." to mean another result of secondary importance.

In the question I linked to, there was, as far as I can tell, only 1 actual answer, and many people totally misunderstanding the question. I do not want stock data, prices, or anything like that! The one answer that is addressing the correct issue looks like it is a very private API and one that could break at any time. The exact callback used by the website must be used or else it doesn't appear to work. It also only works in JSON format and not XML which I would prefer if possible.

There are 3 things that I am considering at the moment, and I would appreciate any feedback on these, or suggestions of others:

  • Use SPARQL to query DBPedia and the "Traded As" fields in boxes on Wikipedia, this data is relatively unstructured, incomplete or inconsistent. I also haven't used SPARQL before so it might be a challenge.
  • Construct a virtual table for use with the Yahoo Query Language that actually screen scrapes the Yahoo website (or another) but provides a 'good' interface to allow me to change the backend data without re-distributing the application (for example if Yahoo change their site). This has the added benefit that I already have code for dealing with YQL+XML.
  • Simply screen-scrape data from within my application from sites that allow it in their terms of use.

Screen-scraping feels like a hack, and feels like it could be broken very easily, so I am reluctant to do the latter two options, however having had a look at the data on DBPedia with a test query, it seems like it is really terrible and might well not be of any use at all.

Summary: I need a reliable API for getting stock symbols for company names.

Edit: This does not have to be a Yahoo API at all. I would prefer to use them if possible, but only because of other code using their services.

Tedford answered 9/12, 2011 at 17:8 Comment(0)
M
5

This may be useful :)

'http://d.yimg.com/autoc.finance.yahoo.com/autoc?query=COMPANY_NAME_HERE&callback=YAHOO.Finance.SymbolSuggest.ssCallback';

It returns as JSON.

Mahon answered 26/3, 2013 at 17:43 Comment(5)
it is not working any more with company name. Also it only return 1 result.Guideboard
seems like they added 2 additional param,"region" and "lang". try the following d.yimg.com/autoc.finance.yahoo.com/…Patrilineal
@Patrilineal but now it returns only one result instead of multiple.Caseous
@DoctororDrive yeah and it seem like you can do a search via a company name as well. I reckon certain back end changes have affected this.Patrilineal
@Patrilineal here's a modified url that works as previously s.yimg.com/aq/…Caseous
S
1

XIgnite provides a web service that provides this service, although I have never used and cannot comment on its quality. You can license this information from financial data providers such as Thomson Reuters. If you want to do your own fuzzy matching Bloomberg's BSYM data might be a good place to get started.

Sphenoid answered 13/12, 2011 at 6:12 Comment(2)
I was looking for a free API. I find it very odd that all the market data is available for free, but just a search of symbols is charged for.Tedford
Yeah. Well until BSYM it required a lot of work to assemble what companies are trading from web data. Most websites don't do probabilistic matching so you will probably have to build that yourself.Sphenoid
H
0

The web site I use is http://www.eoddata.com/

You can download EOD data for free. or purchase a 100yrs of data affordably. with the EOD data you can easily import it into any relative data base program (Lotus Access is very easy to use). Access will automatically update the EOD data. you can then copy this data into Lotus 123 (or microsucks) wherein you can easily manipulate the data.

This will get you by and it's basically free. however you will find that a stand alone program is the way to go.

rewriting mine at this time in Python

Holdup answered 29/1, 2012 at 3:24 Comment(1)
Thanks for the reply, but this is not what I asked for. I was asking for an API, not a bunch of static data, and I was asking for company names in particular, not general market data.Tedford

© 2022 - 2024 — McMap. All rights reserved.