Create a flow rule

Create a new flow rule just as you create business process maps, except that, for a business rule you define the inputs and outputs. A business rule can only contain automatic activities.

Once a business rule is created, you can save the rule in an unreleased (work in progress) state so that it can be modified later. However, you must release the business rule before using the rule in a process or form.

When you configure an activity with the business rule, create new job, or custom service and if you double-click on the activity, the configured rule, process, or custom service is opened in a new tab.

You can also generate a flow rule using Generative AI.

The Chat with Copilot icon helps you open a Chat window where you can provide your request and get a response from the Copilot. For tips on how to use a Copilot, see Tips for using Copilot.

  1. Navigate to Workflow > Business rules.
    The Business rules page appears.
  2. Click New > Flow rule.

    A new business rule opens in a new browser tab.

  3. Configure the properties for the business rule. See Properties of a business rule.
  4. Create variables for the business rule and set the variables as rule inputs and outputs.
    1. On the modeling bar of business rule, click Variables and click New.

      The New variable dialog box is displayed.

    2. Enter a Name for the variable.
      By default, the name of the variable becomes the ID of the variable; however, you can change the ID if needed.
    3. Select the variable Type, such as Date. (Default: String)
    4. To set the variable as input, select Input and provide a value.
      A business rule supports dynamic complex variables as input. These input variables can hold the data from a table field within a document for validation, such as in creating a running total for a column.
    5. To set the variable as output, select Output and provide a value.

      If you select a String variable, you can use error codes within the business rule so that the output can be translated. For this, select Error code or Error code message (Default: Static) for Value. Error message is only populated when the business rule is called from the parent map.

    6. Click Add another to add as many variables as needed without navigating away from the New variable dialog box or click Add and close to add one variable and close the dialog box.

      The Variables page appears.

    7. Similarly, create other variables.
      By default, all the variables are sorted on Name and displayed in ascending order. However, you can sort (ascending or descending) on the following columns: Name, ID, Type, Value, Input, and Output.
    8. To view the variables of a specific type, on the Type filter, select the variable type, such as Folder. (Default: All)
      The variables of the selected type are displayed.
      The Type filter only contains the variable types that exist in the list for the current business rule.
  5. To set the order in which TotalAgility should process the input and output variables, perform the following steps:
    1. Click the Input/Output order link on the Variables page. The Input/Output variables dialog box is displayed.
    2. Select the Input or Output tab and use or .
    3. Click OK.
  6. Add activities, decision nodes, and an end node.

    A business rule only supports automatic activities (except Export and Transfer); it does not support manual activities.

  7. Release the rule.

Generate a flow rule using Generative AI

Use the Generative AI functionality to pass a request to the AI provider to generate a flow rule.

  1. Navigate to Workflow > Business rules.
    The Business rules page appears.
  2. Click New > Flow rule.

    The New business rule Design view opens in a new browser tab.

  3. Click the Chat with Copilot icon .
    The floating Chat with Copilot window appears with the following message: "Welcome <username>, what type of business rule would you like to create? An example request might be "Validate claim."

    You can pass the request as a plain text or provide an image as an input to get a response from the Copilot.

  4. See Generate a process using Copilot for additional steps.