This article covers using the Execute Process action in irAuthor to call a process from Process Automation.
Adding the Execute Process action to a Rule Set
In order to execute a Process Automation process from rules, start by adding an Execute Process action to a rule set:
This will add a new action to your rule set and open an editor for selecting and configuring the process. First, you will need to select an environment by clicking on the blue arrow button for the Environment setting. This will open the same environment selector used for syncing form schemas from Process Automation. Next, select the process to execute in the Process setting.
How to Pass Data from InRule to a Process in Process Automation
Within Process Automation, ensure the process is configured to receive messages. The message name and message field names can be found in the process under the Configure message option of the start event. Take note of this information to enter into the Execute Process action in irAuthor. More information about configuring messages can be found on the Process Automation Help Center.
In irAuthor, fill out the Message Name and Message Fields based on the message configured for the process start event in Process Automation. Set the name and value for each message field in the Message Fields grid. When rule authoring is complete, you can test calling the process using irVerify.
Testing the Execute Process action
When testing a rule that uses the Execute Process action, it is important that you select the Test button under the Process Automation tab, rather than the test button on the Home tab.
This will bring up the Process Automation environment selection screen before opening irVerify. Once irVerify has launched, fill out any entity fields you want to use for the test, then Apply Rules. This will invoke the Process Automation API with the credentials from the selected environment, and start the process specified in the rules.
Note: Since Process Automation processes are asynchronous, information on the status of the process is not returned. If the process is successfully queued, you should see “success”:true in the State Changes tab in irVerify.
To see the status of your process within Process Automation, go to the Lists area in the Process Automation portal, then select All instances. Once the process has completed, you will see a check in the status column for the instance:
How to Execute Rules that call a Process Automation Process from the Rule Execution Service
This video contains a general overview for executing rules using the Rules Execution Service. In the case where the rule application contains an Execute Process action for Process Automation, then additional configuration will be needed in the form of runtime overrides. More information about runtime overrides and how they are added through the InRule SaaS portal can be found here.
To enable the Rule Execution Service to connect with Process Automation, runtime overrides will need to be configured to provide the API URL and authentication credentials.
The main runtime override that will need to be provided is for authentication with Process Automation. To do this:
- Add a RestOperation for the Body.
- Make the name of the override Authenticate Process
- And the value as the username, password, and API key for connecting to Process Automation in the following format: username=yourUsername&password=yourPassword&apikey=yourApiKey
Trial Users Only: Need to request an API enabled account from InRule support in order to provide the above credentials.
If you want your process action to connect to a different Process Automation environment than the one selected in your rule app, you can optionally provide a runtime override for the URL for your desired Process Automation environment. To do this:
- Add a RestService for the RestServiceRootUrl
- Make the name of the override ProcessEndpoint
- Make the value the URL for your desired Process Automation Environment with the API route added in the following format: https://yourProcessAutomationEnvironment.inrulecloud.com/api/v1.0
Please sign in to leave a comment.