Triggers and Automation
Triggers and automation rules modify document properties based on predefined conditions and actions. They can be helpful in implementing budget and security policies, and for tailoring efficient workflows.
Triggers run when a document is added or printed, and execute when a predefined set of conditions is met.
Automations run every 15 minutes and execute if conditions are met.
In this section, the triggers & automation features are explained, and these main aspects will be covered:
- Building condition and action statements
- Name triggers and automations using descriptive names
- Reordering triggers and automations to achieve the desired outcome
- Avoid conflicting triggers or automation
Working with triggers & automation
Triggers and Automation rules are handled in the Dispatcher Paragon Cloud Web UI under each account and office. Therefore, you can set up rules for an entire organization or a specific office within the organization.
On the Triggers & Automations pages, you can search for, add and reorder rules. You can also edit, clone, and deactivate/activate specific triggers/automation. Note that inactive rules are shown at the bottom of the table. Only inactive rules from the list may be deleted.
Rules are run, and possibly executed, in a sequential cycle according to the order defined in the Web UI. Whenever the conditions for a specific rule are met, and an action is executed, the cycle restarts (see flowchart below). This cyclic flow ensures that interdependent rules execute as expected with fewer requirements for detailed ordering of rules.
Default triggers
Certain Dispatcher Paragon Cloud functionalities are implemented as default triggers when a new tenant is created.
Default rules
Certain Dispatcher Paragon Cloud functionalities are implemented as default rules when a new tenant is created. For example, an automation will mark print jobs as expired after 32 hours. We recommend you not to deactivate or delete the default rules. Be aware that some default rules, such as Delete expired failed scan jobs, do not have the Delete and Edit options.
Delete expired failed scan jobs
This rule controls Retention in My documents. If you wish to decrease it and have the new value displayed to the end users correctly, clone it and make sure the cloned rule contains the following three conditions:
- Hours since document created
- Documents status Is Failed
- Job type Is Scan
If you use higher value than 7 days in your cloned rule, then the default rule will take precedence.
Building condition and action statements
Both Triggers and Automation consist of condition statements and action statements.
- Condition statements consist of conditions, field operators, and condition values (these vary depending on the condition selected). Condition statements are essentially ‘if’ statements that return all print jobs that meet the specified criteria.
For condition statements, the trigger will execute whenever the condition is changed. 'Changed' means any update made to the value, even if the value previously did not exist. For example, the Input Port Name trigger condition will execute even if the Output Port did not exist when a trigger was defined. - Action statements consist of actions and action values (these vary depending on the condition selected). Some actions will be unambiguous, in which case a value does not apply – for example, the Delete Document action. Action statements define what occurs if all the condition statements are true and the trigger executes. You can think of action statements as ‘then’ statements – if all your conditions are true then perform these actions to update the document or print job.
At the end of this section are reference lists with all conditions and actions, as well as field operators and values (see Conditions and Actions Reference lists below).
Best Practices for triggers & automation
Triggers and automation rules should be carefully designed and arranged to achieve the desired outcome. As more rules are added over time, it becomes more critical to manage the collection – therefore we recommend establishing good practices from the beginning.
Choosing a descriptive name
While triggers and automation rules can be a huge benefit, they can be tedious to maintain if not named appropriately. Choose a descriptive name that makes it easy for you (and any future admins) to remember what statements are contained in the rule, and to distinguish between different rules.
Consider these three identical triggers with different names.
They all communicate some aspect of the rule, but the first name is clearly superior for introducing what the rule does.
Reordering rules
Rules run in a sequential cycle. Certain rules will have actions that change parameters used as conditions in other rules. To achieve the expected outcome, it is therefore important to consider the order by which rules are run.
Avoiding conflicting rules
You may need to watch out for triggers that undo or modify an action contained in another trigger.
Consider an example where you want all print by guests to be in black&white. Trigger 1 determines all print jobs by guests will be set to black&white. Now consider a Trigger 2 – added for a different purpose – that sets all PowerPoint files to be printed in color. Consequently, if a guest prints a PowerPoint file, the order of triggers will determine the color attribute. One remedy for this situation is to add a condition to Trigger 2 that checks if it is a guest user, so only PowerPoint files from non-guests are set to color.
Consider if automation only runs once
Automations check every 15 minutes to see if their conditions are met. Typically, automation rules are meant to only execute once for each print job or document that satisfies the conditions.
To avoid continuous executions, an automation must include one of the following:
* an action that nullifies at least one of the conditions, or * a condition that can be true only once
If there is no nullifying action or true-only-once condition, the unmodified conditions will continue to be met, and the automation will continue to execute – possibly in an endless loop.
Conditions and Actions Reference lists
Condition | Operators | Values | Triggers | Automations |
---|---|---|---|---|
User Assign actions to either employees or guest users | Is Is not | (authenticated) User is successfully authenticated in a designated authentication provider. Non-authenticated can be used for assigning rights to a guest user | ||
User name Assign actions to specific users | Is Is not Contains Does not Contain | [text input] Text is (part of) the user name | ||
User group Assign actions to specific user groups | Is Is not Contains Does not contain | [text input] Text is (part of) the group name | ||
Document status Assign actions to documents at a specific time during the print flow | Is Is not Changed Changed from Changed to Changed not from Changed not to | Received Awaiting conversion The document failed to convert and is awaiting conversion to be retried. Converting The document conversion is in progress. Conversion failed The document conversion failed and will not be retried. Stored The document is received and stored in the storage service. Deleting The document failed to be deleted. The deletion will be retried. | ||
Document name Assign actions to specific documents | Is Is not Contains Does not contain | [text input] Text is (part of) the document name | ||
Document type Assign actions to certain types of documents | Is Is not | Unknown | ||
Document attribute Assign actions to a document that has certain attributes | Is Is not | Color Black & white Duplex long side Duplex short side Simplex | ||
Hours since document ready Assign action within a certain time after the document state changed to “ready” | Is Is not Greater Than Not greater than Not less than | [number input] The number defines whole hours (integer) | ||
Print queue Assign actions to documents sent from known or unknown print queues | Is Is not | (Empty) Documents sent via IPP or API can have a designated print queue that is not specified in the Dispatcher Paragon Cloud Web UI, in which case the port is empty. (Listed input ports) Print queues set up in the Dispatcher Paragon Cloud Web UI are individually listed. | ||
Print queue name Assign actions to documents received from specific print queues. | Is Is not Contains Does not contain | [text input] Text is (part of) print queue name | ||
Print queue type Assign actions to documents from either a push or pull queue | Is Is not | Roaming Print Queue Follow-me print Direct (Push) Print queue Direct print | ||
Output port Assign actions to documents that are not associated with any output port (for example, a printer) | Is Is not | (Empty) Push print jobs can have a designated output port that is not specified in the Dispatcher Paragon Cloud Web UI. (Listed output ports) Output ports set up in the Dispatcher Paragon Cloud Web UI are individually listed. | ||
Output port name Assign actions to print jobs assigned to specific output ports (for example, printers) | Is Is not Contains Does not contain | [text input] Text is (part of) output port (for example, printer) name. | ||
Output port type Assign actions to print jobs assigned to either a physical printer or a dummy | Is Is not | Dummy Printer Rightfax Output port is a virtual Rightfax destination. Discovered Printer Output port for the printer has been automatically discovered. | ||
Output port address Assign actions to print jobs assigned to specific output ports (for example, printers) | Is Is not Contains Does not contain | [text input] Text is (part of) the output port address in IP-format | ||
User card ID | Is Is not Contains Dost not contain | [text input] | ||
User one-time password Assign actions to users with a specific one-time password. | Is Is not Contains Does not contain | [text input] Text is (part of) the user's one-time password. | ||
User short ID Assign actions to users with a specific short ID | Is Is not Contains Dost not contain | [text input] Text is (part of) the user's short ID | ||
Scan job status Assign actions to scan jobs in the specific status | Is | Failed The scan job has failed | ||
Job type Assign actions in dependency of the job type | Is | Print | ||
Hours since document created | Greater Than | [number input] The number defines whole hours (integer). | ||
Number of pages in the document Assign actions based on the total number of pages in the document (number of pages multiplied by number of copies) | Is Is not Greater Than Not greater than Not less than | [number input] The number defines the page count |
Action | Values | Triggers | Automations |
---|---|---|---|
Output document Output the document, for example, by printing | (associated output port) The specific output port the document is already associated with (Listed output ports) Output ports that are added in the Dispatcher Paragon Cloud Web UI shown as individual entries in the list of possible values | ||
Delete document Delete the document from storage | - | ||
Set document attribute Set a specific document attribute | Color Black & white Duplex long side Duplex short side Simplex | ||
Store document Store the document in storage | (Default storage) Default storage according to storage service settings. | ||
Assign document Assign the document to the specified user | (Alias) | ||
Convert document Runs the document conversion | - | ||
Generate OTP for user Generates new one-time password for the user | - | ||
Generate short ID for user | - | ||
Send email to user | (template - SMTP config) List of available email templates and SMTP configs. | ||
Send email to address | (template - SMTP config) [text input] |
Template parameters
Several conditions and actions may accept template parameters enclosed in double curly braces. The following parameters are currently recognized:
Parameter | Value |
---|---|
{{username}} | Name of the user |
{{userotp}} | Value of one-time password of the user |
{{shortid}} | Value of the short ID field of the user |
{{documentname}} | Title of the document submitted to trigger chain |
{{inputportname}} | Name of the input port through which the document was sent |
{{outputportname}} | Name of the printer to which the document was sent for printing |
{{errorcode}} | Value of the error code (scan workflows only) |
{{correlationid}} | Value of the correlation ID of the failed scan job. This can help to identify the cause of the failure. |
{{errorhint}} | Value of the hint connected to the error code, if it exists. |
{{usererrorhint}} | Value of the hint bound to the error code for the user, if it exists. |