

Nodemailer: Easy e-mail sending from your Node.js applications - tilt
http://www.nodemailer.com/

======
whileonebegin
Is this really much easier than using
[https://www.npmjs.org/package/mailer](https://www.npmjs.org/package/mailer)?
Also, unless nodemailer is written by the same developer as mailer, it appears
they copied the tagline, "simple as cake".

    
    
            email.send({
                host : "smtp.gmail.com",              // smtp server hostname
                port : "465",                     // smtp server port
                ssl: true,
                domain : "localhost",            // domain used by client to identify itself to server
                to : "recipient@somewhere.com",
                from : 'sender@somewhere.com',
                subject : 'My Subject',
                body: 'Blah\nBlah\nBlah.,
                authentication : "login",        // auth login is supported; anything else is no auth
                username : '',
                password : ''
            },
            function (err, result) {
            });

~~~
andris9
"mailer" and its derivatives are deprecated in favor of "nodemailer". Besides,
"mailer" uses "nodemailer" as its backend (it used to have its own SMTP client
but it had a lot of shortcomings), so it doesn't really count. You could as
well create your own wrapper areound "nodemailer" that would be even easier to
use.

------
singlow
I started using this in all my node projects a couple years ago. It has been
my favorite email library in any language I've used. I love the pre-configured
services for gmail and sendgrid, etc. Surprised to see it posted - I figured
everyone already was using it.

------
bevacqua
I wrote a module you can use on top of Nodemailer to send beautiful emails
effortlessly.

[https://github.com/bevacqua/campaign](https://github.com/bevacqua/campaign)

[https://github.com/bevacqua/campaign#using-
nodemailer](https://github.com/bevacqua/campaign#using-nodemailer)

~~~
lttlrck
That looks really nice. I'll give it a go.

------
eknkc
Been using it for re than a year. Sent more than a million newsletters over
SES and SendGrid. Never had a problem.

Website does not seem to have a link to repo though:
[https://github.com/andris9/Nodemailer](https://github.com/andris9/Nodemailer)

~~~
ruethewhirled
Thanks, was wondering if it was on github!

------
sehrope
Nice module. Logo is pretty nifty too. The default "well known" server list is
particularly useful.

If you happen to use this with AWS watch out though. It's hard coded to US
east. If you're not in that region then you should configure the server
manually to a local end point so that you don't have to pay for bandwidth.
Would be a tad faster too.

[1]:
[https://github.com/andris9/Nodemailer/blob/master/lib/wellkn...](https://github.com/andris9/Nodemailer/blob/master/lib/wellknown.js#L46)

------
ThatGeoGuy
This might be a minor comment, but I noticed you guys are using Node.js with
Express.js to render nodemailer.com. You can (and maybe should) change the
favicon from the default Express.js favicon.

You can do so by removing `app.use(express.favicon());` from the generated
app.js file. At the very least, you could add your own favicon in your public/
folder to make the project page look (albeit in the most vain sense) more
polished.

------
kenperkins
Regardless of which package you use for delivering email, I can't recommend
enough to put the email delivery code into an async job queue that
automatically retries.

Even with major providers there are enough occasional blips that you don't
want to impact delivery of your email. Additionally, it would allow you to
decouple sending (popping from the queue) if you ever needed to delay it
momentarily.

~~~
balls187
What async job queue do you recommend? Is it decoupled from your app server?

~~~
baudehlo
How about a mail server?

~~~
balls187
My use isn't specific to mail. Instead I would like something similar to
Resque in functionality.

------
splatcollision
Such a lovely logo. Compliments to the designer

------
asadlionpk
I used this in my product. Good work! :)

~~~
feralmoan
Same here, between Nodemailer and Haraka, SMTP relaying with node is a breeze

~~~
baudehlo
Thanks! (I wrote Haraka)

~~~
feralmoan
And node-phantom-simple :D (saved my bacon with that also)

------
munimkazia
This module is the main cog behind the email delivery service application in
my organization, which I built over a year ago, and it has been supremely
reliable while handling 40-50 million emails per month. Just my testimonial.

------
el_tone
The product itself looks great but am I missing something with the tagline?
Surely it should be either "easy as pie" or "a piece of cake".

~~~
andris9
I'm the author of Nodemailer. I'm not a native english speaker and I
"borrowed" the tagline from a Node.js module by Marak Squires and didn't
realize that "easy as cake" is not a widely used expression but something he
probably made up himself.

~~~
el_tone
Fair enough, thanks for all your hard work btw!

------
cardamomo
I'm familiar with this as one of the dependencies of Ghost. It was great to
see that it includes sending via SES.

------
ladon86
We've used Nodemailer in production at ClassDojo to send at least 100m emails
- it's a great module.

