# Nightmail API

Send, receive and reply to email on your own domains. 202 means queued, not delivered.

- [Interactive documentation](/docs)
- [OpenAPI 3.1 JSON](/openapi.json)
- [Agent index](/llms.txt)
- TypeScript package: `@nightmail/sdk`

## Quickstart

1. **Add and verify your domain.** In the dashboard, open Domains and add it, or call POST /v1/domains with {"name":"acme.com"}. Publish the DNS records it returns at your DNS provider. Sending works once GET /v1/domains/{id} reports sending: "verified", usually within minutes of the records resolving. A domain whose records are still unproven after 72 hours is released.
2. **Create an API key.** In the dashboard, open API keys in the sidebar and choose Create key. A Send only key restricted to your domain is enough to send; it can’t read logs, so add Read permission if your code should look up outcomes. Store it as NIGHTMAIL_API_KEY on your server and never ship it to a browser.
3. **Send.** 202 means queued, not delivered. Follow the outcome in the dashboard’s Logs, or with GET /v1/emails/{id} and a key that has Read permission (a Send only key gets 403). Leave out region: the sender domain decides it. To test without reaching a real inbox, send to success@simulator.amazonses.com (or bounce@, complaint@, ooto@ and suppressionlist@ the same domain). Simulator sends use your daily sending limit like any other send, but never count towards your sender score.

   ```sh
   curl --request POST \
     --url 'https://nightmail.dev/v1/emails/send' \
     --header "Authorization: Bearer $NIGHTMAIL_API_KEY" \
     --header 'Content-Type: application/json' \
     --header "Idempotency-Key: $(uuidgen)" \
     --data '{"from":"hello@acme.com","to":"you@acme.com","subject":"Hello from Nightmail","text":"It works."}'
   ```
4. **Receive (optional).** Publish the receiving MX record from the domain page. Hosted Nightmail receives on a free subdomain such as reply.<your domain>, so the domain’s existing mailboxes keep working; it uses the domain itself only when its MX already points to Nightmail, or when you choose it. Create an address with POST /v1/inbound/addresses and subscribe to message.received with POST /v1/inbound/webhooks.
5. **Reply.** POST /v1/inbound/threads/{threadId}/reply answers the newest message from its receiving address and sets In-Reply-To and References.

## Verify webhook signatures

Every webhook delivery (email events and inbound webhooks alike) carries Webhook-Id, Webhook-Timestamp (Unix seconds) and Webhook-Signature headers in the Standard Webhooks format. Compute HMAC-SHA256 over "{Webhook-Id}.{Webhook-Timestamp}.{raw body}" with the base64-decoded part of the signing secret after whsec_, and compare it in constant time to the value after v1, in Webhook-Signature. Reject timestamps more than five minutes old, and use Webhook-Id to skip a delivery you already handled. Standard Webhooks libraries (such as the standardwebhooks npm package) verify it too. The secret is shown once when you create a webhook; reveal or rotate it on the webhook’s page, or with revealWebhookSecret (from an API key you made) and rotateWebhookSecret. MCP approvals can rotate it but not read it back; temporary agent tokens can do neither. Every reveal and rotation is recorded.

```js
import { createHmac, timingSafeEqual } from 'node:crypto'

// secret: the webhook's signing secret (whsec_…). body: the raw request body, before JSON.parse.
export function verifyBaneWebhook(secret, headers, body) {
  const id = headers['webhook-id'], timestamp = headers['webhook-timestamp']
  if (!id || !timestamp || Math.abs(Date.now() / 1000 - Number(timestamp)) > 300) return false
  const key = Buffer.from(secret.slice('whsec_'.length), 'base64')
  const expected = createHmac('sha256', key).update(`${id}.${timestamp}.${body}`).digest()
  return String(headers['webhook-signature'] ?? '').split(' ').some(part => {
    const [version, signature = ''] = part.split(',')
    const given = Buffer.from(signature, 'base64')
    return version === 'v1' && given.length === expected.length && timingSafeEqual(given, expected)
  })
}
```

## API reference by tag

Each tag below links to its complete reference (every operation with parameters, request body, SDK and cURL examples, and responses). Each operation also has its own page.

## Emails

Full reference: [Emails](/docs/tags/emails.md)

- [Check email](/docs/operations/checkEmail.md) — `POST /v1/emails/check`
- [Send email](/docs/operations/sendEmail.md) — `POST /v1/emails/send`
- [Send email batch](/docs/operations/sendEmailBatch.md) — `POST /v1/emails/batch`
- [Preview email](/docs/operations/previewEmail.md) — `POST /v1/emails/preview`
- [List emails](/docs/operations/listEmails.md) — `GET /v1/emails`
- [Get email](/docs/operations/getEmail.md) — `GET /v1/emails/{id}`
- [Get email detail](/docs/operations/getEmailDetail.md) — `GET /v1/emails/{id}/detail`
- [Get email content](/docs/operations/getEmailContent.md) — `GET /v1/emails/{id}/content`
- [List email events](/docs/operations/listEmailEvents.md) — `GET /v1/emails/{id}/events`
- [List logs](/docs/operations/listLogs.md) — `GET /v1/logs`

## Domains

Full reference: [Domains](/docs/tags/domains.md)

- [List domains](/docs/operations/listDomains.md) — `GET /v1/domains`
- [Create domain](/docs/operations/createDomain.md) — `POST /v1/domains`
- [Configure domain mail from](/docs/operations/configureDomainMailFrom.md) — `POST /v1/domains/{id}/mail-from`
- [Choose receiving host](/docs/operations/chooseReceivingHost.md) — `POST /v1/domains/{id}/receiving-host`
- [Send domain test email](/docs/operations/sendDomainTestEmail.md) — `POST /v1/domains/{id}/test-send`
- [Get domain dns setup](/docs/operations/getDomainDnsSetup.md) — `GET /v1/domains/{id}/dns-setup`
- [Complete domain dns setup](/docs/operations/completeDomainDnsSetup.md) — `GET /v1/domains/{id}/dns-setup/return/{token}`
- [Get domain](/docs/operations/getDomain.md) — `GET /v1/domains/{id}`
- [Delete domain](/docs/operations/deleteDomain.md) — `DELETE /v1/domains/{id}`
- [Verify domain](/docs/operations/verifyDomain.md) — `POST /v1/domains/{id}/verify`

## Inbound addresses

Full reference: [Inbound addresses](/docs/tags/inbound-addresses.md)

- [Release retired address](/docs/operations/releaseRetiredAddress.md) — `DELETE /v1/inbound/retired/{address}`
- [List inbound addresses](/docs/operations/listInboundAddresses.md) — `GET /v1/inbound/addresses`
- [Create inbound address](/docs/operations/createInboundAddress.md) — `POST /v1/inbound/addresses`
- [Get inbound address](/docs/operations/getInboundAddress.md) — `GET /v1/inbound/addresses/{addressId}`
- [Update inbound address](/docs/operations/updateInboundAddress.md) — `PATCH /v1/inbound/addresses/{addressId}`
- [Delete inbound address](/docs/operations/deleteInboundAddress.md) — `DELETE /v1/inbound/addresses/{addressId}`
- [Get inbound overview](/docs/operations/getInboundOverview.md) — `GET /v1/inbound/overview`

## Inbound threads

Full reference: [Inbound threads](/docs/tags/inbound-threads.md)

- [List inbound threads](/docs/operations/listInboundThreads.md) — `GET /v1/inbound/threads`
- [Create inbound thread](/docs/operations/createInboundThread.md) — `POST /v1/inbound/threads`
- [Get inbound thread](/docs/operations/getInboundThread.md) — `GET /v1/inbound/threads/{threadId}`
- [Update inbound thread](/docs/operations/updateInboundThread.md) — `PATCH /v1/inbound/threads/{threadId}`
- [List inbound messages](/docs/operations/listInboundMessages.md) — `GET /v1/inbound/messages`
- [Get inbound message](/docs/operations/getInboundMessage.md) — `GET /v1/inbound/messages/{messageId}`
- [Get inbound attachment](/docs/operations/getInboundAttachment.md) — `GET /v1/inbound/messages/{messageId}/attachments/{attachmentId}`
- [Reply to inbound thread](/docs/operations/replyToInboundThread.md) — `POST /v1/inbound/threads/{threadId}/reply`

## Inbound webhooks

Full reference: [Inbound webhooks](/docs/tags/inbound-webhooks.md)

- [List inbound webhooks](/docs/operations/listInboundWebhooks.md) — `GET /v1/inbound/webhooks`
- [Create inbound webhook](/docs/operations/createInboundWebhook.md) — `POST /v1/inbound/webhooks`
- [Get inbound webhook](/docs/operations/getInboundWebhook.md) — `GET /v1/inbound/webhooks/{id}`
- [Update inbound webhook](/docs/operations/updateInboundWebhook.md) — `PATCH /v1/inbound/webhooks/{id}`
- [Delete inbound webhook](/docs/operations/deleteInboundWebhook.md) — `DELETE /v1/inbound/webhooks/{id}`
- [Test inbound webhook](/docs/operations/testInboundWebhook.md) — `POST /v1/inbound/webhooks/{id}/test`
- [Redeliver inbound message](/docs/operations/redeliverInboundMessage.md) — `POST /v1/inbound/messages/{messageId}/redeliver`
- [Rotate inbound webhook secret](/docs/operations/rotateInboundWebhookSecret.md) — `POST /v1/inbound/webhooks/{id}/rotate-secret`
- [Retry inbound webhook delivery](/docs/operations/retryInboundWebhookDelivery.md) — `POST /v1/inbound/webhooks/{id}/deliveries/{deliveryId}/retry`
- [List inbound webhook deliveries](/docs/operations/listInboundWebhookDeliveries.md) — `GET /v1/inbound/webhooks/{id}/deliveries`

## Inbound events

Full reference: [Inbound events](/docs/tags/inbound-events.md)

- [List inbound events](/docs/operations/listInboundEvents.md) — `GET /v1/inbound/events`

## Inbound domains

Full reference: [Inbound domains](/docs/tags/inbound-domains.md)

- [Get inbound scan policy](/docs/operations/getInboundScanPolicy.md) — `GET /v1/inbound/policy`
- [Update inbound scan policy](/docs/operations/updateInboundScanPolicy.md) — `PATCH /v1/inbound/policy`
- [List inbound domains](/docs/operations/listInboundDomains.md) — `GET /v1/inbound/domains`
- [Get inbound domain](/docs/operations/getInboundDomain.md) — `GET /v1/inbound/domains/{id}`
- [Update inbound domain](/docs/operations/updateInboundDomain.md) — `PATCH /v1/inbound/domains/{id}`
- [Check inbound domain](/docs/operations/checkInboundDomain.md) — `POST /v1/inbound/domains/{id}/check`
- [Enable inbound domain](/docs/operations/enableInboundDomain.md) — `POST /v1/inbound/domains/{id}/enable`
- [Disable inbound domain](/docs/operations/disableInboundDomain.md) — `POST /v1/inbound/domains/{id}/disable`
- [List receiving hosts](/docs/operations/listReceivingHosts.md) — `GET /v1/inbound/domains/{id}/hosts`
- [Add receiving host](/docs/operations/addReceivingHost.md) — `POST /v1/inbound/domains/{id}/hosts`
- [Update receiving host](/docs/operations/updateReceivingHost.md) — `PATCH /v1/inbound/domains/{id}/hosts/{hostId}`
- [Remove receiving host](/docs/operations/removeReceivingHost.md) — `DELETE /v1/inbound/domains/{id}/hosts/{hostId}`
- [List inbound subdomains](/docs/operations/listInboundSubdomains.md) — `GET /v1/inbound/domains/{id}/subdomains`
- [Create inbound subdomain](/docs/operations/createInboundSubdomain.md) — `POST /v1/inbound/domains/{id}/subdomains`
- [Get inbound subdomain](/docs/operations/getInboundSubdomain.md) — `GET /v1/inbound/domains/{id}/subdomains/{subdomainId}`
- [Update inbound subdomain](/docs/operations/updateInboundSubdomain.md) — `PATCH /v1/inbound/domains/{id}/subdomains/{subdomainId}`
- [Remove inbound subdomain](/docs/operations/removeInboundSubdomain.md) — `DELETE /v1/inbound/domains/{id}/subdomains/{subdomainId}`

## Webhooks

Full reference: [Webhooks](/docs/tags/webhooks.md)

- [List webhooks](/docs/operations/listWebhooks.md) — `GET /v1/webhooks`
- [Create webhook](/docs/operations/createWebhook.md) — `POST /v1/webhooks`
- [Get webhook](/docs/operations/getWebhook.md) — `GET /v1/webhooks/{id}`
- [Update webhook](/docs/operations/updateWebhook.md) — `PATCH /v1/webhooks/{id}`
- [Delete webhook](/docs/operations/deleteWebhook.md) — `DELETE /v1/webhooks/{id}`
- [Reveal webhook secret](/docs/operations/revealWebhookSecret.md) — `GET /v1/webhooks/{id}/secret`
- [Rotate webhook secret](/docs/operations/rotateWebhookSecret.md) — `POST /v1/webhooks/{id}/rotate-secret`
- [Test webhook](/docs/operations/testWebhook.md) — `POST /v1/webhooks/{id}/test`
- [List webhook deliveries](/docs/operations/listWebhookDeliveries.md) — `GET /v1/webhooks/{id}/deliveries`
- [Get webhook delivery](/docs/operations/getWebhookDelivery.md) — `GET /v1/webhooks/{id}/deliveries/{deliveryId}`
- [Retry webhook delivery](/docs/operations/retryWebhookDelivery.md) — `POST /v1/webhooks/{id}/deliveries/{deliveryId}/retry`

## Events

Full reference: [Events](/docs/tags/events.md)

- [Receive ses sns event](/docs/operations/receiveSesSnsEvent.md) — `POST /v1/events/ses`

## Metrics

Full reference: [Metrics](/docs/tags/metrics.md)

- [Get metrics](/docs/operations/getMetrics.md) — `GET /v1/metrics`
- [Get sender score](/docs/operations/getSenderScore.md) — `GET /v1/sender-score`
- [Release sender standing](/docs/operations/releaseSenderStanding.md) — `POST /v1/sender-score/release`
- [Get usage](/docs/operations/getUsage.md) — `GET /v1/usage`
- [Get public stats](/docs/operations/getPublicStats.md) — `GET /v1/public/stats`

## Attachments

Full reference: [Attachments](/docs/tags/attachments.md)

- [Upload attachment](/docs/operations/uploadAttachment.md) — `POST /v1/attachments`
- [Get attachment](/docs/operations/getAttachment.md) — `GET /v1/attachments/{id}`
- [Delete attachment](/docs/operations/deleteAttachment.md) — `DELETE /v1/attachments/{id}`
- [Get attachment content](/docs/operations/getAttachmentContent.md) — `GET /v1/attachments/{id}/content`

## Templates

Full reference: [Templates](/docs/tags/templates.md)

- [List campaign templates](/docs/operations/listCampaignTemplates.md) — `GET /v1/templates`
- [Create campaign template](/docs/operations/createCampaignTemplate.md) — `POST /v1/templates`
- [Get campaign template](/docs/operations/getCampaignTemplate.md) — `GET /v1/templates/{id}`
- [Update campaign template](/docs/operations/updateCampaignTemplate.md) — `PATCH /v1/templates/{id}`
- [Delete campaign template](/docs/operations/deleteCampaignTemplate.md) — `DELETE /v1/templates/{id}`
- [Publish campaign template](/docs/operations/publishCampaignTemplate.md) — `POST /v1/templates/{id}/publish`
- [Preview campaign template](/docs/operations/previewCampaignTemplate.md) — `GET /v1/templates/{id}/preview`
- [Render campaign template preview image](/docs/operations/renderCampaignTemplatePreviewImage.md) — `GET /v1/templates/{id}/preview-image`
- [Set campaign template archived](/docs/operations/setCampaignTemplateArchived.md) — `PATCH /v1/templates/{id}/archive`
- [Upload template asset](/docs/operations/uploadTemplateAsset.md) — `POST /v1/template-assets`
- [Import template image](/docs/operations/importTemplateImage.md) — `POST /v1/template-assets/import`
- [Get template asset](/docs/operations/getTemplateAsset.md) — `GET /v1/template-assets/{id}`
- [Delete template asset](/docs/operations/deleteTemplateAsset.md) — `DELETE /v1/template-assets/{id}`
- [Get template asset content](/docs/operations/getTemplateAssetContent.md) — `GET /v1/template-assets/{id}/content`

## Campaigns

Full reference: [Campaigns](/docs/tags/campaigns.md)

- [List campaigns](/docs/operations/listCampaigns.md) — `GET /v1/campaigns`
- [Create campaign](/docs/operations/createCampaign.md) — `POST /v1/campaigns`
- [Get campaign](/docs/operations/getCampaign.md) — `GET /v1/campaigns/{id}`
- [Update campaign](/docs/operations/updateCampaign.md) — `PATCH /v1/campaigns/{id}`
- [Delete campaign](/docs/operations/deleteCampaign.md) — `DELETE /v1/campaigns/{id}`
- [Get campaign stats](/docs/operations/getCampaignStats.md) — `GET /v1/campaigns/{id}/stats`
- [Get campaign content guide](/docs/operations/getCampaignContentGuide.md) — `GET /v1/campaign-content-guide`
- [Preview campaign](/docs/operations/previewCampaign.md) — `GET /v1/campaigns/{id}/preview`
- [Preview campaign audience](/docs/operations/previewCampaignAudience.md) — `GET /v1/campaigns/{id}/audience`
- [Render campaign preview image](/docs/operations/renderCampaignPreviewImage.md) — `GET /v1/campaigns/{id}/preview-image`
- [Get campaign state](/docs/operations/getCampaignState.md) — `GET /v1/campaigns/{id}/state`
- [Set campaign archived](/docs/operations/setCampaignArchived.md) — `PATCH /v1/campaigns/{id}/archive`
- [Test campaign](/docs/operations/testCampaign.md) — `POST /v1/campaigns/{id}/test`
- [Send campaign](/docs/operations/sendCampaign.md) — `POST /v1/campaigns/{id}/send`
- [Schedule campaign](/docs/operations/scheduleCampaign.md) — `POST /v1/campaigns/{id}/schedule`
- [Cancel campaign](/docs/operations/cancelCampaign.md) — `POST /v1/campaigns/{id}/cancel`
- [Pause campaign](/docs/operations/pauseCampaign.md) — `POST /v1/campaigns/{id}/pause`
- [Resume campaign](/docs/operations/resumeCampaign.md) — `POST /v1/campaigns/{id}/resume`
- [Set campaign pacing](/docs/operations/setCampaignPacing.md) — `POST /v1/campaigns/{id}/pacing`
- [Unschedule campaign](/docs/operations/unscheduleCampaign.md) — `POST /v1/campaigns/{id}/unschedule`
- [Reschedule campaign](/docs/operations/rescheduleCampaign.md) — `POST /v1/campaigns/{id}/reschedule`

## Audience

Full reference: [Audience](/docs/tags/audience.md)

- [List contacts](/docs/operations/listContacts.md) — `GET /v1/contacts`
- [Create contact](/docs/operations/createContact.md) — `POST /v1/contacts`
- [Get contact](/docs/operations/getContact.md) — `GET /v1/contacts/{id}`
- [Update contact](/docs/operations/updateContact.md) — `PATCH /v1/contacts/{id}`
- [Delete contact](/docs/operations/deleteContact.md) — `DELETE /v1/contacts/{id}`
- [List contact lists](/docs/operations/listContactLists.md) — `GET /v1/lists`
- [Create contact list](/docs/operations/createContactList.md) — `POST /v1/lists`
- [Get contact list](/docs/operations/getContactList.md) — `GET /v1/lists/{id}`
- [Update contact list](/docs/operations/updateContactList.md) — `PATCH /v1/lists/{id}`
- [Delete contact list](/docs/operations/deleteContactList.md) — `DELETE /v1/lists/{id}`
- [List list members](/docs/operations/listListMembers.md) — `GET /v1/lists/{id}/members`
- [Add list members](/docs/operations/addListMembers.md) — `POST /v1/lists/{id}/members`
- [Remove list member](/docs/operations/removeListMember.md) — `DELETE /v1/lists/{id}/members/{contactId}`
- [List segments](/docs/operations/listSegments.md) — `GET /v1/segments`
- [Create segment](/docs/operations/createSegment.md) — `POST /v1/segments`
- [Get segment](/docs/operations/getSegment.md) — `GET /v1/segments/{id}`
- [Update segment](/docs/operations/updateSegment.md) — `PATCH /v1/segments/{id}`
- [Delete segment](/docs/operations/deleteSegment.md) — `DELETE /v1/segments/{id}`
- [Preview segment](/docs/operations/previewSegment.md) — `POST /v1/segments/{id}/preview`
- [List contact imports](/docs/operations/listContactImports.md) — `GET /v1/contact-imports`
- [Preview contact import](/docs/operations/previewContactImport.md) — `POST /v1/contact-imports`
- [Get contact import](/docs/operations/getContactImport.md) — `GET /v1/contact-imports/{id}`
- [Commit contact import](/docs/operations/commitContactImport.md) — `POST /v1/contact-imports/{id}/commit`
- [Query audience](/docs/operations/queryAudience.md) — `POST /v1/audience-query/query`
- [Plan audience mutation](/docs/operations/planAudienceMutation.md) — `POST /v1/audience-query/plan`
- [Apply audience plan](/docs/operations/applyAudiencePlan.md) — `POST /v1/audience-query/apply`

## Consent

Full reference: [Consent](/docs/tags/consent.md)

- [List contact consent events](/docs/operations/listContactConsentEvents.md) — `GET /v1/contacts/{id}/consent`
- [Update contact consent](/docs/operations/updateContactConsent.md) — `POST /v1/contacts/{id}/consent`
- [Unsubscribe by link](/docs/operations/unsubscribeByLink.md) — `GET /unsubscribe/{token}`
- [Unsubscribe one click](/docs/operations/unsubscribeOneClick.md) — `POST /unsubscribe/{token}`

## ApiKeys

Full reference: [ApiKeys](/docs/tags/api-keys.md)

- [List api keys](/docs/operations/listApiKeys.md) — `GET /v1/api-keys`
- [Create api key](/docs/operations/createApiKey.md) — `POST /v1/api-keys`
- [Revoke api key](/docs/operations/revokeApiKey.md) — `POST /v1/api-keys/{id}/revoke`
- [Update api key](/docs/operations/updateApiKey.md) — `PATCH /v1/api-keys/{id}`

## Inbound keys

Full reference: [Inbound keys](/docs/tags/inbound-keys.md)

- [List inbound keys](/docs/operations/listInboundKeys.md) — `GET /v1/inbound/keys`
- [Create inbound key](/docs/operations/createInboundKey.md) — `POST /v1/inbound/keys`
- [Revoke inbound key](/docs/operations/revokeInboundKey.md) — `POST /v1/inbound/keys/{id}/revoke`

## Settings

Full reference: [Settings](/docs/tags/settings.md)

- [Get workspace settings](/docs/operations/getWorkspaceSettings.md) — `GET /v1/settings/workspace`
- [Update workspace settings](/docs/operations/updateWorkspaceSettings.md) — `PATCH /v1/settings/workspace`
- [Get ses settings](/docs/operations/getSesSettings.md) — `GET /v1/settings/ses`
- [Get overview setup](/docs/operations/getOverviewSetup.md) — `GET /v1/overview/setup`

## Regions

Full reference: [Regions](/docs/tags/regions.md)

- [List regions](/docs/operations/listRegions.md) — `GET /v1/regions`
- [Configure region](/docs/operations/configureRegion.md) — `PUT /v1/regions/{region}`
- [Discover region](/docs/operations/discoverRegion.md) — `GET /v1/regions/{region}/discovery`
- [Provision region](/docs/operations/provisionRegion.md) — `POST /v1/regions/{region}/provision`
- [Configure region auto validation](/docs/operations/configureRegionAutoValidation.md) — `PUT /v1/regions/{region}/auto-validation`

## Workspaces

Full reference: [Workspaces](/docs/tags/workspaces.md)

- [List workspaces](/docs/operations/listWorkspaces.md) — `GET /v1/workspaces`
- [Create workspace](/docs/operations/createWorkspace.md) — `POST /v1/workspaces`
- [Rename current workspace](/docs/operations/renameCurrentWorkspace.md) — `PATCH /v1/workspaces/current`
- [List workspace members](/docs/operations/listWorkspaceMembers.md) — `GET /v1/workspaces/current/members`
- [Invite workspace member](/docs/operations/inviteWorkspaceMember.md) — `POST /v1/workspaces/current/members`
- [List workspace invitations](/docs/operations/listWorkspaceInvitations.md) — `GET /v1/workspaces/current/invitations`
- [Create workspace invitation](/docs/operations/createWorkspaceInvitation.md) — `POST /v1/workspaces/current/invitations`
- [Revoke workspace invitation](/docs/operations/revokeWorkspaceInvitation.md) — `DELETE /v1/workspaces/current/invitations`
- [Update workspace member](/docs/operations/updateWorkspaceMember.md) — `PATCH /v1/workspaces/current/members/{id}`
- [Remove workspace member](/docs/operations/removeWorkspaceMember.md) — `DELETE /v1/workspaces/current/members/{id}`
- [Get workspace invitation](/docs/operations/getWorkspaceInvitation.md) — `GET /v1/workspaces/invitations/{id}`
- [Accept workspace invitation](/docs/operations/acceptWorkspaceInvitation.md) — `POST /v1/workspaces/invitations/{id}/accept`
- [Get connection](/docs/operations/getConnection.md) — `GET /v1/connection`
- [Create connection](/docs/operations/createConnection.md) — `POST /v1/connection`
- [Delete connection](/docs/operations/deleteConnection.md) — `DELETE /v1/connection`
- [List connection regions](/docs/operations/listConnectionRegions.md) — `GET /v1/connection/regions`
- [Refresh connection scan](/docs/operations/refreshConnectionScan.md) — `POST /v1/connection/scan`
- [Import connection domains](/docs/operations/importConnectionDomains.md) — `POST /v1/connection/imports`
- [Get connection region status](/docs/operations/getConnectionRegionStatus.md) — `GET /v1/connection/regions/status`
- [Verify connection](/docs/operations/verifyConnection.md) — `POST /v1/connection/verify`
- [List activity](/docs/operations/listActivity.md) — `GET /v1/activity`
- [Contact support](/docs/operations/contactSupport.md) — `POST /v1/contact-support`

## Auth

Full reference: [Auth](/docs/tags/auth.md)

- [List MCP connections](/docs/operations/listMcpConnections.md) — `GET /v1/mcp-connections`
- [Bind MCP connection](/docs/operations/bindMcpConnection.md) — `POST /v1/mcp-connections/{id}/workspace`
- [Revoke MCP connection](/docs/operations/revokeMcpConnection.md) — `POST /v1/mcp-connections/{id}/revoke`
- [List agents](/docs/operations/listAgents.md) — `GET /v1/agents`
- [Revoke agent](/docs/operations/revokeAgent.md) — `POST /v1/agents/{id}/revoke`
- [Get current identity](/docs/operations/getCurrentIdentity.md) — `GET /v1/me`
- [List agent tokens](/docs/operations/listAgentTokens.md) — `GET /v1/agent-tokens`
- [Create agent token](/docs/operations/createAgentToken.md) — `POST /v1/agent-tokens`
- [Revoke agent token](/docs/operations/revokeAgentToken.md) — `POST /v1/agent-tokens/{id}/revoke`

## Routing

Full reference: [Routing](/docs/tags/routing.md)

- [Get routing](/docs/operations/getRouting.md) — `GET /v1/routing`
- [Apply routing](/docs/operations/applyRouting.md) — `PUT /v1/routing`
- [List routes](/docs/operations/listRoutes.md) — `GET /v1/routing/routes`
- [Create route](/docs/operations/createRoute.md) — `POST /v1/routing/routes`
- [Get route](/docs/operations/getRoute.md) — `GET /v1/routing/routes/{id}`
- [Update route](/docs/operations/updateRoute.md) — `PATCH /v1/routing/routes/{id}`
- [Delete route](/docs/operations/deleteRoute.md) — `DELETE /v1/routing/routes/{id}`
- [Get routing audit](/docs/operations/getRoutingAudit.md) — `GET /v1/routing/audit`
- [List routing versions](/docs/operations/listRoutingVersions.md) — `GET /v1/routing/versions`
- [Get routing version](/docs/operations/getRoutingVersion.md) — `GET /v1/routing/versions/{v}`
- [Restore routing version](/docs/operations/restoreRoutingVersion.md) — `POST /v1/routing/versions/{v}/restore`
- [Test routing](/docs/operations/testRouting.md) — `POST /v1/routing/test`

## Rules

Full reference: [Rules](/docs/tags/rules.md)

- [List rule versions](/docs/operations/listRuleVersions.md) — `GET /v1/rules/history`
- [List ritual versions](/docs/operations/listRitualVersions.md) — `GET /v1/rituals/history`
- [Restore rule version](/docs/operations/restoreRuleVersion.md) — `POST /v1/rules/restore`
- [Restore ritual version](/docs/operations/restoreRitualVersion.md) — `POST /v1/rituals/restore`
- [Set decision opt ins](/docs/operations/setDecisionOptIns.md) — `PUT /v1/rules/decisions`
- [Set omen opt ins](/docs/operations/setOmenOptIns.md) — `PUT /v1/rituals/omens`
- [Get rule version](/docs/operations/getRuleVersion.md) — `GET /v1/rules/version`
- [Get ritual version](/docs/operations/getRitualVersion.md) — `GET /v1/rituals/version`
- [Check rule](/docs/operations/checkRule.md) — `POST /v1/rules/check`
- [Check ritual](/docs/operations/checkRitual.md) — `POST /v1/rituals/check`
- [Get rule typings](/docs/operations/getRuleTypings.md) — `GET /v1/rules/typings`
- [Get ritual typings](/docs/operations/getRitualTypings.md) — `GET /v1/rituals/typings`
- [List rule templates](/docs/operations/listRuleTemplates.md) — `GET /v1/rules/templates`
- [List ritual templates](/docs/operations/listRitualTemplates.md) — `GET /v1/rituals/templates`
- [List rule recipes](/docs/operations/listRuleRecipes.md) — `GET /v1/rules/recipes`
- [Create rule from recipe](/docs/operations/createRuleFromRecipe.md) — `POST /v1/rules/recipes`
- [List ritual recipes](/docs/operations/listRitualRecipes.md) — `GET /v1/rituals/recipes`
- [Create ritual from recipe](/docs/operations/createRitualFromRecipe.md) — `POST /v1/rituals/recipes`
- [Update rule from recipe](/docs/operations/updateRuleFromRecipe.md) — `PUT /v1/rules/scripts/{key}/recipe`
- [Update ritual from recipe](/docs/operations/updateRitualFromRecipe.md) — `PUT /v1/rituals/scripts/{key}/recipe`
- [Get rule](/docs/operations/getRule.md) — `GET /v1/rules/scripts/{key}`
- [Save rule](/docs/operations/saveRule.md) — `PUT /v1/rules/scripts/{key}`
- [Update rule](/docs/operations/updateRule.md) — `PATCH /v1/rules/scripts/{key}`
- [Delete rule](/docs/operations/deleteRule.md) — `DELETE /v1/rules/scripts/{key}`
- [Get ritual](/docs/operations/getRitual.md) — `GET /v1/rituals/scripts/{key}`
- [Save ritual](/docs/operations/saveRitual.md) — `PUT /v1/rituals/scripts/{key}`
- [Update ritual](/docs/operations/updateRitual.md) — `PATCH /v1/rituals/scripts/{key}`
- [Delete ritual](/docs/operations/deleteRitual.md) — `DELETE /v1/rituals/scripts/{key}`
- [Attach rules](/docs/operations/attachRules.md) — `PUT /v1/rules/attachments`
- [Attach rituals](/docs/operations/attachRituals.md) — `PUT /v1/rituals/attachments`
- [Get rules](/docs/operations/getRules.md) — `GET /v1/rules`
- [Apply rules](/docs/operations/applyRules.md) — `PUT /v1/rules`
- [Get rituals](/docs/operations/getRituals.md) — `GET /v1/rituals`
- [Apply rituals](/docs/operations/applyRituals.md) — `PUT /v1/rituals`
- [Test rules](/docs/operations/testRules.md) — `POST /v1/rules/test`
- [Test rituals](/docs/operations/testRituals.md) — `POST /v1/rituals/test`

## Endpoints

Full reference: [Endpoints](/docs/tags/endpoints.md)

- [List endpoints](/docs/operations/listEndpoints.md) — `GET /v1/endpoints`
- [Create endpoint](/docs/operations/createEndpoint.md) — `POST /v1/endpoints`
- [Get endpoint](/docs/operations/getEndpoint.md) — `GET /v1/endpoints/{name}`
- [Update endpoint](/docs/operations/updateEndpoint.md) — `PATCH /v1/endpoints/{name}`
- [Delete endpoint](/docs/operations/deleteEndpoint.md) — `DELETE /v1/endpoints/{name}`
- [Send endpoint verification](/docs/operations/sendEndpointVerification.md) — `POST /v1/endpoints/{name}/verification`
- [Test endpoint](/docs/operations/testEndpoint.md) — `POST /v1/endpoints/{name}/test`
- [List inbound endpoints](/docs/operations/listInboundEndpoints.md) — `GET /v1/inbound/endpoints`

## Agent inboxes

Full reference: [Agent inboxes](/docs/tags/agent-inboxes.md)

- [Create inbox connection](/docs/operations/createInboxConnection.md) — `POST /v1/inbox-connections`
- [List inbox folders](/docs/operations/listInboxFolders.md) — `GET /v1/inboxes/{id}/folders`
- [Create inbox folder](/docs/operations/createInboxFolder.md) — `POST /v1/inboxes/{id}/folders`
- [Update inbox folder](/docs/operations/updateInboxFolder.md) — `PATCH /v1/inboxes/{id}/folders/{folder}`
- [Delete inbox folder](/docs/operations/deleteInboxFolder.md) — `DELETE /v1/inboxes/{id}/folders/{folder}`
- [Get inbox message](/docs/operations/getInboxMessage.md) — `GET /v1/inboxes/{id}/messages/{messageId}`
- [Update inbox message](/docs/operations/updateInboxMessage.md) — `PATCH /v1/inboxes/{id}/messages/{messageId}`
- [Delete inbox message](/docs/operations/deleteInboxMessage.md) — `DELETE /v1/inboxes/{id}/messages/{messageId}`
- [Move inbox message](/docs/operations/moveInboxMessage.md) — `POST /v1/inboxes/{id}/messages/{messageId}/move`
- [Copy inbox message](/docs/operations/copyInboxMessage.md) — `POST /v1/inboxes/{id}/messages/{messageId}/copy`
- [Expunge inbox folder](/docs/operations/expungeInboxFolder.md) — `POST /v1/inboxes/{id}/folders/{folder}/expunge`
- [Get inbox changes](/docs/operations/getInboxChanges.md) — `GET /v1/inboxes/{id}/changes`
- [List inbox app passwords](/docs/operations/listInboxAppPasswords.md) — `GET /v1/inboxes/{id}/app-passwords`
- [Create inbox app password](/docs/operations/createInboxAppPassword.md) — `POST /v1/inboxes/{id}/app-passwords`
- [List app passwords](/docs/operations/listAppPasswords.md) — `GET /v1/app-passwords`
- [Revoke inbox app password](/docs/operations/revokeInboxAppPassword.md) — `DELETE /v1/inboxes/{id}/app-passwords/{passwordId}`
- [List inboxes](/docs/operations/listInboxes.md) — `GET /v1/inboxes`
- [Create inbox](/docs/operations/createInbox.md) — `POST /v1/inboxes`
- [Get inbox](/docs/operations/getInbox.md) — `GET /v1/inboxes/{id}`
- [Update inbox](/docs/operations/updateInbox.md) — `PATCH /v1/inboxes/{id}`
- [Delete inbox](/docs/operations/deleteInbox.md) — `DELETE /v1/inboxes/{id}`
- [Simulate inbox message](/docs/operations/simulateInboxMessage.md) — `POST /v1/inboxes/{id}/simulate`
- [List inbox messages](/docs/operations/listInboxMessages.md) — `GET /v1/inboxes/{id}/messages`
- [Get inbox attachment](/docs/operations/getInboxAttachment.md) — `GET /v1/inboxes/{id}/messages/{messageId}/attachments/{attachmentId}`

## Billing

Full reference: [Billing](/docs/tags/billing.md)

- [Get billing](/docs/operations/getBilling.md) — `GET /v1/billing`
- [Get billing usage](/docs/operations/getBillingUsage.md) — `GET /v1/billing/usage`
- [List billing ledger](/docs/operations/listBillingLedger.md) — `GET /v1/billing/ledger`
- [List billing payments](/docs/operations/listBillingPayments.md) — `GET /v1/billing/payments`
- [Get billing payment](/docs/operations/getBillingPayment.md) — `GET /v1/billing/payments/{id}`
- [Create billing top up](/docs/operations/createBillingTopUp.md) — `POST /v1/billing/top-ups`
- [Create billing top up link](/docs/operations/createBillingTopUpLink.md) — `POST /v1/billing/top-up-links`
- [Update billing auto recharge](/docs/operations/updateBillingAutoRecharge.md) — `PUT /v1/billing/auto-recharge`
- [Create billing card setup](/docs/operations/createBillingCardSetup.md) — `POST /v1/billing/payment-method`
- [Delete billing payment method](/docs/operations/deleteBillingPaymentMethod.md) — `DELETE /v1/billing/payment-method`
