I build Stockwell, a low stock alert app. Everything below is plain Shopify Flow though, no app needed.
The reason people in this thread keep getting alerts for the wrong location: the Product variant inventory quantity changed trigger fires for the variant, not for a location. It never tells you which location changed. So a condition like “Warehouse A available is at or below 1” is true on every stock change anywhere, for as long as Warehouse A stays low. A sale at Warehouse B sends you the Warehouse A email again.
The fix is to remember, per location, that you already sent the alert. One true or false metafield per location does it.
1. Create one flag per location
Settings → Custom data → Variants → Add definition. Type: True or false. One per location, for example:
stock_alerts.warehouse_a_alerted
stock_alerts.warehouse_b_alerted
stock_alerts.warehouse_c_alerted
2. Build one workflow per location
Trigger: Product variant inventory quantity changed
Condition 1 (all must be true):
- At least one of
productVariant / inventoryItem / inventoryLevels where location / name is equal to Warehouse A and available is less than or equal to 1
- The variant’s
warehouse_a_alerted metafield is not true
Then:
- Send internal email. Put the location in the subject so nobody has to guess, for example
{{productVariant.sku}} is low at Warehouse A
- Update product variant metafield:
stock_alerts.warehouse_a_alerted = true
Otherwise, add Condition 2:
- At least one of
inventoryLevels where location / name is equal to Warehouse A and available is greater than 1
- The variant’s
warehouse_a_alerted metafield is true
Then:
- Update product variant metafield:
stock_alerts.warehouse_a_alerted = false
Duplicate the workflow for each other location, changing the location name and the metafield.
What you get
One email when a location first drops to your number. Nothing while it stays low, even when other locations sell. A fresh alert only after that location is restocked above the number and drops again.
Two things worth knowing:
- If a location is already low when you switch this on, you get one email for it on the next stock change. That is expected.
- Type the location name exactly as it appears under Settings → Locations. If someone renames the location, the match fails silently.
I wrote up why the total across locations hides these stockouts in the first place, with examples of picking a different number for each location: Low Stock Alerts Across Multiple Shopify Locations