Plaid[1] is only company I know of offering this sort of API. Maybe there are others, I wasn't able to find any from a quick google search. You can actually get a dev account (free with up to 100 bank accounts) and pull your own transaction data with it. I've been meaning to write a little tool to import from them into GnuCash.
I happen to have been looking around at this earlier today.
I found an open source project named Firefly III[1], that uses an API called Spectre[2]. Same deal, free for a certain number of bank accounts, but looks like you need to contact them to set up your API access. Incidentally, I recently saw an iOS app that had been using the Spectre API as well.
[1] https://plaid.com/