Skip to content

Send Email Transactional

POST
/v1/send/email

Sends an email using the provided JSON body.

This method is suitable for production usage and allows for more complex email configurations.

The request body for sending an email.

This request body should be a JSON object containing the necessary fields to send an email.

object
from
required
object
name

The name of the sender.

string
John Doe
email

The email address of the sender.

string format: email
john@doe.com
to
required
Array<object>
object
name

The name of the recipient.

string
Jane Smith
email

The email address of the recipient.

string format: email
jane@smith.com
subject
required

The subject of the email.

string
Welcome to Our Service
text
required

The content of the email.

string
Hello, this is a test email.
html
required

The HTML content of the email.

string
<p>Hello, this is a test email.</p>
variables

Variables to be used in the email template. Variables avalaible from A to Z. You can define variables like variable_a_var, variable_b_var, etc.

These variables can be used in dynamic content like {{variable_a_var}}.

object
variable_a_var

Use on dynamic content like {{variable_a_var}}.

string
Variable A Value
attachment

A list of files to be attached to the email.

Each file can be specified by its name and URL
(Max size allowed 10MB).

Array<object>
object
name

The name of the file to be attached.

string
document.pdf
url

The URL of the file to be attached.

The file will be downloaded and attached to the email.

string format: url
https://www.buildquickbots.com/whatsapp/media/sample/pdf/sample01.pdf
attachment_buffer

A list of files to be attached to the email.

Each file can be specified by its name and base64 encoded content
(Max size allowed 10MB).

Array<object>
object
name

The name of the file to be attached.

string
document.pdf
content

The base64 encoded content of the file to be attached.

This is useful for small files that can be sent directly in the request.

string format: byte
data:(mime type),base64,JVBERi0xLjQKJazc... (base64 content)

Email sent successfully.

object
status
boolean
true
message
string
Email sent successfully
data

A list of sent email identifiers.

Array

Your key auth is not valid

object
status
boolean
error
boolean
true
message
string
Your key auth is not valid, please check with your administrator to get the new key
Example
{
"status": false,
"error": true,
"description": "Your key auth is not valid, please check with your administrator to get the new key"
}

Your account dont have credits availables for send

object
status
boolean
error
boolean
true
message
string
Your account dont have credits availables for send this, please contact your administrator
Example
{
"status": false,
"error": true,
"description": "Your account dont have credits availables for send this, please contact your administrator"
}

Missing required parameters

object
status
boolean
error
boolean
true
message
string
Missing params, please verify or contact to support
Example
{
"status": false,
"error": true,
"description": "Missing params, please verify or contact to support"
}

Useful for guiding users to view code examples in different developer languages.

developer@developer:~#
curl -X POST "https://api.example.com/v1/send/email" \
-H "Accept: application/json" \
-H "Connection: keep-alive" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer <your-token>" \
-d '{"from":{"name":"John Doe","email":"john@doe.com"},"to":[{"name":"Jane Smith","email":"jane@smith.com"}],"subject":"Welcome to Our Service","text":"Hello, this is a test email.","html":"<p>Hello, this is a test email.</p>","variables":{"variable_a_var":"Variable A Value"},"attachment":[{"name":"document.pdf","url":"https://www.buildquickbots.com/whatsapp/media/sample/pdf/sample01.pdf"}],"attachment_buffer":[{"name":"document.pdf","content":"data:(mime type),base64,JVBERi0xLjQKJazc... (base64 content)"}]}'