I've been having trouble sending Matlab SOAP request callSoapService(endpoint,soapAction,message) <--http://www.mathworks.com/help/techdoc/ref/callsoapservice.html
For instance how would I find the endpoint, soapAction, and message in http://www.webservicex.net/FedWire.asmx?WSDL
I understand that there are multiple possible soapActions, endpoints, and messages in a wsdl but I was just looking for an example of any SOAP request.
This is the process you need to go through.
First, create a class from the WDSL definition:
This will create a directory called @FedWire in the current directory. You can dir this directory or use the following to explore the services that FedWire offers:
Before you can use the web service, create an instance of the FedWire object:
To use a service, for example, GetParticipantByLocation, which requires a City and StateCode:
Result should be true and FedWireLists is a deeply nested structure containing the data returned.
Opening @FedWire\GetParticipantsByLocation.m reveals how the MATLAB generated code is using createSoapMessage and callSoapService. If the service does not support WSDL queries, then using these low level functions becomes necessary.
The parameters for createSoapMessage are populated like this:
and callSoapService:
The following code makes the same query with the low level calls:
I had a lot of trouble making these examples work because I was capitalizing the service domain name like this
www.webserviceX.NET
which I took from their example XML. When I changed to lowercase, it worked.The example using
createClassFromWsdl
is an adaptation of http://www.mathworks.co.uk/products/bioinfo/examples.html?file=/products/demos/shipping/bioinfo/connectkeggdemo.html