Answered

Is the Alexa AudioPlayer interface now fully supported?

  • 27 February 2021
  • 16 replies
  • 285 views

Does anyone know what elements of the "Alexa AudioPlayer interface" is not supported on Sonos One?

The reason I ask, I have a skill that streams our radio station just fine on Amazon made speakers but plays only silence when the skill is enabled on Sonos One.   The skills interacts fine and says it is playing the station, but only silence is heard - no error prompts.  The station streams fine with the TuneIn skill but we would prefer to promote the "Get Me Radio" skill.  Wondering what I could tell the developers to help them determine why it fails only on Sonos speakers.

 

p.s. I have disabled and re-enabled the skill many times...works consistently with Amazon speakers but fails with Sonos One, no matter what station I select.

icon

Best answer by James L. 2 March 2021, 17:20

View original

This topic has been closed for further comments. You can use the search bar to find a similar topic, or create a new one by clicking Create Topic at the top of the page.

16 replies

Userlevel 6
Badge +15

Hi @mikek401, welcome to the Sonos Community!

Mind sharing a couple of the stations you’re trying this with? That way we can do some testing on our side as well :)

It may also be worth disabling and re-enabling the Sonos skill if you haven’t tried that - I wasn’t sure if you were referring to the Sonos skill or the Get Me Radio skill in your post.

Hi @Xander P, please try “Alexa, ask Get Me Radio to play DOC Radio Christian Hits”.    yep, I’ve tried disable/enable for both the Sonos and Get Me Radio skills - neither helped.

You can try other stations from their directory, such as “Y100 Michiana”.

Userlevel 6
Badge +15

Thanks @mikek401, I’ve been able to test that on my own system and having the same experience - Alexa says she’ll play but then nothing happens.

Taking a quick look through the logs from my system, it looks like the skill is providing audio in an unsupported format, possibly an unsupported bitrate (33kbps) - hope this helps :)

Interesting @Xander P .  In our case, the stream should be 128 kbps as we supplied this stream url: https://streaming.live365.com/a08828

Badge +17

Interesting @Xander P .  In our case, the stream should be 128 kbps as we supplied this stream url: https://streaming.live365.com/a08828

Hey Mike,

 

The issue isn’t with your stream URL - that works perfectly fine and is as you say; 128kbps. The issue is with the URL the Get Me Radio! skill returns, which is https://alexa.getmeradio.com/stations/docradio-christianhits-2051/listen.plsIt seems like there’s an issue with that URL that causes the Sonos players to throw up an “unsupported format” error. We can’t say for certain what the issue is, but as Xander mentioned earlier, it looks to be identifying as a 33kbps stream, instead of redirecting to your 128kbps URL. In something like VLC player, the stream redirects correctly to the URL you provided.

 

I hope that helps :slight_smile:

 
 
 
 
 

 See below

@James L.  @Xander P  The pls contents from the url you highlighted doesn’t specify any bitrate.  What values are required in the .pls for Sonos to play the stream?  Amazon built speakers seem to be quite content with that .pls.

Here is the contents from the .pls returned by the skill:

[playlist]
NumberOfEntries=1
File1=https://streaming.live365.com/a08828
Title1=DOC Radio - Christian Hits
Length1=-1
Version=2

 

By the way, is there any documentation from Sonos on how one accesses the “log files” from the Sonos player?

 

(Disclaimer - I’m associated with Get Me Radio!)

Hello Sonos Devs,

Thank you for looking into this, we’re not sure what the problem could be with the .pls file as it works directly on Alexa devices.

I’m not aware that you can specify bitrates in .pls files, if so we could certainly add it to the generation of the file when the radio stations submit their details.

Do you have any examples (maybe in your documentation) that show a .pls type file format that works on your devices?

Many thanks.

 

Gavin.

 @James L.  @Xander P   Upon further research I found that a private skill created using Amazon’s skill wizard tool,  https://blueprints.amazon.com/skills/ also fails in the same way.  For that skill I tried both https://alexa.getmeradio.com/stations/docradio-christianhits-2051/listen.pls and https://api.live365.com/play/a08828.pls

Both play fine on Amazon speakers but fail on my Sonos One.

The contents of the 2 .pls files are similar, as you can see below.  One merely specifies an http stream and the other an https stream.  So as @Gavin - Get Me Radio!  also asks, “Do you have any examples (maybe in your documentation) that show a .pls type file format that works on your devices?”

 

https://api.live365.com/play/a08828.pls

[playlist]
File1=http://streaming.live365.com/a08828
Title1=DOC Radio
Length1=-1
NumberOfEntries=1
version=2

 

https://alexa.getmeradio.com/stations/docradio-christianhits-2051/listen.pls

[playlist]
NumberOfEntries=1
File1=https://streaming.live365.com/a08828
Title1=DOC Radio - Christian Hits
Length1=-1
Version=2

Badge +17

Hey @mikek401 and @Gavin - Get Me Radio!, thanks for that information.

 

You’re quite right, a .pls file doesn’t contain bitrate information, which makes reading the error log a bit more confusing. We’re not developers here, so I’m afraid help with the API is going to be pretty limited from my side.

I managed to find this documentation around playing radio stations and pls files, though this isn’t specific to Alexa skills. Hopefully it’s of some use though: playbackSession > loadstreamurl

We also have a developer community on Stack Overflow that might be a bit more help in this case.

 

By the way, is there any documentation from Sonos on how one accesses the “log files” from the Sonos player?

 

No, I’m afraid not. System diagnostics are only available internally at Sonos.

@James L.  @Xander P  Would you be able to provide the url of the .pls sent to your speaker when you say “Alexa, ask Live365 to play DOC Radio Top Christian Hits”?   The Live365 Alexa skill is able to stream the station on Sonos speakers so it would be helpful to compare the contents of that .pls with the ones that fail.

Badge +17

@James L.  @Xander P  Would you be able to provide the url of the .pls sent to your speaker when you say “Alexa, ask Live365 to play DOC Radio Top Christian Hits”?   The Live365 Alexa skill is able to stream the station on Sonos speakers so it would be helpful to compare the contents of that .pls with the ones that fail.

Sure, the URL returned by the Live365 skill isn’t actually a .pls file, it requests and plays https://streaming.live365.com/a08828 

@James L.  @Xander P  Interesting... the official developer information from Amazon for the Alexa AudioPlayer Interface states that .PLS is a valid format for the "audioItem.stream.url" parameter:
https://developer.amazon.com/it-IT/docs/alexa/custom-skills/audioplayer-interface-reference.html#audio-stream-requirements

So that brings me back to my original unanswered question (and post subject): Is the Alexa AudioPlayer interface now fully supported?  Any chance you could ask a Sonos developer for the valid options for the audioItem.stream.url parameter?

Remember they can easily re-create the issue by creating your own streaming skill and specify any valid .pls file: https://blueprints.amazon.com/skills/create/amzn.ask.bp.8f2b73a4-056c-4baa-a439-47791d941bad/en-US?ref_=ask_bp_detail_make

Badge +17

So that brings me back to my original unanswered question (and post subject): Is the Alexa AudioPlayer interface now fully supported?  Any chance you could ask a Sonos developer for the valid options for the audioItem.stream.url parameter?

Remember they can easily re-create the issue by creating your own streaming skill and specify any valid .pls file: https://blueprints.amazon.com/skills/create/amzn.ask.bp.8f2b73a4-056c-4baa-a439-47791d941bad/en-US?ref_=ask_bp_detail_make

I’m afraid this question would be better posted over on Stack Overflow for our developer community to take a look at. You’ll get a more accurate answer there a lot quicker than here, since this is a general community forum for Sonos products and services. 

@James L. 

Hi James, is there any way we can contact someone at Sonos (business to business) to discuss this?

We’re struggling to make contact with someone to find out how we can resolve this? Is there any way you could PM me a contact at Sonos to discuss further?

Many thanks.

 

Gavin. 

Badge +17

Hi @Gavin - Get Me Radio!,

 

I’m afraid not. I can only suggest you contact our customer care team and refer to this thread, so they can pass the query on to someone who may be able to handle it further. You can make it clear that I’ve sent you over there, and they can reach out to me with any questions.