Spotify Connect Devices #996
Replies: 4 comments 9 replies
-
Probably worth mentioning that those are snapcast sources specified in the post. Note that Spotify devices within the same LAN can see each other without needing to communicate via Spotify's server. That's possibly the reason for the discrepancy you are seeing. Although I always thought that librespot clients did publish themselves to Spotify's server and would show up in the results. I would guess only librespot servers that are currently logged in as that user will be present in the Spotify API results obtained using a given user's auth token. But I'm not sure, I've never tried that. |
Beta Was this translation helpful? Give feedback.
-
It is my understanding that the API would only return players you had connected to before. Devices on your network on the other hand use local announcements to find players. They don’t talk to a server to find the players, but they send out a broadcast message to all devices on the network. And those who understand the request will respond, making themselves known to that device or application. |
Beta Was this translation helpful? Give feedback.
-
That is how I understand it to work. But somehow when a user selects the Device it calls Spotify's API servers to register it (unpublished API?) then the app proceeds to transfer playback to that source's Device ID (published API). The problem here I am calling out is for an app that any of us would like to develop, that integrates with with other capabilities, your/my app cannot get all the Devices the way the proprietary Spotify App can, and can only get just those Devices that have been recently selected by the active user from Spotify's App (very limiting). Also, their TransferPlayback API call will only accept a DeviceId that has been registered for that user. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
Not sure where to turn, so thought I would post here to reach some experts in the Spotify API + Connect skillset.
I have librespot installed and have registered three Spotify Sources (one for each member of the fam):
They all show up in our Spotify apps like our Android Phone App, or even Desktop Apps. And even a bunch of others show up, like our NVidia Shield, Firestick, and old Gramofons.
However, when I call https://api.spotify.com/v1/me/player/devices, depending on the Auth token for each one of my family, I get back only a couple devices, and definitely not all devices on the home network.
Curious... if the Spotify Desktop or Mobile App can get all the Devices on a home network, how can I?
This leads me to whether this capability would fall within the scope of librespot, and perhaps this Library could or already does support essentially what these other client apps already do.
Goal: If I could get back all these devices from the Spotify API, then my client app would allow my family to have a one-stop shop for grouping Snapcast clients, turning on network receivers, and choosing playback device.
LMK if I am not making any sense, but thank you for taking time to read my inquiry!
Beta Was this translation helpful? Give feedback.
All reactions