sonos icon indicating copy to clipboard operation
sonos copied to clipboard

Add support for Spotify playlists

Open jackwilsdon opened this issue 5 years ago • 5 comments

I'm not really a fan of my implementation here as I'm somewhat masquerading a collection of tracks as a single Track object, however it seems that the library doesn't have a concept of a "Playlist" yet (although this is something that #98 may change).

I've left a comment or two below regarding my changes.

Fixes #56.

jackwilsdon avatar Mar 19 '19 16:03 jackwilsdon

Hey Jack, I can't get this to work with any of the playlists I've tried, do you have an example Spotify playlist ID?

duncan3dc avatar Mar 24 '19 14:03 duncan3dc

It works fine for me when using spotify:user:spotifycharts:playlist:37i9dQZEVXbMDoHDwVN2tF. I see that the Spotify track accepts URIs without the spotify:track prefix, which I haven't implemented in the SpotifyPlaylist track (primarily because the format is spotify:user:{username}:playlist:{track}. Would it be better if it accepted URIs in the form spotifycharts:playlist:37i9dQZEVXbMDoHDwVN2tF and automatically prepended spotify:user:?

jackwilsdon avatar Mar 24 '19 16:03 jackwilsdon

Ah I was just passing 37i9dQZEVXbMDoHDwVN2tF so that'll be why it wasn't working. Let me take another look

duncan3dc avatar Mar 24 '19 16:03 duncan3dc

It's a pain but it seems to need user ID too, although I could be missing something here.

jackwilsdon avatar Mar 24 '19 16:03 jackwilsdon

It appears that some changes were made in June last year to allow Spotify playlist URIs without the user ID (in the form spotify:playlist:37i9dQZEVXbMDoHDwVN2tF), however it seems that the Sonos doesn't support this, as trying it out results in an 800 UPnP error.

jackwilsdon avatar Mar 24 '19 19:03 jackwilsdon