Starting a workflow

Starting a workflow from another workflow

The application provides new actions to start workflows that begin with custom triggers.

Actions for starting a single workflow

Action that starts a custom workflow and is independent of data from previous steps:

  • Start custom workflow — runs workflows that use the Custom trigger triggered trigger.

Actions that start custom workflows for the selected customer, order, or product in the current workflow:

  • Start custom customer workflow — runs workflows that use the Customer: custom trigger triggered trigger.
  • Start custom order workflow — runs workflows that use the Order: custom trigger triggered trigger.
  • Start custom product workflow — runs workflows that use the Product: custom trigger triggered trigger.

Example

Add the Start custom order workflow action. Fill in the Trigger specifier field with a value that describes the purpose of the workflow you want to start: Start workflow from another workflow – action

Create another workflow that starts with the Order: custom trigger triggered trigger. Immediately after the trigger, add a condition on the Specifier field so the value equals the one passed from the previous workflow. Add the rest of the logic after the condition. Start workflow from another workflow – trigger

This configures one workflow to start another workflow while passing the current order.

Warning! If you have multiple custom workflows, combine them into one to reduce the load on Shopify Flow. Learn more here.

Actions for batch-starting workflows

Actions that start custom workflows for a list of customers, orders, or products:

There are no limits on the number of elements that can be processed by these actions. However, these actions are subject to Shopify's rate limits. When rate limits are reached, action's execution will continue as limits become available. This may slow down the action's execution, but it will not result in an error.

You can adjust the delay between workflow starts using the action's configuration parameter Delay between triggering. This allows you to manage the load on Shopify Flow and avoid exceeding limits.

Example

Add the Start custom workflow for list of orders action. Fill in the Trigger specifier field with a value that describes the purpose of the workflow you want to start, and enter a filter in the Query field to select only the needed orders. If the filter contains an error, it will not be applied at all - in that case, the custom workflow will be started for all objects in the store. Start workflows for list of orders – action

Create another workflow that starts with the Order: custom trigger triggered trigger. Immediately after the trigger, add a condition on the Specifier field so the value equals the one passed from the previous workflow. Add the rest of the logic after the condition. Start workflows for list of orders – trigger

This configures a scheduled run of a workflow for a list of orders.

Warning! If you have multiple custom workflows, combine them into one to reduce the load on Shopify Flow. Learn more here.

Additional considerations

It is important to know that these actions only start workflows but do not wait for their completion. If you want to perform a subsequent action after the started custom workflow completes, you need to add this action to the end of the started custom workflow.

Infinite loop detection

The app includes loop detection to prevent infinite recursive workflows. If a workflow is triggered more than 10 times with the same object and the same Specifier within 30 minutes, the loop detection will activate and the workflow will terminate with an error.

See also: