API Reference
The full API reference is generated from the same public contract used by the API worker and SDK tooling. Use the API reference to find exact paths, methods, parameters, request schemas, response schemas, operation IDs, and the downloadable OpenAPI document.
OpenAPI Contract
Download the exact schema document that powers this reference and the public worker.
Platform
Version metadata, discovery URLs, capability discovery, and the machine-readable OpenAPI document.
/v1 Get API metadata
Returns the current public API version and discovery links for docs, llms files, the OpenAPI contract, webhook subscriptions, and the authenticated capability endpoint.
Responses
{
"$ref": "#/components/schemas/ApiMetadata"
} /v1/capabilities Get authenticated API capabilities
Returns the current workspace context, discovery URLs, shared request conventions, supported webhook events, and public resource operations available to the authenticated bearer credential.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Capabilities"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/openapi.json Get the OpenAPI document
Returns the machine-readable OpenAPI 3.1 contract for the current public API.
Responses
{
"type": "object"
} Workspace
Read the current authenticated workspace profile and execution context.
/v1/workspace Get the current workspace
Returns the authenticated workspace profile and mailing context used by broadcasts, sequences, automations, forms, and magic links.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Workspace"
}
}
} {
"$ref": "#/components/schemas/Error"
} Subscribers
Create or upsert subscribers and list subscriber records in a workspace.
/v1/subscribers List subscribers
Returns subscribers in the authenticated workspace, sorted from newest to oldest.
Parameters
search query Filter subscribers by name, email, or status.
email query Filter subscribers by an exact subscriber email address.
status query Filter subscribers by subscriber status.
cold_only query When `true`, return only cold subscribers.
tag_id query Return subscribers that currently have this tag ID. Repeat `tag_id` or use `tag_ids` to match any of several tags.
tag_ids query Comma-separated tag IDs. By default, the API returns subscribers who have any listed tag.
tag_operator query Controls how tag filters are applied. Defaults to `has_any_of`.
sequence_id query Return subscribers that match this sequence ID. Repeat `sequence_id` or use `sequence_ids` to match any of several sequences.
sequence_ids query Comma-separated sequence IDs. By default, the API returns only subscribers who are active in any listed sequence.
sequence_operator query Controls how sequence filters are applied. Defaults to `is_active_in_any_of`.
limit query Maximum number of subscribers to return. Defaults to 25 and is capped at 100.
starting_after query Use the opaque cursor from the previous page to request the next page.
Responses
{
"type": "object",
"required": [
"data",
"pagination"
],
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/components/schemas/Subscriber"
}
},
"pagination": {
"$ref": "#/components/schemas/Pagination"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/subscribers Create or upsert a subscriber
Creates a new subscriber when the email does not exist in the workspace. If the email already exists, the API updates the existing subscriber unless create_only is true.
Request Body
{
"$ref": "#/components/schemas/SubscriberUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Subscriber"
}
}
} {
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Subscriber"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/subscribers/{subscriber_id} Update a subscriber
Updates profile fields, status, custom fields, tags, or sequence assignments for one subscriber. Fields omitted from the request stay unchanged. Blank optional custom field values also leave saved values unchanged, and filled-in invalid values are rejected.
Parameters
subscriber_id path
required
The subscriber identifier.
Request Body
{
"$ref": "#/components/schemas/SubscriberUpdateRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Subscriber"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/subscribers/{subscriber_id}/sequences/{sequence_id} Add a subscriber to a sequence
Adds the selected subscriber to the selected sequence. If the subscriber is already in the sequence, the API returns the subscriber unchanged.
Parameters
subscriber_id path
required
The subscriber identifier.
sequence_id path
required
The sequence identifier.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Subscriber"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/subscribers/{subscriber_id}/sequences/{sequence_id} Remove a subscriber from a sequence
Removes the selected subscriber from the selected sequence. If the subscriber is not in the sequence, the API returns the subscriber unchanged.
Parameters
subscriber_id path
required
The subscriber identifier.
sequence_id path
required
The sequence identifier.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Subscriber"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/subscribers/{subscriber_id}/tags/{tag_id} Remove a tag from a subscriber
Removes the selected tag from a subscriber. If the subscriber does not have the tag, the API returns the subscriber unchanged.
Parameters
subscriber_id path
required
The subscriber identifier.
tag_id path
required
The tag identifier.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Subscriber"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} Custom Fields
Read and manage the typed custom-field schema available to the authenticated workspace.
/v1/custom-fields List custom fields
Returns custom fields in the authenticated workspace.
Parameters
limit query Maximum number of custom fields to return.
starting_after query Use the opaque cursor from the previous page to request the next page.
Responses
{
"type": "object",
"required": [
"data",
"pagination"
],
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/components/schemas/CustomField"
}
},
"pagination": {
"$ref": "#/components/schemas/Pagination"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/custom-fields Create a custom field
Creates a workspace-scoped custom-field definition.
Parameters
Idempotency-Key header Optional idempotency key to make retries safe.
Request Body
{
"$ref": "#/components/schemas/CustomFieldUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/CustomField"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/custom-fields/{custom_field_id} Get a custom field
Returns one custom field from the authenticated workspace.
Parameters
custom_field_id path
required
The custom field identifier.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/CustomField"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/custom-fields/{custom_field_id} Update a custom field
Updates a custom-field definition for the authenticated workspace.
Parameters
custom_field_id path
required
The identifier of the custom field to update.
Request Body
{
"$ref": "#/components/schemas/CustomFieldUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/CustomField"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/custom-fields/{custom_field_id} Delete a custom field
Deletes a custom-field definition from the authenticated workspace.
Parameters
custom_field_id path
required
The identifier of the custom field to delete.
Responses
{
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} Email Templates
Create and manage reusable email templates for the authenticated workspace.
/v1/email-templates List email templates
Returns reusable email templates linked to the authenticated workspace.
Parameters
limit query Maximum number of items to return.
starting_after query Opaque cursor returned by the previous page.
Responses
{
"type": "object",
"required": [
"data",
"pagination"
],
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/components/schemas/EmailTemplate"
}
},
"pagination": {
"$ref": "#/components/schemas/Pagination"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/email-templates Create an email template
Creates a reusable email template scoped to the authenticated workspace.
Parameters
Idempotency-Key header Optional idempotency key for safe retries.
Request Body
{
"$ref": "#/components/schemas/EmailTemplateUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/EmailTemplate"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/email-templates/{template_id} Get an email template
Returns a reusable email template linked to the authenticated workspace.
Parameters
template_id path
required
The email template identifier.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/EmailTemplate"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/email-templates/{template_id} Update an email template
Updates the content or enabled state of an existing email template.
Parameters
template_id path
required
The email template identifier.
Request Body
{
"$ref": "#/components/schemas/EmailTemplateUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/EmailTemplate"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/email-templates/{template_id} Delete an email template
Deletes an existing email template linked to the authenticated workspace.
Parameters
template_id path
required
The email template identifier.
Responses
{
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} Forms
Read and manage embeddable form definitions and presentation settings.
/v1/forms List forms
Returns forms from the authenticated workspace.
Parameters
search query Filter forms by ID, name, or public URL token.
limit query The maximum number of forms to return.
starting_after query The opaque cursor from the previous page of forms.
Responses
{
"type": "object",
"required": [
"data",
"pagination"
],
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/components/schemas/Form"
}
},
"pagination": {
"$ref": "#/components/schemas/Pagination"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/forms Create a form
Creates a form in the authenticated workspace.
Parameters
Idempotency-Key header Optional idempotency key to retry the request safely.
Request Body
{
"$ref": "#/components/schemas/FormUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Form"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/forms/{form_id} Get a form
Returns a form from the authenticated workspace.
Parameters
form_id path
required
The identifier of the form to return.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Form"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/forms/{form_id} Update a form
Updates an existing form without creating a new form.
Parameters
form_id path
required
The identifier of the form to update.
Request Body
{
"$ref": "#/components/schemas/FormUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Form"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/forms/{form_id} Delete a form
Deletes a form from the authenticated workspace.
Parameters
form_id path
required
The identifier of the form to delete.
Responses
{
"$ref": "#/components/schemas/Error"
} /v1/forms/{form_id}/submissions List form submissions
Returns recent real submissions for one form, including the subscriber who submitted the form. Requires both `forms:read` and `subscribers:read`.
Parameters
form_id path
required
The identifier of the form whose submissions you want to list.
limit query The maximum number of submissions to return. Defaults to 25 and is capped at 100.
starting_after query The opaque cursor from the previous page of form submissions.
Responses
{
"type": "object",
"required": [
"data",
"pagination"
],
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/components/schemas/FormSubmission"
}
},
"pagination": {
"$ref": "#/components/schemas/Pagination"
}
}
} {
"$ref": "#/components/schemas/Error"
} Landing Pages
Read and manage hosted landing pages, page definitions, and public URLs.
/v1/landing-pages List landing pages
Returns landing pages from the authenticated workspace.
Parameters
search query Filter landing pages by ID, name, slug, custom path, or public URL token.
limit query The maximum number of landing pages to return.
starting_after query The opaque cursor from the previous page of landing pages.
Responses
{
"type": "object",
"required": [
"data",
"pagination"
],
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/components/schemas/LandingPage"
}
},
"pagination": {
"$ref": "#/components/schemas/Pagination"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/landing-pages Create a landing page
Creates a hosted landing page in the authenticated workspace.
Parameters
Idempotency-Key header Optional idempotency key to retry the request safely.
Request Body
{
"$ref": "#/components/schemas/LandingPageUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/LandingPage"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/landing-pages/{landing_page_id} Get a landing page
Returns a landing page from the authenticated workspace.
Parameters
landing_page_id path
required
The identifier of the landing page to return.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/LandingPage"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/landing-pages/{landing_page_id} Update a landing page
Updates an existing hosted landing page without creating a new landing page.
Parameters
landing_page_id path
required
The identifier of the landing page to update.
Request Body
{
"$ref": "#/components/schemas/LandingPageUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/LandingPage"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/landing-pages/{landing_page_id} Delete a landing page
Deletes a landing page from the authenticated workspace.
Parameters
landing_page_id path
required
The identifier of the landing page to delete.
Responses
{
"$ref": "#/components/schemas/Error"
} /v1/landing-pages/{landing_page_id}/submissions List landing page submissions
Returns recent real submissions for one landing page, including the subscriber who submitted the landing page. Requires both `landing_pages:read` and `subscribers:read`.
Parameters
landing_page_id path
required
The identifier of the landing page whose submissions you want to list.
limit query The maximum number of submissions to return. Defaults to 25 and is capped at 100.
starting_after query The opaque cursor from the previous page of landing page submissions.
Responses
{
"type": "object",
"required": [
"data",
"pagination"
],
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/components/schemas/LandingPageSubmission"
}
},
"pagination": {
"$ref": "#/components/schemas/Pagination"
}
}
} {
"$ref": "#/components/schemas/Error"
} Sequences
Create and manage email sequences, sequence status, and delivery configuration.
/v1/sequences List sequences
Returns sequences in the authenticated workspace.
Parameters
search query Filter sequences by ID, name, or status.
limit query Maximum number of sequences to return.
starting_after query Use the opaque cursor from the previous page to request the next page.
Responses
{
"type": "object",
"required": [
"data",
"pagination"
],
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/components/schemas/Sequence"
}
},
"pagination": {
"$ref": "#/components/schemas/Pagination"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/sequences Create a sequence
Creates a sequence in the authenticated workspace.
Parameters
Idempotency-Key header Optional idempotency key to make retries safe.
Request Body
{
"$ref": "#/components/schemas/SequenceUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Sequence"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/sequences/{sequence_id} Get a sequence
Returns one sequence from the authenticated workspace.
Parameters
sequence_id path
required
The sequence identifier.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Sequence"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/sequences/{sequence_id} Update a sequence
Updates an existing sequence.
Parameters
sequence_id path
required
The sequence identifier.
Request Body
{
"$ref": "#/components/schemas/SequenceUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Sequence"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/sequences/{sequence_id} Delete a sequence
Deletes an existing sequence from the authenticated workspace.
Parameters
sequence_id path
required
The sequence identifier.
Responses
{
"$ref": "#/components/schemas/Error"
} Automations
Create and manage automation definitions and lifecycle state.
/v1/automations List automations
Returns automations in the authenticated workspace.
Parameters
limit query Maximum number of automations to return.
starting_after query Use the opaque cursor from the previous page to request the next page.
Responses
{
"type": "object",
"required": [
"data",
"pagination"
],
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/components/schemas/Automation"
}
},
"pagination": {
"$ref": "#/components/schemas/Pagination"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/automations Create an automation
Creates an automation in the authenticated workspace.
Parameters
Idempotency-Key header Optional idempotency key to make retries safe.
Request Body
{
"$ref": "#/components/schemas/AutomationUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Automation"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/automations/{automation_id} Get an automation
Returns one automation from the authenticated workspace.
Parameters
automation_id path
required
The automation identifier.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Automation"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/automations/{automation_id} Update an automation
Updates an existing automation.
Parameters
automation_id path
required
The automation identifier.
Request Body
{
"$ref": "#/components/schemas/AutomationUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Automation"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/automations/{automation_id} Delete an automation
Deletes an automation from the authenticated workspace.
Parameters
automation_id path
required
The automation identifier.
Responses
{
"$ref": "#/components/schemas/Error"
} Magic Links
Create and manage magic links used in broadcasts, sequences, and automations.
/v1/magic-links List magic links
Returns magic links in the authenticated workspace.
Parameters
limit query Maximum number of magic links to return.
starting_after query Use the opaque cursor from the previous page to request the next page.
Responses
{
"type": "object",
"required": [
"data",
"pagination"
],
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/components/schemas/MagicLink"
}
},
"pagination": {
"$ref": "#/components/schemas/Pagination"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/magic-links Create a magic link
Creates a magic link in the authenticated workspace.
Parameters
Idempotency-Key header Optional idempotency key to make retries safe.
Request Body
{
"$ref": "#/components/schemas/MagicLinkUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/MagicLink"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/magic-links/{magic_link_id} Get a magic link
Returns one magic link from the authenticated workspace.
Parameters
magic_link_id path
required
The magic link identifier.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/MagicLink"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/magic-links/{magic_link_id} Update a magic link
Updates an existing magic link.
Parameters
magic_link_id path
required
The magic link identifier.
Request Body
{
"$ref": "#/components/schemas/MagicLinkUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/MagicLink"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/magic-links/{magic_link_id} Delete a magic link
Deletes a magic link from the authenticated workspace.
Parameters
magic_link_id path
required
The magic link identifier.
Responses
{
"$ref": "#/components/schemas/Error"
} Broadcasts
Create, schedule, test, send, and inspect one-off broadcasts.
/v1/broadcasts List broadcasts
Returns broadcast drafts, scheduled sends, active sends, and completed sends.
Parameters
limit query Maximum number of items to return.
starting_after query Opaque cursor returned by the previous page.
Responses
{
"type": "object",
"required": [
"data",
"pagination"
],
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/components/schemas/Broadcast"
}
},
"pagination": {
"$ref": "#/components/schemas/Pagination"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/broadcasts Create a broadcast
Creates a broadcast draft or scheduled broadcast in the authenticated workspace.
Parameters
Idempotency-Key header Optional idempotency key for safe retries.
Request Body
{
"$ref": "#/components/schemas/BroadcastUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Broadcast"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/broadcasts/{broadcast_id} Get a broadcast
Returns a broadcast draft, scheduled send, active send, or completed send.
Parameters
broadcast_id path
required
The broadcast identifier.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Broadcast"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/broadcasts/{broadcast_id} Update a broadcast
Updates a broadcast draft or scheduled send in place.
Parameters
broadcast_id path
required
The broadcast identifier.
Request Body
{
"$ref": "#/components/schemas/BroadcastUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Broadcast"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/broadcasts/{broadcast_id} Delete a broadcast
Deletes a draft, scheduled, or failed broadcast from the authenticated workspace. Broadcasts cannot be deleted after they start sending.
Parameters
broadcast_id path
required
The broadcast identifier.
Responses
{
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/broadcasts/{broadcast_id}/send Send a broadcast now
Starts delivery now for a broadcast draft or a scheduled send.
Parameters
broadcast_id path
required
The broadcast identifier.
Idempotency-Key header Optional idempotency key to make retries safe.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"type": "object",
"required": [
"status",
"resource"
],
"properties": {
"status": {
"type": "string",
"enum": [
"completed"
]
},
"resource": {
"$ref": "#/components/schemas/Broadcast"
}
}
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/broadcasts/{broadcast_id}/test Send a broadcast test email
Sends a test message from an existing broadcast to one recipient.
Parameters
broadcast_id path
required
The broadcast identifier.
Idempotency-Key header Optional idempotency key to make retries safe.
Request Body
{
"$ref": "#/components/schemas/BroadcastTestRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/ActionResult"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} Segments
Read saved segments and preview dynamic segment definitions.
/v1/segments List segments
Returns saved segments from the authenticated workspace.
Parameters
limit query The maximum number of segments to return.
starting_after query The opaque cursor from the previous page of saved segments.
Responses
{
"type": "object",
"required": [
"data",
"pagination"
],
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/components/schemas/Segment"
}
},
"pagination": {
"$ref": "#/components/schemas/Pagination"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/segments Create a segment
Creates a saved segment in the authenticated workspace.
Parameters
Idempotency-Key header Optional idempotency key to retry the request safely.
Request Body
{
"$ref": "#/components/schemas/SegmentUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Segment"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/segments/{segment_id} Get a segment
Returns one saved segment from the authenticated workspace.
Parameters
segment_id path
required
The identifier of the segment to return.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Segment"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/segments/{segment_id} Update a segment
Updates a saved segment in the authenticated workspace.
Parameters
segment_id path
required
The identifier of the segment to update.
Request Body
{
"$ref": "#/components/schemas/SegmentUpsertRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/Segment"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/segments/{segment_id} Delete a segment
Deletes a saved segment from the authenticated workspace.
Parameters
segment_id path
required
The identifier of the segment to delete.
Responses
{
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/segments/preview Preview a segment definition
Returns subscriber counts for an unsaved segment definition. Include `current_segment_id` when previewing edits to an existing segment so circular segment references are rejected before saving.
Request Body
{
"$ref": "#/components/schemas/SegmentPreviewRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/SegmentPreview"
}
}
} {
"$ref": "#/components/schemas/Error"
} Jobs
Create and inspect asynchronous subscriber import and export jobs.
/v1/jobs/subscriber-exports Create a subscriber export job
Queues an asynchronous subscriber export for the authenticated workspace. Requires `jobs:write` and `subscribers:read` because the finished file contains subscriber data.
Parameters
Idempotency-Key header Optional idempotency key to retry the request safely.
Request Body
{
"$ref": "#/components/schemas/SubscriberExportJobCreateRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/SubscriberExportJob"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/jobs/subscriber-exports/{job_id} Get a subscriber export job
Returns the current state of a previously created export job. Requires `jobs:read` and `subscribers:read` because completed jobs include a subscriber CSV download URL.
Parameters
job_id path
required
The identifier of the export job to return.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/SubscriberExportJob"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/jobs/subscriber-imports Create a subscriber import job
Queues an asynchronous import job that creates or updates subscribers from CSV text.
Parameters
Idempotency-Key header Optional idempotency key to retry the request safely.
Request Body
{
"$ref": "#/components/schemas/SubscriberImportJobCreateRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/SubscriberImportJob"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/jobs/subscriber-imports/{job_id} Get a subscriber import job
Returns the current state of a previously created import job.
Parameters
job_id path
required
The identifier of the import job to return.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/SubscriberImportJob"
}
}
} {
"$ref": "#/components/schemas/Error"
} Webhooks
Create and manage outbound webhook subscriptions for Mailrith events and signed event delivery.
/v1/webhook-subscriptions List webhook subscriptions
Returns the outbound webhook subscriptions configured for the authenticated workspace.
Responses
{
"type": "object",
"required": [
"data",
"pagination"
],
"properties": {
"data": {
"type": "array",
"items": {
"$ref": "#/components/schemas/WebhookSubscription"
}
},
"pagination": {
"$ref": "#/components/schemas/Pagination"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/webhook-subscriptions Create a webhook subscription
Creates a signed outbound webhook subscription and returns the signing secret once. The caller must also have read scopes for the selected event families.
Request Body
{
"$ref": "#/components/schemas/WebhookSubscriptionCreateRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/WebhookSubscriptionCreateResult"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/webhook-subscriptions/{webhook_subscription_id} Get a webhook subscription
Returns one outbound webhook subscription configured for the authenticated workspace.
Parameters
webhook_subscription_id path
required
The webhook subscription identifier.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/WebhookSubscription"
}
}
} {
"$ref": "#/components/schemas/Error"
} /v1/webhook-subscriptions/{webhook_subscription_id} Update a webhook subscription
Updates the destination URL, status, or event pattern set for an existing webhook subscription. The caller must also have read scopes for the subscription's event families.
Parameters
webhook_subscription_id path
required
The webhook subscription identifier.
Request Body
{
"$ref": "#/components/schemas/WebhookSubscriptionUpdateRequest"
} Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"$ref": "#/components/schemas/WebhookSubscription"
}
}
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} {
"$ref": "#/components/schemas/Error"
} /v1/webhook-subscriptions/{webhook_subscription_id} Delete a webhook subscription
Deletes an existing outbound webhook subscription from the authenticated workspace.
Parameters
webhook_subscription_id path
required
The webhook subscription identifier.
Responses
{
"type": "object",
"required": [
"data"
],
"properties": {
"data": {
"type": "object",
"required": [
"id",
"deleted"
],
"properties": {
"id": {
"type": "string"
},
"deleted": {
"type": "boolean",
"enum": [
true
]
}
}
}
}
} {
"$ref": "#/components/schemas/Error"
} Need Help Shipping an Integration?
Reach the Mailrith team if you need help planning a sync, validating a webhook flow, or troubleshooting a request.