Skip to content
Sendtier Docs
API reference

Send an email

Source: OpenAPI (openapi/openapi.yaml).

curl -X POST "https://api.sendtier.example/emails" \  -H "Authorization: Bearer st_live_REPLACE_ME" \  -H "API-Version: 2026-10-01" \  -H "Content-Type: application/json" \  -d '{    "from": "Example <hello@mail.example.com>",    "to": [      "user@example.com"    ],    "subject": "Your first email",    "text": "Hello from Sendtier."  }'
{  "id": "string",  "status": "queued",  "status_detail": "string",  "created_at": "2019-08-24T14:15:22Z"}
POST
/emails

Validates and queues one email. A st_test_ key never sends a real email. It may use any domain the tenant has added that is not deleted, including pending and failed. A live key needs that domain verified. An unknown, deleted, or other-tenant domain returns 404 not_found. Optional resend_of keeps the source email's mode. A test email stays in test and is never delivered, even when the caller is live. A test key cannot resend a live email.

Authorization

headerAuthorizationBearer <token>

API key: st_live_... or st_test_...

Header Parameters

Idempotency-Key?string

Repeated POST with the same key within 24 h returns the first response.

Lengthlength <= 255
API-Version?string

Request Body

application/json
  1. body
from*string
to*array<string>
Items1 <= items <= 50
subject*string
Lengthlength <= 998
html?string
text?string
tags?
scheduled_at?string

ISO 8601 UTC, at most 72 h in the future.

Formatdate-time
resend_of?string

Email ID to resend. The new email keeps that email's mode. A test email is never sent live. A live email cannot be resent with a test key.

Response Body

Email accepted and queued.

application/json
  1. response
id*string
status*EmailStatus
Value in"queued""scheduled""sent""delayed""delivered""bounced""complained""failed""canceled"
status_detail?string

Provider detail for the current status, truncated to 500 characters when present.

Lengthlength <= 500
created_at*string
Formatdate-time