1.5.4 • Published 6 years ago
voilab-send v1.5.4
voilab-send
Transactional mailer
Basic usage
var mailer = new (require('voilab-send'))({
adapter: 'some-adapter',
adapterConfig: {
someData: 'someConfig'
}
});
mailer.getAdapter()
.setFrom('from@email.com')
.addTo('to@email.co')
.setSubject('A subject')
.setHtml('<p>Hello -name-</p>')
.addGlobalData('name', 'John');
mailer.send()
.then(function () {
console.log('mail is sent');
})
.catch(function (err) {
console.log(err);
});Sendgrid V4
var mailer = new (require('voilab-send'))({
adapter: 'sendgrid-v4',
adapterConfig: {
apikey: 'your-api-key',
globalDataSurround: '-'
}
});Note that you'll need to add this dependency into your own package.json:
sendgridversion5.*
Sparkpost V2
var mailer = new (require('voilab-send'))({
adapter: 'sparkpost-v2',
adapterConfig: {
apikey: 'your-api-key'
}
});Note that you'll need to add these dependencies into your own package.json:
sparkpostversion2.*
1.5.4
6 years ago
1.5.3
6 years ago
1.5.2
6 years ago
1.5.1
6 years ago
1.5.0
7 years ago
1.4.0
7 years ago
1.3.6
7 years ago
1.3.5
7 years ago
1.3.4
7 years ago
1.3.3
7 years ago
1.3.2
7 years ago
1.3.1
7 years ago
1.3.0
7 years ago
1.2.1
7 years ago
1.2.0
7 years ago
1.1.1
8 years ago
1.1.0
8 years ago
1.0.2
9 years ago
1.0.1
10 years ago
1.0.0
10 years ago
0.1.1
10 years ago
0.1.0
10 years ago