How to pass parameters and load the wsdl using Web

2019-09-19 09:30发布

问题:

Hi I am working with Mule Studio and i just want to know how can i pass the parameters and call the particular Operation from SOAP using the Web Service Consumer component.

Payload i am setting as #[{'Orlando','United States'}] for the operation GetWeather

The sample SOAP service i am using is LINK

回答1:

Here you have a video demonstration on how to do it.

Here the manual Page, and here an example.

If you don't want to use DataMapper, I would recommend to use a CXF client or to write a specilized connector.

If you still want to use the web service consumer no matter what, you just need to set a payload with the body (this is just the body, not the whole envelope) of the operation. You are passing a JSON, this more than probably won't work. You need to convert it to a proper XML SOAP request body.