John Smith
John Smith

Reputation: 91

What's the simplest way to send emails using Node.js?

About two years ago, I created a Node.js application that would send emails periodically through Gmail's Less Secure Apps option. This worked quite well, but they recently got rid of it. I have G-Suite email addresses under my domain that I would like to send emails from, but the new Gmail API takes quite a bit of effort to set up and maintain. Is there a way that I can use Node.js to send emails from those addresses, but in a simpler way? Could I possibly use another SMTP server, like Yahoo or iCloud, with Nodemailer?

Upvotes: 0

Views: 180

Answers (1)

Linda Lawton - DaImTo
Linda Lawton - DaImTo

Reputation: 116948

if you want to continue as you are just create an apps password.

otherwise you can configure a service account and set up domain wide deligation through your workspace domain account.

The service account will be able to send email on behalf of a user on your domain without any authorization needed. This is probably the most robust solution

Upvotes: 1

Related Questions