The Problem with Finance APIs

The Problem with Finance APIs

Since 2014 I invest and trade with stocks. Since then, I always wanted to create programs which make my life as an Investor easier and since then my journey with always reliving finance API problems started.

Unfortunately I didn’t find my first PHP scripts which tried to get stock data – so I don’t remember which API stopped back then, but the rest of my journey was well documented with the help of Git.

Yahoo Stock Data APIβŒ—

# Read Symbols from Database
symbols = datab.getSymbols()

# Get Price Data for each Symbol from yahoo
for sym in symbols:

    url = ""+sym+"&f=sabd"

    with closing(requests.get(url, stream=True)) as r:

Guess what: The API is not available anymore.

Yahoo Currency Data APIβŒ—

with urllib.request.urlopen("") as url:

Current Currency rates on a stable API? Not with Yahoo!

CoinMarketCap Free Crypto APIβŒ—

# Get Market Data
with urllib.request.urlopen("") as url:

Free Crypto prices? No! The guys behind CoinMarketCap found out that offering a free and open service is stupid and now ask for money!

Finsymbols Python libβŒ—

Mainly get obtained via web scraping. I didn’t check all the functions, but it seems that many are outdated now.

IEX ExchangeβŒ—

Back in the day I was crazy about this. A whole exchange which advertised it was made for developers with a free API.

iexurl = ""+sym+"/quote"
with urllib.request.urlopen(iexurl) as url:

Ha! Markets move too fast to provide the same URL for a longer period! You now have to use a new one, and it is not even free anymore.


Was a free and open source service with API for current exchange rates from the ECB.

The guy behind it sold it to a company which is owned by a big American Corporation. Of course, they now ask for money, even while there are many APIs which offer the same for free.


These are not even all APIs that changed – I used other ones before that. I use finance APIs since 2014, and I never encountered one which didn’t change after a few years or months.

So to rely on any finance API alone sounds stupid to me now because even the biggest players in this area changed their API dramatically multiple times.

The SolutionβŒ—

I think the only solution for that problem is to create a wrapper around multiple APIs, check which APIs are online and give the fastest responses and deliver the information from these APIs.

Because there are many APIs which deliver the data from the European Central Bank and have a similar / compatible API to what had back in the day, I created two wrappers for currencies:

exchangerates-wrapper outputs a URL to an API which is online, and you can also define which currencies need to be supported from the API. It’s written in TypeScript and usable for projects in the Node ecosystem.

go-currency-wrapper is the same, but for projects which use the Go programming language.

What about stocks and crypto?βŒ—

While I plan similar projects for stocks and cryptocurrencies, I am currently not sure if or when I will release it to the public. However, other projects also have similar ideas:



Hey! look, i give tutorials to all my users and i help them!