Comment

Comment by avarsh

I made a similar site last August. http://www.hearnow.io/

You can pick a location on a map and it will generate a playlist for pretty much any city. I haven't done much work on it since then, but had a decent response when I posted it to Reddit. I've been considering open sourcing it, but not sure if there is interest.

My approach:

- Use SeatGeek's API to find venues/artists near the user

- Query Spotify's search API for artists with these names to get artist IDs (which you need to do other interesting things with Spotify's API)

- Filter results from Spotify search queries with fuzzy matching between artist names and results

- Use Spotify's API to get the top 5-10 most popular tracks for each artist, and randomly select ~30 to add to a playlist

Spotify's search API cannot be queried in batch which is a pretty frustrating bottleneck. I mainly solved this by caching artist name / ID pairs, but this would only really be effective if I got a lot of traffic (I don't).

Also, SeatGeek's API was a lot more friendly than Songkick, which I considered using. But SeatGeek didn't seem to have data for many venues overseas, so I had some users outside the U.S. that were disappointed that their queries would usually fail because the app couldn't find enough tracks.

parent avarsh 8 years ago

Discussion

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton