📧Email provider
Harmony.Notifications currently supports Gmail & Brevo email service provider integration.
Gmail setup
For the Gmail setup set the GmailSettings property in the appsettings.json file in Harmony.Notifications.
Each email service provider, e.g Gmail, Outlook, etc.. has its own settings so please advice and setup accordingly. Keep in mind that some providers, for example Gmail require that you have setup Two Factor Authentication to your account and create a specific App Password for your application. Following is an example of a Gmail account, assumming the email address is [email protected]:
The password xxxx yyyy zzzz wwww isn't the actual password for signing with the harmony username. It's a new app password created specifically on its google account to be used for the smtp settings. After adding 2FA authentication on your Gmail account, search for App passwords and create a password for your app. Then paste that password in the corresponding property in appsettings.json file.
Last thing you need to do is to register the Gmail service provider in code. Ensure you don't have any other registrations for the IEmailService interface.
Brevo setup
Brevo setup is much easier to configure. Follow the next steps to create an API key:
Register an account.
Navigate to /settings/key/api/ and click Generate new API key.
Fill the BrevoSettings property in the appsettings.json file:
Last thing you need to do is to register the Brevo service provider in code. Ensure you don't have any other registrations for the IEmailService interface.
Read next - Deploy Harmony
🚢DeploymentLast updated