---
name: emit
description: Add an RSS-to-newsletter to a blog using emit (rssemit.com). Use when the user wants to send their RSS feed as an email newsletter — creating an account, verifying a sending domain, connecting the feed, importing subscribers, topping up credits, and sending the first broadcast — all via the emit API.
---

# Set up emit on this project

Emit (rssemit.com) turns an RSS feed into a newsletter, billed per email. Drive it
through its REST API (`https://api.rssemit.com`, OpenAPI at `/openapi.json`) or the
emit MCP server if registered.

## Steps

1. **Find the feed.** Look in the repo for an RSS/Atom URL (e.g. `/rss.xml`,
   `/feed.xml`, `CLAUDE.md`, the site config). Confirm it with the user.

2. **Create an account** (skip if they already have a key):
   `POST /v1/accounts {"name","email"}` → store the returned `api_key` as
   `EMIT_API_KEY` (shown once). All later calls use `Authorization: Bearer $EMIT_KEY`.

3. **Verify the sending domain:** `POST /v1/domains {"domain"}` → add the returned
   DNS records (ownership TXT, SPF, DMARC, and SES DKIM CNAMEs) at the user's DNS
   provider, then `POST /v1/domains/{id}/verify`.

4. **Connect the feed:** `POST /v1/feeds {"url","from_email","schedule"}`
   (`on_publish` | `daily` | `weekly`).

5. **Subscribers:** add the embed snippet from `GET /v1/snippets` to the site, and/or
   import an existing list with `POST /v1/subscribers/import`.

6. **Top up:** `POST /v1/billing/topup {"amount_usd"}` → open the Stripe Checkout URL.

7. **Done.** New posts now email subscribers automatically. Confirm the balance and
   subscriber count with `GET /v1/account` and `GET /v1/account/analytics`.

## Notes

- New accounts start at a zero balance — they must top up before anything sends.
- Subscribers are double-opt-in: they're `pending` until they click the confirm link.
- Never print or commit the API key; store it in the environment.
