Mapping XML data types


To define the user name and password to be used when consuming the web service with a SOAP header, map the SOAP attributes for user name and password in the Input Mapping table of the Set Fields action. The following figure shows an example using the AR Authentication option.

setfields_ar_auth.gif

For each authentication type and based on the selected WSDL, the authentication elements in the XML Data Type column change. The mapping options in the Form/Field and Mapping Info columns also change depending on the Authentication type. In general, you can use any of these methods to map the user name and password values:

  • Map the XML data types to character fields in the associated form.
  • Provide static values (the default XML data type).
  • Use the AR System user name and password of the user currently executing the filter.

You can also use a combination of these mappings. If the user name and password elements are mapped to fields, the AR System server first attempts to retrieve the values from those fields. If the field values are NULL, then the AR System server checks for the static value (in the default attribute) of userName and password, and uses it if present. If the mapped fields and the default values are NULL the current AR System user name and password of the user executing the filter action are used.

Tip

You can see the XML attributes and their values for any element in the XML Data Type column by hovering the mouse cursor over the element.

Mapping XML data types using AR Authentication

Use the AR Authentication method when the web service is hosted on an AR System server. In this case, Developer Studio automatically sets the XML attributes arUsername: true and arPassword: true. In the Input Mapping table, this is represented by the entries User Name and Password in the Mapping Info column. This allows the AR System server to use the current user's user name and password at run time.

To enter static values for userName and password with AR Authentication

  1. In the Form/Field column, click in the cell corresponding to the userName attribute.
  2. Type the user name, and then press Enter.
  3. Repeat steps 1 and 2 in the cell corresponding to the password attribute, typing the password.
    The password is obscured as you type.

To map the userName and password attributes to fields in the form

  1. In the Form/Field column, click in the cell corresponding to the userName attribute, and then click the ellipsis (...) button.
  2. In the Field Selector dialog box, select the appropriate field, and then click OK. For example, map the Requester field to userName.
  3. Repeat steps 1 and 2 for the password attribute.

Tip

To configure the input mapping to have both a field mapping and a static value, enter the static value first. Then, click in the cell again without deleting the static value, click the ellipsis, and select the field to map. To verify that the static value has been assigned, hover the cursor over the appropriate field and check the value of the default attribute. If you delete the field mapping after doing this, the static value is also deleted.

Mapping XML data types using custom authentication

Use the custom authentication method for an external web service, not hosted by an AR System server, where the Username Token is not required. The consumed web service must be designed to recognize the fields that contain the user name and password. In this case, the SOAPHeader element is not used in the input mapping. The following figure shows the input mapping being configured for the Custom authentication method. 

setfields_ar_auth.gif

With the custom method, you can enter a static value for the user name and password, map fields to the appropriate attributes, use the run time user's AR System user name and password, or any combination of the three. With the Custom method, when you use the Mapping Info column to identify which element the web service should use as the User Name and password, Developer Studio also sets the attributes arUsername and arPassword to true

To assign the User Name and Password flags to the appropriate elements

  1. In the Mapping Info column, click in the appropriate cell for the XML data type you are using as the user name.
  2. Click the drop-down menu icon that appears, and select User Name.
  3. Press Enter.
    If you click elsewhere on the table instead of pressing Enter, the attribute is not set correctly.
  4. Repeat steps 1 through 3 for the XML data type you are using as the password.

Mapping XML data types using Username Token authentication

The WS-Security WS-Security Username Token 1.0 standard allows you to specify whether you send the password in digest or plain text format. Digest format is a hash, and the consuming web service must know the password to authenticate the password. For documents describing the WS-Security Username Token 1.0 standard, see http://www.oasis-open.org/committees/tc_home.php?wg_abbrev=wss.

For a web service that requires the Username Token, the selected WSDL might not indicate that a Username Token is required. In that case, the designer must know whether the web service requires the Username Token and create the workflow accordingly.

With the Username Token method, you can perform any of the following tasks or a combination of any of them:

  • Enter a static value for the user name and password
  • Map fields to the appropriate attributes
  • Use the run time AR System user name and password

With this method, Developer Studio automatically sets the XML attributes arUsername: true and arPassword: true, but this is not reflected in the Mapping Info column. For this method, the Mapping Info column defines whether to send the password in digest or plain text format. 

setfields_usernametoken_auth.gif

To map fields or assign static values for the user name and password elements, follow the procedures in Mapping XML data types using AR Authentication.

To assign digest or plain text format to the password element

  1. Click in the Mapping Info cell for the Password element.
  2. Click the drop-down menu that appears, and then select Digest or Text.

 

Tip: For faster searching, add an asterisk to the end of your partial query. Example: cert*