Jump to: navigation, search

Inbound Transformation Script

The inbound transformation script path is iwd_scripts\iWD2IxnServerTransformer.groovy. The script produces output in UTF-8 for Interaction Server to parse.

Inbound Script Parameters

The script uses the following parameters:

  • CompleteQueues—A comma-separated list of queue names for completed interactions (default iWD_Completed).
  • RestartQueues—A comma-separated list of queue names for new interactions (default iWD_New).
  • CancelQueues—A comma-separated list of queue names for canceled interactions (default iWD_Canceled).
  • ExtendedAttributes—A comma-separated list of attributes that must be present under the <Ext> tag of the CreateTask iWD message.
  • AllowAnyAttributes—If set to true or yes, the transformation script copies any unknown attributes to the transformed message.
  • CaseSensitiveAttributes—If set to false or no, the transformation script ignores the case of known attribute names (including Ext and Data section names).
  • CaseSensitiveActions—If set to false or no, the transformation script ignores letter case of action names.
  • Interaction Server parser and interaction representation are case sensitive. The customized script must take care to produce the output in the correct case.

Root Element

The root element of iWD inbound message may be GTLMessages or GTLMessage. The script checks for the root element name and generates an error if the document root element is anything else. The root element of the transformed messages is always messages and the child elements describe the operations.

Transforming Actions

The iWD message action is the name of the tag of the child element of the root element. Possible actions and their translations are as follows:

  • CreateTask—Translates to <interaction operation='submit'>
  • GetTaskInfo—Translates to <interaction operation='getinfo'>
  • UpdateTask—Translates to <interaction operation='update'>
  • CompleteTask—Translates to <interaction operation='update'>
  • HoldTask—Translates to <interaction operation='hold'>
  • ResumeTask—Translates to <interaction operation='resume'>
  • RestartTask—Translates to <interaction operation='update'>
  • CancelTask—Translates to <interaction operation='update'>
  • CompleteTask, RestartTask, and CancelTask are transformed into the update operation, which allows changing the queue for the interaction. The queue name is then added based on transformer parameters. Specifically, for the CompleteTask action, the first queue name from the transformer parameter CompleteQueues is added as the Queue property of the translated message. For the rest of these actions, the first queue name from the appropriate parameter is taken.

Transforming Properties

The following transformation takes place for the inbound iWD message:

  • All known direct children of the action element are translated according to the Translation Table for Known Attributes (Inbound) below and put into the properties tag of the transformed message.
  • If any unknown tag is encountered, it is ignored if the AllowAnyAttributes option of the transformer is not set to true or yes. If the option is set to true or yes, the attribute is copied without any translation to the properties tag of the transformed message.
  • If the Ext tag is encountered, all children of this tag are copied into the properties tag of the transformed message with the prefix IWD_ext_.
  • If the Data tag is encountered, all children of this tag are copied into the properties tag of the transformed message without any changes.
  • If the Reason tag is encountered, it is translated to the reason tag with the name attribute containing the value of the original Reason tag (for example <reason name="Original Reason"/>).
  • Attributes appear in the transformed message in the order described above.
Translation Table for Known Attributes (Inbound)
iWD Message Attribute Attribute Name in Interaction Server Notes
BrokerId InteractionId
CaptureId ExternalId
Actor Ignored
ActionDateTime Ignored
tenantId IWD_tenantId
solutionId IWD_solutionId
capturePointId IWD_capturePointId Same as SubmittedBy
priority Priority
businessValue IWD_businessValue
channel iWD_channel
category IWD_category
activationDateTime IWD_activationDateTime No default value
dueDateTime IWD_dueDateTime No default value
expirationDateTime IWD_expirationDateTime No default value
processId IWD_processId
departmentId IWD_departmentId
reprioritizeDateTime IWD_reprioritizeDateTime
Hold IsHeld Changed to 0 or 1 (from false or true)
This page was last edited on June 18, 2020, at 10:43.
Comments or questions about this documentation? Contact us for support!