Sonos - Switch Source

New to Hassio and have the google assistant “skill” component set up so I can turn my Sonos speakers on and off.

How do I go about setting up a custom “command” to change the source on the speaker… such as changing from “SpinCycle” to “The Chainsmokers”. A command that I can then tell verbally to my google assistant to change the Sonos source.

I’ve tried looking through the forum at creating scripts, automation, etc and have no clue where to start.

Any help is greatly appreciated.

1 Like

This scripts changes the source:

      - service: media_player.select_source
          source: 'The Chainsmokers'
1 Like

thank you!