Configuration Of Mailjet API in Odoo
Configuration Of Mailjet API in Odoo We can configure Mailjet’s API with Odoo, also set up a mass mailing server through Mailjet by configuring in the Odoo database and Mailjet account. The DNS settings of the custom domain is also to be configured.
Set Up In Mailjet
Create API Credentials in Odoo
First we need to sign into the Mailjet Account and click on SMTP and Send API settings in the Sender & Domains section.
The SMTP configuration settings which include the server address, the security option needed and the port number is found under the configuration section.
Next retrieve the Mailjet API credentials by clicking on the button labeled Retrieve Your API Credentials.
The API key serves as the username in the Odoo configuration which can be seen by clicking the eye icon. Also the the Secret Key serves as the password in the Odoo configuartion which is generated by clicking on the Generate Secret Key button.
Add Verified Sender Address:
Inorder for an email address or domain to be approved to send emails using Mailjet’s servers we need to add a sender address or a domain to the Mailjet’s account settings.
Now we need to go to the Mailjet Account Information page and under the Senders & Domains section find the Add a Sender Domain or Address link and click on it.
We can either add a senders’s email address or the entire domain to the mailjet settings.It is easier to configure the domain as a whole if DNS access is available.
The email address set up in the Mailjet account is added as a trusted sender by default and to add anoher email address, we need to click on the button Add a sender address, then add the email address that is configured to send from domain.
A form is to be filled out which is the Email Information form and an activation email is send to the email address from where the trusted sender can be activated. SPF/DKIM/DMARC settings on the domain of the sender is recommended to be set up.
Add a domain
When adding an entire domain to a Mailjet account all the sender addresses related to the domain are automatically validated for sending emails using Mailjet servers.
To add a domain click on Add a Sender Domain or Address link which is present under the Senders & Domains section and then click on Add domain to add the custom domain and fill the Add a new Domain page on Mailjet.
After succesfully adding a domain a validation page will be generated and unless the Odoo database is on-premise choose the option Create a DNS Record.
Setup in the domain’s DNS:
On getting the TXT record from the Mailjet account add a TXT record to the particular Domain’s DNS. The TXT record consists of information of the Host and Value.
Return to Mailjet account information:
After adding the TXT record to the domain’s DNS return back to the Mailjet account and validate. This action can also be done using Manage.
If a success screen appears on clicking Check Now the TXT record added on the domain is configured correctly.
After setting up the domain successfully there is an option to Authenticate this domain (SPF/DKIM) which populates SPF & DKIM provider.
Set up in Odoo
For the setup to be completed, we need to navigate to Odoo database and go to the Technical Menu Email Outgoing Mail Servers in the settings all the while with the Developer mode that is the Debug mode on. Then new outgoing server configuration is created by clicking on the Create button.
Input API KEY and SECRET KEY which was copied from the Mailjet account as the Username and Password respectively.
Set the Priority value of Mailjet higher than of any transactional email server if Mailjet server is to be used for mass mailing. Now save the settings and Test the Connection.
Now the setup is complete and the Odoo database is set to use the Mailjet email server for mass mailing or transactional email.
Also Read: How to Write Odoo Test Cases In Odoo 17
"Unlock the Full Potential of Your Business with Odoo ERP!"
"Get a Cost Estimate for Your ERP Project, Absolutely FREE!"
Get a Free Quote