← All guides marginal.sh

Testing Referral Program Subject Lines in Zed

Updated June 2026 · Hosted email MCP server

Zed's AI assistant can drive a full referral program subject line test without leaving your editor. Connect marginal's email MCP server and let the agent generate variants, launch managed sends, and surface within-test lift.

Why test referral subject lines from Zed

Referral campaigns live or die on the open. A subscriber has to notice that a friend invited them, that there's a reward waiting, or that their own referral earned a bonus — and that decision happens in the inbox preview. Iterating on referral program subject lines in Zed keeps that work next to the code that triggers the emails.

Because marginal exposes its tools over MCP, the Zed agent treats subject line A/B testing as just another callable action. You describe the campaign in plain language, and the agent handles variant generation, the send, and reporting.

Connecting marginal to Zed

marginal is a hosted email MCP server, so there's nothing to deploy. Point Zed's MCP configuration at the marginal endpoint and authenticate with your Bearer API key. Once connected, the agent can call generate_variants, launch_test, get_results, and recommend_next.

The endpoint is https://marginal.sh/mcp and the registry name is sh.marginal/mcp. Use an API key that begins with marg_live_ — full setup details are in the docs at https://marginal.sh/docs/.

A referral subject line A/B test workflow

A typical referral program subject line test in Zed starts with a prompt describing the audience and the incentive. The agent calls generate_variants to produce several distinct angles, then launch_test to send them as a managed split.

After delivery, get_results returns open and click data with within-test lift so you can see which framing earned more attention. recommend_next suggests where to take the following round.

Tips for AI agent email marketing on referrals

Referral copy benefits from contrast: test reward-led subject lines against social-led ones, and personalized phrasing against generic invites. Letting the Zed agent run the subject line A/B test means you can explore more variations quickly without manually authoring each send.

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.

Documentation · Sign up · FAQ