If you are going to post StackOverflow-type questions here, please include the full request/response payload.
Yes, you are so right!
Somehow I've missed this repositories.
I’ll take a look to them
Much appreciated for your input!
If you are going to post StackOverflow-type questions here, please include the full request/response payload.
Request:
<soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:ns="http://www.sonos.com/Services/1.1">
<soapenv:Header>
</soapenv:Header>
<soapenv:Body>
<ns:getLastUpdate/>
</soapenv:Body>
</soapenv:Envelope>
Reply with Skip SOAP Action = false (do not reach API endpoint)
HTTP/1.1 500 Internal Server Error
Cache-Control: private
Content-Type: text/xml; charset=utf-8
Server: Microsoft-IIS/10.0
X-AspNet-Version: 4.0.30319
X-SourceFiles: =?UTF-8?B?RDpcUHJvamVjdHNcV2F5bWVkaWEyMDIwXFdheWJveFdTXFNPTk9TLmFzbXg=?=
X-Powered-By: ASP.NET
Date: Tue, 27 Sep 2022 00:38:43 GMT
Content-Length: 817
<?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><soap:Fault><faultcode>soap:Client</faultcode><faultstring>System.Web.Services.Protocols.SoapException: Server did not recognize the value of HTTP Header SOAPAction: http://www.sonos.com/Services/1.1#getLastUpdate.
at System.Web.Services.Protocols.Soap11ServerProtocolHelper.RouteRequest()
at System.Web.Services.Protocols.SoapServerProtocol.Initialize()
at System.Web.Services.Protocols.ServerProtocolFactory.Create(Type type, HttpContext context, HttpRequest request, HttpResponse response, Boolean& abortProcessing)</faultstring><detail /></soap:Fault></soap:Body></soap:Envelope>
Reply with Skip SOAP Action = true (reaching API endpoint and returning data)
HTTP/1.1 200 OK
Cache-Control: private, max-age=0
Content-Type: text/xml; charset=utf-8
Vary: Accept-Encoding
Server: Microsoft-IIS/10.0
X-AspNet-Version: 4.0.30319
X-SourceFiles: =?UTF-8?B?RDpcUHJvamVjdHNcV2F5bWVkaWEyMDIwXFdheWJveFdTXFNPTk9TLmFzbXg=?=
X-Powered-By: ASP.NET
Date: Tue, 27 Sep 2022 00:40:57 GMT
<?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><getLastUpdateResponse xmlns="http://www.sonos.com/Services/1.1"><getLastUpdateResult><autoRefreshEnabled>true</autoRefreshEnabled><catalog>123</catalog><favorites>1</favorites><pollInterval>30</pollInterval></getLastUpdateResult></getLastUpdateResponse></soap:Body></soap:Envelope>
Basicaly, what I’m trying to do is create an app to select my custom playlist (with my own mp3 files) to my SONOS device,
Just to give un update.
I’ve solved this issue by creating a proxy at my REST API to get the requests