Example
This example sends an email to a client from an imaginary database mydatabase-ad0c. The REST endpoint for sending email from a database is:
mydatabase-ad0c.restdb.io/mail
Send an email with cURL:
curl -X POST -H "Content-Type: application/json"\
-H "x-apikey: 588ca88ca2c06c75467a12ca"\
-H "Cache-Control: no-cache"\
-d '{"to":"jones@restdb.io","subject":"Your order is ready", "html": "<p>Lorem ipsum dolor sit amet, <b>price $20</b> luctu.</p>", "company": "Acme Inc", "sendername": "Acme customer support"}'\
"https://mydatabase-ad0c.restdb.io/mail"
The resulting email from the example above will look something like this screenshot:
Housekeeping
To help you keep track of which emails has been sent via the API, you will find copies of all outgoing emails in the system collection email_outbound.
It's never been simpler to build email into your application.
Next on your ToDo: get a cup of coffee, then add email communication to your application.