The Mail area publishes 51 REST endpoints. Paths are relative to https://api.lessly.com; see Authentication for the required header.
GET/mail/api-keys
List active API keys (prefix + metadata only, never the secret)
MCP tool: mail_apikey_list
Parameters
No parameters.
Response
Returns object[].
| Item field | Type | Always | Description |
|---|
id | string | • | — |
name | string | • | — |
scope | string | • | — |
prefix | string | • | — |
domainId | string | null | • | — |
createdAt | string | • | — |
POST/mail/api-keys
Issue a scoped sending API key; the full secret is returned only once
MCP tool: mail_apikey_create
Parameters
| Name | In | Type | Required | Description |
|---|
name | body | string | • | Human-readable label for the key |
scope | body | stringone of: full_access, sending_access | • | Permission scope: 'full_access' or 'sending_access' |
domainId | body | string (uuid) | — | Optional Domain id this key is locked to |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
key | string | • | — |
name | string | • | — |
scope | string | • | — |
prefix | string | • | — |
domainId | string | null | • | — |
createdAt | string | • | — |
DELETE/mail/api-keys/:id
Revoke an API key by id
MCP tool: mail_apikey_delete
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | UUID of the API key to revoke |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
revoked | booleanone of: true | • | — |
GET/mail/audiences
List audiences for the current product
MCP tool: mail_audience_list
Parameters
No parameters.
Response
Returns object[].
| Item field | Type | Always | Description |
|---|
id | string | • | — |
name | string | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
POST/mail/audiences
Create an audience (a named bucket of contacts) for the current product
MCP tool: mail_audience_create
Parameters
| Name | In | Type | Required | Description |
|---|
name | body | string | • | Human label for the audience |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
name | string | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
GET/mail/audiences/:audienceId/contacts
List contacts in an audience
MCP tool: mail_contact_list
Parameters
| Name | In | Type | Required | Description |
|---|
audience_id | query | string (uuid) | • | Audience to list contacts from |
unsubscribed | query | string | booleanone of: true, false | — | Filter by unsubscribed flag |
cursor | query | string | — | Opaque pagination cursor from a prior page |
limit | query | integer | — | Max items per page (1–100, default 50) |
audienceId | path | string | — | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
data | object[] | • | — |
nextCursor | string | null | • | — |
POST/mail/audiences/:audienceId/contacts
Add a contact to an audience
MCP tool: mail_contact_create
Parameters
| Name | In | Type | Required | Description |
|---|
audience_id | body | string (uuid) | • | Audience the contact belongs to |
email | body | string | • | Contact email address |
properties | body | object | — | Custom key/value properties (e.g. first_name, last_name) |
unsubscribed | body | boolean | — | Marketing opt-out flag |
audienceId | path | string | — | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
email | string | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
audienceId | string | • | — |
properties | null | — | — |
unsubscribed | boolean | • | — |
DELETE/mail/audiences/:audienceId/contacts/:id
Delete a contact from an audience
MCP tool: mail_contact_delete
Parameters
| Name | In | Type | Required | Description |
|---|
audience_id | body | string (uuid) | • | Audience id |
id | path | string (uuid) | • | Contact id |
audienceId | path | string | — | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
deleted | boolean | • | — |
GET/mail/audiences/:audienceId/contacts/:id
Get a single contact by id
MCP tool: mail_contact_get
Parameters
| Name | In | Type | Required | Description |
|---|
audience_id | body | string (uuid) | • | Audience id |
id | path | string (uuid) | • | Contact id |
audienceId | path | string | — | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
email | string | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
audienceId | string | • | — |
properties | null | — | — |
unsubscribed | boolean | • | — |
PATCH/mail/audiences/:audienceId/contacts/:id
Update a contact (properties or unsubscribed flag)
MCP tool: mail_contact_update
Parameters
| Name | In | Type | Required | Description |
|---|
audience_id | body | string (uuid) | • | Audience id |
id | path | string (uuid) | • | Contact id |
properties | body | object | — | Replace the custom properties object |
unsubscribed | body | boolean | — | Set the marketing opt-out flag |
audienceId | path | string | — | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
email | string | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
audienceId | string | • | — |
properties | null | — | — |
unsubscribed | boolean | • | — |
DELETE/mail/audiences/:id
Delete an audience and all its contacts (cascade)
MCP tool: mail_audience_delete
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Audience id to delete |
Response
Returns object.
| Field | Type | Always | Description |
|---|
deleted | boolean | • | — |
GET/mail/audiences/:id
Get a single audience by id
MCP tool: mail_audience_get
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Audience id |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
name | string | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
PATCH/mail/audiences/:id
Rename an audience
MCP tool: mail_audience_update
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Audience id |
name | body | string | — | New name |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
name | string | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
GET/mail/broadcasts
List broadcasts for the product (cursor-paginated)
MCP tool: mail_broadcast_list
Parameters
| Name | In | Type | Required | Description |
|---|
cursor | query | string | — | — |
limit | query | integer | — | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
items | object[] | • | — |
nextCursor | string | null | • | — |
POST/mail/broadcasts
Create a draft broadcast (inline content or a template reference) targeting an audience
MCP tool: mail_broadcast_create
Parameters
| Name | In | Type | Required | Description |
|---|
name | body | string | • | — |
audienceId | body | string (uuid) | • | — |
from | body | string | • | — |
replyTo | body | string[] | — | — |
headers | body | object | — | — |
subject | body | string | — | — |
html | body | string | — | — |
text | body | string | — | — |
template | body | object | — | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
from | string | • | — |
html | string | null | • | — |
name | string | • | — |
text | string | null | • | — |
sentAt | string (date-time) | null | • | — |
status | string | • | — |
headers | object | • | — |
replyTo | string[] | • | — |
subject | string | null | • | — |
queuedAt | string (date-time) | null | • | — |
createdAt | string (date-time) | • | — |
lastError | string | null | • | — |
productId | string | • | — |
updatedAt | string (date-time) | • | — |
variables | null | — | — |
audienceId | string | • | — |
templateId | string | null | • | — |
recipientCount | number | • | — |
DELETE/mail/broadcasts/:id
Delete a draft broadcast
MCP tool: mail_broadcast_delete
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
deleted | boolean | • | — |
GET/mail/broadcasts/:id
Get one broadcast by id
MCP tool: mail_broadcast_get
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
from | string | • | — |
html | string | null | • | — |
name | string | • | — |
text | string | null | • | — |
sentAt | string (date-time) | null | • | — |
status | string | • | — |
headers | object | • | — |
replyTo | string[] | • | — |
subject | string | null | • | — |
queuedAt | string (date-time) | null | • | — |
createdAt | string (date-time) | • | — |
lastError | string | null | • | — |
productId | string | • | — |
updatedAt | string (date-time) | • | — |
variables | null | — | — |
audienceId | string | • | — |
templateId | string | null | • | — |
recipientCount | number | • | — |
PATCH/mail/broadcasts/:id
Edit a draft broadcast
MCP tool: mail_broadcast_update
Parameters
| Name | In | Type | Required | Description |
|---|
name | body | string | — | — |
audienceId | body | string (uuid) | — | — |
from | body | string | — | — |
replyTo | body | string[] | — | — |
headers | body | object | — | — |
subject | body | string | — | — |
html | body | string | — | — |
text | body | string | — | — |
template | body | object | — | — |
id | path | string (uuid) | • | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
from | string | • | — |
html | string | null | • | — |
name | string | • | — |
text | string | null | • | — |
sentAt | string (date-time) | null | • | — |
status | string | • | — |
headers | object | • | — |
replyTo | string[] | • | — |
subject | string | null | • | — |
queuedAt | string (date-time) | null | • | — |
createdAt | string (date-time) | • | — |
lastError | string | null | • | — |
productId | string | • | — |
updatedAt | string (date-time) | • | — |
variables | null | — | — |
audienceId | string | • | — |
templateId | string | null | • | — |
recipientCount | number | • | — |
POST/mail/broadcasts/:id/cancel
Cancel a draft or queued broadcast
MCP tool: mail_broadcast_cancel
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
from | string | • | — |
html | string | null | • | — |
name | string | • | — |
text | string | null | • | — |
sentAt | string (date-time) | null | • | — |
status | string | • | — |
headers | object | • | — |
replyTo | string[] | • | — |
subject | string | null | • | — |
queuedAt | string (date-time) | null | • | — |
createdAt | string (date-time) | • | — |
lastError | string | null | • | — |
productId | string | • | — |
updatedAt | string (date-time) | • | — |
variables | null | — | — |
audienceId | string | • | — |
templateId | string | null | • | — |
recipientCount | number | • | — |
POST/mail/broadcasts/:id/queue
Queue a draft broadcast — fans out one email per eligible contact
MCP tool: mail_broadcast_queue
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
from | string | • | — |
html | string | null | • | — |
name | string | • | — |
text | string | null | • | — |
sentAt | string (date-time) | null | • | — |
status | string | • | — |
headers | object | • | — |
replyTo | string[] | • | — |
subject | string | null | • | — |
queuedAt | string (date-time) | null | • | — |
createdAt | string (date-time) | • | — |
lastError | string | null | • | — |
productId | string | • | — |
updatedAt | string (date-time) | • | — |
variables | null | — | — |
audienceId | string | • | — |
templateId | string | null | • | — |
recipientCount | number | • | — |
GET/mail/broadcasts/:id/stats
Per-broadcast analytics: recipients/suppressed/failed + delivered/opened/clicked/bounced
MCP tool: mail_broadcast_stats
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
failed | number | • | — |
opened | number | • | — |
bounced | number | • | — |
clicked | number | • | — |
delivered | number | • | — |
recipients | number | • | — |
suppressed | number | • | — |
GET/mail/domains
List sending domains for the current product
MCP tool: mail_domain_list
Parameters
No parameters.
Response
Returns object[].
| Item field | Type | Always | Description |
|---|
id | string | • | — |
tls | string | • | — |
apex | string | null | • | — |
mode | string | null | • | — |
name | string | • | — |
active | boolean | • | — |
region | string | • | — |
status | string | • | — |
records | object[] | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
verifiedAt | string | null | • | — |
instructions | string[] | • | — |
openTracking | boolean | • | — |
bindingStatus | string | • | — |
clickTracking | boolean | • | — |
customReturnPath | string | • | — |
trackingSubdomain | string | null | • | — |
governanceDomainId | string | null | • | — |
governanceBindingId | string | null | • | — |
verificationStartedAt | string | • | — |
lastVerificationCheckAt | string | null | • | — |
POST/mail/domains
Register a sending domain (SES Easy DKIM) and return the DNS records to publish
MCP tool: mail_domain_create
Parameters
| Name | In | Type | Required | Description |
|---|
name | body | string | • | The sending domain to register, e.g. "example.com" |
region | body | string | — | AWS region for the SES identity (data residency); immutable after create |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
tls | string | • | — |
apex | string | null | • | — |
mode | string | null | • | — |
name | string | • | — |
active | boolean | • | — |
region | string | • | — |
status | string | • | — |
records | object[] | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
verifiedAt | string | null | • | — |
instructions | string[] | • | — |
openTracking | boolean | • | — |
bindingStatus | string | • | — |
clickTracking | boolean | • | — |
customReturnPath | string | • | — |
trackingSubdomain | string | null | • | — |
governanceDomainId | string | null | • | — |
governanceBindingId | string | null | • | — |
verificationStartedAt | string | • | — |
lastVerificationCheckAt | string | null | • | — |
DELETE/mail/domains/:id
Delete a sending domain and its SES identity
MCP tool: mail_domain_delete
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Domain id to delete |
Response
Returns object.
| Field | Type | Always | Description |
|---|
deleted | boolean | • | — |
GET/mail/domains/:id
Get a sending domain with its DNS records and per-record verification status
MCP tool: mail_domain_get
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Domain id |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
tls | string | • | — |
apex | string | null | • | — |
mode | string | null | • | — |
name | string | • | — |
active | boolean | • | — |
region | string | • | — |
status | string | • | — |
records | object[] | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
verifiedAt | string | null | • | — |
instructions | string[] | • | — |
openTracking | boolean | • | — |
bindingStatus | string | • | — |
clickTracking | boolean | • | — |
customReturnPath | string | • | — |
trackingSubdomain | string | null | • | — |
governanceDomainId | string | null | • | — |
governanceBindingId | string | null | • | — |
verificationStartedAt | string | • | — |
lastVerificationCheckAt | string | null | • | — |
PATCH/mail/domains/:id
Update tracking / TLS / return-path config for a domain
MCP tool: mail_domain_update
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Domain id |
openTracking | body | boolean | — | Enable open tracking (1×1 pixel); off by default |
clickTracking | body | boolean | — | Enable click tracking (link rewrite); off by default |
trackingSubdomain | body | string | null | — | Host used for the click-redirect and open-pixel |
tls | body | stringone of: opportunistic, enforced | — | TLS policy: opportunistic (default) or enforced |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
tls | string | • | — |
apex | string | null | • | — |
mode | string | null | • | — |
name | string | • | — |
active | boolean | • | — |
region | string | • | — |
status | string | • | — |
records | object[] | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
verifiedAt | string | null | • | — |
instructions | string[] | • | — |
openTracking | boolean | • | — |
bindingStatus | string | • | — |
clickTracking | boolean | • | — |
customReturnPath | string | • | — |
trackingSubdomain | string | null | • | — |
governanceDomainId | string | null | • | — |
governanceBindingId | string | null | • | — |
verificationStartedAt | string | • | — |
lastVerificationCheckAt | string | null | • | — |
POST/mail/domains/:id/verify
Re-check a domain's DNS + SES verification immediately
MCP tool: mail_domain_verify
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Domain id to re-check now |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
tls | string | • | — |
apex | string | null | • | — |
mode | string | null | • | — |
name | string | • | — |
active | boolean | • | — |
region | string | • | — |
status | string | • | — |
records | object[] | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
verifiedAt | string | null | • | — |
instructions | string[] | • | — |
openTracking | boolean | • | — |
bindingStatus | string | • | — |
clickTracking | boolean | • | — |
customReturnPath | string | • | — |
trackingSubdomain | string | null | • | — |
governanceDomainId | string | null | • | — |
governanceBindingId | string | null | • | — |
verificationStartedAt | string | • | — |
lastVerificationCheckAt | string | null | • | — |
GET/mail/domains/allowed
List apex domains this product may register sending domains under (from governance)
MCP tool: mail_domain_allowed_list
Parameters
No parameters.
Response
Returns object[].
| Item field | Type | Always | Description |
|---|
mode | string | • | — |
domain | string | • | — |
domainId | string | • | — |
extensionCount | number | • | — |
POST/mail/emails
Send a single email
MCP tool: mail_email_send
Parameters
| Name | In | Type | Required | Description |
|---|
from | body | string | • | Sender, e.g. "Name <you@your-domain.com>" |
to | body | string | string[] | — | Primary recipient(s) |
cc | body | string | string[] | — | Cc recipient(s) |
bcc | body | string | string[] | — | Bcc recipient(s) — not shown in headers |
subject | body | string | — | Email subject (required for inline sends) |
reply_to | body | string | string[] | — | Reply-To address(es) |
html | body | string | — | HTML body |
text | body | string | — | Plain-text body; auto-derived from html if omitted |
headers | body | object | — | Custom headers map |
tags | body | object[] | — | Metadata tags |
template | body | object | — | Send by reference to a published template |
scheduled_at | body | string | — | ISO-8601 instant to send at; future, within 30 days. Omit to send now. |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
GET/mail/emails/:id
Retrieve an email by id, with its last event
MCP tool: mail_email_get
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Email id |
Response
Returns null.
PATCH/mail/emails/:id
Reschedule a scheduled email to a new ISO-8601 instant
MCP tool: mail_email_update
Parameters
| Name | In | Type | Required | Description |
|---|
scheduled_at | body | string | • | New ISO-8601 instant; future, within 30 days |
id | path | string (uuid) | • | Email id |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
POST/mail/emails/:id/cancel
Cancel a scheduled email
MCP tool: mail_email_cancel
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Email id |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
status | stringone of: canceled | • | — |
POST/mail/emails/batch
Send up to 100 emails in one atomic batch
MCP tool: mail_email_send_batch
Parameters
| Name | In | Type | Required | Description |
|---|
emails | body | object[] | • | Up to 100 emails to send, each shaped like a single send |
Response
Returns object[].
| Item field | Type | Always | Description |
|---|
id | string | • | — |
GET/mail/reputation
Current sender-reputation status for the product: hard-bounce and complaint rates over the rolling window, the sample volume, whether sends are throttled, the tripped metric, and the configured thresholds
MCP tool: mail_reputation_get
Parameters
No parameters.
Response
Returns object.
| Field | Type | Always | Description |
|---|
gated | boolean | • | — |
volume | number | • | — |
complaints | number | • | — |
thresholds | object | • | — |
window_days | number | • | — |
hard_bounces | number | • | — |
complaint_rate | number | • | — |
tripped_metric | string | null | • | — |
hard_bounce_rate | number | • | — |
GET/mail/stats
Dashboard aggregation for the product over 7d|30d|90d: sent/delivered/bounced/complained totals, period-over-period deltas, daily volume buckets, and deliverability percentages
MCP tool: mail_stats_get
Parameters
| Name | In | Type | Required | Description |
|---|
period | query | stringone of: 7d, 30d, 90d | — | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
range | object | • | — |
deltas | object | • | — |
period | string | • | — |
totals | object | • | — |
volume | object[] | • | — |
deliverability | object | • | — |
GET/mail/suppressions
List suppressed recipient addresses for the current product (paginated, filter by reason or address substring)
MCP tool: mail_suppression_list
Parameters
| Name | In | Type | Required | Description |
|---|
reason | query | stringone of: hard_bounce, complaint, manual, unsubscribe | — | Filter by reason |
q | query | string | — | Case-insensitive substring match on address |
cursor | query | string | — | Opaque pagination cursor from a prior page |
limit | query | integer | — | Max items per page (1–100, default 50) |
Response
Returns object.
| Field | Type | Always | Description |
|---|
items | object[] | • | — |
next_cursor | string | null | • | — |
POST/mail/suppressions
Manually suppress a recipient address (reason is always "manual"); idempotent
MCP tool: mail_suppression_add
Parameters
| Name | In | Type | Required | Description |
|---|
address | body | string | • | Email address to suppress |
note | body | string | — | Optional free-text note |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
note | string | null | • | — |
reason | string | • | — |
address | string | • | — |
created_at | string | • | — |
source_event_id | string | null | • | — |
DELETE/mail/suppressions/:address
Remove an address from the suppression list; idempotent (returns whether a row existed)
MCP tool: mail_suppression_remove
Parameters
| Name | In | Type | Required | Description |
|---|
address | path | string | • | Email address to remove from the suppression list |
Response
Returns object.
| Field | Type | Always | Description |
|---|
address | string | • | — |
removed | boolean | • | — |
GET/mail/templates
List email templates for the current product
MCP tool: mail_template_list
Parameters
No parameters.
Response
Returns object[].
| Item field | Type | Always | Description |
|---|
id | string | • | — |
html | string | • | — |
name | string | • | — |
text | string | null | • | — |
status | string | • | — |
subject | string | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
variables | object[] | • | — |
POST/mail/templates
Create a draft email template with typed {{ variable }} placeholders
MCP tool: mail_template_create
Parameters
| Name | In | Type | Required | Description |
|---|
name | body | string | • | Human label for the template |
subject | body | string | • | Email subject; may contain {{ variable }} placeholders |
html | body | string | • | HTML body; may contain {{ variable }} placeholders |
text | body | string | — | Optional plaintext body; derived from html when omitted |
variables | body | object[] | — | Declared variables ([{name,type,optional,fallback}], <=20) |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
html | string | • | — |
name | string | • | — |
text | string | null | • | — |
status | string | • | — |
subject | string | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
variables | object[] | • | — |
DELETE/mail/templates/:id
Delete a template
MCP tool: mail_template_delete
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Template id to delete |
Response
Returns object.
| Field | Type | Always | Description |
|---|
deleted | boolean | • | — |
GET/mail/templates/:id
Get a single email template by id, with its send-usage rollup
MCP tool: mail_template_get
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Template id |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
html | string | • | — |
name | string | • | — |
text | string | null | • | — |
usage | object | • | — |
status | string | • | — |
subject | string | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
variables | object[] | • | — |
PATCH/mail/templates/:id
Update a draft template (published templates are not editable)
MCP tool: mail_template_update
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Template id |
name | body | string | — | — |
subject | body | string | — | — |
html | body | string | — | — |
text | body | string | null | — | — |
variables | body | object[] | — | — |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
html | string | • | — |
name | string | • | — |
text | string | null | • | — |
status | string | • | — |
subject | string | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
variables | object[] | • | — |
POST/mail/templates/:id/publish
Publish a template (draft -> published)
MCP tool: mail_template_publish
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Template id to publish |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
html | string | • | — |
name | string | • | — |
text | string | null | • | — |
status | string | • | — |
subject | string | • | — |
createdAt | string | • | — |
updatedAt | string | • | — |
variables | object[] | • | — |
GET/mail/usage
Current free-tier usage for the product: emails sent this day and month with used/limit/remaining, the hard cap, a blocked flag, and the point-in-time contacts count
MCP tool: mail_usage_get
Parameters
No parameters.
Response
Returns object.
| Field | Type | Always | Description |
|---|
emails | object | • | — |
period | object | • | — |
contacts | object | • | — |
GET/mail/webhooks
List webhook endpoints for the current product (secret omitted).
MCP tool: mail_webhook_list
Parameters
No parameters.
Response
Returns object[].
| Item field | Type | Always | Description |
|---|
id | string | • | — |
url | string | • | — |
enabled | boolean | • | — |
created_at | string | • | — |
updated_at | string | • | — |
description | string | null | • | — |
enabled_events | string[] | • | — |
POST/mail/webhooks
Register a webhook endpoint for the current product. Returns the signing secret ONCE.
MCP tool: mail_webhook_create
Parameters
| Name | In | Type | Required | Description |
|---|
url | body | string (uri) | • | HTTPS URL that signed events are POSTed to |
enabled_events | body | string[]one of: email.delivered, email.bounced, email.complained, email.suppressed, email.opened, email.clicked | • | Event types to deliver. One or more of: email.delivered, email.bounced, email.complained, email.suppressed, email.opened, email.clicked |
description | body | string | — | Optional human label |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
url | string | • | — |
secret | string | • | — |
enabled | boolean | • | — |
created_at | string | • | — |
updated_at | string | • | — |
description | string | null | • | — |
enabled_events | string[] | • | — |
DELETE/mail/webhooks/:id
Delete a webhook endpoint.
MCP tool: mail_webhook_delete
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Webhook endpoint id |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
deleted | boolean | • | — |
GET/mail/webhooks/:id
Get a webhook endpoint by id (secret omitted).
MCP tool: mail_webhook_get
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Webhook endpoint id |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
url | string | • | — |
enabled | boolean | • | — |
created_at | string | • | — |
updated_at | string | • | — |
description | string | null | • | — |
enabled_events | string[] | • | — |
PATCH/mail/webhooks/:id
Update a webhook endpoint (url, enabled_events, description, or enable/disable).
MCP tool: mail_webhook_update
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Webhook endpoint id |
url | body | string (uri) | — | HTTPS URL that signed events are POSTed to |
enabled_events | body | string[]one of: email.delivered, email.bounced, email.complained, email.suppressed, email.opened, email.clicked | — | Event types to deliver. One or more of: email.delivered, email.bounced, email.complained, email.suppressed, email.opened, email.clicked |
description | body | string | null | — | Optional human label |
enabled | body | boolean | — | Enable (true) or disable (false) delivery |
Response
Returns object.
| Field | Type | Always | Description |
|---|
id | string | • | — |
url | string | • | — |
enabled | boolean | • | — |
created_at | string | • | — |
updated_at | string | • | — |
description | string | null | • | — |
enabled_events | string[] | • | — |
GET/mail/webhooks/:id/deliveries
List recent delivery attempts for a webhook endpoint (status, attempts, last error).
MCP tool: mail_webhook_deliveries_list
Parameters
| Name | In | Type | Required | Description |
|---|
id | path | string (uuid) | • | Webhook endpoint id |
limit | query | integer | — | Max items (1-100, default 50) |
Response
Returns object[].
| Item field | Type | Always | Description |
|---|
id | string | • | — |
status | string | • | — |
attempts | number | • | — |
event_id | string | • | — |
created_at | string | • | — |
event_type | string | • | — |
last_error | string | null | • | — |
updated_at | string | • | — |
endpoint_id | string | • | — |
last_attempt_at | string | null | • | — |
response_status | number | null | • | — |
Was this page helpful?Thanks for your feedback!