/
/
Build a Mailchimp renewal segment from Rillet contracts
For marketers who want subscribed contacts of Rillet customers with contracts ending soon placed in a static Mailchimp segment.
On this page
Connector
Connect Rillet, pick your AI tool and paste the prompt.
The problem
Renewal segments built by hand miss customers or include opt-outs
A renewal campaign needs contacts whose Rillet contracts end soon and who still subscribe in Mailchimp. Building that segment by hand means filtering contracts, finding emails, checking each status and avoiding people already in it.
Without PopdockAI
- Filter Rillet contracts by end date
- Look up each customer's email addresses
- Check every address for its Mailchimp status
- Cross off people already in the segment
With PopdockAI
- Contracts ending in your window read from Rillet, closed ones skipped
- Only subscribed contacts not yet in the segment kept
- Everyone left out listed with the reason
- Contacts added after you confirm and the segment read back
The prompt
Use this prompt
Copy it into any AI tool connected to PopdockAI. Swap the values in braces for your own.
**Objective:** Put the subscribed Mailchimp contacts of Rillet customers whose contracts end in the next `{days-ahead}` days (default 90) into the static segment `{segment-name}` of audience `{list-name}`, ready for a renewal campaign.
**Step 1: Resolve the audience and segment**
* Call `mailchimp-get-list` with `name.contains` set to `{list-name}`. Continue only if exactly one audience matches; keep its `list-id`.
* Call `mailchimp-get-segment` with `list-id` and `name` set to `{segment-name}`. Continue only if exactly one segment matches and its `type` is static. If it is a saved (condition-based) segment, explain that its members are set by its conditions and stop. If none matches, say so and stop; do not try to create one.
* Call `mailchimp-get-segment-member` with `segment-id` and `list-id` to get who is already in it.
**Step 2: Find the renewing customers**
Call `rillet-get-contracts` with `end-date.from` today and `end-date.to` today plus the window (YYYY-MM-DD). Exclude closed or cancelled contracts. Then call `rillet-get-customer-emails` once (no filters) to get the emails for those customers.
**Step 3: Keep only addable contacts**
Call `mailchimp-get-list-member` with `list-name` set to the confirmed audience name and `max-records` covering its size. Match emails case-insensitively after trimming spaces. A Rillet customer can have several emails (`email-type`), and one email can appear on more than one Rillet customer: keep every pairing and say so in the report. Keep emails that are members with status subscribed and are not already in the segment.
**Step 4: Show the plan and stop**
Table: email, Rillet customer name, contract name, `end-date`. Also list, separately, renewing contacts left out and why (not in audience, unsubscribed, cleaned, already in segment). Ask the user to confirm and wait.
**Step 5: Add and confirm**
For each confirmed email, call `mailchimp-add-segment-member` with `segment-id`, `list-id` and `email-address`. Then call `mailchimp-get-segment-member` with `segment-id` and report added, skipped and failed.
**Rules & Guidelines:**
* Tools named mailchimp- come from the mailchimp MCP server; tools named rillet- come from the rillet MCP server. If a tool from either server is missing, stop and say which server is not connected rather than working around it.
* The only key shared by the two systems is the email address. Mailchimp `customer-id` values (e-commerce store customers) are NOT Rillet customer ids; never pass one system's id into the other.
* The only write tool this prompt may call is `mailchimp-add-segment-member` on the mailchimp server, and only after the user confirms Step 4.
* Never call `mailchimp-add-list-member` or `mailchimp-update-list-member`: people not already subscribed stay out of the segment.
* Do not call `mailchimp-start-automation` or `mailchimp-replicate-campaign` to send anything, and do not call any Rillet tool whose name starts with rillet-add-, rillet-update-, rillet-apply-, rillet-unapply-, rillet-record-, rillet-set- or rillet-setup-.
**Validation:**
* If `{days-ahead}` is empty or not a whole number, use 90.
* If nothing is left to add after Step 3, report the left-out list and stop.
* If an add fails for one email, record it and continue.Who it's for
One answer, three teams that use it
Lifecycle marketers
Run renewal campaigns on the right list
Your segment holds the customers whose contracts actually end soon, so the renewal email reaches the right people.
Add contacts for Rillet contracts ending in the next 60 days to our Renewals segment in Mailchimp.
Account managers
Warm up accounts before renewal talks
Customers coming up for renewal get your campaign ahead of the conversation, without you building the list.
Put customers like Contoso with Rillet renewals before year end into the Upcoming renewals segment.
Marketing operations
Keep opt-outs out of renewal sends
Only subscribed contacts are added, and anyone left out is listed with the reason, so you can trust the segment.
Update the Renewals Q1 segment with renewing Rillet customers and tell me who was skipped and why.
How it works
What PopdockAI does when you ask
You name the audience, the static segment and how far ahead to look, and your AI assistant finds the renewing customers you can reach. Nothing is added until you confirm, and nothing is sent.
01
Ask
You name the audience, the static segment and how many days ahead.
02
Find
It reads Rillet contracts ending in that window and their emails.
03
Filter
It keeps subscribed contacts not yet in the segment and lists the rest.
04
Add
You confirm, then it adds them and reads the segment back.
What PopdockAI provides
The tools behind the answer
Ready made tools for Rillet and one secure connection to your AI tool. No code, no exports.
mailchimp-get-list
mailchimp-get-segment
mailchimp-get-segment-member
rillet-get-contracts
rillet-get-customer-emails
mailchimp-get-list-member
mailchimp-add-segment-member
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
A renewal segment with every reachable renewing customer
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)
