Passing SOAP Header with XML Query
Hi,
I have a Report requirement to have Web Services as a Datasource. The Service is a secured one.
So it requires SOAPHEADER to be passed along with the query.
I have the current query as :
<Query>
<SoapAction>http://location.company.com.au/services/GetLocation</SoapAction>
<Method Namespace="http://location.company.com.au/services/" Name="GetLocation">
<ServiceAuthHeader xmlns="http://location.company.com.au/services/">
<Username>userLocator</Username>
<Password>123456789</Password>
</ServiceAuthHeader>
<Parameters>
<Parameter Name="typeID" Type="integer">
<DefaultValue>2</DefaultValue>
</Parameter>
</Parameters>
</Method>
<ElementPath IgnoreNamespaces="true">*</ElementPath>
</Query>
I tried adding <soap:Header> tag in the query but it gives error
Please let me know the way to pass the SOAPHeaders with the above SSRS query.
PS: Through Fiddler the following Request works fine and response is provided.
<?xml version="1.0" encoding="utf-8"?>
<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
<soap:Header>
<ServiceAuthHeader xmlns="http://location.company.com.au/services/">
<Username>string</Username>
<Password>string</Password>
</ServiceAuthHeader>
</soap:Header>
<soap:Body>
<GetLocation xmlns="http://location.company.com.au/services/" />
</soap:Body>
</soap:Envelope>
Thanks in Advance - M. MahendraPlease click the 'Mark as Answer' button if my Reply helped you to solve your problem! Thanks M.Mahendra
February 1st, 2012 8:39pm
Hi M. Mahendra,
Thanks for the question. In order to pass soap header as parameter, please try tp enclose it in the tags. This is one similar thread, please reference
it:
How to pass in SOAP Header when querying XML
datasource
Thanks,
Sharp Wang
TechNet Subscriber
Support in forum
If you have any feedback on our support, please contact
us.
Please remember to mark the replies as answers if they help you and unmark them if they provide no help.
Free Windows Admin Tool Kit Click here and download it now
February 5th, 2012 8:54pm
Hi M. Mahendra,
Thanks for the question. In order to pass soap header as parameter, please try tp enclose it in the tags. This is one similar thread, please reference
it:
How to pass in SOAP Header when querying XML
datasource
Thanks,
Sharp Wang
TechNet Subscriber
Support in forum
If you have any feedback on our support, please contact
us.
Please remember to mark the replies as answers if they help you and unmark them if they provide no help.
February 5th, 2012 8:54pm