# Rasket API

A JSON API for transactional and marketing email — campaigns are the `/broadcasts` API — and for mail you receive in Rasket Inbox: one endpoint to send, a webhook to hear what happened, and a dashboard to look when you need to.

## Base URL

The base URL:

```text
https://api.rasket.com/emails
```

HTTPS only. Every path on this site is written relative to that origin, so `POST /emails` means `https://api.rasket.com/emails`.

The same routes also answer on a deployment's own host, with the `/api/v1` prefix spelled out:

On a deployment host:

```text
https://<deployment-host>/api/v1/emails
```

Same code, same behaviour, same responses — only the origin differs, because `api.<domain>` is a rewrite onto this deployment rather than a separate service.

## Start here

If you have not sent anything yet, the [quickstart](https://www.rasket.com/docs/quickstart) takes you from an empty account to a delivered email.

### Guides

- [Overview](https://www.rasket.com/docs): What exists today, and where to start.
- [Quickstart](https://www.rasket.com/docs/quickstart): Key, domain, first send — in that order.
- [Authentication](https://www.rasket.com/docs/authentication): Bearer keys, the mandatory User-Agent, and what each refusal means.
- [Errors](https://www.rasket.com/docs/errors): The whole vocabulary, with the status each name carries.
- [Idempotency](https://www.rasket.com/docs/idempotency): Retry a send without sending it twice.
- [Pagination](https://www.rasket.com/docs/pagination): Cursors are item IDs, not page numbers.
- [Rate limits](https://www.rasket.com/docs/rate-limits): Ten a second per team, and the headers that tell you where you are.
- [Events](https://www.rasket.com/docs/events): Every event a webhook can carry, with one real payload each.
- [Domains](https://www.rasket.com/docs/domains): The records, where they go at each registrar, and what the page does while you wait.
- [Tracking](https://www.rasket.com/docs/tracking): Opens and clicks: one record, two toggles, and what an open really means.
- [Receiving](https://www.rasket.com/docs/receiving): Inbound mail, and the Inbox: a webhook fires, you read it, you answer it.
- [Inbox](https://www.rasket.com/docs/inbox): Channels, personal mailboxes and seats: who sees what, and where a reply goes.
- [Node SDK](https://www.rasket.com/docs/sdk/node): The rasket package: typed from the API's own document, retries only what is safe.
- [Python SDK](https://www.rasket.com/docs/sdk/python): The rasket package on PyPI: the Node client's methods, in snake_case, over httpx.
- [MCP server](https://www.rasket.com/docs/mcp): Connect Claude, ChatGPT or any MCP client: your scopes, no key.
- [AI assist](https://www.rasket.com/docs/ai): Subject lines, drafts and diagnosis — in the dashboard and over the API, off until you allow it.
- [Agents](https://www.rasket.com/docs/agents): Let an AI agent set Rasket up: the skill, the rules file, MCP, and the recipe they share.
- [OAuth](https://www.rasket.com/docs/oauth): Let another app act for a team: register, authorize with PKCE, exchange, refresh.
- [Single sign-on](https://www.rasket.com/docs/sso): OIDC login for your team, a domain proved by DNS, enforcement and break-glass.
- [Integrations](https://www.rasket.com/docs/integrations): Vercel, Netlify and Cloudflare, plus Zapier and n8n for workflows without code.
- [SMTP](https://www.rasket.com/docs/smtp): Send from anything that speaks SMTP: settings, setup guides, limits and replies.
- [Zapier](https://www.rasket.com/docs/integrations/zapier): Send email, add contacts and react to email events from a Zap, with no code.
- [n8n](https://www.rasket.com/docs/integrations/n8n): The Rasket node and trigger for n8n workflows: install, connect, every operation.
- [Vercel](https://www.rasket.com/docs/integrations/vercel): Add Rasket on Vercel: a Sending key in each project as RASKET_API_KEY, no copying.

### API reference

- [Emails](https://www.rasket.com/docs/api-reference/emails): Send, batch, retrieve, list, reschedule, cancel, attachments.
- [Domains](https://www.rasket.com/docs/api-reference/domains): Add a domain, publish its records, verify it.
- [API keys](https://www.rasket.com/docs/api-reference/api-keys): Create, list, rename and revoke credentials.
- [Webhooks](https://www.rasket.com/docs/api-reference/webhooks): Payloads, signature verification, retries and replay.
- [Suppressions](https://www.rasket.com/docs/api-reference/suppressions): Addresses we will not send to, and why.
- [Logs](https://www.rasket.com/docs/api-reference/logs): Every request made with this team's credentials.
- [Metrics](https://www.rasket.com/docs/api-reference/metrics): Delivery, bounce, complaint and engagement counts.
- [Templates](https://www.rasket.com/docs/api-reference/templates): Versioned email content with typed variables, addressed by ID or alias.
- [Contacts](https://www.rasket.com/docs/api-reference/contacts): Your audience: contacts, their typed properties, segments and topic choices.
- [Segments](https://www.rasket.com/docs/api-reference/segments): Audiences defined by a filter, by hand, or both.
- [Topics](https://www.rasket.com/docs/api-reference/topics): What contacts subscribe to, and the preference page's list.
- [Campaigns](https://www.rasket.com/docs/api-reference/broadcasts): Campaigns, at /broadcasts: one message to a segment, from draft to results.
- [Imports](https://www.rasket.com/docs/api-reference/imports): CSV uploads: column mapping, conflicts and counts.
- [Automations](https://www.rasket.com/docs/api-reference/automations): Workflows that run per contact: the graph, its versions, and every run.
- [Custom events](https://www.rasket.com/docs/api-reference/events): The names your product fires, and what starts a workflow.
- [Receiving](https://www.rasket.com/docs/api-reference/receiving): Mail sent to you: the message, its attachments, its raw source.
- [OAuth](https://www.rasket.com/docs/api-reference/oauth): Client registration, the token endpoint, and the grants a team has given.
- [Team](https://www.rasket.com/docs/api-reference/team): The team a credential belongs to: its plan, sender identity, AI flag and members.
- [Billing](https://www.rasket.com/docs/api-reference/billing): Plan, usage, invoices and add-ons, and the hosted pages where a customer pays.
- [AI helpers](https://www.rasket.com/docs/api-reference/ai): Subject lines, a first draft, and why an email did what it did.

## Sending over SMTP

An app that can only send over SMTP — Supabase Auth, WordPress, a framework mailer — can point at the [SMTP relay](https://www.rasket.com/docs/smtp) instead. Each message it sends becomes one call to this same API, with your key as the password.
