Skip to main content

Send Email

Send outbound email through the PurpleToad Mail API or SMTP. The API is the easiest way to start.

API request

curl -X POST https://api.purpletoadmail.com/api/v1/outbound/send \
-H "Authorization: Bearer pt_live_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"from_email": "hello@yourdomain.com",
"to": ["recipient@example.com"],
"subject": "Hello from PurpleToad Mail",
"text": "This is the plain-text body.",
"html": "<p>This is the <strong>HTML</strong> body.</p>"
}'

Required fields

FieldTypeDescription
from_emailstringA verified address on one of your domains.
tostring[]Recipient email addresses (max 50 total across to/cc/bcc).
subjectstringEmail subject line.
text or htmlstringBody content; at least one is required.

Optional fields

  • from_name — display name for the sender.
  • cc, bcc — additional recipients.
  • reply_to — override the reply address.
  • attachments — base64-encoded file attachments (max 10, total size ≤ 25 MB).
  • headers — custom headers; each key must start with X-.
  • metadata — arbitrary key/value data attached to the message.
  • thread_id — group related messages into a thread.

Sending with templates

Templates are stored under /api/v1/templates. To send using a template, use the dedicated template send endpoint:

curl -X POST https://api.purpletoadmail.com/api/v1/outbound/send-template \
-H "Authorization: Bearer pt_live_your_key_here" \
-H "Content-Type: application/json" \
-d '{
"from_email": "hello@yourdomain.com",
"to": ["user@example.com"],
"template_id": "7d871e40-32c1-4e8a-9030-29f876f69f27",
"variables": {"name": "Ada", "product": "Acme"}
}'

SMTP

If you prefer SMTP, use these settings:

SettingValue
Hostmail.purpletoadmail.com
Port587
SecuritySTARTTLS
UsernameYour full mailbox address
PasswordYour mailbox password