How to receive an email when a product goes out of stock

Having up-to-the-minute information regarding your Shopify store’s inventory levels can be challenging. This post will show you how to receive an email when a Shopify product goes out of stock. Using the built-in app, Email by MESA, you can set things up in just a few clicks!

Step by Step Instructions

1. First, click your MESA Discover tab, and select the blue Create your own workflow button in the right-hand corner. You’ll need to name your workflow; we’ll call this one “Receive an email when a product goes out of stock” Click the pink Continue button when finished.

Create and name your workflow
Create and name your workflow

2. Second, you’ll want to pick the Trigger step, the first step in a workflow that causes automation to begin. In this case, you’ll want to start with Shopify and select Order Created.

Select the Trigger step
Select the Trigger step

3. Next, set up your Action Step, which is any additional step beyond the Trigger step. In the search field of the Action Step, search for “Loop By MESA.” Under the Setup Configuration, you will need to assign snippets of data called Tokens to ensure the correct information is being pulled in. You can utilize MESA Tokens by clicking the {+} icon to find the right Token value for any field in the step.

Under Order Created in the right-hand menu, select Line Items, which will assign the values to loop over. MESA will repeat the next step in your workflow for each value identified in the Loop step.

Select the Action step and Line Items token
Select the Action step and Line Items token

4. In the next Action Step, you’ll want to type search for Shopify in the search field. This time you’ll select Retrieve Variant, and under Step Configuration in the Variant ID field, select the Loop Variant ID token.

Select the next Action step and add Loop Variant ID token
Select the next Action step and add the Loop Variant ID token

5. Now, you’ll need to add MESA built-in app, Filter by MESA, as your next action step. Under Step Configuration in the field, select the Retrieve Variant Inventory Quantity token. This will ensure that MESA checks for an inventory of zero before moving on to the next step. If you want to change the quantity to check for, simply adjust the value in the numerical field.

Add Filter by MESA as your next action step and select the Inventory Quanity token
Add Filter by MESA as your next action step and select the Inventory Quantity token

Almost there!

6. Finally, add the built-in app Email by MESA as the last step in your workflow. In the Recipient field, type in {{context.shop.email}} which will pull in your store’s email address. Tailor the Subject line to any messaging you want; by adding a Retrieve Variant Sku token, you can include the product SKU in the subject line.

The Message field can include anything you’d like to be notified about. The below example uses a variety of tokens to report the SKU of the out-of-stock item and a link to the product.

Add Email by MESA as the last step of the workflow
Add Email by MESA as the last step of the workflow

7. In the end, you will be prompted to turn OnTest, or Save your workflow. We recommend testing your workflow before turning it on to ensure everything is working properly.

Turn your workflow on
Turn your workflow on

What you should do now

Whenever you’re ready…here are 4 ways we can help you grow your business:

  1. Add MESA to your Shopify store. The best way to get started is by adding the MESA app from the Shopify App store. Every plan includes the first 7-days free so you can be assured your workflow is running properly.
  2. Browse pre-made templates. Our customizable workflow templates are a great way to get started more quickly.
  3. Talk to our automation experts. If you need help personalizing any workflow template, guidance how to make any automation or, simply want us to make your workflow, we can help.
  4. If you know another merchant who’d enjoy reading this page, share it with them via LinkedIn, YouTube, Twitter, or Facebook.

Automate anything and get more from your apps.
For free.

Start free trial

Automate everything with MESA

Make any workflow and get more from your existing apps.

Try MESA for free, 7-day trial included.