Buildwithclaude brevo-automation
Automate Brevo (Sendinblue) tasks via Rube MCP (Composio): manage email campaigns, create/edit templates, track senders, and monitor campaign performance. Always search tools first for current schemas.
git clone https://github.com/davepoon/buildwithclaude
T=$(mktemp -d) && git clone --depth=1 https://github.com/davepoon/buildwithclaude "$T" && mkdir -p ~/.claude/skills && cp -r "$T/plugins/all-skills/skills/brevo-automation" ~/.claude/skills/davepoon-buildwithclaude-brevo-automation && rm -rf "$T"
plugins/all-skills/skills/brevo-automation/SKILL.mdBrevo Automation via Rube MCP
Automate Brevo (formerly Sendinblue) email marketing operations through Composio's Brevo toolkit via Rube MCP.
Toolkit docs: composio.dev/toolkits/brevo
Prerequisites
- Rube MCP must be connected (RUBE_SEARCH_TOOLS available)
- Active Brevo connection via
with toolkitRUBE_MANAGE_CONNECTIONSbrevo - Always call
first to get current tool schemasRUBE_SEARCH_TOOLS
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
respondsRUBE_SEARCH_TOOLS - Call
with toolkitRUBE_MANAGE_CONNECTIONSbrevo - If connection is not ACTIVE, follow the returned auth link to complete Brevo authentication
- Confirm connection status shows ACTIVE before running any workflows
Core Workflows
1. Manage Email Campaigns
When to use: User wants to list, review, or update email campaigns
Tool sequence:
- List all campaigns with filters [Required]BREVO_LIST_EMAIL_CAMPAIGNS
- Update campaign content or settings [Optional]BREVO_UPDATE_EMAIL_CAMPAIGN
Key parameters for listing:
: Campaign type ('classic' or 'trigger')type
: Campaign status ('suspended', 'archive', 'sent', 'queued', 'draft', 'inProcess', 'inReview')status
/startDate
: Date range filter (YYYY-MM-DDTHH:mm:ss.SSSZ format)endDate
: Stats type to include ('globalStats', 'linksStats', 'statsByDomain')statistics
: Results per page (max 100, default 50)limit
: Pagination offsetoffset
: Sort order ('asc' or 'desc')sort
: SetexcludeHtmlContent
to reduce response sizetrue
Key parameters for update:
: Numeric campaign ID (required)campaign_id
: Campaign namename
: Email subject linesubject
: HTML email body (mutually exclusive withhtmlContent
)htmlUrl
: URL to HTML contenthtmlUrl
: Sender object withsender
,name
, oremailid
: Object withrecipients
andlistIdsexclusionListIds
: Scheduled send time (YYYY-MM-DDTHH:mm:ss.SSSZ)scheduledAt
Pitfalls:
andstartDate
are mutually required; provide both or neitherendDate- Date filters only work when
is not passed or set to 'sent'status
andhtmlContent
are mutually exclusivehtmlUrl- Campaign
email must be a verified sender in Brevosender - A/B testing fields (
,subjectA
,subjectB
,splitRule
) requirewinnerCriteriaabTesting: true
uses full ISO 8601 format with timezonescheduledAt
2. Create and Manage Email Templates
When to use: User wants to create, edit, list, or delete email templates
Tool sequence:
- List all templates [Required]BREVO_GET_ALL_EMAIL_TEMPLATES
- Create a new template or update existing [Required]BREVO_CREATE_OR_UPDATE_EMAIL_TEMPLATE
- Delete an inactive template [Optional]BREVO_DELETE_EMAIL_TEMPLATE
Key parameters for listing:
: Filter active (templateStatus
) or inactive (true
) templatesfalse
: Results per page (max 1000, default 50)limit
: Pagination offsetoffset
: Sort order ('asc' or 'desc')sort
Key parameters for create/update:
: Include to update; omit to create newtemplateId
: Template display name (required for creation)templateName
: Email subject line (required for creation)subject
: HTML template body (min 10 characters; use this orhtmlContent
)htmlUrl
: Sender object withsender
andname
, oremail
(required for creation)id
: Reply-to email addressreplyTo
: Activate or deactivate the templateisActive
: Category tag for the templatetag
Pitfalls:
- When
is provided, the tool updates; when omitted, it createstemplateId - For creation,
,templateName
, andsubject
are requiredsender
must be at least 10 charactershtmlContent- Template personalization uses
syntax{{contact.ATTRIBUTE}} - Only inactive templates can be deleted
andhtmlContent
are mutually exclusivehtmlUrl
3. Manage Senders
When to use: User wants to view authorized sender identities
Tool sequence:
- List all verified senders [Required]BREVO_GET_ALL_SENDERS
Key parameters: (none required)
Pitfalls:
- Senders must be verified before they can be used in campaigns or templates
- Sender verification is done through the Brevo web interface, not via API
- Sender IDs can be used in
fields for campaigns and templatessender.id
4. Configure A/B Testing Campaigns
When to use: User wants to set up or modify A/B test settings on a campaign
Tool sequence:
- Find the target campaign [Prerequisite]BREVO_LIST_EMAIL_CAMPAIGNS
- Configure A/B test settings [Required]BREVO_UPDATE_EMAIL_CAMPAIGN
Key parameters:
: Campaign to configurecampaign_id
: Set toabTesting
to enable A/B testingtrue
: Subject line for variant AsubjectA
: Subject line for variant BsubjectB
: Percentage split for the test (1-99)splitRule
: 'open' or 'click' for determining the winnerwinnerCriteria
: Hours to wait before selecting winner (1-168)winnerDelay
Pitfalls:
- A/B testing must be enabled (
) before setting variant fieldsabTesting: true
is the percentage of contacts that receive variant AsplitRule
defines how long to test before sending the winner to remaining contactswinnerDelay- Only works with 'classic' campaign type
Common Patterns
Campaign Lifecycle
1. Create campaign (status: draft) 2. Set recipients (listIds) 3. Configure content (htmlContent or htmlUrl) 4. Optionally schedule (scheduledAt) 5. Send or schedule via Brevo UI (API update can set scheduledAt)
Pagination
- Use
(page size) andlimit
(starting index)offset - Default limit is 50; max varies by endpoint (100 for campaigns, 1000 for templates)
- Increment
byoffset
each pagelimit - Check
in response to determine total availablecount
Template Personalization
- First name: {{contact.FIRSTNAME}} - Last name: {{contact.LASTNAME}} - Custom attribute: {{contact.CUSTOM_ATTRIBUTE}} - Mirror link: {{mirror}} - Unsubscribe link: {{unsubscribe}}
Known Pitfalls
Date Formats:
- All dates use ISO 8601 with milliseconds: YYYY-MM-DDTHH:mm:ss.SSSZ
- Pass timezone in the date-time format for accurate results
andstartDate
must be used togetherendDate
Sender Verification:
- All sender emails must be verified in Brevo before use
- Unverified senders cause campaign creation/update failures
- Use GET_ALL_SENDERS to check available verified senders
Rate Limits:
- Brevo API has rate limits per account plan
- Implement backoff on 429 responses
- Template operations have lower limits than read operations
Response Parsing:
- Response data may be nested under
ordatadata.data - Parse defensively with fallback patterns
- Campaign and template IDs are numeric integers
Quick Reference
| Task | Tool Slug | Key Params |
|---|---|---|
| List campaigns | BREVO_LIST_EMAIL_CAMPAIGNS | type, status, limit, offset |
| Update campaign | BREVO_UPDATE_EMAIL_CAMPAIGN | campaign_id, subject, htmlContent |
| List templates | BREVO_GET_ALL_EMAIL_TEMPLATES | templateStatus, limit, offset |
| Create template | BREVO_CREATE_OR_UPDATE_EMAIL_TEMPLATE | templateName, subject, htmlContent, sender |
| Update template | BREVO_CREATE_OR_UPDATE_EMAIL_TEMPLATE | templateId, htmlContent |
| Delete template | BREVO_DELETE_EMAIL_TEMPLATE | templateId |
| List senders | BREVO_GET_ALL_SENDERS | (none) |
Powered by Composio