SKILL.md
Mailchimp Automation via Rube MCP
Automate Mailchimp email marketing workflows including campaign creation and sending, audience/list management, subscriber operations, segmentation, and performance analytics through Composio's Mailchimp toolkit.
Prerequisites
- Rube MCP must be connected (RUBESEARCHTOOLS available)
- Active Mailchimp connection via
RUBEMANAGECONNECTIONSwith toolkitmailchimp - Always call
RUBESEARCHTOOLSfirst to get current tool schemas
Setup
Get Rube MCP: Add https://rube.app/mcp as an MCP server in your client configuration. No API keys needed — just add the endpoint and it works.
- Verify Rube MCP is available by confirming
RUBESEARCHTOOLSresponds - Call
RUBEMANAGECONNECTIONSwith toolkitmailchimp - If connection is not ACTIVE, follow the returned auth link to complete Mailchimp OAuth
- Confirm connection status shows ACTIVE before running any workflows
Core Workflows
1. Create and Send Email Campaigns
When to use: User wants to create, configure, test, and send an email campaign.
Tool sequence:
MAILCHIMPGETLISTSINFO- List available audiences and get listid [Prerequisite]MAILCHIMPADDCAMPAIGN- Create a new campaign with type, audience, subject, from name [Required]MAILCHIMPSETCAMPAIGN_CONTENT- Set HTML content for the campaign [Required]MAILCHIMPSENDTEST_EMAIL- Send preview to reviewers before live send [Optional]MAILCHIMPSENDCAMPAIGN- Send the campaign immediately [Required]MAILCHIMPSCHEDULECAMPAIGN- Schedule for future delivery instead of immediate send [Optional]
Key parameters for MAILCHIMPADDCAMPAIGN:
type: "regular", "plaintext", "rss", or "variate" (required)recipientslistid: Audience/list ID for recipientssettingssubjectline: Email subject linesettingsfromname: Sender display namesettingsreplyto: Reply-to email address (required for sending)settings__title: Internal campaign titlesettingspreviewtext: Preview text shown in inbox
Key parameters for MAILCHIMPSETCAMPAIGN_CONTENT:
campaign_id: Campaign ID from creation step (required)html: Raw HTML content for the emailplain_text: Plain-text version (auto-generated if omitted)template__id: Use a pre-built template instead of raw HTML
Pitfalls:
MAILCHIMPSENDCAMPAIGNis irreversible; always send a test email first and get explicit user approval- Campaign must be in "save" (draft) status with valid audience, subject, from name, verified email, and content before sending
MAILCHIMPSCHEDULECAMPAIGNrequires a valid future datetime; past timestamps fail- Templates and HTML content must include compliant footer/unsubscribe merge tags
- Mailchimp uses double-underscore notation for nested params (e.g.,
settingssubjectline)
2. Manage Audiences and Subscribers
When to use: User wants to view audiences, list subscribers, or check subscriber details.
Tool sequence:
MAILCHIMPGETLISTS_INFO- List all audiences with member counts [Required]MAILCHIMPGETLIST_INFO- Get details for a specific audience [Optional]MAILCHIMPLISTMEMBERS_INFO- List members with status filter and pagination [Required]MAILCHIMPSEARCHMEMBERS- Search by email or name across lists [Optional]MAILCHIMPGETMEMBER_INFO- Get detailed profile for a specific subscriber [Optional]MAILCHIMPLISTSEGMENTS- List segments within an audience [Optional]
Key parameters for MAILCHIMPLISTMEMBERS_INFO:
list_id: Audience ID (required)status: "subscribed", "unsubscribed", "cleaned", "pending", "transactional", "archived"count: Records per page (default 10, max 1000)offset: Pagination offset (default 0)sortfield: "timestampopt", "timestampsignup", or "lastchanged"fields: Comma-separated list to limit response size
Pitfalls:
stats.avgopenrateandstats.avgclickrateare 0-1 fractions, NOT 0-100 percentages- Always use
status="subscribed"to filter active subscribers; omitting returns all statuses - Must paginate using
countandoffsetuntil collected members matchtotal_items - Large list responses may be truncated; data is under
response.data.members
3. Add and Update Subscribers
When to use: User wants to add new subscribers, update existing ones, or bulk-manage list membership.
Tool sequence:
MAILCHIMPGETLIST_INFO- Validate target audience exists [Prerequisite]MAILCHIMPSEARCHMEMBERS- Check if contact already exists [Optional]MAILCHIMPADDORUPDATELIST_MEMBER- Upsert subscriber (create or update) [Required]MAILCHIMPADDMEMBERTOLIST- Add new subscriber (create only) [Optional]MAILCHIMPBATCHADDORREMOVE_MEMBERS- Bulk manage segment membership [Optional]
Key parameters for MAILCHIMPADDORUPDATELIST_MEMBER:
list_id: Audience ID (required)subscriber_hash: MD5 hash of lowercase email (required)email_address: Subscriber email (required)statusifnew: Status for new subscribers: "subscribed", "pending", etc. (required)status: Status for existing subscribersmerge_fields: Object with merge tag keys (e.g.,{"FNAME": "John", "LNAME": "Doe"})tags: Array of tag strings
Key parameters for MAILCHIMPADDMEMBERTOLIST:
list_id: Audience ID (required)email_address: Subscriber email (required)status: "subscribed", "pending", "unsubscribed", "cleaned", "transactional" (required)
Pitfalls:
subscriber_hashmust be MD5 of the lowercase email; incorrect casing causes 404s or duplicates- Use
MAILCHIMPADDORUPDATELISTMEMBER(upsert) instead ofMAILCHIMPADDMEMBERTO_LISTto avoid duplicate errors statusifnewdetermines status only for new contacts; existing contacts usestatus- Use
skipmergevalidation: trueto bypass required merge field validation MAILCHIMPBATCHADDORREMOVE_MEMBERSmanages static segment membership, not list membership
4. View Campaign Reports and Analytics
When to use: User wants to review campaign performance, open rates, click rates, or subscriber engagement.
Tool sequence:
MAILCHIMPLISTCAMPAIGNS- List sent campaigns with report summaries [Required]MAILCHIMPSEARCHCAMPAIGNS- Find campaigns by name, subject, or content [Optional]MAILCHIMPGETCAMPAIGN_REPORT- Get detailed performance report for a campaign [Required]MAILCHIMPLISTCAMPAIGN_REPORTS- Bulk fetch reports across multiple campaigns [Optional]MAILCHIMPLISTCAMPAIGN_DETAILS- Get link-level click statistics [Optional]MAILCHIMPGETCAMPAIGNLINKDETAILS- Drill into specific link click data [Optional]MAILCHIMPLISTCLICKEDLINKSUBSCRIBERS- See who clicked a specific link [Optional]MAILCHIMPGETSUBSCRIBEREMAILACTIVITY- Get per-subscriber campaign activity [Optional]MAILCHIMPGETCAMPAIGN_CONTENT- Retrieve campaign HTML content [Optional]
Key parameters for MAILCHIMPLISTCAMPAIGNS:
status: "save", "paused", "schedule", "sending", "sent"count/offset: Pagination (default 10, max 1000)sincesendtime/beforesendtime: ISO 8601 date range filtersortfield: "createtime" or "send_time"fields: Limit response fields for performance
Key parameters for MAILCHIMPGETCAMPAIGN_REPORT:
campaign_id: Campaign ID (required)- Returns: opens, clicks, bounces, unsubscribes, timeseries, industry_stats
Pitfalls:
MAILCHIMPLISTCAMPAIGNSonly returns high-levelreportsummary; useMAILCHIMPGETCAMPAIGNREPORTfor detailed metrics- Draft/unsent campaigns lack meaningful report data
- When using
fieldsparameter on LISTCAMPAIGNS, explicitly requestsendtime andreport_summarysubfields - Pagination defaults are low (10 records); iterate with
countandoffsetuntiltotal_itemsis covered send_timeis ISO 8601 with timezone; parse carefully
Common Patterns
ID Resolution
Always resolve names to IDs before operations:
- Audience name -> listid:
MAILCHIMPGETLISTSINFOand match by name - Subscriber email -> subscriber_hash: Compute MD5 of lowercase email in code
- Campaign name -> campaignid:
MAILCHIMPSEARCH_CAMPAIGNSwith query - Segment name -> segmentid:
MAILCHIMPLISTSEGMENTSwith listid
Pagination
Mailchimp uses offset-based pagination:
- Use
count(page size, max 1000) andoffset(skip N records) - Continue until collected records match
total_itemsfrom the response - Default
countis 10; always set explicitly for bulk operations - Search endpoints max at 10 pages (300 results for 30/page)
Subscriber Hash
Many endpoints require subscriber_hash (MD5 of lowercase email):
import hashlib
subscriber_hash = hashlib.md5(email.lower().encode()).hexdigest()
Known Pitfalls
ID Formats
list_id(audience ID) is a short alphanumeric string (e.g., "abc123def4")campaign_idis an alphanumeric stringsubscriber_hashis an MD5 hex string (32 characters)- Segment IDs are integers
Rate Limits
- Mailchimp enforces API rate limits; use batching for bulk subscriber operations
- High-volume use of GETMEMBERINFO and ADDORUPDATELISTMEMBER can trigger throttling
- Use
MAILCHIMPBATCHADDORREMOVE_MEMBERSfor bulk segment operations
Parameter Quirks
- Nested parameters use double-underscore notation:
settingssubjectline,recipientslistid avgopenrateandavgclickrateare 0-1 fractions, not percentagesstatusifnewonly applies to new contacts in upsert operationssubscriber_hashmust be MD5 of lowercase email; wrong casing creates phantom records- Campaign
typeis required for creation; most common is "regular" MAILCHIMPSENDCAMPAIGNreturns HTTP 204 on success (no body)
Content and Compliance
- Campaign HTML must include unsubscribe link and physical address (merge tags)
- Content must be set via
MAILCHIMPSETCAMPAIGN_CONTENTbefore sending - Test emails require campaign to have content already set
Quick Reference
| Task | Tool Slug | Key Params |
|---|---|---|
| List audiences | MAILCHIMPGETLISTS_INFO |
count, offset |
| Get audience details | MAILCHIMPGETLIST_INFO |
list_id |
| Create campaign | MAILCHIMPADDCAMPAIGN |
type, recipientslistid, settingssubjectline |
| Set campaign content | MAILCHIMPSETCAMPAIGN_CONTENT |
campaign_id, html |
| Send test email | MAILCHIMPSENDTEST_EMAIL |
campaignid, testemails |
| Send campaign | MAILCHIMPSENDCAMPAIGN |
campaign_id |
| Schedule campaign | MAILCHIMPSCHEDULECAMPAIGN |
campaignid, scheduletime |
| Get campaign info | MAILCHIMPGETCAMPAIGN_INFO |
campaign_id |
| Search campaigns | MAILCHIMPSEARCHCAMPAIGNS |
query |
| List campaigns | MAILCHIMPLISTCAMPAIGNS |
status, count, offset |
| Replicate campaign | MAILCHIMPREPLICATECAMPAIGN |
campaign_id |
| List subscribers | MAILCHIMPLISTMEMBERS_INFO |
list_id, status, count, offset |
| Search members | MAILCHIMPSEARCHMEMBERS |
query, list_id |
| Get member info | MAILCHIMPGETMEMBER_INFO |
listid, subscriberhash |
| Add subscriber | MAILCHIMPADDMEMBERTOLIST |
listid, emailaddress, status |
| Upsert subscriber | MAILCHIMPADDORUPDATELIST_MEMBER |
listid, subscriberhash, emailaddress, statusif_new |
| Batch members | MAILCHIMPBATCHADDORREMOVE_MEMBERS |
listid, segmentid |
| List segments | MAILCHIMPLISTSEGMENTS |
list_id |
| Campaign report | MAILCHIMPGETCAMPAIGN_REPORT |
campaign_id |
| All reports | MAILCHIMPLISTCAMPAIGN_REPORTS |
count, offset |
| Link click details | MAILCHIMPLISTCAMPAIGN_DETAILS |
campaign_id, count |
| Subscriber activity | MAILCHIMPGETSUBSCRIBEREMAILACTIVITY |
campaignid, subscriberhash |
| Member recent activity | MAILCHIMPVIEWRECENT_ACTIVITY |
listid, subscriberhash |
| Campaign content | MAILCHIMPGETCAMPAIGN_CONTENT |
campaign_id |
When to Use
This skill is applicable to execute the workflow or actions described in the overview.
Limitations
- Use this skill only when the task clearly matches the scope described above.
- Do not treat the output as a substitute for environment-specific validation, testing, or expert review.
- Stop and ask for clarification if required inputs, permissions, safety boundaries, or success criteria are missing.