Sending an Email

This endpoint allows you to start sending emails through the Restsend Email API.

Overview

Send an email using this POST request:

bash
POST https://restsend.com/api/sendmail

Request Body

json
{
  "from": "hello@restsend.com",
  "to": "john@example.com",
  "subject": "Hello from restsend",
  "body": "<b>This is just a friendly hello from your friends at restsend.</b>",
  "enabledTracker": true
}

Request parameters

JSON parameters are provided in dot notation.

JSON ParameterTypeRequiredLimitationsDescription
fromstringyes
tostringyes
subjectstringyes
bodystringyes*Not required if templateID is present.
templateIDstringyes*Only required if there's no body present.
attachmentsobject[]no
attachments.*.contentstringyesAfter decoding Base64Base64 encoded content of the attachment.
attachments.*.filenamestringyes

Response

json
{
  "message": "Email sent successfully",
  "status": "success"
}