Help Wizard

Step 1

NEXT STEP

500 internal server error

500 internal server error

i got a token by making a post request using the client credentials and

{ 'grant_type':'client_credentials',
'scope': 'user-read-recently-played'} in header. as data for that post request.

 

But when i use this token to get recently played tracks- https://api.spotify.com/v1/me/player/recently-played, it gives me a 500 error:

{'error': {'status': 500, 'message': 'Server error.'}}

 

Any idea what is happenning here?

Reply
3 Replies

Hey @deepaksai__, thanks for your post here!

Since the client credentials flow does not include authorization, only endpoints that do not access user information can be accessed. You can use another authentication flow for getting recently played tracks from a user. Let me know if you have any questions!

Have a great day,

Hubo

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

Hey Hubo, I know it's over a year late but I am experiencing the same error, how should I go about retrieiving data for a user's recently played tracks? If client credentials is not the way

@bananaboydan, any other flow shown at this page: https://developer.spotify.com/documentation/web-api/concepts/authorization

Suggested posts