Announcements

Help Wizard

Step 1

NEXT STEP

[All Platforms][Developer] Add Session Privacy Flag to "currently-playing" API endpoint

[All Platforms][Developer] Add Session Privacy Flag to "currently-playing" API endpoint

It does not appear that session privacy details are included in the "/v1/me/player/currently-playing" endpoint. As I would like to use this endpoint to implement a "What are users listening to" feature on an online community website, I would very much like to respect the privacy of my users and not publicly show details about tracks that are being listened to during a private listening session in Spotify.

 

Please add a boolean flag to this endpoint that indicates whether or not private session mode is enabled for the currently playing track.

Reply
3 Replies

In the meantime you can get this information from the get-user-player endpoint.
https://developer.spotify.com/console/get-user-player

The return data includes device.is_private_session

Actually the answer seems much simpler.
From a quick test, if a track is played in a private session (tested with the PC app), the currently-playing endpoint data is not updated. So you should be able to just use it, knowing that private session data will not be provided.

I couldn't find anything in the documentation that clarifies this behaviour.

The question then is if I can expect this behaviour to stay consistent over time given that it seems undocumented?

Suggested posts