Resume previous volume level and song/playlist on SONOS after playing local sound

Hi,

I am using a script to change the volume and play a local mp3 on my SONOS when my doorbell rings.
I really want to be able to resume volume and playlist playing on SONOS after that. Does anyone know if this is possible?

I started looking into a python script, and I have somewhat a clue (though this is my first venture into python scripts).

I am storing the initial volume and play state, then I set the volume and play the doorbell.mp3 file, then I set the volume back to the initial volume. But I can’t just set the state to the initial state, because now the playlist is just the doorbell.mp3. So what I believe I’m missing is the “state” including something that says what song and playlist is playing, and where in the song we currently are.

Does anyone know if this is possible? And how, then, to proceed? And I’m also totally fine not using a python script, that’s just what I though might be easier… once I string together something meaningful from other peoples examples :grin:

Cheers!

You can use the Sonos snapshot service for that.

1 Like

Perfect, it even says “useful if you want to play a doorbell or notification sound and resume playback afterwards”. Not sure how i missed that. Thanks, I’ll try playing around with that!

Unfortunately it also specifies

A cloud queue cannot be restarted. This includes queues started from within Spotify and queues controlled by Amazon Alexa.

That severely limits the utility of that function. Did you ever get this to work?

Wow, that’s an old thread. No, I actually stopped using SONOS. Sorry.