Interceptor Rules

Last Updated: 10/10/2018 Introduced in Version:

This example demonstrates how to configure an Interceptor Rule. The Interceptor Rule is set up the same way that a Rule Set is set up. Additionally, a Rule Set has a setting that allows an Interceptor Rule.

For more information on setting up a Rule Set, navigate to the attached link:

 

Example

This example starts with a Rule Set created for the purpose of demonstrating how the Interceptor Rule works. The Rule Set example is named “Pet Insurance”. This Rule Set is set up to evaluate the applicant’s pet according to the Age and Type of the animal that the applicant is applying for.

  • The Completed Rule phrase that will be used as Interceptor Data Rule is displayed in the image below (Figure 1).

Figure 1

 

Setting up the Interceptor Rule Set

Start in a designer Folder, select Create Rule>Rule Set and choose Rule Set.  In the Rule designer select Set up Rule Set from the Actions Panel located at the bottom of the Rule designer page. In the Setup Rule Set in the Rule Set Data section under Inputs add the Inputs (Age, Int32 and Pet Type, String) (Figure 2).

Figure 2

 

Next in the Rule Types section under Interceptor Rules check the box next to Allow Interceptor Rules to turn this Rule type on (Figure 3).

Figure 3

 

 

In the Actions Bar located at the bottom of the Rule designer select Add Rule and then choose Intercept (Figure 4).

Figure 4

 

The Interceptor Rule is applied to an existing Rule Set. Now, edit the Rule Set phrase to evaluate “Not” (This condition returns the opposite result). Select Data Element at the top of the Data Element selector and check the box next to “Not [this condition returns the opposite result]” (Figure 5).

Figure 5

 

After you create the rule phrase select configure and add Inputs to the Rule Set.  This example shows a Rule Phrase with added Inputs (Dog, Cat).  Save and Close the Interceptor Rule (Figure 7).

Figure 7

 

This completes the Interceptor Rule Set Phrase. The next step is to create a Flow. 

 

Create a Flow using the Interceptor Rule

The example below is a flow built for the purpose of demonstrating how Interceptor Rules are configured and how they work in a flow. As you can see the different steps used in the flow example are listed here. 

 

Steps

  • Start Step: Located in the Flow designer.
  • Run Rule Set (Interceptor Rule): Rules> Run Rule Set Step

 

Configure The Steps

Start Step

Select the Start Step and in the Flow Data section under Flow Input Data and select Show Editor to add Input Data. This example uses Pet Type and Age, (Figure 8).

Figure 8

 

Rule Step

In the Run Rule Set Step choose the Rule Set configured above, choose (Pet Insurance). In the Inputs section next to Age choose Select From Flow and Pick the correct Input (Figure 9.

Figure 9

 

In the Inputs section next to Pet Type choose Select From Flow and Pick the correct Input. Next to Rule Set Run Description choose Null. Next to Rule Set Run Name choose Merge Plain Text (Figure 10).

Figure 10

 

In the Merge Text Editor add desired Text. The example states Age (from flow Data) year old Pet Type ( form flow data). Save and exit the Flow to navigate back to the designer folders (Figure 11).

Figure 11

 

In the designer Folders navigate to the Rule Set Results Folder. This folder is automatically generated and will display under the created Interceptor Rules. In the Rule Set Results folder locate Rule Breaks. Under Rule Breaks is where the Interceptor Rule will store caught data. Select one of the results to Edit Rule, change the Rule to evaluate True or False. After the Rule has been edited and changed the Rule will be saved with the edits. Save the changes and the flow will finish (Figure 12).

Figure 12

 

Edit the Rule and add bird to the list of Pet Types to evaluate False. Now the Flow will finish and the Rule will not be caught in Rule Set Results folder (Figure 13).

Figure 13

The Rule has been edited and is now saved with the changes made. The Rule now evaluates False for “bird (Pet Type) is Not in list” (Figure 14).

Figure 14

Complete the flow by selecting the Rule Sets Result report in the designer Folder and select a result in the Intercepted data, choose Run Rules and pick from either All Intercepted Data or This Instance.  The Rule will run and if the Rule was edited to evaluate False it will then clear from the results report (Figure 15).

Figure 15

 

This complete the Interceptor Rule example, for more information on setting up Rule Sets and Interceptor Rules, see attached links. 

 

 

 

Links

Setting up a Rule Set

What are Interceptor Rules

Additional Resources