mandrill-dust
v0.0.2
Published
Module with very specific functionality. E-mails dust templates via Mandrill.
Downloads
7
Readme
mandrill-dust
This module does something very specific - it takes a path to a dust template, a model and a list of recipients, and uses the mandrill API to send an HTML e-mail.
As usual, this is a promise-based library.
Initialize by using
var client = require('mandrill-dust')({
'API_KEY': 'secret',
'sender': '[email protected]'
});
then send by using a send request
client.send({
'template': 'templates/email.dust',
'model': {
'name': 'world'
},
'subject': 'How are you?'
'to': ['[email protected]'],
//'cc': ['[email protected]'],
//'bcc': ['[email protected]']
});
Note that template
, subject
and one of [to
, cc
, bcc
] is required to send an e-mail.