Waitlist open: get early access

API reference: Emails

10 endpoints of the Emails group.

Send an email

POST/v1/emails

Accepts the mail, stores it and answers at once. Delivery happens in the background; follow it with webhooks or GET /v1/emails/{id}.

Parameters

NameInTypeDescription
Idempotency-KeyheaderstringMakes a repeated request safe (24 hours).

Request body application/json

FieldTypeDescription
fromstringFrom a verified domain (live keys) Example: Sendtide <hello@sendtide.ch>
tostring (email) | array<string (email)>
ccstring (email) | array<string (email)>
bccstring (email) | array<string (email)>
reply_tostring (email) | array<string (email)>
subjectstring
htmlstring
textstring
templatestringAlias or tpl_ id; instead of subject
dataobjectValues for the template
localestringLanguage of the template: exact, then the base language, then the account's default Example: de-CH
tenantstringSub-account slug to send for
headersobject
tagsarray<string>
metadataobject
send_atstring (date-time)At most 72 hours ahead
trackbooleanTrack opens and clicks; default from the account setting (off)
attachmentsarray<Attachment>Files and inline images. In a batch, defaults.attachments is shared by all mails that do not set their own.
attachments[].filename *stringSanitized: path and control characters are removed. Executable and script files are refused. Example: rechnung.pdf
attachments[].content *string (base64)
attachments[].content_typestringTaken from the file extension if missing Example: application/pdf
attachments[].content_idstringMakes the file an inline image; the HTML refers to it as src="cid:logo" Example: logo
attachments[].dispositionenum: attachment | inlineDefault inline with a content_id, else attachment
categorystringGroups mail for unsubscribes: lowercase letters, digits, dot, dash, underscore, up to 64 characters Example: newsletter
unsubscribeUnsubscribeList-Unsubscribe with one-click (RFC 8058). Needs a mail with exactly one recipient. Without this object the account setting unsubscribe_default decides.
unsubscribe.enabledbooleanDefault: true
unsubscribe.urlstring (uri)Your own https page instead of Sendtide's link; it must accept the one-click POST itself. Nothing is suppressed by Sendtide then.
streamstringMessage stream: transactional (default) or one of your own (GET /v1/streams). broadcast and streams of kind broadcast are not available yet (403 broadcast_not_available) Example: transactional

Example

curl -X POST "https://api.sendtide.ch/v1/emails" \
  -H "Authorization: Bearer sk_test_…" \
  -H "Idempotency-Key: order-4821" \
  -H "Content-Type: application/json" \
  -d '{"from":"Sendtide <hello@sendtide.ch>","to":"anna@example.com","subject":"Willkommen","html":"<p>Hallo Anna</p>"}'

Responses

StatusDescription
200 Repeat of an idempotent request EmailAccepted
Response fields
idstringExample: msg_8kq2m4bt
statusenum: queued | suppressed | held
send_atstring (date-time)
held_reasonenum: bulk_reviewOnly when the status is held: the mail was accepted but waits for a review of the platform (see Held mail)
202 Accepted EmailAccepted
Response fields
idstringExample: msg_8kq2m4bt
statusenum: queued | suppressed | held
send_atstring (date-time)
held_reasonenum: bulk_reviewOnly when the status is held: the mail was accepted but waits for a review of the platform (see Held mail)
400 Error in the usual format, errors and limits
401 Error in the usual format, errors and limits
409 Error in the usual format, errors and limits
422 Error in the usual format, errors and limits
429 Error in the usual format, errors and limits

Search emails

GET/v1/emails

Newest first. q understands status:bounced, tag:invoice, domain:gmx.ch, to:anna@example.com, template:welcome, stream:broadcast, recipient_status:bounced (some recipient of the mail has this status), a leading - to negate, and free text (recipient and subject). status:bounced also finds mail that bounced for some of its recipients.

Parameters

NameInTypeDescription
qquerystring
sincequerystring (date-time)Default 30 days ago
untilquerystring (date-time)
limitqueryintegerPage size. The default and the maximum depend on the endpoint (emails 50 up to 500, received mail 50 up to 200, audit up to 200, the others 100 up to 500 or 1000). Default: 100
cursorquerystringThe next_cursor of the previous page. Opaque; pass it unchanged to the same endpoint with the same filters.
tenantquerystringSlug of a sub-account to act for.

Example

curl "https://api.sendtide.ch/v1/emails" \
  -H "Authorization: Bearer sk_test_…"

Responses

StatusDescription
200 Results
Response fields
dataarray<EmailListItem>
data[].idstring
data[].statusenum: queued | sending | sent | delayed | delivered | partially_delivered | opened | clicked | bounced | complained | rejected | failed | suppressed | canceled | held
data[].streamstring
data[].toarray<string>
data[].subjectstring
data[].templatestring | null
data[].tagsarray<string>
data[].send_atstring (date-time)Planned send time; equals created_at for mail sent at once
data[].created_atstring (date-time)
totalintegerfirst page only (no cursor)
estimatedbooleantrue above 10'000 results; first page only
next_cursorstring | nullCursor for the next page
nextstringOld name of next_cursor (empty at the end)

Send up to 1'000 emails

POST/v1/emails/batch

Every entry of emails is merged onto defaults. All are validated first; if one is invalid, none is sent.

Parameters

NameInTypeDescription
Idempotency-KeyheaderstringMakes a repeated request safe (24 hours).

Request body application/json

FieldTypeDescription
defaultsSendEmailRequest
defaults.fromstringFrom a verified domain (live keys) Example: Sendtide <hello@sendtide.ch>
defaults.tostring (email) | array<string (email)>
defaults.ccstring (email) | array<string (email)>
defaults.bccstring (email) | array<string (email)>
defaults.reply_tostring (email) | array<string (email)>
defaults.subjectstring
defaults.htmlstring
defaults.textstring
defaults.templatestringAlias or tpl_ id; instead of subject
defaults.dataobjectValues for the template
defaults.localestringLanguage of the template: exact, then the base language, then the account's default Example: de-CH
defaults.tenantstringSub-account slug to send for
defaults.headersobject
defaults.tagsarray<string>
defaults.metadataobject
defaults.send_atstring (date-time)At most 72 hours ahead
defaults.trackbooleanTrack opens and clicks; default from the account setting (off)
defaults.attachmentsarray<Attachment>Files and inline images. In a batch, defaults.attachments is shared by all mails that do not set their own.
defaults.attachments[].filename *stringSanitized: path and control characters are removed. Executable and script files are refused. Example: rechnung.pdf
defaults.attachments[].content *string (base64)
defaults.attachments[].content_typestringTaken from the file extension if missing Example: application/pdf
defaults.attachments[].content_idstringMakes the file an inline image; the HTML refers to it as src="cid:logo" Example: logo
defaults.attachments[].dispositionenum: attachment | inlineDefault inline with a content_id, else attachment
defaults.categorystringGroups mail for unsubscribes: lowercase letters, digits, dot, dash, underscore, up to 64 characters Example: newsletter
defaults.unsubscribeUnsubscribeList-Unsubscribe with one-click (RFC 8058). Needs a mail with exactly one recipient. Without this object the account setting unsubscribe_default decides.
defaults.unsubscribe.enabledbooleanDefault: true
defaults.unsubscribe.urlstring (uri)Your own https page instead of Sendtide's link; it must accept the one-click POST itself. Nothing is suppressed by Sendtide then.
defaults.streamstringMessage stream: transactional (default) or one of your own (GET /v1/streams). broadcast and streams of kind broadcast are not available yet (403 broadcast_not_available) Example: transactional
emails *array<SendEmailRequest>Same fields as SendEmailRequest above.

Example

curl -X POST "https://api.sendtide.ch/v1/emails/batch" \
  -H "Authorization: Bearer sk_test_…" \
  -H "Idempotency-Key: order-4821" \
  -H "Content-Type: application/json" \
  -d '{"defaults":{"from":"Shop <hallo@example.ch>","template":"invoice","locale":"de-CH"},"emails":[{"to":"anna@example.com","data":{"amount":"120.00"}},{"to":"beat@example.com","data":{"amount":"80.00"}}]}'

Responses

StatusDescription
202 Accepted
Response fields
batch_idstring
dataarray<EmailAccepted>
data[].idstringExample: msg_8kq2m4bt
data[].statusenum: queued | suppressed | held
data[].send_atstring (date-time)
data[].held_reasonenum: bulk_reviewOnly when the status is held: the mail was accepted but waits for a review of the platform (see Held mail)
422 Error in the usual format, errors and limits

Send a complete MIME message

POST/v1/emails/mime

The message is sent as it is (Bcc removed). Envelope recipients default to To, Cc and Bcc.

Parameters

NameInTypeDescription
Idempotency-KeyheaderstringMakes a repeated request safe (24 hours).

Request body application/json

FieldTypeDescription
raw *string (base64)RFC 5322 message, at most 10 MB
toarray<string (email)>
tagsarray<string>
send_atstring (date-time)

Example

curl -X POST "https://api.sendtide.ch/v1/emails/mime" \
  -H "Authorization: Bearer sk_test_…" \
  -H "Idempotency-Key: order-4821" \
  -H "Content-Type: application/json" \
  -d '{"raw":"RnJvbTogaGFsbG9AZXhhbXBsZS5jaA0K…"}'

Responses

StatusDescription
200 Repeat with the same Idempotency-Key EmailAccepted
Response fields
idstringExample: msg_8kq2m4bt
statusenum: queued | suppressed | held
send_atstring (date-time)
held_reasonenum: bulk_reviewOnly when the status is held: the mail was accepted but waits for a review of the platform (see Held mail)
202 Accepted EmailAccepted
Response fields
idstringExample: msg_8kq2m4bt
statusenum: queued | suppressed | held
send_atstring (date-time)
held_reasonenum: bulk_reviewOnly when the status is held: the mail was accepted but waits for a review of the platform (see Held mail)
409 Error in the usual format, errors and limits
422 Error in the usual format, errors and limits

Get an email with its events

GET/v1/emails/{id}

Parameters

NameInTypeDescription
id *pathstring
tenantquerystringSlug of a sub-account to act for.

Example

curl "https://api.sendtide.ch/v1/emails/msg_8kq2m4bt" \
  -H "Authorization: Bearer sk_test_…"

Responses

StatusDescription
200 The email Email
Response fields
idstring
statusenum: queued | sending | sent | delayed | delivered | partially_delivered | opened | clicked | bounced | complained | rejected | failed | suppressed | canceled | held
fromstring
toarray<string>
subjectstring
tagsarray<string>
templatestring | null
localestring | null
batch_idstring | null
send_atstring (date-time)
created_atstring (date-time)
last_errorstring | null
categorystring | null
held_reasonstring | nullbulk_review while the status is held
streamstring
recipientsarray<Recipient>Status per address. The status of the mail is their aggregate (delivered, bounced, partially_delivered ...). Empty for mail from before this existed.
recipients[].addressstring
recipients[].typeenum: to | cc | bcc
recipients[].statusenum: queued | sending | sent | delayed | delivered | partially_delivered | opened | clicked | bounced | complained | rejected | failed | suppressed | canceled | held
recipients[].last_eventstring | null
recipients[].last_event_atstring | null (date-time)
recipients[].bounce_classstring | nullSendtide's class of a bounce, see Bounce classes
recipients[].bounceobject | null
recipients[].bounce.codestring
recipients[].bounce.severityenum: hard | soft | block | unknown
recipients[].bounce.explanationstringGerman
recipients[].bounce.actionstringGerman
attachmentsarray<AttachmentInfo>Name and size; the content is not returned
attachments[].filenamestring
attachments[].content_typestring
attachments[].dispositionenum: attachment | inline
attachments[].content_idstring | null
attachments[].sizeintegerBytes
eventsarray<object>
events[].typeenum: email.queued | email.sent | email.delivered | email.delayed | email.opened | email.machine_opened | email.clicked | email.bounced | email.complained | email.rejected | email.failed | email.suppressed | email.canceled | email.held | email.unsubscribed | email.received
events[].dataobject
events[].created_atstring (date-time)
404 Error in the usual format, errors and limits

Change the send time of a queued email

PATCH/v1/emails/{id}

Only while the mail is queued (409 not_reschedulable otherwise). send_at at most 72 hours ahead; a time in the past sends at once.

Parameters

NameInTypeDescription
id *pathstring
tenantquerystringSlug of a sub-account to act for.

Request body application/json

FieldTypeDescription
send_at *string (date-time)

Example

curl -X PATCH "https://api.sendtide.ch/v1/emails/msg_8kq2m4bt" \
  -H "Authorization: Bearer sk_test_…" \
  -H "Content-Type: application/json" \
  -d '{"send_at":"2026-12-01T08:00:00Z"}'

Responses

StatusDescription
200 Rescheduled
Response fields
idstring
statusenum: queued
send_atstring (date-time)
404 Error in the usual format, errors and limits
409 Error in the usual format, errors and limits
422 Error in the usual format, errors and limits

Cancel a queued email

POST/v1/emails/{id}/cancel

Only while the mail is queued, that is scheduled or not yet taken by a worker (409 not_cancelable otherwise). The status becomes canceled and the event email.canceled is recorded. Recipients counted for today's usage are counted back.

Parameters

NameInTypeDescription
id *pathstring
tenantquerystringSlug of a sub-account to act for.

Example

curl -X POST "https://api.sendtide.ch/v1/emails/msg_8kq2m4bt/cancel" \
  -H "Authorization: Bearer sk_test_…"

Responses

StatusDescription
200 Canceled
Response fields
idstring
statusenum: canceled
404 Error in the usual format, errors and limits
409 Error in the usual format, errors and limits

Cancel the queued emails of a batch

POST/v1/batches/{id}/cancel

Parameters

NameInTypeDescription
id *pathstring
tenantquerystringSlug of a sub-account to act for.

Example

curl -X POST "https://api.sendtide.ch/v1/batches/bat_4f8k2m9q/cancel" \
  -H "Authorization: Bearer sk_test_…"

Responses

StatusDescription
200 Result
Response fields
batch_idstring
canceledinteger
not_cancelableintegerMails of the batch that already left the queue or were canceled before
404 Error in the usual format, errors and limits

Unsubscribe page (public)

GET/u/{token} No API key

Shows a confirmation page with a button. Changes nothing, so mail scanners that open links cannot unsubscribe anybody. No API key.

Parameters

NameInTypeDescription
token *pathstring

Example

curl "https://api.sendtide.ch/u/tok_…"

Responses

StatusDescription
200 HTML page
404 Unknown token

One-click unsubscribe (RFC 8058, public)

POST/u/{token} No API key

The mail client posts List-Unsubscribe=One-Click here. Adds a suppression with reason unsubscribe (for the mail's category, if it had one) and fires email.unsubscribed. Repeating it changes nothing. No API key.

Parameters

NameInTypeDescription
token *pathstring

Example

curl -X POST "https://api.sendtide.ch/u/tok_…"

Responses

StatusDescription
200 HTML page
404 Unknown token
429 Too many requests