0.1.1 • Published 6 years ago
mail-queue v0.1.1
Mail Queue
A mailer tool that sends bulk emails using mailgun in a controlled manner using the prefetch and delay configurations, prefetch is the number of emails send concurrently in a single time while the delay is the interval in seconds between prefetches.
Usage
import mailer from 'mailer-queue';
mailer(
[
{ from: ..., to: ..., subject: ..., text: ... },
{ from: ..., to: ..., subject: ..., text: ... },
{ from: ..., to: ..., subject: ..., text: ... },
{ from: ..., to: ..., subject: ..., text: ... },
...
],
5, /* prefetch */
100, /* delay */
function(err) { if (err) throw err; }
);