

How to Tag Customers by Purchase with Pipedream
Tags new customers in Mailchimp based on their WooCommerce purchase, triggering product-specific email sequences.
Steps and UI details are based on platform versions at time of writing β check each platform for the latest interface.
Best for
WooCommerce stores that need instant customer tagging based on product purchases to trigger targeted email campaigns
Not ideal for
Simple one-size-fits-all email sequences where product-specific tagging isn't needed
Sync type
real-timeUse case type
notificationReal-World Example
A clothing store with 200 orders/month uses this to tag customers by purchase category (shoes, shirts, accessories) in Mailchimp within 30 seconds of checkout. Before automation, they manually tagged customers twice weekly, missing 40% of new purchases and sending generic follow-ups instead of product-specific care instructions and upsells.
What Will This Cost?
Drag the slider to your expected monthly volume.
Each platform counts differently β Zapier: 1 task per trigger. Make: 1 operation per module per record. n8n: 1 execution per run.





Prices shown for annual billing. Based on published pricing as of April 2026.
Estimated ROI
1000
min saved/mo
$583
labor value/mo
Free
no platform cost
Based on ~2 min manual effort per operation at $35/hr fully loaded labor cost.
Implementation
Import this workflow directly into Pipedream
Copy the pre-built Pipedream blueprint and paste it straight into Pipedream. All modules, filters, and field mappings are already configured β you just need to connect your accounts.
Before You Start
Make sure you have everything ready.
Field Mapping
Map these fields between your apps.
| Field | API Name | |
|---|---|---|
| Required | ||
| Customer Email | email_address | |
| Product Tags | tags | |
| Subscription Status | status | |
4 optional fieldsβΈ show
| First Name | merge_fields.FNAME |
| Last Name | merge_fields.LNAME |
| Order Total | merge_fields.ORDER_TOTAL |
| Purchase Date | merge_fields.LAST_PURCHASE |
Step-by-Step Setup
Dashboard > New > Start from scratch
Create new Pipedream workflow
Go to pipedream.com and click New in the top navigation. Select 'Start from scratch' to build a custom workflow. This gives you full control over the trigger configuration and data processing steps needed for order-based tagging.
- 1Click 'New' in the top navigation bar
- 2Select 'Start from scratch' from the template options
- 3Name your workflow 'WooCommerce to Mailchimp Tagging'
Workflow Canvas > Add your first step > WooCommerce
Add WooCommerce webhook trigger
Click 'Add your first step' and search for WooCommerce. Select the 'Order Created' webhook trigger to capture new orders instantly. This webhook fires within 5 seconds of checkout completion, giving you real-time access to purchase data.
- 1Click 'Add your first step'
- 2Search for and select 'WooCommerce'
- 3Choose 'Order Created (Instant)' from the trigger list
- 4Connect your WooCommerce store using the API key
WooCommerce Admin > Settings > Advanced > Webhooks
Configure WooCommerce webhook in your store
Copy the webhook URL from Pipedream and add it to your WooCommerce webhooks. Go to WooCommerce > Settings > Advanced > Webhooks and create a new webhook for 'Order created' events. This connects your store to the Pipedream trigger.
- 1Copy the webhook URL from your Pipedream trigger
- 2In WooCommerce admin, go to Settings > Advanced > Webhooks
- 3Click 'Add webhook'
- 4Set Topic to 'Order created' and paste the webhook URL
Pipedream Workflow > Test Section
Test the webhook connection
Place a test order in your WooCommerce store to verify the webhook fires correctly. You should see order data appear in Pipedream within 10 seconds. Check that line items, customer email, and product categories are captured properly.
- 1Go to your store and add a product to cart
- 2Complete checkout with a test email address
- 3Return to Pipedream and check the 'Test' section
- 4Verify order data appears with customer and product details
Workflow Canvas > + > Code
Add code step for tag logic
Click the + button below your trigger and select 'Code'. This Node.js step will analyze the order data and determine which tags to apply based on purchased products. You'll map product categories or specific items to Mailchimp tags.
- 1Click the + button below the WooCommerce trigger
- 2Select 'Code' from the step options
- 3Choose 'Run Node.js code'
- 4Name the step 'Generate Tags from Order'
This Node.js code analyzes the WooCommerce order data and creates smart tags based on product categories, order value, and customer history. Paste it into your 'Generate Tags from Order' code step.
JavaScript β Code Stepasync (event, steps) => {βΈ Show code
async (event, steps) => {
const order = steps.trigger.event
const tags = []... expand to see full code
async (event, steps) => {
const order = steps.trigger.event
const tags = []
// Tag by product categories
if (order.line_items && order.line_items.length > 0) {
order.line_items.forEach(item => {
if (item.categories) {
item.categories.forEach(cat => {
tags.push(`purchased-${cat.slug}`)
})
}
// Tag specific high-value products
if (parseFloat(item.price) > 100) {
tags.push('high-value-item')
}
})
}
// Tag by order value
const total = parseFloat(order.total)
if (total > 200) {
tags.push('vip-customer')
} else if (total > 100) {
tags.push('high-value-customer')
} else {
tags.push('standard-customer')
}
// Tag new vs returning customers
if (order.customer_id === 0) {
tags.push('new-customer')
} else {
tags.push('returning-customer')
}
// Remove duplicates and return
const uniqueTags = [...new Set(tags)]
return { tags: uniqueTags }
}Workflow Canvas > + > Mailchimp
Add Mailchimp step
Click + again and search for Mailchimp. Select 'Add or Update List Member' action to either create new contacts or update existing ones with tags. This handles both new customers and returning buyers automatically.
- 1Click + to add another step
- 2Search for and select 'Mailchimp'
- 3Choose 'Add or Update List Member'
- 4Connect your Mailchimp account via OAuth
Mailchimp Step > Configuration
Map customer data fields
Configure the Mailchimp step to pull customer email from the WooCommerce order data. Map billing name to first/last name fields and set the subscription status based on marketing preferences. Use the data from your webhook test to verify field paths.
- 1Set Email Address to steps.trigger.event.billing.email
- 2Map First Name to steps.trigger.event.billing.first_name
- 3Map Last Name to steps.trigger.event.billing.last_name
- 4Set Status to 'subscribed' or reference marketing consent field
Mailchimp Step > Tags Field
Configure dynamic tagging
In the Tags field of the Mailchimp step, reference the tags array created by your code step. Use steps.generate_tags_from_order.tags to pull the computed tags based on purchased products. This ensures each customer gets product-specific tags automatically.
- 1Scroll to the Tags section in Mailchimp configuration
- 2Click the reference data button (looks like {})
- 3Select steps > generate_tags_from_order > tags
- 4Verify the reference shows as steps.generate_tags_from_order.tags
Workflow Canvas > Deploy > Test
Test complete workflow
Deploy your workflow and place another test order to verify the complete flow works. Check that the customer appears in Mailchimp with correct tags within 60 seconds of checkout. Verify that email sequences trigger based on the applied tags.
- 1Click 'Deploy' in the top right corner
- 2Place a test order with different products
- 3Check Mailchimp audience for the new contact
- 4Verify correct tags are applied and sequences trigger
Going live
Production Checklist
Before you turn this on for real, confirm each item.
Troubleshooting
Common errors and how to fix them.
Frequently Asked Questions
Common questions about this workflow.
Analysis
Use Pipedream for this if you need instant webhook processing and custom tagging logic that goes beyond simple field mapping. The Node.js code steps let you analyze product data, calculate customer lifetime value, and create complex tag combinations that Zapier's built-in tools can't handle. Skip Pipedream if you're doing basic one-tag-per-order setups where Make's visual interface is faster to configure.
This workflow costs nothing until you hit 10,000 invocations per month on Pipedream's free tier. At 500 orders monthly, you're looking at free processing since each order triggers just one workflow run. Zapier would cost $20/month at that volume, and Make charges $9/month. Pipedream wins on cost until you reach serious e-commerce volume.
Make handles WooCommerce webhooks more reliably - their error handling retries failed webhook deliveries automatically while Pipedream requires manual retry configuration. Zapier has better Mailchimp integration with built-in duplicate prevention that Pipedream lacks. n8n offers similar Node.js flexibility but you'll host it yourself. Power Automate doesn't connect to WooCommerce webhooks without premium connectors. But Pipedream's instant processing and unlimited webhook endpoints make it ideal for real-time customer tagging where timing matters for email sequences.
You'll hit WooCommerce webhook inconsistencies first - some themes and plugins change the order data structure, breaking your field mappings without warning. Mailchimp's tag limits catch people off guard: 1,000 tags maximum per audience and 255 characters per tag name. Test orders don't always fire webhooks the same way as real purchases, especially with payment gateway plugins that modify the checkout flow. Plan for data validation in your code steps.
Ideas for what to build next
- βAdd purchase history enrichment β Extend the code step to track total lifetime value and purchase frequency for advanced customer segmentation.
- βCreate abandoned cart recovery β Set up a second workflow triggered by cart abandonment to tag prospects and send recovery sequences.
- βBuild order status updates β Add shipping and delivery confirmation emails by triggering on WooCommerce order status changes beyond just creation.
Related guides
How to Share Notion Meeting Notes to Slack with Pipedream
~15 min setup
How to Share Notion Meeting Notes to Slack with Power Automate
~15 min setup
How to Share Notion Meeting Notes to Slack with n8n
~20 min setup
How to Send Notion Meeting Notes to Slack with Zapier
~8 min setup
How to Share Notion Meeting Notes to Slack with Make
~12 min setup
How to Create Notion Tasks from Slack with Pipedream
~15 min setup