Creating Rule Based Alerts

In the last blog, you learnt about creating Record Based Alerts. Here, we will focus on Rule Based Alerts. Rule Based alerts are designed for specific conditions. There are two types of Rule Based Alerts:

  1. Simple: Create Alerts based on the View of an entity.
  2. Advanced: Create alerts based on filter criteria or conditions (conditions defined in Fetch XML).

To create Rule Based Alerts go to Alerts4Dynamics App–>Alerts–>New and set the Alert Type as Rule Based. Select the Rule Mode as Simple or Advanced.

Fill the fields:

  1. Name: Enter a suitable name for this Alert.
  2. Alert Type: Select the type of alert you are creating. Here you have the option to choose Rule Based or Announcement. Select Rule Based from the dropdown.
  3. Entity Configuration: Select one of the entities for which you have enabled Entity Configuration.
  4. Rule Mode: This option only appears for Rule Based alerts.

Simple Alerts

a) Simple alerts are rule-based alerts created based on System Views related to the entity whose Entity Configuration has been selected. Select the View for which Alert has to be created.

b) Select the Interval:

  • Poll Interval: This is the duration after which the system checks if any new record has been created in selected view of the entity in order to create a new notification for it.

The workflow can run:

  1. Only Once: The alerts for all the records in selected view are created Only Once.
  2. X Hour(s): New records in the defined condition are checked for in every X Hour(s). If new records are found based on the defined condition, new notifications are created for them.
  3. X Day(s): New records in the defined condition are checked for in every X Day(s). If new records are found based on the defined condition new notifications are created for them.
  4. X Week(s): New records in the defined condition are checked for in every X Week(s). If new records are found based on the defined condition, new notifications are created for them.
  5. X Month(s): New records in the defined condition are checked for in every X Month(s). If new records are found based on the defined condition, new notifications are created for them.
  • Interval: This is a numeric value of X in the Poll Interval. The minimum value X can correspond to 2 hours.

c) After entering values in the Alerts field click on Save and the alert will be created. Create new message from the Messages subgrid. To know how to Add New Message skip to Message section.

Advanced Alerts

Alerts can be created based on conditions.

You have to enter your query in Fetch XML. For e.g. If you want to send alerts to all the Invoices whose Total Amount is greater than or equal to 1000, you have to enter the Fetch XML for it. Below is the Fetch XML for Total Amount in Invoices greater than or equal to 1000.

<fetch version=”1.0″ output-format=”xml-platform” mapping=”logical” distinct=”false”>

<entity name=”invoice”>

<attribute name=”name” />

<attribute name=”customerid” />

<attribute name=”statuscode” />

<attribute name=”totalamount” />

<attribute name=”invoiceid” />

<order attribute=”name” descending=”false” />

<filter type=”and”>

<condition attribute=”totalamount” operator=”ge” value=”1000″ />

</filter>

</entity>

</fetch>

a) To create an Advanced Alert, select Rule Mode as Advanced and enter the Fetch XML as per your conditions.

b) After creating the Alert, you can add a message to it.

To know how to Add New Message click here.

To explore the above illustrated features , download free trail of Alerts4Dynamics from our Website.

Also, don’t forget to send us your valuable feedback at crm@inogic.com