jpochyla / psst

Fast and multi-platform Spotify client with native GUI
MIT License
8.46k stars 215 forks source link

Discord Rich Presence is not showing #186

Open MertBhey opened 3 years ago

MertBhey commented 3 years ago

In the official Spotify app (including web and mobile version) it sets your Discord Rich Presence (RPC) to "Listening to Spotify" with the songs name etc. but in Psst, this feature is not working.

jpochyla commented 3 years ago

Hi! I don't personally use Discord, but a PR would be welcome, if it's not too complex.

MertBhey commented 3 years ago

Hi! I don't personally use Discord, but a PR would be welcome, if it's not too complex.

Can u suggest me a way (or an network tracker app) to find how is the official Spotify app doing this?

naufik commented 3 years ago

Not 100% sure on this, but it looks like the Discord Rich presence for Spotify is actually generated remotely from Spotify Connect activity. See #33.

I did some research on spotifyd/spotifyd. They support rich presence but I couldn't find anything in their codebase that explicitly sends out a rich presence event. So it leans towards spotify actually generating this remotely.

Implementing it inside psst's codebase would instead create a custom "Psst" rich presence badge.

yavko commented 3 years ago

The reason this probably doesn't work is because the music playback in psst isn't sent to the spotify api (I think) Whenever I get the current song through spotify api nothing appears when I use psst. Discord gets the song through spotify api. So the fix would be to fix that! (I THINK)

(Im not sure this is the case 100% but yeh)

kothavade commented 2 years ago

https://github.com/trungk18/angular-spotify shows itself as a spotify player, which means it can identify itself as a spotify player, which should allow this... not sure how they implement it, but it seems possible.

yavko commented 2 years ago

trungk18/angular-spotify shows itself as a spotify player, which means it can identify itself as a spotify player, which should allow this... not sure how they implement it, but it seems possible.

Maybe its for clients that appear in spotify connect?