Questions tagged [nodemailer]

Easy to use module to send e-mails with Node.JS

Nodemailer is an easy to use module to send e-mails with Node.JS (using SMTP or sendmail or Amazon SES) and is unicode friendly.

Nodemailer is Windows friendly, you can install it with npm on Windows just like any other module, there are no compiled dependencies. Use it from Azure or from your Windows box hassle free.

Installation:-

Install through NPM

npm install nodemailer

Useful Links:

2466 questions
10
votes
3 answers

Nodemailer getaddrinfo ENOTFOUND Error

Looking for some insight into this error I'm getting. on smtpTransport.sendmail(func(err, info){}) The err variable returns this: Error: getaddrinfo ENOTFOUND smtp.gmail.com smtp.gmail.com:465 at errnoException (dns.js:50:10) at…
Ali Malik
  • 101
  • 1
  • 1
  • 4
10
votes
4 answers

Nodemailer, Heroku, Gmail, invalid login - works locally

I have been having this issue for the past couple of weeks, it works every time locally, however once I deploy it to my heroku server, it will give me an invalid login error. I have gone into the account and givin access to less secure apps. And the…
Truextacy
  • 562
  • 1
  • 5
  • 26
10
votes
3 answers

Google oauth 2.0 API password change Username and Password not accepted

I have a form using nodemailer, xoauth2 with google APi oauth2, I updated the password last week and since then my app hasn't worked and I get: '535-5.7.8 Username and Password not accepted. Learn more at\n535 5.7.8 I've tried deleting the app and…
Graeme Paul
  • 1,143
  • 1
  • 16
  • 30
10
votes
2 answers

node js SMTP error

I am sending e mail through my godaddy email account. For that i am using node js for sending emails but it is giving following error : { [Error: getaddrinfo ENOTFOUND] code: 'ENOTFOUND', errno: 'ENOTFOUND', syscall: 'getaddrinfo' } Source…
hectk
  • 350
  • 1
  • 3
  • 11
10
votes
1 answer

How to cause sent emails to appear threaded in GMail recipient's view with Message-ID, In-Reply-To and References

I've read some great online resources like http://www.jwz.org/doc/threading.html, and it seems that any email is send with a Message-ID header, then any replies to it include In-Reply-To naming that ID and Refences which can name a list of parent…
Neek
  • 7,181
  • 3
  • 37
  • 47
9
votes
2 answers

Why won't error handling work in nodemailer?

I am trying to set up a really simple contact form with nodemailer and it works fine, but my issue is that it doesn't handle errors. The page should redirect if an error is thrown, but instead the redirect does not happen and the app stops running.…
9
votes
2 answers

Set up Nodemailer to secure email with a STARTLS handshake?

I need to send e-mail through my remote Postfix/Dovecot SASL service from Node.js on my desktop. When I send email using Thunderbird, it works and the Postfix server logs show Anonymous TLS connection established from unknown[dh.cp.ip.ip]: TLSv1.2…
Kickaha
  • 3,680
  • 6
  • 38
  • 57
9
votes
5 answers

Sending email from own server to the internets

I have set up an email server on my host. It's basically a SMTP server that listens on port 25. const recvServer = new SMTPServer({ requireTLS: true, authOptional: true, logger: true, onConnect(session, callback) { return…
Alex
  • 66,732
  • 177
  • 439
  • 641
9
votes
3 answers

Nodemailer - email send but not receive

I'm build an API with feathersjs and I need to send an email with an attachment. The email seems to be send but I receive nothing. In my mail.service.js const nodemailer = require('nodemailer'); const transporter = nodemailer.createTransport({ …
Ragnar
  • 2,550
  • 6
  • 36
  • 70
9
votes
1 answer

Sending emails from contact form, with the firebase functions and nodemailer

I use these technologies: Angular 4 Firebase firebase hosting firebase functions firebase real time database firebase storage I host my website on firebase hosting, and I have a contact form like the picture below, I want every time the user…
George C.
  • 6,574
  • 12
  • 55
  • 80
9
votes
1 answer

Sending email attachments with Meteor.js (email package and/or nodemailer or otherwise)

Sending email attachments doesn't appear to be implemented yet in Meteor's official email package. I've tried the nodemailer suggestion (seen here) but received the error "Cannot read property 'createTransport' of undefined". I'm attempting to…
Kyle Bachan
  • 1,053
  • 2
  • 15
  • 33
9
votes
1 answer

Cannot read property 'createTransport' of undefined

I am testing sending email with meteor js and nodemailer plugin: meteor add mrt:meteor-nodemailer when the page loaded, i saw error in the console of the navigator : Cannot read property 'createTransport' of undefined. so what is the problem ? this…
user3385657
  • 131
  • 1
  • 6
9
votes
4 answers

Nodemailer send base64 data URI as attachment. How?

Basically I have an image created using Canvas and it's in base64 encoded data URI. This data URI is then attached to email. ..., attachments:[{ filename: "cat.jpg", contents: new Buffer(cat, 'base64') }], The email is received but the…
9
votes
4 answers

Preventing Spam; Using Nodemailer; Using Sendmail

I'm using the Nodemailer Node.js module to interface with sendmail. However, my emails go directly to the spam folder when reached by a Gmail account. Why are my emails being shit-canned? It must be something to do with the headers of the email, but…
Sam
  • 6,414
  • 11
  • 46
  • 61
9
votes
2 answers

How to send emails from my server with a mail server and nodejs

I have a server with static IP in my home, I serve my own web pages with a domain and all works fine. in my web pages, you can register by email and password. when you register a node module called nodemailer, sends an email from a google account,…
andrescabana86
  • 1,778
  • 8
  • 30
  • 56