Headless ESP for AI Agents
A traditional email service provider assumes a human clicking through a dashboard. marginal flips that model: it's a headless ESP for AI agents, exposing email testing and sending as MCP tools your agent can call directly.
What 'headless' means for email automation
Headless software separates the engine from the interface. In email marketing that means an agent can generate copy, launch a campaign, and read results without ever loading a UI. marginal runs entirely as an email MCP server, so the agent talks to it through a structured protocol instead of scraping screens or stitching together REST calls.
Because marginal is hosted, there's no infrastructure to operate. You point your agent at the endpoint, authenticate with a Bearer API key, and the tools become available like any other MCP capability.
- Endpoint: https://marginal.sh/mcp
- Auth: Bearer API key in the marg_live_... format
- Registry id: sh.marginal/mcp
- No self-hosting — marginal is a managed service
The tools your agent gets
A headless ESP for AI agents is only useful if the surface area maps to real marketing work. marginal exposes four MCP tools that cover the loop from drafting to deciding.
- generate_variants — produce candidate subject lines to test
- launch_test — start a subject line A/B test with a managed send
- get_results — pull open/click tracking and within-test lift metrics
- recommend_next — get a data-backed suggestion for the next move
Running a subject line A/B test from an agent
AI agent email marketing works best as a tight feedback cycle. The agent asks marginal for variants, launches a subject line A/B test, waits for engagement data, then reads the lift before recommending what to send next. Each step is a single tool call, so the agent reasons over results rather than parsing dashboards.
Lift is reported within the test, which keeps comparisons honest — you're measuring variants against each other in the same audience, not against historical baselines that drift over time.
- Generate several subject lines, then narrow with launch_test
- Track opens and clicks automatically once the send goes out
- Use within-test lift to pick a winner with confidence
- Loop with recommend_next to plan the following campaign
Where it plugs in
marginal speaks standard MCP, so it works across the clients developers already use for agentic work. If your tool supports MCP servers, marginal slots in alongside your other tools.
Start on the free tier with 100 experiments per month, and check the docs for setup details and tool schemas.
- Clients: Cursor, OpenAI Codex, Claude Desktop, Claude Code, Windsurf, Cline, Continue, Zed
- Free tier: 100 experiments/month
- Docs: https://marginal.sh/docs/
Get started with marginal
marginal is a hosted email marketing MCP server at marginal.sh. Sign up free, create an API key, and connect https://marginal.sh/mcp from Cursor, Codex, or Claude Desktop.
- 100 experiments/month on the free tier
- Four MCP tools: generate_variants, launch_test, get_results, recommend_next
- Listed in the MCP Registry as sh.marginal/mcp