> ## Documentation Index
> Fetch the complete documentation index at: https://docs.brew.new/llms.txt
> Use this file to discover all available pages before exploring further.

# MCP workflows

> Guided email-marketing recipes for agents — launch a campaign, build a segment, set up an automation, analyze performance, and personalize with a CRM MCP.

The Brew MCP ships **guided prompts** so agents chain the right tools in the right order. On clients that surface prompts, your agent can invoke them directly; the same recipes are also returned by `get_brew_capabilities` under `workflows`.

## Launch a campaign

`launch_email_campaign` — the full create → send → analyze loop:

1. `create_email_design` from a prompt → iterate with `edit_email_with_ai`.
2. `send_email` with `test: true` to QA.
3. `list_domains` (verified sender) + `list_audiences` (or build one).
4. `send_email` with `audienceId`, `domainId`, and an `idempotency_key`. Add `scheduledAt` to schedule.
5. `get_send_analytics` + `get_campaign_analytics`.

## Build a segment and send

`build_segment_and_send` — a segment is a saved Audience with filters:

1. `search_contacts` + `list_custom_fields` to see what you can filter on.
2. `create_audience` with `filters` + `logicalOperator` (`and` / `or`). Add `include: ["count"]` to size it.
3. `create_email_design` → `send_email` to the `audienceId`.

## Set up an automation

`set_up_automation`:

1. `create_trigger` (note the `triggerEventId`).
2. `create_email_design`.
3. `create_automation` (a graph of sendEmail / wait / filter / split nodes).
4. `test_automation` → `update_automation { published: true }`.
5. `fire_trigger_event` from your app + monitor with `list_automation_runs`.

## Analyze performance

`analyze_campaign_performance` — `get_send_analytics` → `get_campaign_analytics` → `get_event_analytics` (and `get_automation_analytics`), then summarize wins, deliverability issues, and next experiments.

## Personalize with a CRM MCP

`personalize_with_crm` — this is where Brew shines next to other MCPs. Brew is the durable **email marketing memory and infrastructure**; a CRM / enrichment MCP (Clay, Attio, …) is the **contact intelligence**:

1. **Enrich** — pull contact context (lifecycle, intent, firmographics) from your CRM MCP.
2. **Write it to Brew** — `create_custom_field` for each attribute, then `create_contact` / `update_contact` (or `import_contacts_csv`).
3. **Segment** — `create_audience` filtering on the enriched fields (e.g. `lifecycle = "trial" AND intent = "high"`).
4. **Personalize** — `create_email_design` that speaks to the segment, then `send_email`.
5. **Measure & re-segment** — read analytics and refine.

This loop — enrich → segment → design → send → measure → re-segment — is the complete personalized email-marketing cycle, with Brew as the memory across runs.

## Need Help?

Our team is ready to support you at every step of your journey with Brew. Choose the option that works best for you:

<Tabs>
  <Tab title="Self-Service Tools">
    <CardGroup cols="2">
      <Card title="Search Documentation" icon="magnifying-glass" color="#c44925">
        Type in the "Ask any question" search bar at the top left to instantly find relevant documentation pages.
      </Card>

      <Card title="ChatGPT/Claude Integration" icon="robot" color="#c44925">
        Click "Open in ChatGPT" at the top right of any page to analyze documentation with ChatGPT or Claude for deeper insights.
      </Card>
    </CardGroup>
  </Tab>

  <Tab title="Talk to Our Team">
    <CardGroup cols="2">
      <Card title="Schedule a Call" icon="calendar" color="#c44925" href="https://calendar.google.com/calendar/u/0/appointments/schedules/AcZssZ1iYoRUG1J792XQpbuQLjSRRDupr7MwraFK-HQRCtTYdBmrQi8nZu2qXfzKQigb8gbKJK3KN3-R">
        Book time with our founders for personalized guidance on strategy, best practices, or complex implementation questions.
      </Card>

      <Card title="Call Us Directly" icon="phone" color="#c44925">
        Need immediate assistance? Reach us at **+1-(332)-203-2145** for urgent issues or time-sensitive questions.
      </Card>

      <Card title="Slack Channel" icon="slack" color="#c44925">
        Our preferred support channel. You'll receive an invite after signup for direct founder support and fast responses.
      </Card>

      <Card title="Email Support" icon="envelope" color="#c44925" href="mailto:support@brew.new">
        Contact us at **[support@brew.new](mailto:support@brew.new)** for detailed inquiries or if you prefer not to use Slack.
      </Card>
    </CardGroup>
  </Tab>
</Tabs>
