Forum Discussion
How to get data from a SOAP WS with Power BI
I have solved the problem
I needed in URL of WSDL - remove in the end "?wsdl"
let
body="<soapenv:Envelope xmlns:soapenv=#(0022)http://schemas.xmlsoap.org/soap/envelope/#(0022) xmlns:csv=#(0022)http://www.csv.org#(0022)>
<soapenv:Header/>
<soapenv:Body>
<csv:ReportTransactions>
<csv:DateFrom>2020-01-01</csv:DateFrom>
<csv:DateBy>2020-01-04</csv:DateBy>
<csv:UNP>691759953</csv:UNP>
</csv:ReportTransactions>
</soapenv:Body>
</soapenv:Envelope>",
Source = Xml.Tables(Web.Contents("http://XXXXXXXXXXX/ws/ws_csv.1cws",
// NOT http://XXXXXXXXXXX/ws/ws_csv.1cws?wsdl -
// this ending ?WSDL stopped the recieving of the response!
[Content=Text.ToBinary(body),
Headers =[
#"Authorization" = "basic XXXXXXXXXX",
#"Accept-Encoding"= "gzip,deflate",
#"Content-Type"="text/xml;charset=UTF-8"
]])),
Table = Source{1}[Table],
Table1 = Table{0}[Table],
Table2 = Table1{0}[Table]
inHi 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>
- Anonymous6 years agoNot applicable
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)