Sonos Say

PlayBar and Play:1 are not S2 devices (Boost I’m not sure)
S1 devices cannot be used for the new Say App.

Be carefull with this info.
According to this info this should not be possible with my Play1?


Here is the correct info:

1 Like

Re-adding the speakers did the trick. Works fine now :hugs:


Thank for this info, makes it complete.

1 Like

Incorrect, Play1 and PlayBar are BOTH S2 and they both work fine with Sonos Say.
S1 Speakers should also work with Sonos Say, it did for me two weeks ago when i updated Sonos Say to include the node-server and added a few new Send Announcement cards.
I had a old Connect (which had my headset on it) and it worked fine with sending URL’s and grouping through Sonos Say.

Hai Jeroen,

This is partly true; after i updated the Sonos Say app to run the node-server itself, Ludvig and I tried to publish it to the Store App. It was denied because they only want one Brand per App.
But they were willing to look at Ludvig’s app (Sonos Say) and take from it what could be used, thats why they added two cards into the Athom Sonos App:

  1. Say … volume … Card
    This uses the ‘old’ google translate TTS engine, which is very limited and in dutch the voice is terrible.
  2. Play Audio Track … volume …
    This one is why i changed the Sonos Say app: send a URL (from my Google Services - Translate and Text-to-Speech to a Sonos device.
    This Sonos Card doesn’t repeat (while the old Play… card does put it in repeat).

Sonos Say does a few things like restoring groups and volumes, and for direct actions like mute unmute it is WAY faster then Athom’s Sonos App.
(The new cards are fast because they seem to be using the direct (UPnP protocols) method.)

So, if you don’t need to regroup after announcement, you could just use the Athom Sonos App.
But i would advice you too use the Google Service speech and not the build in Sonos Say/App “Say(url) cards”, the voices are much better.

1 Like

Well thank you for the explanation, i have been trying to set up the google speech services because the “athom say” cuts of long messages (like telling a joke) but all works right until the last card. play audio clip does not give sound, and no error, play url gives an error about wrong stream format. the generated mp3 seems fine and i can reach and hear it from the browser. What can be wrong?

Weird, you the second person who seems to have this issue.
Are you at Sonos App 6.0.9?

If you play a list or song directly/normal on the Sonos speaker, and then you send Play Audio Clip and/or Play (url), do you hear a very short interruption (listen very carefull!)?

Could you share your two flows?

Yes 6.0.9. i reduced my test to just playing the audio clip. the url is stored in a variable so i can repeat it.

When i am playing music already on the speaker, the music stops for a second silence.
the url pasted in a browser plays the mp3.

A new insight!
if i choose the “play url” card using the variable i get an error. stream

But if paste the url in the box instead of using the variable it does play! but it then keeps repeating as you have already pointed out.

Yeah, i’ve heart this before, there is something wrong with some URL cards of sonos. I guess the Beam-card doesn’t handle it well.
They fixed it a while back, but i guess not good enough.

Eather submit a bug to Athom Sonos App or use the Sonos Say app (which is what this topic is about ;).

Athom allready has an open ticket because the Play URL/AudioCard cannot handle flac files, probably send a header of audio/mpeg with it. Athom is looking into it (i hope). It might be connected.

That was easier said then done… i have now installed the sonos say app from github on the homey, but it is not running “deze app is onverwachts gestopt” Can i see errors in a log somewhere?
I had to fix the json file first, it was missing some " and one or two invalid characters were there.
also warnings about brandcolor missing.
never mind found the log, cannot find module basic-auth

Which repo did you use?

did you do npm install (to update npm packages)?

yes i took GitHub - ludvigaldrin/com.svipler.athom.sonos-say: Sonos Say Athom Homey App it seems to have your PR in there.

npm install did fix the error. the app is running, The text to speech card works but only on shorter messages. This joke does not work… Other trial: the send url as announcement does not give any sound when i try to play the mp3 from the google services app.

How is your trigger flow?
It should be like:
Trigger flow | Homey

And the start speech flow should look like:
Start Speech flow| Homey

Sonos Say - Say card uses the old Google TTS engine with “bad” voice and max 200 characters.

Ah i see 200 chars. Yes i have the TTS flows setup just like the samples. still no sound, just like the play audio clip card of athom. the generated mp3 is checked it is playing from the browser. How can i see the logs and warnings that are emitted in the code?, or even better can i run/debug the code locally using visual studio code? i have tried npm run, that does not start the app.

// Use IntelliSense to learn about possible attributes.
// Hover to view descriptions of existing attributes.
// For more information, visit:
“version”: “0.2.0”,
“configurations”: [
“type”: “node”,
“request”: “attach”,
“restart”: true,
“name”: “Attach to Homey”,
“address”: “”, ← change your IP address
“port”: 9222,
“localRoot”: “${workspaceFolder}”,
“remoteRoot”: “/”
} ]

Then you can debug.

Or disable/comment the “if (process.env.DEBUG === ‘1’) require(‘inspector’).open(9222, ‘’, true);” from app.js OnOAuth2Init.

If you save an URL to a variable and play it in the browser? Does it play?

Wonderfull learning a lot here! i got the error in the log:
2021-03-17T21:35:10.147Z INFO Could not find file /node-sonos-http-api-master/settings.json
2021-03-17T21:35:11.237Z INFO Presets loaded: {}

Think its no coordinator
isRadioOrLineIn uri: x-sonos-htastream:RINCON_949F3EC2767B01400:spdif
2021-03-17T21:36:06.363Z ERROR
Error: Got status 500 when invoking /MediaRenderer/AVTransport/Control
at Object.invoke (/node_modules/sonos-discovery/lib/helpers/soap.js:99:10)
at Player.setAVTransport (/node_modules/sonos-discovery/lib/models/Player.js:727:15)
at /node_modules/sonos-discovery/lib/prototypes/SonosSystem/applyPreset.js:128:46
at processTicksAndRejections (internal/process/task_queues.js:97:5)

i have dug deeper, i intercepted <s:Envelope xmlns:s=“” s:encodingStyle=“”><s:Body><s:Fault>s:ClientUPnPError714</s:Fault></s:Body></s:Envelope>’

and that errorcode shows up as invalid mimet ype if i google it.

What kind of (Sonos) device do you have?

And you got the Debugging working?
Could you set some loging at node_modules\sonos-discovery\lib\modesl\Playes.js line 721 (first line of Player.prototype.setAVTransport)
Could you message me the URL and Metadata arguments BEFORE and AFTER xmlEntities.encode(***?

So, at line nummer 727, insert these lines before the return

I went and installed version 3.1.5 with the buildIn http-api package of sonos. I was using 2.0.1 previously with my own docker installation of the http-api.

Now it cannot find any speakers, any thought what this could be? Because my docker image does find it. And there is no option to change the ‘api’ server. Would rather keep using my own docker.

Would be great if there is a way to resolve this.