Skip to Content
🎉 New release with new features and improvements! V0.0.5 Release →

Send Email

Send an email using either plain text, HTML content, or email templates.

First you need to configure the email configurations before using this endpoint.

Endpoint

POST /api/mailing/send

Request Body

Here’s the code in markdown format:

Send a simple plain text or HTML email directly.

{ "to": "recipient@example.com", "cc": ["colleague@example.com"], "bcc": ["archive@example.com"], "subject": "Test Email", "body": "This is a test email body", "html": false // or true for HTML }

Parameters

ParameterTypeRequiredDescription
tostring/arrayYesRecipient email address(es)
ccstring/arrayNoCarbon copy recipient email address(es)
bccstring/arrayNoBlind carbon copy recipient email address(es)
subjectstringNoEmail subject line
bodystringNo*Email body content
htmlbooleanNoWhether body contains HTML (default: false)
templatestringNo*Template name for template-based emails
dataobjectNoTemplate variables for dynamic content

* Either body or template is required, but not both.