Sonos play track issues

I have a Sonos Play speaker which until now I've just used for TTS with Hubitat. Works great, but now I thought it might be nice to have Hubitat control music on it too. Searching around I found you can play track using the uri link that appears on the device page when using the Sonos app. I have used that method to get a couple of streaming radio station addresses. I tested one and thought initially it was working ok. But when I hit the command today, instead of playing the radio stream, it played one of my TTS messages from earlier. More testing seems to suggest that the play track (uri) actually just plays whatever track is currently in the device memory and it ignores the uri link. Anyone else have this issue?

1 Like

Can you send me the uri for the station in question?

Mike.

This is the main one I'm using to test it.

BBC Radio 2

x-sonosapi-stream:s24940?sid=254&flags=8224&sn=0

1 Like

Was there ever a solution to this? I am having similar issues.

From my testing it seems that if you enter an invalid uri (or simply one that HE thinks is invalid) the play() method resumes whatever track is in the queue. HE has been very inconsistent with what uri it accepts. I try each of the uri's (enqueued, transport, etc) till I find the one that works.

Ok, I will fiddle around. So far I can retrieve a radio station (via Sonos-tunein) okay, but the personal playlists (via sonos-Spotify) remains challenging as I’ve tried every type of uri string available (except for artwork. I hate artβ€”-just kidding :smile:) and no luck.

Thanks for your response.

Got the exact same problem today. It keeps playing the text/speach message instead of the track...

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.