Send email
Send email
POST
https://simplemail-nodejs.herokuapp.com/send-email
Sending email and send request to another server.
Request Body
email*
String
The email of the receiver.
from*
String
The email of the sender. Same as the one that provided in smtp_user
.
subject*
String
The subject of the mail.
text*
String
The text of the email. If html
is provided, this field will be overwritten.
html
String
The raw html.
smtp_pass*
String
The app password of your Gmail account.
smtp_user*
String
The email of your Gmail account.
callback_url
String
The url you want to call after sending email to receiver.
*exclude localhost
callback_data
String
The data you want to send along with the callback_url after sending email to receiver.
method
String
Methods of your callback_url
eg: POST, GET, PUT, PATCH, DELETE
send_at
String
The datetime you want the email get sent. Make sure the provided value is less or equal than 7 days.
eg: "2021-11-26 23:59"
*This function is not very stable since the server is hosting at Heroku with hobby plan, it may not work due to the idle stuff
timezone
String
Timezone for send_at
.
Default value: "Asia/Kuala_Lumpur"
// Not scheduled email
{
"msg": "Success"
}
// Is scheduled email
{
"msg": "Success",
// same with rescheduleID if `callback_url` is not provided
"cancelID": "2js4h23a-3767-4130-bfb9-56425f406da9",
"rescheduleID": "w12hj21-3767-4130-bfb9-56425f406da9"
}
Last updated