Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • Aug 24 19:36
    stale[bot] closed #1028
  • Aug 24 06:51
    z1988hf opened #1051
  • Aug 23 17:45
    stale[bot] closed #1027
  • Aug 23 16:49
    v1b3m commented #677
  • Aug 23 14:41
    hbendix commented #677
  • Aug 22 19:57
    Travis nodemailer/wildduck (master) broken (750)
  • Aug 22 05:53
    rols2015 closed #1047
  • Aug 22 05:53
    rols2015 commented #1047
  • Aug 21 22:02
    EyePulp commented #1047
  • Aug 21 22:01
    EyePulp commented #1047
  • Aug 21 13:01
    kriddile commented #902
  • Aug 21 12:46
    kriddile commented #902
  • Aug 21 03:26
    kriddile commented #902
  • Aug 20 08:41
    stale[bot] closed #1026
  • Aug 19 21:50
    ibidpayfazz commented #230
  • Aug 19 12:31
    martiiian commented #953
  • Aug 18 10:35
  • Aug 17 19:12
    stale[bot] labeled #1028
  • Aug 17 19:12
    stale[bot] commented #1028
  • Aug 17 18:12
    stale[bot] closed #1024
Sebastian
@B0rschti
Ah okay i think i found my error. It was caused by configuration problems because i used nodemailer inside a docker container.
but thanks anyway
Sebastian
@B0rschti

Okay my error still exists but i am able to send a mail from the guest os (docker container) through the host os postfix (MTA).
It seem to my that nodemailer tries to open a connection to the MTA of the guest os (docker container) which has no MTA installed.
My first assumption was that the nodemailer-sendmail-transport is not spawning the proper command and put a log out before to inspect the spawned command and args but this section is never reached.

So, is nodemailer open a connection to 127.0.0.1:25 during transport creation?
Can i configure this behavior?
Because i only need to spawn the sendmail command to get my sending a email issue working ... ?

Ah i forgot I am using the nodemailer version 2.7.0 and sendmail-transport 1.0.2

Can you guys please help me and provide an advice how to solve the last remaining config issue for my problem?

Sebastian
@B0rschti

Okay now i upgraded to version 4.0.1 and use the internal sendmail feature.
This gives me the success callback but the mail is not send.

sendmail command spawned: /usr/sbin/sendmail [ '-i', '-f', 'blah@blub.de', 'test@gmail.com' ]

Result is:
Mail send { envelope:
{ from: 'blah@blub.de',
to: [ 'test@gmail.com' ] },
messageId: '18db223c-6e90-a629-4c2e-e6647a939bc6@blub.de',
response: 'Messages queued for delivery' }

i logged the spawned command then and use it manualy in the terminal and my mail was send.
...
This is a curious behaviour. (@.@)

Anyone have an idea about this?

Abdul-Samii Ajala Olalekan
@jalasem

I am developing a pure node App (without express or any other framework)
I stored some values in the req (request) object like this

req.token = uuid();
`

in another route, when I did this

console.log(req.token);

I get undefined. Please is there a sure way of saving value into the http request object for later use?

FloatingDreamer
@FloatingDreamer
Hi guys, have you guys is the templateSender function for built in templating gone in nodemailer 4.1.0? Looking in tutorials this was the function needed to do builtin templating
vantrungduy
@vantrungduy
I've set X-Mailer header but it always return "X-Mailer: nodemailer (2.7.2; +https://nodemailer.com/; SMTP/2.7.4[client:2.12.0])"
Can I override X-Mailer header? thanks
Joe Early
@JoeEarly

Hi all, I am wondering why the following:

from: req.params.name + ' <' + req.params.email + '>',

keeps returning the error: Domain of sender address XXXXXX@gmail.com&#62 does not exist

It does not seem to like the "right-tag" on at the end.
Joe Early
@JoeEarly
from: req.params.name + ' ' + req.params.email,
This worked fine :shipit:
Joe Early
@JoeEarly
HI all, quick question if someone can answer. I am trying to send in a contact form, and when its "message" is larger than 260 char, it fails to complete the request.
Running expressjs and I think its an issue there but am asking in here just in case
AKASH SOURAV NAYAK
@AkashSouravNayak
while sending email How to cache the template file so that it will not compile for each request?
Volodymyr Besyada
@BesyadaV
Hello, it is possible to send mail to multi users(example to:'o@gmail.com, s@gmail.com...'). But when they receive mail in field receive user seen just his email(not list of all receivers)?
Abdul Jalil Laguindab
@wnxhaja
@UaSensei do you mean cc and bcc? if it is then nodemailer does support it.
Volodymyr Besyada
@BesyadaV
@wnxhaja thx!
yaodehuang
@yaodehaung
i don't know this responce { Error: getaddrinfo ENOTFOUND stmp.gmai.com stmp.gmai.com:587
at errnoException (dns.js:53:10)
at GetAddrInfoReqWrap.onlookup [as oncomplete] (dns.js:95:26)
code: 'ECONNECTION',
errno: 'ENOTFOUND',
syscall: 'getaddrinfo',
hostname: 'stmp.gmai.com',
host: 'stmp.gmai.com',
port: 587,
command: 'CONN' }
Jithin James
@jithinjk
Is there any example to show how to use nodemailer-build-attachment with nodemailer.
Alexander Escamilla
@alexesca
Please mention me. Apple mail Mac/iphone does not show my pdf attachment. I am using nodemailer and AWS to send out emails. It works well on Chrome though. Here is my attachment config.
[{
            path: path + pdfFileName,
            filename: pdfFileName,
            contentType: 'application/pdf'
        }]
Egwuenu Gift
@lauragift21
Hello I'm working with nodemailer in my sailsjs application is there a way for me to defie the To: sender email without inputing a string?
Ben Chiciudean
@benydc
I have an issue when trying to send email using an office365 email address, this is the log:
[2018-06-21 12:32:20] DEBUG Creating transport: nodemailer (4.6.7; +https://nodemailer.com/; SMTP/4.6.7[client:4.6.7])
[2018-06-21 12:32:20] DEBUG Sending mail using SMTP/4.6.7[client:4.6.7]
[2018-06-21 12:32:20] INFO  [lBg35Kf9cPY] Connection established to 40.101.70.18:587
[2018-06-21 12:32:20] INFO  [lBg35Kf9cPY] Connection upgraded with STARTTLS
[2018-06-21 12:32:20] DEBUG [lBg35Kf9cPY] SMTP handshake finished
[2018-06-21 12:32:27] INFO  [lBg35Kf9cPY] User "ben@synthbit.io" failed to authenticate
[2018-06-21 12:32:27] DEBUG [lBg35Kf9cPY] Closing connection to the server using "end"
[2018-06-21 12:32:27] ERROR Send Error: Invalid login: 535 5.7.3 Authentication unsuccessful [VI1PR0502CA0027.eurprd05.prod.outlook.com]
my credentials are correct as I can login fine from office365 portal
Ben Chiciudean
@benydc
it was Multi-factor authentication, I disabled it for my account
is there way to create app password for nodemailer?
Ben Chiciudean
@benydc
is it possible to store/save sent emails?
I’m using the Outlook365 service
fattahkus
@fattahkus
I tried sending emails in bulk using Smtp Gsuite, but I got the problem "trying an attempt login"
how to fix it?
Spacetime
@justinemar

Can't find solution to this error

{ Error: connect ECONNREFUSED 127.0.0.1:465
    at Object.exports._errnoException (util.js:1050:11)
    at exports._exceptionWithHostPort (util.js:1073:20)
    at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1093:14)
  code: 'ECONNECTION',
  errno: 'ECONNREFUSED',
  syscall: 'connect',
  address: '127.0.0.1',
  port: 465,
  command: 'CONN' }

I also tried using 587 but same error, there no process using the ports

    var transporter = nodemailer.createTransport({
        service: 'smtp.gmail.com',
        port: 465,
        auth: {
          user: process.env.EMAIL,
          pass: process.env.PWD
        }
      });
Álvaro Arcaya
@AlvaroArcaya
@justinemar use h ost instead of service
host *
Make It Count
@makeitcount
Need recommendations to approach email templates
I am using nodemailer v2.x and node v4.6.1. Trying out EmailTemplate v2.x
Want to make it modular structure with css inline and other heavy lifting should be done by libraries such as emailtemplate. Don't know much of the options I might have
Make It Count
@makeitcount
why so silence
@boldt ca n you help
Chris Davis
@chrisdav6
Good day everyone, I have an interesting problem i was hoping you could help me with. I just deployed my nodejs/express site live out into the wild onto a digital ocean droplet with a domain name pointing to it and everything! 🤘 Everything was going great until i noticed spam bots submitting bogus data to my contact form which i'm using nodemailer to send. I set up a hidden honeypot field that cancels form submission if not empty, i thought that would do it, but no luck. I searched the internet, npm for packages and stackoverflow high and low for a solution and came up with nothing. If anyone has any suggestions, i would be all ears! Thank you in advance for your help 😊
Chris Davis
@chrisdav6
Just in case anyone was curious. I was able to get it done with the NPM package email-existence. Thanks all for the help.
Existence is determined by telnetting to the MX server of the email domain and attempting to send an email to the supplied address. MX servers return 250 if the email address exists and 550 if it does not.
app.post("/products/contactCorporate", function (req, res) {
  let { name, email, message, businessAddress } = req.body;

  emailExistence.check(email, function (error, response) {
    if (response === false) {
      req.flash('success', 'Sorry, the email seems to be spam!');
      res.redirect("/products/contactCorporate");
    } else {
      submitForm();
    }
  });
});
Matteo
@Nibelino
Is @types/nodemailer up to date?
Mathieu Ghennassia
@mathieug
Hello, I'd like to run a smtp server in my tests to catch outgoing emails. I'm testing smtp-server + nodemailer.
const { SMTPServer } = require('smtp-server');
const nodemailer = require('nodemailer');

const SMTPServerInstance = new SMTPServer({
  logger: true,
  debug: true,
  authOptional: true
});

SMTPServerInstance.listen(() => {
  console.log('SMTP server is listening!\n');

  const transporter = nodemailer.createTransport({
    logger: true,
    debug: true,
    host: SMTPServerInstance.server.address().address,
    port: SMTPServerInstance.server.address().port,
    ignoreTLS: true
  });

  console.log('Sending email...');
  transporter
    .sendMail({
      from: 'sender@example.com',
      to: 'receiver@example.com',
      subject: 'Subject',
      text: 'Text',
      html: 'HTML'
    })
    .then((info) => {
      console.log('Email successfully sent!', info);
    })
    .catch((err) => {
      console.log('Error when sending an email:', err);
    })
    .finally(() => {
      SMTPServerInstance.close();
    });
});
I'm not sure why I set ignoreTLS: true on the client. I'd like to disable any auth/encryption on the server, the client should adapt by itself.
And I'm not convinced with authOptional: true on the server, I want it disabled not optional.
Mathieu Ghennassia
@mathieug
Mathieu Ghennassia
@mathieug
Second thing, I don't understand why attributes host+port doesn't work like attribute url. I'm trying to do url: 'smtp://{host}:{port}' but I get a TLS upgrade: https://runkit.com/mathieug/nodemailer--smtp-server/1.0.1
Surbhi Rawat
@RVTsurbhi
hello
i have used nodemailer for my app and every time my emails are going in spam...can anyone suggest the solution for this?
i'm using bluehost and while sending mails directly through my account its working fine but using node server mails are going in spam