A Mandrill transport for Nodemailer.
'use strict';
var nodemailer = require('nodemailer');
var mandrillTransport = require('nodemailer-mandrill-transport');
var transport = nodemailer.createTransport(mandrillTransport({
auth: {
apiKey: 'key'
}
}));
transport.sendMail({
from: 'sender@example.com',
to: 'user@example.com',
subject: 'Hello',
html: '<p>How are you?</p>'
}, function(err, info) {
if (err) {
console.error(err);
} else {
console.log(info);
}
});
mandrillTransport(options);
async
tags
metadata
recipient_metadata
preserve_recipients
transport.sendMail(options, function(err, info) {});
to
cc
bcc
from
subject
headers
text
html
tags
metadata
recipient_metadata
preserve_recipients
async