compohub
compohub copied to clipboard
Feature request: JSON API
Heya!
Today I have a little feature request, that I think might be cool to have: a JSON API Things that should be included would be:
- Jams that are currently in progress
- Jams that happen within x days/weeks/months
- Jams that ended x days/weeks/months ago
That's all I want. :)
Agreed! In fact the site could run using the same json api
I don't know that the site has a backend to give those kinds of features. It would be trivial to change the javascript client the site uses to allow other sites to get the same data.
https://github.com/leafo/compohub/blob/master/jamhub.coffee#L88
Currently the whole thing is just static files, there is no server side logic. I wouldn't be opposed to having a little PHP script on the server though for dynamically slicing up the json files.
Is this for server side or client side access? If it's for client side I could convert the json files to jsonp and then write some helper javascript you can include on the page that loads the appropriate files.
@leafo I'm mostly about the client-side access!