/
/
Stop Mailchimp counting revenue you refunded in WooCommerce
For marketers who want fully refunded and canceled WooCommerce orders updated in the Mailchimp store by asking their AI assistant.
On this page
Connector
Connect WooCommerce, pick your AI tool and paste the prompt.
The problem
Campaign revenue that counts refunded orders
When an order is refunded or canceled in WooCommerce, the Mailchimp store copy often keeps counting it, so campaign revenue looks better than it is. Fixing it means finding each full refund and changing its status by hand.
Without PopdockAI
- List refunds and cancellations in WooCommerce
- Work out which are full refunds
- Find each order in the Mailchimp store
- Change its status by hand
With PopdockAI
- Only orders whose refunds equal the total count as refunded
- Each order is confirmed in the Mailchimp store by order id
- Partial refunds are left alone, with an email warning shown
- Only the financial status changes after you confirm
The prompt
Use this prompt
Copy it into any AI tool connected to PopdockAI. Swap the values in braces for your own.
**Objective:** For WooCommerce orders refunded in full or cancelled in the last `{days-back}` days (default 7), set the matching Mailchimp store order's financial status to refunded or cancelled, after the user confirms, so Mailchimp stops counting that revenue.
**Step 1: Find the WooCommerce store in Mailchimp**
Call `mailchimp-get-store` with `platform` set to WooCommerce and note its `store-id`. If none comes back, report that no WooCommerce store is connected and stop. If several come back, list them and stop unless the user names one.
**Step 2: Read refunds and cancellations in WooCommerce**
Work out the start date as today minus `{days-back}` days. Call `woocommerce-get-refund` with `created-date.from` set to that date, and total the refunded `amount` per `order-id`. An order is **fully refunded** when that total equals its `order-total` within 0.01, and **partly refunded** otherwise. Then call `woocommerce-get-order` with `status` set to cancelled and `created-date.from` set to the same date for cancellations.
**Step 3: Confirm each order exists in Mailchimp**
For each fully refunded or cancelled order, call `mailchimp-get-order-line` with `order-id` set to the WooCommerce `order-id`, keeping rows on the Step 1 store. If nothing comes back, report the order as not in Mailchimp and skip it.
**Step 4: Confirm**
List the planned changes: WooCommerce order number, customer email, amount, and the new Mailchimp financial status (refunded or cancelled). List partly refunded orders separately as not being changed. Warn that Mailchimp may send order notification emails when the financial status changes. Wait for an explicit yes.
**Step 5: Update Mailchimp**
For each confirmed order, call `mailchimp-update-order` once with `store-id`, `order-id` and `financial-status` set to refunded or cancelled, and nothing else. Record each success or error and continue past failures.
**Step 6: Report**
Counts updated, skipped as not in Mailchimp, left alone as partial refunds, and failed, with the failures and their error text.
**Rules & Guidelines:**
* `woocommerce-get-refund` and `woocommerce-get-order` are on the woocommerce server. `mailchimp-get-store`, `mailchimp-get-order-line` and `mailchimp-update-order` are on the mailchimp server.
* `mailchimp-update-order` is the only write tool this prompt may call, after Step 4, and only to set `financial-status`. Do not change fulfilment or tracking. WooCommerce is the source of truth: never call `woocommerce-update-order`, `woocommerce-add-refund` or `woocommerce-add-order-note`.
**Validation:**
* Match on order id. Do not match on email or amount.
* Never mark a partly refunded order as refunded.
* If there are no full refunds or cancellations in the window, say so and stop.Who it's for
One answer, three teams that use it
Email marketers
Report honest campaign revenue
Refunded and canceled orders stop counting, so campaign revenue reflects real sales.
Sync the last 14 days of WooCommerce refunds to the Mailchimp store.
Marketing analysts
Keep partial refunds as they are
Partly refunded orders are left alone, so they are never marked as fully refunded.
Which WooCommerce orders this month are fully refunded but still paid in Mailchimp?
Ecommerce managers
Fix cancellations in the email store
Canceled orders are updated in Mailchimp after you review the list.
Update Mailchimp for WooCommerce orders canceled in the last 7 days.
How it works
What PopdockAI does when you ask
You choose how many days back to look, and your AI assistant lines up Mailchimp order status with WooCommerce. Nothing is written until you confirm, and WooCommerce is never touched.
01
Ask
You choose how many days back to look.
02
Read
It reads refunds and cancellations, counting only full refunds as refunded.
03
Match
It confirms each order in the Mailchimp store by order id.
04
Confirm
You review the changes, then only the financial status is updated.
What PopdockAI provides
The tools behind the answer
Ready made tools for WooCommerce and one secure connection to your AI tool. No code, no exports.
mailchimp-get-store
woocommerce-get-refund
woocommerce-get-order
mailchimp-get-order-line
mailchimp-update-order
This report is built from Get data tools only. PopdockAI applies the row, field and parameter rules your admin sets, and every query is written to the audit trail.
The outcome
Mailchimp revenue you actually kept
Related use cases
More ways to put this data to work
One prompt template with infinite possibilities.
Your AI assistant adapts its approach, tone, and capabilities to match each unique context while you maintain a single, manageable workflow.
Join forward-thinking companies that are transforming their operations with intelligent, secure AI automation.

.webp)
