WSDL Connector
Symptoms
How do I set up a Connector to a Web Service (WSDL Connector)?
Environment
VoiceObjects
- VoiceObjects> 9 is the easier part as we don't need to take the parameter type too much into account.
- VoiceObjects < 9 needs to be treated differently as older versions can't work with complex datatypes. The general setup is equal though.
Setting up the Connector Object
- Connection Parameters
- Class/Port: The web service port type to be used.
- Method: The Method to be called.
- WSDL Location: Resource Locator to the WSDL
- WSDL File: Link to the file / application which provides the WSDL to VoiceObjects
Some webservices additionally present the WSDL in a HTML page. This can't be used as WSDL source!
- Input Parameters
- Only simple types -> 1 parameter item per parameter
- Complex types -> 1 single parameter containing full XML structure
To pass complex parameters to a WSI backend the following steps need to be taken:
- Create one XML structure containing all variable contents (like in the original SOAP request), this XML needs to contain all data which is inside the <soap:Body> element
- Pass this data into all parameters (each input parameter needs to be a parameter in the object)
- To create the XML use a script object by using the E4X JavaScript functionality - EcmaScript for XML
- Output Parameters (only 1 return value!)
- Simple type -> directly available via Return value
- Complex type -> XML structure available via Return value
Please download the WSDL for the examples here: CardPaymentService.wsdl