Hacker News new | ask | show | jobs
by bmelton 4125 days ago
At least the NBA and NFL write out RSS feeds of games as they're playing with the scores and plays as they occur, to varying degrees of specificity.

They're kind of a bear to parse, but it's definitely doable without scraping, in some cases.

1 comments

Hi, do you have a link to these feeds by any chance? Was hoping for something like this for a POC. Thanks!
The NFL game feed is a combination of a couple of feeds. There's

http://www.nfl.com/liveupdate/scorestrip -- which will show you the events and IDs that are currently going active. Right now, in the off-season, it will undoubtedly be blank. You can then take those values and plug them into this one:

http://www.nfl.com/liveupdate/game-center/%s/%s_gtd.json % (year, game_id)

For something to illustrate how they work together, you can check out this repository: https://github.com/BurntSushi/nflgame

I don't remember the one for the NBA, as I've never used it, but I saw an article on reddit a few weeks ago about how to get the data from the NBA using their RSS feed, so I have a good faith belief that it exists.

Thanks for sharing this! The only thing I had found was stuff like SportsXML, etc. but it took me weeks to just get a demo data dump for a single game and the pricing was way too much to bite off.