Initiate Workflow Route
Initiate Workflow Route
The Initiate Workflow action allows you to start an entirely new workflow for a Record or for a single Document within a Record. This is useful from either an Add-In to start a new route or for starting parallel workflow routes. Parallel routing is an advanced technique but very possible and very practical in certain situations.
This action is normally used in Add-Ins or with Workflow for parallel routing. If you are wanting to use it for other purposes, please contact support to review your use case. If you are using this action from within a workflow, consider putting it in an Action Set and calling that Action Set using the deferred option. Otherwise, it could easily cause your workflow to have an error and stop.
Routing a Record or a Document
Workflow can route a whole Record or a single Document, and this action supports both. Which one it does is decided by the Record ID and Document ID options together.
If you supply a Record ID only, or leave both blank, the Record is routed. If you supply a Document ID only, the system looks up the Record that Document belongs to and routes the Document within that Record. If you supply both, they must belong together — a workflow route for a Document always needs that Document's Record, so if the Document ID you supply does not belong to the Record ID you supply, the action stops with an error rather than routing the wrong thing. When they do match, the route proceeds normally.
Options
- Record ID - If you wish to route the current Record then leave this blank. However, if you wish to route a different Record you can specify which Record to route here.
- Document ID - Leave this blank to route the Record itself. If you supply a Document ID then that Document is routed instead. If you supply a Document ID and leave Record ID blank, the Document's own Record is found for you. If you supply both, they must match or the action will error and the route will not happen.
- Trigger / Process - If you wish to send the Record directly to a specific trigger or process, select it here. The workflow will start there and when the first trigger is completed the system will reevaluate where to go from there. If you do not select a trigger and don't enter in a trigger name (see below) then the system will route the Record from the top of the trigger list as normal.
- Trigger Name - There are times when you know the name of the trigger to go to from a Record field or by name but not necessarily ahead of time during design. For instance, you could give the users a drop down list of triggers to move to and then have this trigger read that data field to find the right trigger. If no match is found the system will route the Record from the top of the trigger list as normal.
- Defer Actions - When this is on, the new route is queued and performed offline instead of immediately. Any updates made during the route will not be available until after that processing cycle completes. Deferred routes carry the Document along with the Record, so a Document route behaves the same whether it runs immediately or deferred. This option requires an Enterprise license and is only available in the cloud.
- Alert User(s) on Failure - Only applies when Defer Actions is on. When enabled, the user(s) running this Action Set are notified if the deferred route fails.
- Alert Admins on Failure - Only applies when Defer Actions is on. When enabled, administrators are notified if the deferred route fails.
- Alert Support on Failure - Only applies when Defer Actions is on. When enabled, the support email address is notified if the deferred route fails.
- Parallel Name - If you route items in a parallel fashion then you usually want to merge those routes back together at some point. You do this by naming each parallel route. You will then use this same name in the Parallel Merge action later. Please refer to the Parallel Merge action for more information.
- Workflow ID to Field - Names a field to receive the ID of the workflow item that this action creates. This is useful when a later action or trigger needs to refer back to the route that was started here.
All fields can contain static values or variables, so the Record ID and Document ID can both be supplied from Record data rather than typed in during design.
Errors you may see
- Record Not Found - No Record could be resolved. Either the Record ID supplied does not exist, or it was left blank and there was no active Record in context.
- Document Not Found - The Document ID supplied does not exist.
- Document ID x does not belong to Record ID y - Both a Record ID and a Document ID were supplied and they are not related. Correct one of the two values, or clear the Record ID and let the system find the Document's Record for you.