Design your own email templates w/ visual composer directly inside the Strapi admin panel and send composed emails programmatically from your controllers / services.
Quick summary what's this feature request about.
I would like to send emails from several domains, as my backend hosts several domains.
Why is it needed?
I want clients to receive emails from the domain that is associated with the project
Suggested solution(s)
I know i can manually send from several transporters but i have no idea on how to use it with your layouts.
const nodemailer = require('nodemailer');
// Transporter for the first identity
const transporter1 = nodemailer.createTransport({
host: 'smtp.first-server.com',
port: 587,
secure: false, // true for 465, false for other ports
auth: {
user: 'user1@example.com',
pass: 'password1'
}
});
// Transporter for the second identity
const transporter2 = nodemailer.createTransport({
host: 'smtp.second-server.com',
port: 587,
secure: false, // true for 465, false for other ports
auth: {
user: 'user2@example.com',
pass: 'password2'
}
});
// Example of sending an email with the first identity
transporter1.sendMail({
from: 'user1@example.com',
to: 'recipient@example.com',
subject: 'Email from first identity',
text: 'This is the email content.'
}, (err, info) => {
if (err) {
console.error(err);
} else {
console.log('Email sent: ' + info.response);
}
});
// Example of sending an email with the second identity
transporter2.sendMail({
from: 'user2@example.com',
to: 'recipient@example.com',
subject: 'Email from second identity',
text: 'This is the email content.'
}, (err, info) => {
if (err) {
console.error(err);
} else {
console.log('Email sent: ' + info.response);
}
});
A clear and concise description of what you want to happen.
Suggest a solution
Related issue(s)/PR(s)
Let us know if this is related to any issue/pull request.
Feature request
Use multiple transporters
Summary
Quick summary what's this feature request about. I would like to send emails from several domains, as my backend hosts several domains.
Why is it needed?
I want clients to receive emails from the domain that is associated with the project
Suggested solution(s)
I know i can manually send from several transporters but i have no idea on how to use it with your layouts.
A clear and concise description of what you want to happen.
Suggest a solution
Related issue(s)/PR(s)
Let us know if this is related to any issue/pull request.