Export Magento 2 Customers to Mailchimp (different segments)
Trusted by 4,150+
Exporting existing Magento 2 customers to Mailchimp is a common task, and it can be fully automated with extensions. However, in that case, you lose the ability to split customers into different groups, which is required for better email targeting.
This flow splits customers into two groups based on the number of orders (with orders and without orders). For each group, it creates separate .CSV files that meet Mailchimp's requirements for importing files.
How does it work?
The flow fetches customers and orders directly from the MySQL database. After the initial customer filtration (for example, removing all customers with 'test' emails), the flow joins order tables to calculate the number of orders for each customer.
In the next steps, the flow splits customers into two different groups using a Filter node and saves each group to a .CSV file.
The flow is fully customizable and can be adapted for any business requirements with different customer segmentation rules and groups.
Main use cases
- Export Magento 2 customers
- Prepare files for exporting Magento 2 customers to Mailchimp
- Segment customers
- Improve email marketing targeting
- Automate customer data export processes
Benefits
- Automated process saves time and reduces manual effort
- Improved email marketing effectiveness through targeted segmentation
- Customizable flow to fit specific business needs
- Accurate customer data export
Technical Details
The flow utilizes MySQL node to interact with the MySQL database. It leverages advanced querying capabilities to filter and segment customer data efficiently. The process includes:
- Fetching customer data from the MySQL database
- Filtering out unwanted records (e.g., test emails)
- Joining order data to determine the number of orders per customer
- Segmenting customers into groups based on predefined criteria
- Generating .CSV files for each segment