Automate Mailchimp email marketing including campaigns, audiences, subscribers, segments, and analytics via Rube MCP (Composio). Always search tools first for current schemas.
Add this skill
npx mdskills install sickn33/mailchimp-automationComprehensive Mailchimp automation guide with detailed workflows, parameter specs, and pitfall warnings
1---2name: mailchimp-automation3description: "Automate Mailchimp email marketing including campaigns, audiences, subscribers, segments, and analytics via Rube MCP (Composio). Always search tools first for current schemas."4requires:5 mcp: [rube]6---78# Mailchimp Automation via Rube MCP910Automate Mailchimp email marketing workflows including campaign creation and sending, audience/list management, subscriber operations, segmentation, and performance analytics through Composio's Mailchimp toolkit.1112## Prerequisites1314- Rube MCP must be connected (RUBE_SEARCH_TOOLS available)15- Active Mailchimp connection via `RUBE_MANAGE_CONNECTIONS` with toolkit `mailchimp`16- Always call `RUBE_SEARCH_TOOLS` first to get current tool schemas1718## Setup1920**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.2122231. Verify Rube MCP is available by confirming `RUBE_SEARCH_TOOLS` responds242. Call `RUBE_MANAGE_CONNECTIONS` with toolkit `mailchimp`253. If connection is not ACTIVE, follow the returned auth link to complete Mailchimp OAuth264. Confirm connection status shows ACTIVE before running any workflows2728## Core Workflows2930### 1. Create and Send Email Campaigns3132**When to use**: User wants to create, configure, test, and send an email campaign.3334**Tool sequence**:351. `MAILCHIMP_GET_LISTS_INFO` - List available audiences and get list_id [Prerequisite]362. `MAILCHIMP_ADD_CAMPAIGN` - Create a new campaign with type, audience, subject, from name [Required]373. `MAILCHIMP_SET_CAMPAIGN_CONTENT` - Set HTML content for the campaign [Required]384. `MAILCHIMP_SEND_TEST_EMAIL` - Send preview to reviewers before live send [Optional]395. `MAILCHIMP_SEND_CAMPAIGN` - Send the campaign immediately [Required]406. `MAILCHIMP_SCHEDULE_CAMPAIGN` - Schedule for future delivery instead of immediate send [Optional]4142**Key parameters for MAILCHIMP_ADD_CAMPAIGN**:43- `type`: "regular", "plaintext", "rss", or "variate" (required)44- `recipients__list__id`: Audience/list ID for recipients45- `settings__subject__line`: Email subject line46- `settings__from__name`: Sender display name47- `settings__reply__to`: Reply-to email address (required for sending)48- `settings__title`: Internal campaign title49- `settings__preview__text`: Preview text shown in inbox5051**Key parameters for MAILCHIMP_SET_CAMPAIGN_CONTENT**:52- `campaign_id`: Campaign ID from creation step (required)53- `html`: Raw HTML content for the email54- `plain_text`: Plain-text version (auto-generated if omitted)55- `template__id`: Use a pre-built template instead of raw HTML5657**Pitfalls**:58- `MAILCHIMP_SEND_CAMPAIGN` is irreversible; always send a test email first and get explicit user approval59- Campaign must be in "save" (draft) status with valid audience, subject, from name, verified email, and content before sending60- `MAILCHIMP_SCHEDULE_CAMPAIGN` requires a valid future datetime; past timestamps fail61- Templates and HTML content must include compliant footer/unsubscribe merge tags62- Mailchimp uses double-underscore notation for nested params (e.g., `settings__subject__line`)6364### 2. Manage Audiences and Subscribers6566**When to use**: User wants to view audiences, list subscribers, or check subscriber details.6768**Tool sequence**:691. `MAILCHIMP_GET_LISTS_INFO` - List all audiences with member counts [Required]702. `MAILCHIMP_GET_LIST_INFO` - Get details for a specific audience [Optional]713. `MAILCHIMP_LIST_MEMBERS_INFO` - List members with status filter and pagination [Required]724. `MAILCHIMP_SEARCH_MEMBERS` - Search by email or name across lists [Optional]735. `MAILCHIMP_GET_MEMBER_INFO` - Get detailed profile for a specific subscriber [Optional]746. `MAILCHIMP_LIST_SEGMENTS` - List segments within an audience [Optional]7576**Key parameters for MAILCHIMP_LIST_MEMBERS_INFO**:77- `list_id`: Audience ID (required)78- `status`: "subscribed", "unsubscribed", "cleaned", "pending", "transactional", "archived"79- `count`: Records per page (default 10, max 1000)80- `offset`: Pagination offset (default 0)81- `sort_field`: "timestamp_opt", "timestamp_signup", or "last_changed"82- `fields`: Comma-separated list to limit response size8384**Pitfalls**:85- `stats.avg_open_rate` and `stats.avg_click_rate` are 0-1 fractions, NOT 0-100 percentages86- Always use `status="subscribed"` to filter active subscribers; omitting returns all statuses87- Must paginate using `count` and `offset` until collected members match `total_items`88- Large list responses may be truncated; data is under `response.data.members`8990### 3. Add and Update Subscribers9192**When to use**: User wants to add new subscribers, update existing ones, or bulk-manage list membership.9394**Tool sequence**:951. `MAILCHIMP_GET_LIST_INFO` - Validate target audience exists [Prerequisite]962. `MAILCHIMP_SEARCH_MEMBERS` - Check if contact already exists [Optional]973. `MAILCHIMP_ADD_OR_UPDATE_LIST_MEMBER` - Upsert subscriber (create or update) [Required]984. `MAILCHIMP_ADD_MEMBER_TO_LIST` - Add new subscriber (create only) [Optional]995. `MAILCHIMP_BATCH_ADD_OR_REMOVE_MEMBERS` - Bulk manage segment membership [Optional]100101**Key parameters for MAILCHIMP_ADD_OR_UPDATE_LIST_MEMBER**:102- `list_id`: Audience ID (required)103- `subscriber_hash`: MD5 hash of lowercase email (required)104- `email_address`: Subscriber email (required)105- `status_if_new`: Status for new subscribers: "subscribed", "pending", etc. (required)106- `status`: Status for existing subscribers107- `merge_fields`: Object with merge tag keys (e.g., `{"FNAME": "John", "LNAME": "Doe"}`)108- `tags`: Array of tag strings109110**Key parameters for MAILCHIMP_ADD_MEMBER_TO_LIST**:111- `list_id`: Audience ID (required)112- `email_address`: Subscriber email (required)113- `status`: "subscribed", "pending", "unsubscribed", "cleaned", "transactional" (required)114115**Pitfalls**:116- `subscriber_hash` must be MD5 of the **lowercase** email; incorrect casing causes 404s or duplicates117- Use `MAILCHIMP_ADD_OR_UPDATE_LIST_MEMBER` (upsert) instead of `MAILCHIMP_ADD_MEMBER_TO_LIST` to avoid duplicate errors118- `status_if_new` determines status only for new contacts; existing contacts use `status`119- Use `skip_merge_validation: true` to bypass required merge field validation120- `MAILCHIMP_BATCH_ADD_OR_REMOVE_MEMBERS` manages static segment membership, not list membership121122### 4. View Campaign Reports and Analytics123124**When to use**: User wants to review campaign performance, open rates, click rates, or subscriber engagement.125126**Tool sequence**:1271. `MAILCHIMP_LIST_CAMPAIGNS` - List sent campaigns with report summaries [Required]1282. `MAILCHIMP_SEARCH_CAMPAIGNS` - Find campaigns by name, subject, or content [Optional]1293. `MAILCHIMP_GET_CAMPAIGN_REPORT` - Get detailed performance report for a campaign [Required]1304. `MAILCHIMP_LIST_CAMPAIGN_REPORTS` - Bulk fetch reports across multiple campaigns [Optional]1315. `MAILCHIMP_LIST_CAMPAIGN_DETAILS` - Get link-level click statistics [Optional]1326. `MAILCHIMP_GET_CAMPAIGN_LINK_DETAILS` - Drill into specific link click data [Optional]1337. `MAILCHIMP_LIST_CLICKED_LINK_SUBSCRIBERS` - See who clicked a specific link [Optional]1348. `MAILCHIMP_GET_SUBSCRIBER_EMAIL_ACTIVITY` - Get per-subscriber campaign activity [Optional]1359. `MAILCHIMP_GET_CAMPAIGN_CONTENT` - Retrieve campaign HTML content [Optional]136137**Key parameters for MAILCHIMP_LIST_CAMPAIGNS**:138- `status`: "save", "paused", "schedule", "sending", "sent"139- `count` / `offset`: Pagination (default 10, max 1000)140- `since_send_time` / `before_send_time`: ISO 8601 date range filter141- `sort_field`: "create_time" or "send_time"142- `fields`: Limit response fields for performance143144**Key parameters for MAILCHIMP_GET_CAMPAIGN_REPORT**:145- `campaign_id`: Campaign ID (required)146- Returns: opens, clicks, bounces, unsubscribes, timeseries, industry_stats147148**Pitfalls**:149- `MAILCHIMP_LIST_CAMPAIGNS` only returns high-level `report_summary`; use `MAILCHIMP_GET_CAMPAIGN_REPORT` for detailed metrics150- Draft/unsent campaigns lack meaningful report data151- When using `fields` parameter on LIST_CAMPAIGNS, explicitly request `send_time` and `report_summary` subfields152- Pagination defaults are low (10 records); iterate with `count` and `offset` until `total_items` is covered153- `send_time` is ISO 8601 with timezone; parse carefully154155## Common Patterns156157### ID Resolution158Always resolve names to IDs before operations:159- **Audience name -> list_id**: `MAILCHIMP_GET_LISTS_INFO` and match by name160- **Subscriber email -> subscriber_hash**: Compute MD5 of lowercase email in code161- **Campaign name -> campaign_id**: `MAILCHIMP_SEARCH_CAMPAIGNS` with query162- **Segment name -> segment_id**: `MAILCHIMP_LIST_SEGMENTS` with list_id163164### Pagination165Mailchimp uses offset-based pagination:166- Use `count` (page size, max 1000) and `offset` (skip N records)167- Continue until collected records match `total_items` from the response168- Default `count` is 10; always set explicitly for bulk operations169- Search endpoints max at 10 pages (300 results for 30/page)170171### Subscriber Hash172Many endpoints require `subscriber_hash` (MD5 of lowercase email):173```174import hashlib175subscriber_hash = hashlib.md5(email.lower().encode()).hexdigest()176```177178## Known Pitfalls179180### ID Formats181- `list_id` (audience ID) is a short alphanumeric string (e.g., "abc123def4")182- `campaign_id` is an alphanumeric string183- `subscriber_hash` is an MD5 hex string (32 characters)184- Segment IDs are integers185186### Rate Limits187- Mailchimp enforces API rate limits; use batching for bulk subscriber operations188- High-volume use of GET_MEMBER_INFO and ADD_OR_UPDATE_LIST_MEMBER can trigger throttling189- Use `MAILCHIMP_BATCH_ADD_OR_REMOVE_MEMBERS` for bulk segment operations190191### Parameter Quirks192- Nested parameters use double-underscore notation: `settings__subject__line`, `recipients__list__id`193- `avg_open_rate` and `avg_click_rate` are 0-1 fractions, not percentages194- `status_if_new` only applies to new contacts in upsert operations195- `subscriber_hash` must be MD5 of lowercase email; wrong casing creates phantom records196- Campaign `type` is required for creation; most common is "regular"197- `MAILCHIMP_SEND_CAMPAIGN` returns HTTP 204 on success (no body)198199### Content and Compliance200- Campaign HTML must include unsubscribe link and physical address (merge tags)201- Content must be set via `MAILCHIMP_SET_CAMPAIGN_CONTENT` before sending202- Test emails require campaign to have content already set203204## Quick Reference205206| Task | Tool Slug | Key Params |207|------|-----------|------------|208| List audiences | `MAILCHIMP_GET_LISTS_INFO` | `count`, `offset` |209| Get audience details | `MAILCHIMP_GET_LIST_INFO` | `list_id` |210| Create campaign | `MAILCHIMP_ADD_CAMPAIGN` | `type`, `recipients__list__id`, `settings__subject__line` |211| Set campaign content | `MAILCHIMP_SET_CAMPAIGN_CONTENT` | `campaign_id`, `html` |212| Send test email | `MAILCHIMP_SEND_TEST_EMAIL` | `campaign_id`, `test_emails` |213| Send campaign | `MAILCHIMP_SEND_CAMPAIGN` | `campaign_id` |214| Schedule campaign | `MAILCHIMP_SCHEDULE_CAMPAIGN` | `campaign_id`, `schedule_time` |215| Get campaign info | `MAILCHIMP_GET_CAMPAIGN_INFO` | `campaign_id` |216| Search campaigns | `MAILCHIMP_SEARCH_CAMPAIGNS` | `query` |217| List campaigns | `MAILCHIMP_LIST_CAMPAIGNS` | `status`, `count`, `offset` |218| Replicate campaign | `MAILCHIMP_REPLICATE_CAMPAIGN` | `campaign_id` |219| List subscribers | `MAILCHIMP_LIST_MEMBERS_INFO` | `list_id`, `status`, `count`, `offset` |220| Search members | `MAILCHIMP_SEARCH_MEMBERS` | `query`, `list_id` |221| Get member info | `MAILCHIMP_GET_MEMBER_INFO` | `list_id`, `subscriber_hash` |222| Add subscriber | `MAILCHIMP_ADD_MEMBER_TO_LIST` | `list_id`, `email_address`, `status` |223| Upsert subscriber | `MAILCHIMP_ADD_OR_UPDATE_LIST_MEMBER` | `list_id`, `subscriber_hash`, `email_address`, `status_if_new` |224| Batch members | `MAILCHIMP_BATCH_ADD_OR_REMOVE_MEMBERS` | `list_id`, `segment_id` |225| List segments | `MAILCHIMP_LIST_SEGMENTS` | `list_id` |226| Campaign report | `MAILCHIMP_GET_CAMPAIGN_REPORT` | `campaign_id` |227| All reports | `MAILCHIMP_LIST_CAMPAIGN_REPORTS` | `count`, `offset` |228| Link click details | `MAILCHIMP_LIST_CAMPAIGN_DETAILS` | `campaign_id`, `count` |229| Subscriber activity | `MAILCHIMP_GET_SUBSCRIBER_EMAIL_ACTIVITY` | `campaign_id`, `subscriber_hash` |230| Member recent activity | `MAILCHIMP_VIEW_RECENT_ACTIVITY` | `list_id`, `subscriber_hash` |231| Campaign content | `MAILCHIMP_GET_CAMPAIGN_CONTENT` | `campaign_id` |232
Full transparency — inspect the skill content before installing.