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...


Obtain list of liked albums through non-interactive script

Obtain list of liked albums through non-interactive script



I'm trying to write a script that can be run periodically (cron) and fetches the albums I saved/liked/followed to my library and writes the list to json.


Accessing this endpoint requires the 'user-library-read' scope.


According to the docs, this can only be obtained through the authorization code flow and the implicit grant flow (I'm not 100% sure about the latter but what I gathered from the docs that should be possible). From my understanding, both these flows are meant to be used interactively where the user gets redirected to the spotify account page where he grants those scopes once and then gets an access token everytime upon login. I fear that this login process will be near impossible to automate from a script since it most likely will be using protection against non interactive use (i.e. captchas).


Is there any way to obtain a list of the albums I liked in a non-interactive/programatical way?


Any help is appreciated, Cheers!

1 Reply

I recommend you to write the script in Python and use the module  SpotiPy.

If you use that module, you only need to log in once. After that, the module will use the cached access token and refresh token for subsequent runs.






Suggested posts