Trigger

The Trigger is a Business Rule which stipulates the conditions under which Messages will be sent for the Process concerned.

Business Rule Fields

When configuring a Trigger (Business Rule) on a table to be integrated, make sure one doesn’t exist already. If you have more than one, you will make duplicate updates.

In the native ServiceNow window, navigate to System Definition > Business Rules. Click New.

The Business Rule fields to be configured are as follows:

The top section of your Business Rule record should look like this:

When to run Fields

Click on the 'When to run' tab and configure the fields as follows:

Your 'When to run' tab should look like this:

Advanced Fields

Click on the 'Advanced' tab and configure the fields as follows:

*Script:

The code in the script field should look like this:

(function executeRule(current, previous /*null when async*/) {

    x_snd_eb.snd_console.execute('Business rule: Unifi Incident trigger', function () {
        x_snd_eb.ActivityLog.setDocument(current, current.getTableName());
        x_snd_eb.Message.processOutbound(current);
    });

})(current, previous);

Your 'Advanced' tab should look like this:

10) Click Submit.

The main elements are now in place for our Integration to work. We are now ready to configure and test each of our Scenarios in turn.

Last updated