Empresas
Empleos
  • Sobre nosotros
  • Soluciones
    • Publicación de vacantes
      Publica tu vacante y recibe candidatos calificados en 48h.
    • Evaluación de candidatos
      500+ pruebas técnicas y psicológicas, más anti-fraude.
    • Headhunting
      Búsqueda ejecutiva a la medida de principio a fin.
    • Nómina + EOR
      Dispersión de nómina y EOR en más de 15 países de LATAM.
  • Precios
  • Empleos

0

761
Vistas
Nodemailer error (Error: queryA EREFUSED)

sorry for my english

I am using nodemailer and when querying through the api it gives this error:

    Error: queryA EREFUSED smtp.gmail.com
        at QueryReqWrap.onresolve [as oncomplete] (dns.js:210:19) {
      errno: undefined,
      code: 'EDNS',
      syscall: 'queryA',
      hostname: 'smtp.gmail.com',
      command: 'CONN'
    }

My code:

    this.transporter = nodemailer.createTransport({
      service: 'gmail'
      auth: {
        user: mygmail@gmail.com,
        pass: mypass,
      },
})

UPD: I connected the phone to the Internet instead of my LAN cable, checked, everything worked. There was no error, I connected the LAN back, disconnected the phone, this error appeared again

about 4 years ago · Juan Pablo Isaza
2 Respuestas
Responde la pregunta

0

Make sure that Less secure app access is on in your Gmail account:

Less secure app access > ON

Then fix your code:

this.transporter = nodemailer.createTransport({
  service: "gmail",
  auth: {
    user: email,
    pass: password
  }
});
about 4 years ago · Juan Pablo Isaza Denunciar

0

You can use the built-in service in the Nodemailer and make your code simpler with this one.

this.transporter = nodemailer.createTransport({
  service: 'gmail',
  auth: {
    user: mygmail@gmail.com,
    pass: mypass,
  },
})

Please make sure you have disabled 2-Step verification.

about 4 years ago · Juan Pablo Isaza Denunciar
Responde la pregunta
Encuentra empleos remotos

¡Descubre la nueva forma de encontrar empleo!

Top de empleos
Top categorías de empleo
Empresas
Publicar vacante Precios Comercial
Legal
Términos y condiciones Política de privacidad
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomiéndame algunas ofertas
Necesito ayuda