Forum Discussion
How to get data from a SOAP WS with Power BI
Hi All
I am facing issues while accessing the token bassed SOAP WSDL in Power BI.
Also any other way to accomplish this task part from Zapsys ODBC
Error
DataSource.Error: Web.Contents failed to get contents from 'https://sync.severa.com/webservice/S3/API.svc' (500): Internal Server Error
Details:
DataSourceKind=Web
DataSourcePath=https://sync.severa.com/webservice/S3/API.svc
Url=https://sync.severa.com/webservice/S3/API.svc
Code in Advance Editor
let
Source = Xml.Tables(Web.Contents("https://sync.XXXXXX/S3/API.svc"
,[Content=File.Contents("C:\XX\post.xml"),Headers=[#"Accept-Encoding"="gzip,deflate", #"Content-Type"="text/xml;charset=UTF-8"]]))
in
Source
post.XML
<?xml version="1.0"?>
-<soapenv:Envelope xmlns:soap="http://soap.severa.com/" xmlns:ns1="http://soap.severa.com/" xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">-<soapenv:Header>
<ns1:WebServicePassword>Api Token Key</ns1:WebServicePassword>
</soapenv:Header>-
<soapenv:Body>-
<soap:GetHourEntriesByDate>
<soap:startdate>2020-04-12T09:00:00</soap:startdate>
<!--Optional:--></soap:GetHourEntriesByDate>
</soapenv:Body>
</soapenv:Envelope>
Have you tried to get data with SOAP UI or POSTMAN software?
If it is OK - then I recommend to watch carefully for the headers in POST metod.
- Anonymous6 years agoNot applicable
Yes its working in SOAP UI and I have created above mentioned xml and query by following this thread.
- Anonymous6 years agoNot applicable
Then it should work.
I had a trouble in some unnoticable things - like conncetion string ending...
Also I do not see that in your XML you use #(0022) instead of " . See my example below - may the trouble in it.
body="<soapenv:Envelope xmlns:soapenv=#(0022)http://schemas.xmlsoap.org/soap/envelope/#(0022)
- Anonymous6 years agoNot applicable
I am not using #022 in soap UI and also I made this by review previous posts and they are not using this.