Help Wizard

Step 1



Please see below the most popular frequently asked questions.

Loading article...

Loading faqs...


Ongoing Issues

Please see below the current ongoing issues which are under investigation.

Loading issue...

Loading ongoing issues...


Saving Spotify Genre List in Database/Cache

Saving Spotify Genre List in Database/Cache



I'm interested in making an application using the Spotify API that creates a visual representation of users based on the genres they listen to. We'd want to be able to store the genre list and aggregated audio feature data somewhere at least in cache. Wanted to check if this would comply with the Developer Terms, Section 4:


Storing Spotify Content

  1. Storing and displaying content.

    1. Except as otherwise set out in these Developer Terms, you may not store, aggregate or create compilations or databases of Spotify Content, other than as strictly necessary to operate your SDA. You must use reasonable efforts to ensure that any data you display to users is the most up to date data available through the Spotify Platform, and to delete older data. Do not store Spotify Content indefinitely.

If we take reasonable efforts to refresh this data periodically, would storing the genres in cache be okay?




2 Replies

Depending on what kind of data you specifically collect, I can't see how it would run afoul of the terms of use. If e.g. you store genres as an array of strings, that isn't "Spotify Content", it's just meta-data for YOUR user. It's not even necessarily specific to the platform.


If you store Spotify URIs or IDs to fetch against the API, that's a bit different since those ARE uniquely Spotify's content. 


If I were designing the platform, I would separate generic data like genres, and then have a separate table with Spotify-specific content. Say you want to save a users play history and the associated meta-data, you might create a table with hashes or internal song IDs, and separately store a reference to the corresponding Spotify item. That way you can keep the user data, and periodically refresh the Spotify data so it doesn't grow stale. It also makes it easier to make the application independent of streaming provider.

That's very helpful insight, can definitely see how splitting the data between generic and Spotify-centric content would be beneficial.


However, to clarify in this case I want to store a list of all the genre seeds Spotify currently has and periodically run some data processing jobs on them, caching the results so that I don't need to do it each time a new user registers. Although genres are just strings, it seems a bit more platform specific since it's their entire list. Don't think this would cause any issues if I make sure to periodically refresh the list, but just figured I'd check first.

Suggested posts