Sonos/Smartthings Integration

  • 17 September 2018
  • 14 replies
  • 4596 views

Userlevel 5
Badge +9
Glad to see the new sub-forum. My Sonos speakers are an integral part of my Smart Home, which has been built around SmartThings (and webCore) but also utilizes IFTTT, Alexa, and Google Assistant. Just for those considering the possibilities, I'll share a few examples of things I've done. It would be interesting to see ideas and suggestions from other community members on the things they are doing with theirs.

Automated Controls
Scheduled Volume Adjustments for Day and Nighttime (if speakers are inactive)
Auto Adjust Volume to Default When Speakers are Inactive for Preset Period
Play Music at Bedtime & Slowly Fade before Stopping (Sleep Mode)
Music Plays upon Arrival & Pauses on Departure
Music Pauses on Receiving Phone Call
Lower music volume when Doorbell Rings

Voice Control (Alexa / Google)
Adjust Volume of Individual Speaker in Group
Adjust Volume of All Speakers in Group
Play Random Station, Favorite Station or Playlist

Security/Announcements
Security - Home/Away Door Intrusion Alerts (Alarms Sounds & Announcements)
Security - Lights & Music Operate Randomly when on Vacation
Security - If doorbell Rings with No One Home, Plays Sound of Mean Dog Barking (mostly for laughs 😃 )
Misc. Spoken Announcements (i.e., "The Garage Door has been left open")
Announce Estimated Commute Time (uses Google API) Upon Request

Of course, this list doesn't include all the standard tasks available to an Alexa-enabled devices.

14 replies

Great, how did you achieve your security announcements through Sonos?
Userlevel 7
Badge +22
For security system when you setup your sensors etc. the last page has options for Text/Push Notifications/Audio Notifications/ Alerts with Siren/Alerts with Lights

If you choose Audio notifications - you can then select any sonos speaker as audio device and put in custom message to play if security system set off.
Userlevel 7
Badge +22
You can also go into Marketplace button...smart apps tab at top...Music and Sounds...Speaker Companion.

This allows you to control sound notifications from the speaker when certain things happen.
Userlevel 5
Badge +9
Great, how did you achieve your security announcements through Sonos?

I actually use webCoRE with SmartThings to customize my various announcements, as I find ST's built-in security features a little too limited for me. However, as Chris notes there are options using SmartThings alone.
Userlevel 7
Badge +22
Oh yea with a lot of the custom apps and webcore you can do pretty much anything
Thanks Chris and Master T

I'll try webCoRE as well. But when I tried smartthings, it worked but the volume level of Sonos was very low. Is there any solution for this problem?
Userlevel 7
Badge +22
You can set volume levels from smartthings fir when plays
Hi, many thanks for your post! I am a big ST/IFTT/GA/WebCore fan as well, but I haven't been able to make much progress with Sonos How are you doing this one?

Play Random Station, Favorite Station or Playlist

Todd
Userlevel 5
Badge +9
Play Random Station is easily accomplished through a webCoRE piston. But first you have to capture the URIs for the stations you want the piston to chose from, which you can do by parsing the trackData from the speakers. For an example of how to do that try backup code 8qqd.

Play Favorite Station or Playlist is available through an IFTTT action, which of course can be triggered via Alexa or a webCoRE piston. For playlists, create the Playlist first and then add it to your Sonos favorites via the desktop app.
For security system when you setup your sensors etc. the last page has options for Text/Push Notifications/Audio Notifications/ Alerts with Siren/Alerts with Lights

If you choose Audio notifications - you can then select any sonos speaker as audio device and put in custom message to play if security system set off.
I have done the same alerts with the Classic version of SmartThings, but have not figured out how to do with the latest Version of SmartThings. The Marketplace and Sonos does not exist on the new version.
Sorry if this a duplicate response. I have done the same alerts with the Classic version of SmartThings, but have not figured out how to do with the latest Version of SmartThings. The Marketplace does not exist on the new version SmartThings, neither does the SmartThings lab. Any help is greatly appreciated.
Glad to see the new sub-forum. My Sonos speakers are an integral part of my Smart Home, which has been built around SmartThings (and webCore) but also utilizes IFTTT, Alexa, and Google Assistant. Just for those considering the possibilities, I'll share a few examples of things I've done. It would be interesting to see ideas and suggestions from other community members on the things they are doing with theirs.

Automated Controls
Scheduled Volume Adjustments for Day and Nighttime (if speakers are inactive)
Auto Adjust Volume to Default When Speakers are Inactive for Preset Period
Play Music at Bedtime & Slowly Fade before Stopping (Sleep Mode)
Music Plays upon Arrival & Pauses on Departure
Music Pauses on Receiving Phone Call
Lower music volume when Doorbell Rings

Voice Control (Alexa / Google)
Adjust Volume of Individual Speaker in Group
Adjust Volume of All Speakers in Group
Play Random Station, Favorite Station or Playlist

Security/Announcements
Security - Home/Away Door Intrusion Alerts (Alarms Sounds & Announcements)
Security - Lights & Music Operate Randomly when on Vacation
Security - If doorbell Rings with No One Home, Plays Sound of Mean Dog Barking (mostly for laughs 😃 )
Misc. Spoken Announcements (i.e., "The Garage Door has been left open")
Announce Estimated Commute Time (uses Google API) Upon Request

Of course, this list doesn't include all the standard tasks available to an Alexa-enabled devices.



Hey Master T this is fantastic! Would you consider sharing your Pistons for those of us new to Sonos and WebCoRE?
Userlevel 5
Badge +9
@DavidBQ I've shared a couple of my pistons previously and would be willing to share more, but unfortunately Sonos's integration with SmartThings was broken with the 10.1 update. It still works to a point, but several of my pistons are no longer working reliably. I've been told it's an XML parsing issue, which ST should be able to fix, but I can't get anyone over at ST to pay attention and Sonos (somewhat understandably) doesn't view this as their problem—even though they would be best qualified to write a proper custom Device-Type Handler.
Hi everyone,

Is there a way to play a Spotify playlist? What about loop a Spotify track?

Here's what I've been able to do (using WebCore with SmartThings):

Play a single Spotify track:
Set track to x-sonos-spotify:spotify%3atrack%3a3YqknScYcFrRQR23VZG8RB?sid=12&flags=8224;

Play a Spotify station:
Set track to x-sonosapi-radio:spotify%3aartistRadio%3a3Kt34aALAZu5GUd3WRqsrZ?sid=12&flags=8300

I can't play a Spotify playlist, e.g.

Set track to x-sonos-spotify:10062a6cspotify%3auser%3aericbogs%3aplaylist%3a3HsH3hBIXg47gD814dhj6L?sid=12&flags=10860

or

Set track to x-rincon-cpcontainer:10062a6cspotify%3auser%3aericbogs%3aplaylist%3a3HsH3hBIXg47gD814dhj6L?sid=12&flags=10860

Any ideas?

Reply