🔓 Unlock all 10,000+ workflows & prompts free Join Newsletter →
✅ Full access unlocked — explore all 10,000 AI workflow and prompt templates Browse Templates →
Home n8n Workflow
January 22, 2026

Shopify + WhatsApp: send VIP discount codes fast

Lisa Granqvist Partner Workflow Automation Expert

You create a fresh discount code in Shopify… and then the real work starts. Finding your best customers, cleaning phone numbers, sending messages one by one, and hoping you didn’t miss anyone.

This is the kind of mess that hits store owners first, but marketers and customer teams feel it too. With WhatsApp discount automation, your VIPs get the code fast, and you get a clean activity log without chasing screenshots.

Below is the exact workflow: what breaks in the manual approach, how the automation runs in n8n, and what you can tweak to match your store’s VIP rules.

How This Automation Works

The full n8n workflow, from trigger to final output:

n8n Workflow Template: Shopify + WhatsApp: send VIP discount codes fast

The Problem: VIP discounts get created, but not delivered

A VIP discount is only valuable if the right people actually receive it while it’s still exciting. But once you’re doing this manually, the process gets weirdly fragile. Someone has to export or search customer lists, decide who “counts” as VIP today, copy the code into a message, and then send it out. Meanwhile, phone numbers are inconsistent (missing country codes, extra spaces), and WhatsApp delivery is a coin flip if the number isn’t real. Even if you do everything right, tracking is painful. You end up with scattered notes, partial logs, and no simple answer to “Who got this code?”

It adds up fast. Here’s where it breaks down in day-to-day operations.

  • Sending 30 to 60 messages manually can swallow about 1 to 2 hours per promo.
  • Unverified WhatsApp numbers waste time and make your outreach look sloppy.
  • When results aren’t logged in one place, you can’t learn what offers actually work.
  • Teams hesitate to run more promos because the “send” part becomes the bottleneck.

The Solution: auto-send WhatsApp codes to VIPs and log everything

This n8n workflow listens for a Shopify discount creation webhook, then does the outreach work for you. It takes the discount code details from Shopify, pulls customer data, and filters down to your high-spend segment (your VIPs). Next, it cleans each phone number into a WhatsApp-friendly format, checks if that number is actually active on WhatsApp using Rapiwa’s verification endpoint, and only then sends the promo message. Every attempt is recorded in Google Sheets, so you can see verified sends, skipped contacts, and failures in one place. It also throttles requests and processes in batches (up to 60 rows per cycle) so you don’t trip rate limits.

The workflow starts when Shopify fires a webhook for a new discount code. From there, it gathers and filters customers, validates WhatsApp numbers through Rapiwa, then sends the message and writes the outcome to Google Sheets.

What You Get: Automation vs. Results

Example: What This Looks Like

Say you drop a new VIP discount in Shopify and want to message 60 top customers. Manually, if you spend roughly 2 minutes per person to copy the code, check the number, send, and note it down, that’s about 2 hours. With this workflow, the “work” is basically creating the discount and letting the webhook trigger the run. The batch processes up to 60 rows in the background, and Google Sheets ends up with a clear “sent” or “not sent” status for each contact.

What You’ll Need

  • n8n instance (try n8n Cloud free)
  • Self-hosting option if you prefer (Hostinger works well)
  • Shopify to trigger on discount creation
  • Rapiwa to verify numbers and send WhatsApp
  • Google Sheets to log sends and statuses
  • Rapiwa Bearer Token (get it from the Rapiwa dashboard)

Skill level: Beginner. You’ll connect accounts, paste a token, and match a few sheet columns.

Don’t want to set this up yourself? Talk to an automation expert (free 15-minute consultation).

How It Works

A Shopify discount code is created. Shopify sends a webhook into n8n with the code and basic metadata, so the workflow can react immediately without anyone pushing buttons.

Customer data is pulled and shaped for outreach. The workflow retrieves Shopify customers, formats the payload, and filters down to high-spend clients so you’re not blasting everyone who ever bought a $10 item.

Numbers get cleaned, then verified in Rapiwa. Each customer is processed in batches, phone digits are sanitized, and Rapiwa checks whether the number is active on WhatsApp before the workflow even tries to message it. Frankly, this is where a lot of manual workflows fall apart.

Messages go out and everything is logged. Verified numbers receive the promo message through Rapiwa, and both “sent” and “not sent” outcomes are written back into Google Sheets for simple reporting later.

You can easily modify the VIP filter to match your real segmentation (total spend, tags, last order date). See the full implementation guide below for customization options.

Step-by-Step Implementation Guide

Step 1: Configure the Webhook Trigger

Set up the webhook endpoint that Shopify will call when a discount is created or updated.

  1. Add the Incoming Webhook Trigger node and set HTTP Method to POST.
  2. Set the Path to a9b6a936-e5f2-4d4c-9cf9-182de0a970d5.
  3. Copy the generated webhook URL and register it in Shopify’s webhook settings for discount events.
⚠️ Common Pitfall: If Shopify sends a different payload shape, the downstream Format Webhook Payload code will not map fields correctly. Validate a sample webhook payload first.

Step 2: Connect Shopify and Normalize the Webhook Payload

Fetch customers from Shopify and normalize incoming webhook fields for later use in messaging and logs.

  1. In Format Webhook Payload, keep the provided JavaScript that maps admin_graphql_api_id, title, status, and created_at from the webhook body.
  2. In Retrieve Shopify Customers, set URL to https://your_domain_/admin/api/2025-07/customers.json.
  3. Enable Send Headers and set X-Shopify-Access-Token to [CONFIGURE_YOUR_API_KEY].
  4. Confirm the execution flow: Incoming Webhook TriggerFormat Webhook PayloadRetrieve Shopify Customers.
⚠️ Common Pitfall: Retrieve Shopify Customers has no credentials configured—make sure your Shopify access token header is valid or requests will fail.

Step 3: Set Up Customer Filtering and Number Cleanup

Filter high-spend customers, batch them, and clean phone numbers before verification.

  1. In Filter High-Spend Clients, keep the JavaScript that filters customers with total_spent > 5000 and maps fields like customerName and number.
  2. Connect Filter High-Spend Clients to Iterate Customer Batches to control batch processing.
  3. In Iterate Customer Batches, keep default options and ensure the second output routes to Sanitize WhatsApp Digits.
  4. In Sanitize WhatsApp Digits, retain the JavaScript that strips non-digit characters from number.

Step 4: Verify WhatsApp and Send the Promo

Verify each number with Rapiwa, then send the WhatsApp promo to verified recipients.

  1. In Verify WhatsApp Status, set Number to ={{ $json.number }} and keep Operation as verifyWhatsAppNumber.
  2. Credential Required: Connect your rapiwaApi credentials in Verify WhatsApp Status.
  3. In Verified Number Check, confirm the condition uses ={{ $json.data.exists }} with the boolean operator true.
  4. In Dispatch WhatsApp Promo, set Number to ={{ $json.data.number }}.
  5. Set Message Type to the provided template, keeping expressions like {{ $('Sanitize WhatsApp Digits').item.json.customerName }} and {{ $('Format Webhook Payload').item.json.title }}.
  6. Credential Required: Connect your rapiwaApi credentials in Dispatch WhatsApp Promo.

Step 5: Configure Logging and Throttling

Log verified and unverified attempts to Google Sheets and add a pause between batches.

  1. In Log Unverified Attempts, set Operation to append and keep the field mappings, including status as not sent and verify as unverified.
  2. Credential Required: Connect your googleSheetsOAuth2Api credentials in Log Unverified Attempts.
  3. In Log Verified Sends, set Operation to append and keep the field mappings, including status as sent and verify as verified.
  4. Credential Required: Connect your googleSheetsOAuth2Api credentials in Log Verified Sends.
  5. Leave Pause Throttle with default settings to pace each batch and confirm the flow Log Verified SendsPause ThrottleIterate Customer Batches.
⚠️ Common Pitfall: Make sure the Google Sheet document ID is updated from [YOUR_ID] in both logging nodes, or rows won’t be written.

Step 6: Test and Activate Your Workflow

Run a controlled test to ensure customer filtering, verification, logging, and messaging all work end-to-end.

  1. Click Execute Workflow and send a sample webhook payload to Incoming Webhook Trigger.
  2. Verify the execution flow reaches Retrieve Shopify CustomersFilter High-Spend ClientsIterate Customer Batches.
  3. Confirm that verified numbers reach Dispatch WhatsApp Promo and the WhatsApp message is delivered.
  4. Check Google Sheets to ensure Log Verified Sends and Log Unverified Attempts append rows correctly.
  5. When the test succeeds, switch the workflow to Active to enable production execution.
🔒

Unlock Full Step-by-Step Guide

Get the complete implementation guide + downloadable template

Common Gotchas

  • Google Sheets credentials can expire or need the right file permissions. If rows stop updating, check the n8n Google Sheets node connection and the sheet’s share settings first.
  • If you’re using Wait nodes or external sending, processing times vary. Bump up the wait duration if downstream nodes fail on empty responses.
  • Rapiwa verification and sending can fail if your Bearer Token is expired or your WhatsApp line isn’t connected. Confirm status in the Rapiwa dashboard before you chase bugs inside n8n.

Frequently Asked Questions

How long does it take to set up this WhatsApp discount automation?

About 30 minutes once your sheet and tokens are ready.

Do I need coding skills to automate WhatsApp discount sending?

No. You’ll mostly connect accounts and paste your Rapiwa token. The workflow’s VIP filter is already built; you can adjust it later if you want.

Is n8n free to use for this WhatsApp discount automation workflow?

Yes. n8n has a free self-hosted option and a free trial on n8n Cloud. Cloud plans start at $20/month for higher volume. You’ll also need to factor in Rapiwa costs (they advertise a free 200 messages to start, then a paid subscription).

Where can I host n8n to run this automation?

Two options: n8n Cloud (managed, easiest setup) or self-hosting on a VPS. For self-hosting, Hostinger VPS is affordable and handles n8n well. Self-hosting gives you unlimited executions but requires basic server management.

Can I customize this WhatsApp discount automation workflow for different VIP rules?

Yes, and you should. Swap the “Filter High-Spend Clients” logic to use Shopify tags, lifetime spend thresholds, or “last order within 30 days,” depending on what VIP means in your store. You can also change the Google Sheet columns (for example, add campaign name or message variant) as long as the logging nodes write to the new fields. If you want the sheet to be the source of truth for who gets messages, adjust the “check/verify/status” flow so only marked rows are processed.

Why is my Rapiwa connection failing in this workflow?

Usually it’s an expired or incorrect Bearer Token. Regenerate the token in your Rapiwa dashboard and update it in n8n, then confirm your WhatsApp number is still connected inside Rapiwa. If verification works but sending fails, you may be hitting messaging limits or sending too quickly; the workflow includes a Wait node for throttling, so increase that delay if needed.

How many contacts can this WhatsApp discount automation handle?

This workflow processes up to 60 rows per cycle, and it can run every 5 minutes.

Is this WhatsApp discount automation better than using Zapier or Make?

For this workflow, n8n is usually a better fit because batching, filtering, and conditional routing are built-in without turning every branch into an extra billed step. The WhatsApp verification-before-send pattern is also easier to control when you can inspect responses and write your own logic. Zapier or Make can still work if you’re doing something simple, like sending the same message to a short list. But once you care about VIP filtering, logging, and avoiding unverified numbers, the “simple” version tends to collapse. Talk to an automation expert if you want help choosing the cleanest approach.

You set up the workflow once, and VIP promos stop being a scramble. The automation handles the repetitive sending and logging so you can focus on the offer, not the admin.

Need Help Setting This Up?

Our automation experts can build and customize this workflow for your specific needs. Free 15-minute consultation—no commitment required.

Lisa Granqvist

Workflow Automation Expert

Expert in workflow automation and no-code tools.

×

Use template

Get instant access to this n8n workflow Json file

💬
Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Get a free quote today!
Get a free quote today!

Tell us what you need and we'll get back to you within one working day.

Launch login modal Launch register modal