From SMTX Wiki
Jump to navigation Jump to search

After adding a new web service definition, the web service can be used in processes. Go to the Admin-Processes menu and open the process in which you want to use the new web service call. Go to the tab Edit Steps.

   Open a process and click on the tab Edit Steps
   Click on Add new step

Select as step type the option Webservice Call

   Select Webservice Call as step type


Go to the section called Webservice call and click once to open it. In the first field called Webservice call: you will find the added web service call.

   Select your new webservice call in the dropdown list and click Apply.

The list with available fields now shows the fields defined in the webservice definition.

   Select the fields that should be mapped and click Add

Now you can map any value available in the process to any of the webservice fields. Please make sure that all mandatory fields get mapped.

   TIP: Use the Translations section while testing the webservice call by displaying all fields sent into the webservice call fields in the translation section. That way you know what values are sent to the other system.

Using webservice fields in other process steps

If you want to retrieve information over webservice calls, to for example show field values from the external system in the SMTX process, you need to define such a webservice call in the general settings of the process. Open your process and go to General Settings, scroll down till you see Webservice calls.


   Click on Add New webservice call

Give the call a name like Read Incident, or Retrieve Statusses. Then select the Webservice Call you want to use. The list with Output fields will show the fields available after the webservice call has been executed. This is for your information only.

   Give call a name and select your webservice call. See if the call returns the required value.

The input fields list shows the fields that can be provided to the external webservice application. Select any of the fields you would like to have a value and click the Add button.

   Select Input fields to send to the external webservice application

Please note that you can send information to the webservice by adding a field and then use the dropdown lists to select which value to send. Very commonly used is the option to send a reference ID of a ticket created earlier in the workflow as a property for another webservice call. Use the option Previously Entered Field to use return values from earlier webservice calls.

Example process

To better understand where to define your web service calls, this example shows how to do the following:

   Step 1 in workflow: Create Incident in external system.
   Step 2 in workflow: Wait step that waits for external system status field to reach value 'Solved'

For step 1, a process step of type Webservice call should be created as described above. Select the webserice call that can create an incident in your target system. For Step 2, first go to the general settings of the PROCESS and add a new webservice call, as described above. Make sure to define the webservice call that can retrieve a status from your external system. Use the return value of step 1 to provide the webservice call with the ticket number from which the status should be retrieved. Now create step 2 as a process step of type Wait Step. Within the wait step, click Add Condition and choose the type Wait for external value from webservice call. (When the dropdown list is empty, no webservice call has been defined under General Settings of the process.) Select the webservice call that retrievs the status, so that you can use this as a condition in your wait step.