SOAP Web Service Connections

One of the TaskCentre administrator’s responsibilities is the global configuration of connections, to make them available for task designers. This includes the configuration of web service connections. Both SOAP and REST web services are configurable in TaskCentre.

swc-screen1

Above: You use the Web Service Connector tool to configure web services in TaskCentre. You can use it for both SOAP and REST web services. The tool’s global configuration is accessed in the Execute tool group.

You can now see the Web Service Connector tool listed in the pane on the right. Double clicking the icon opens the Web Service Configurations dialog box.

swc-screen2b

Above: The Web Service Configurations dialog box lists any web services that have already been configured and allows you to edit or remove them. It also allows you to add new web service configurations.

Clicking the add button opens the New Configuration dialog box.

swc-screen3b

Above: In the New Configuration dialog box you give the new configuration a name and select the description option that suits your connection architecture or standard.
The SOAP service we are configuring provides a weather forecast. We have entered “Weather conditions” as the new configuration name.

For a SOAP connection, which makes use of a WSDL definition file, you can provide the path to the WSDL file; otherwise, you can enter the URL which links to the web service provider’s WSDL file.

In this case, we have obtained the URL for the web service, so we select the radio button for the option The Web Service publishes a WSDL definition and I know the URL and have entered the appropriate URL.

For this example, we have entered the URL for the weather service, which we obtained from the web service provider’s documentation.

Background to the weather service example

We’ve used a USA-based web service which operates only with USA postal codes (“zip” codes). For instance, 33040 is the code for Key West in Florida. Key the URL into your web browser to try it out.

This method shows you a way of manually invoking a request through a web service, whereas TaskCentre does this in an automated manner. This manual method is shown here just to aid understanding. The example shows you how to automate this service through TaskCentre.

For your convenience, we’ve provided here the web link to the WSDL file we’ve used in this example, so that you can refer to it or copy it and try it out in your own web browser.

This is the URL for this web service’s WSDL file:

http://wsf.cdyne.com/weatherws/weather.asmx?wsdl

And this is the URL for this web service itself, where you can test the available operations and view the SOAP request and response in XML format:

http://wsf.cdyne.com/weatherws/weather.asmx?

Clicking OK accepts the settings and continues the configuration.

swc-screen4

Above: The WSDL Web Service Configuration dialog box opens. It consists of five tabbed pages.

The General tabbed page contains the name of the newly added configuration and provides a text area where you can add your own description of the service if you so choose.

swc-screen5

Above: The Endpoints tabbed page contains a setting for the port or endpoint for the WSDL definition: you can select the appropriate one from a drop- down list. Some web services have a number of endpoints defined, allowing a user to decide which protocol to connect with, depending on the preferred method or availability.

There is also a setting for overriding the URL used to call the WSDL file, as this may differ from the URL used to call the actual service.

On this occasion, we’ll accept the WeatherSoap endpoint for our method of sending messages. And move on to the Operations tab.
swc-screen6b

Above: The Operations tabbed page lets you de-select operations from the total available from the web service, as derived from the WSDL file. It also lets you combine more than one operation into a single operation. These are known as ‘Multiple Message Operations’ or MMO’s.

You can choose to test any of the available operations. If you do this, a Test Web Service Configuration dialog box opens, which lists the results when done.

swc-screen8b

Above: Here we can see the Test Web Service Configuration dialog box. This allows you to enter values for any of the operation’s available parameters and run the test.

1 – In this example the GetCityForecastByZIP operation has the parameter ZIP.
2 – We have entered a value (a postal code) for the parameter ZIP. Clicking the Test button runs the test.
3 – The test performs the selected operation on the web service and returns the results.

swc-screen9

Above: We will now move onto to the Constants Tab. The Constants tabbed page lets you define constants that can be used by task designers. A typical example would be the username and Password required to log on to a web service. Constants can be configured at a later time.

We will now move on to the Authentication tab.

swc-screen10b

Above: The Authentication tabbed page lets you specify the authentication method, if required. You can choose between None, Basic/Digest and Windows.

There is a test function available, which tells you whether the selected web service requires authentication and also whether the method you have chosen has sufficient strength to meet the requirements of that service.

This concludes configuring the new SOAP web service. Click OK to accept your settings and close the dialog box.

swc-screen11

Above: The newly created SOAP web service is now displayed in the list of available web service configurations.

SOAP Web services: In summary

Among the global configuration done by the TaskCentre administrator is that for web service connections.There are two sorts of technology providing for the exchange of information in web services – SOAP and REST.

REST is not in itself a standard but a set of design principles based on HTTP and XML.

SOAP is a W3C protocol that uses HTTP, XML and a range of other standards. One of those is WSDL, a definition language used to locate and describe each resource.

SOAP configuration is done using the Web Service Connector tool. You can add new service configurations, select operations and their parameters, test, edit or delete them, and set constants and authentication.

Return to TaskCentre Administration