Help Wizard

Step 1

NEXT STEP

FAQs

Please see below the most popular frequently asked questions.

Loading article...

Loading faqs...

VIEW ALL

Ongoing Issues

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

Loading issue...

Loading ongoing issues...

VIEW ALL

Getting track time played

Solved!

Getting track time played

I have a Matrix LED Panel and I want to use it with the Spotify API. I know it's possible to grab the cover of the currently playing song. But is it also possible to get the "song progress" of the current song?

 

In the end I would like to hang the panel on the wall and display the information there: song, artist, possibly album and song progress.

 

I've read that if you pull the song cover, this is queried every second. That will definitely work with the song progress.

Reply

Accepted Solutions
Marked as solution

Yes, if you want to get the progress over time, you have to request every second or on a shorter time interval.

The endpoint you are looking for is Get Playback State. It requires the user-read-playback-state Authorization scope.

XimzendRising Star
Help others find this answer and click "Accept as Solution".
If you appreciate my answer, maybe give me a Like.
Note: I'm not a Spotify employee.

View solution in original post

2 Replies
Marked as solution

Yes, if you want to get the progress over time, you have to request every second or on a shorter time interval.

The endpoint you are looking for is Get Playback State. It requires the user-read-playback-state Authorization scope.

XimzendRising Star
Help others find this answer and click "Accept as Solution".
If you appreciate my answer, maybe give me a Like.
Note: I'm not a Spotify employee.

I looked around a bit and found that I can also get the information from: https://developer.spotify.com/console/get-users-currently-playing-track/.

So that I can show the progress, I also need the song length. Although this can be output ("duration_ms"), unfortunately the time does not match the actual time in Spotify. What can be the reason?

Suggested posts