New York Times campaign finance API upgraded through collaboration
Developers can now pull more recent and more detailed campaign finance data from a New York Times’ database, thanks to an upgrade contributed by one of the API’s heaviest users.
An API, short for “application programming interface,” is a system that enables any software application to retrieve information from another application or database. In a basic sense, you can think of an API like an electrical outlet -- the thing that connects a central resource (electrical current) to any appliance with the right plug. (For more background, see our API beginner’s guide for journalists, four reasons your news org should use APIs and a NewsU course on APIs in action.)
The New York Times offers at least 13 APIs ranging from archive search to real estate listings or movie reviews. The Guardian and USA Today are among others offering APIs. But as a Digiday article this week noted, none of these organizations is making money yet from APIs.
So why do it?
“A large part of the reason why we built it is, it makes it easier for us to do graphics and applications in a shorter amount of time,” Times developer Derek Willis told me.
But opening that same data to the public for other uses has payoffs as well, Willis said. In this most recent case, ProPublica news applications developer Al Shaw had been using the Times’ Campaign Finance API to gather FEC data for a web app that lets users examine Super Pac spending. Shaw realized the Times database also recorded individual campaign contributions data that wasn’t accessible through the API.
So Shaw offered to fix that.
“Most organizations don’t actively solicit other people to help them on the APIs themselves,” Shaw told me. “It’s pretty cool that Derek was open to letting me hack directly on code that’s going to run on their production servers. … What I’m trying to do is make the data that’s already in that database more useful.”
Now the Campaign Finance API offers data on itemized contributions to campaign committees, as well as “electioneering communications” (the third-party ads that seek to influence elections without specifically advocating for or against a candidate). It also polls the FEC for new filings every 15 minutes, so data is almost real-time.
“Not only did he (Shaw) contact us and offer feedback and suggestions about the API, but the suggestions and feedback were so good and valuable that we actually had him do some of the work to improve it,” Willis said. “His code is now part of our API, and that’s a first for us, I think. It shows the value of opening up the API. The API is now better because of the users’ interest and ability … Now everybody else can benefit from the work that Al put in.”