Connectors

/

Shopify

/

Log Shopify refunds as Constant Contact notes
Write
Cross-Connector

Tell your email team about Shopify refunds, on the contact

For email marketers who want each Shopify refund recorded as a note on the Constant Contact contact, by asking their AI assistant.

Try PopdockAI free
Get a live demo
Log Shopify refunds as Constant Contact notes
Log Shopify refunds since 1 October as notes on the customers in Constant Contact.
15 refunds since 1 October, and 11 notes are ready. - Example: Jordan Lee, order #1042, 89.00, Wool Throw - Already noted: 2 refunds - No email or contact: 2 refunds Shall I add the 11 notes?
Shopify
Sample figures. Your results come from your own account.
shopify-get-refund
shopify-get-customer
shopify-get-refund-line
constant-contact-get-contact
constant-contact-add-contact-note
constant-contact-get-contact-note

On this page

The problem

The problem

The prompt

Who it's for

How it works

Tools used

Connector

Shopify

Shopify
Run it on your own Shopify data.

Connect Shopify, pick your AI tool and paste the prompt.

Try PopdockAI free

The problem

Your email team never hears about refunds

When a Shopify order is refunded, the same contact keeps getting promotions for the product they just sent back. Recording each refund in Constant Contact means opening it, adding up its lines, finding the email and typing a note, one refund at a time.

Without PopdockAI

  • Open each Shopify refund and add up its lines
  • Find the shopper's email when the refund lacks one
  • Search Constant Contact for the contact
  • Type a note, and maybe the same note twice

With PopdockAI

  • Refunded amounts and items are worked out from the refund lines
  • Each refund is matched to a contact by email
  • Refunds already in an existing note are skipped
  • You see every planned note and confirm before any is added

The prompt

Use this prompt

Copy it into any AI tool connected to PopdockAI. Swap the values in braces for your own.

Prompt
**Objective:** For every Shopify refund created on or after `{since-date}`, add a note to the matching Constant Contact contact recording the refund, after the user confirms.

**Step 1: Collect the refunds**

Call `shopify-get-refund` with `created-at.from` set to `{since-date}` and `max-records` 200. For each refund keep refund-id, order-name, created-at, note and customer-email. If customer-email is blank, call `shopify-get-customer` with `customer-id` from the refund to get the email. If there is still no email, list the refund as "no email" and skip it.

**Step 2: Work out the refunded amount**

For each refund, call `shopify-get-refund-line` with `order-refund-id` set to its refund-id. Sum subtotal and list the refunded item names.

**Step 3: Find the contact**

Call `constant-contact-get-contact` with `email-address` set to the refund's email. If there is no contact, list the refund as "not in Constant Contact" and skip it. Otherwise call `constant-contact-get-contact-note` with `contact-id` from the result, and skip the refund if a note already mentions its order-name, so a rerun never duplicates a note.

**Step 4: Confirm**

Show the planned notes as a table (email, order-name, refund date, amount, items) and ask the user to confirm. Do not write anything until they do.

**Step 5: Add the notes**

For each confirmed refund, call `constant-contact-add-contact-note` once with `contact-id` and `content` in this shape: "Shopify refund on order <order-name>, <refund date>: <amount> for <items>. <note>". Leave the note text off if Shopify has none.

**Step 6: Report**

Counts of refunds found, notes added, already noted, no email, not in Constant Contact and failed.

**Rules & Guidelines:**

* `shopify-get-refund`, `shopify-get-refund-line` and `shopify-get-customer` are on the shopify server. `constant-contact-get-contact`, `constant-contact-get-contact-note` and `constant-contact-add-contact-note` are on the constant-contact server.
* `constant-contact-add-contact-note` is the only write tool this prompt may call, once per confirmed refund, and only after Step 4.
* Do NOT call `constant-contact-update-contact`, `constant-contact-add-contact`, `shopify-update-order` or any other Shopify write tool.

**Validation:**

* If there are no refunds since `{since-date}`, say so and stop.
* If one note fails, record it and carry on. Do not retry it.

Who it's for

One answer, three teams that use it

Email marketers

Stop promoting what a shopper returned

Refund notes on the contact let you shape follow-up email around what the customer actually kept.

Add notes in Constant Contact for every Shopify refund since 1 November.

Customer experience managers

Keep refund history where marketing can see it

Marketing sees the refund on the contact, so a bad experience is not followed by a cheerful sales email.

Log this week's Shopify refunds as contact notes in Constant Contact, skipping any already noted.

Marketing operations

Rerun safely without duplicate notes

Refunds already mentioned in a note are skipped, so a weekly run never doubles up.

Log Shopify refunds from October in Constant Contact and tell me how many had no email or no contact.

How it works

What PopdockAI does when you ask

You give a start date, and your AI assistant matches each Shopify refund to a Constant Contact contact. Notes are added only after you have seen the plan and said yes.

01

Ask

You give a start date.

Your AI tool

02

Collect

It reads Shopify refunds and works out the refunded amount and items.

shopify-get-refund
shopify-get-refund-line
shopify-get-customer

03

Match

It finds each contact by email and skips refunds already in a note.

constant-contact-get-contact
constant-contact-get-contact-note

04

Add

You see the planned notes, confirm, and it adds each one.

Your AI tool

What PopdockAI provides

The tools behind the answer

Ready made tools for Shopify and one secure connection to your AI tool. No code, no exports.

get-data

shopify-get-refund

Returns Shopify refunds with their order and total adjustments. Filter by order, customer, customer email, refund and created date.
get-data

shopify-get-customer

Returns Shopify customers with their account state, total spent and default address. Filter by name, email, tags, customer id, city, province, created date and total spent.
get-data

shopify-get-refund-line

Returns the line items on Shopify refunds, with the subtotal and how each was restocked. Filter by refund, order, SKU, name and restock type.
get-data

constant-contact-get-contact

Returns Constant Contact contacts with their name, email, company, job title, phone, location, tags and email permission. Filter by email address or domain, last name, company, state, permission and created date.
run-action

constant-contact-add-contact-note

Adds a note to a Constant Contact contact.
get-data

constant-contact-get-contact-note

Returns the notes logged against Constant Contact contacts. Filter by contact, email address, company name and created date.
Read only.Nothing in Shopify Changes

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.

How Popdock AI secures your data

The outcome

Every refund on record against the right contact

Try PopdockAI free
Get a live demo

Related use cases

More ways to put this data to work

All Ramp use cases

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.

Try PopdockAI Free
See Documentation