How to Initate a Trigger with already existing product inventory (ie, out of stock)?

14 0 2

I wasn't completely sure how to ask the question - so hopefully someone will be able to dive in and get past the difficult wording ..

I already have some Flows created (from looking at examples) that for example will "archive" a product that sales out -- but that is apparently only triggered by an inventory change to less than 1.


However we are new to Shopify and have added a lot of products from Square with a program that sync'd over basically our entire inventory (in stock or out of stock).  As a result I have a lot of already  "out of stock" products that are active and I would like to somehow - initiate a flow that checks all my products for stock and archives the ones that are out of stock, while still having that Flow or maybe a seperate one continue to monitor for items that later become out of stock and archive them (and also monitor for if back in stock - to reverse the archive).


Main question is how to initate a flow on the existing products without the trigger of inventory change? 

Replies 2 (2)

Shopify Staff
22 2 1

You can create a workflow that starts with a Product Added to Store trigger, check whatever inventory condition you want (eg. product.totalInventory less than or equal to 0), and then use the Hide Product action.

After this workflow is turned on, you can go to the products section of your admin, multi-select a group of products, hit the "..." button (for more actions) and select Run Flow Automation. You can then pick the workflow you just created. All the products you selected will be run with the selected workflow. More details on manual runs in Flow can be found here.

Another option outside of Flow is using automated collections, covered here.

To learn more visit the Shopify Help Center or the Community Blog.

Shopify Partner
432 14 61

Our app mesa has a flow integration that you could use for this. We have a feature called time travel that allows you to run a workflow across all the products in your catalog and we could tie that into a flow.

Kalen Jordan
Platform Advocate
MESA - Shopify Automation You've Love