airsonic / airsonic

:satellite: :cloud: :notes:Airsonic, a Free and Open Source community driven media server (fork of Subsonic and Libresonic)
https://airsonic.github.io
GNU General Public License v3.0
2.01k stars 235 forks source link

Sonos integration failing #1757

Open colinhowe opened 4 years ago

colinhowe commented 4 years ago

Problem description

I'm running version 10.6.2. I've enabled the sonos integration via settings. Just ticked the box. It isn't appearing in the sonos controller.

Looks like it's finding the sonos speakers but failing to update them.

2020-06-14 07:42:58.827 INFO --- o.a.player.service.SonosService : Found Sonos controllers: [192.168.0.217, 192.168.0.148]
2020-06-14 07:42:58.829 INFO --- o.a.p.s.s.SonosServiceRegistration : Enabling Sonos music service, using Sonos controller IP 192.168.0.217, SID 242, and Airsonic URL http://192.168.0.254:8080/ws/Sonos
2020-06-14 07:42:58.850 WARN --- o.a.player.service.SonosService : Failed to enable/disable music service in Sonos controller 192.168.0.217: org.apache.http.client.HttpResponseException: status code: 400, reason phrase: Bad Request
2020-06-14 07:42:58.852 INFO --- o.a.p.s.s.SonosServiceRegistration : Enabling Sonos music service, using Sonos controller IP 192.168.0.148, SID 242, and Airsonic URL http://192.168.0.254:8080/ws/Sonos
2020-06-14 07:42:58.879 WARN --- o.a.player.service.SonosService : Failed to enable/disable music service in Sonos controller 192.168.0.148: org.apache.http.client.HttpResponseException: status code: 400, reason phrase: Bad Request

System information

luciofsl commented 4 years ago

I'm also have this problem, the post to create a custom service at sonos fails with bad request. I created the service manually with the same parameters, but the login fails when I tried to add in sonos app.

POST /customsd HTTP/1.1
Content-Length: 512
Content-Type: application/x-www-form-urlencoded; charset=UTF-8
Host: 192.168.17.181:1400
Connection: Keep-Alive
User-Agent: Apache-HttpClient/4.5.9 (Java/1.8.0_252)
Accept-Encoding: gzip,deflate

sid=242&name=AirsonicService&uri=http%3A%2F%2F192.168.17.204%3A4040%2Fairsonic%2Fws%2FSonos&secureUri=http%3A%2F%2F192.168.17.204%3A4040%2Fairsonic%2Fws%2FSonos&pollInterval=1200&authType=UserId&containerType=MService&caps=search&caps=trFavorites&caps=alFavorites&caps=ucPlaylists&caps=extendedMD&presentationMapVersion=1&presentationMapUri=http%3A%2F%2F192.168.17.204%3A4040%2Fairsonic%2Fsonos%2FpresentationMap.xml&stringsVersion=5&stringsUri=http%3A%2F%2F192.168.17.204%3A4040%2Fairsonic%2Fsonos%2Fstrings.xmlHTTP/1.1 400 Bad Request
Content-type: text/html
Server: Linux UPnP/1.0 Sonos/58.1-77280 (ZPS21)
Connection: close

<HTML><HEAD><TITLE>Error 400</TITLE></HEAD><BODY><H1>Error 400</H1><P>Bad Request</P></BODY></HTML>
randomnicode commented 4 years ago

airsonic-advanced has a functional Sonos integration.

I don't think vanilla airsonic does yet, certainly not in 10.6.2

luciofsl commented 4 years ago

Yes, I just migrated to airsonic-advanced and setup sonos with success. Many thanks.

colinhowe commented 4 years ago

@luciofsl does the search function work for you?

luciofsl commented 4 years ago

@colinhowe, yes I can search by Artists\Albuns\Songs... at leats in windows app.

colinhowe commented 4 years ago

@luciofsl sorry, I meant: does search work in the sonos app?

luciofsl commented 4 years ago

Yes, it works.

image

stale[bot] commented 4 years ago

This issue has been automatically marked as stale because it has not had recent activity. Thank you for your contributions.