diff --git a/Troubleshooting-Mail.md b/Troubleshooting-Mail.md index bb71182..257525b 100644 --- a/Troubleshooting-Mail.md +++ b/Troubleshooting-Mail.md @@ -1,4 +1,36 @@ -If you can't get your email server working with smtp/stmps or MAIL_SERVICE, look is there more config options for your email server at https://nodemailer.com docs, and add new issue about your email server to https://github.com/wekan/wekan/issues . Thanks! +If you can't get your email server working with smtp/stmps or MAIL_SERVICE, look is there more config options for your email server at https://nodemailer.com docs, and add new issue about your email server to https://github.com/wekan/wekan/issues or [pull request](https://github.com/wekan/wekan/wiki/Emoji#how-you-could-add-another-plugin). + +For example, for https://nodemailer.com/smtp/ + +1) Install node.js 12.22.6 +2) Add to top of code example: `var nodemailer = require('nodemailer');` +3) Install nodemailer: `npm install nodemailer` +4) send email: `node email.js` + +For example, this kind of code uses similar like MAIL_SERVICE in Wekan: + +``` +var nodemailer = require('nodemailer'); + +let transporter = nodemailer.createTransport({ + service: "Outlook365", + auth: { + user: 'firstname.lastname@hotmail.com', + pass: 'TopSecret' + }, +}) + +let info = transporter.sendMail({ + from: 'Firstname Lastname ', + to: 'somebody@example.com', + subject: 'Hi', + text: 'Hi. Reminder: Meeting tomorrow.', + html: '

Hi. Reminder: Meeting tomorrow.

' +}) +``` + + +If with some code example sending email works, xet7 can add it to wekan, like in [Wekan v5.52](https://github.com/wekan/wekan/blob/master/CHANGELOG.md#v552-2021-08-26-wekan-release) xet7 added direct nodemailer usage for MAIL_SERVICE. ## MAIL_SERVICE