Sending emails using a Microsoft Cloud Services application was introduced in Lansweeper 8.3. If you are using an older Lansweeper release, you will need to update by following the instructions in this knowledge base article
Using Lansweeper it's possible to send emails in the context of both the helpdesk module and to send report and event alerts. Since Lansweeper 8.3, O365 with modern authentication is supported as a mail provider. To do this a Microsoft Cloud Services application is required. This article explains what is required to set this up, which permissions to add to your Microsoft Cloud Services application and how to configure your email account in the helpdesk email configuration or email alert configuration.
To use an O365 email account to send or receive emails in Lansweeper, make sure that:
Adding permissions to the Microsoft Graph application to send and receive emails
Step 1: API permissions in the Azure Portal
Open your companies' Azure portal, navigate to app registration and click on the
tab in the left-hand menu.
On the API permissions page, click on the
button and select the
from the API list.
As we are setting up the Graph API to enforce modern authentication, you will need to add Application permissions. Therefore, click the
Add the API permissions listed in the table below. These are all required to send and receive emails.
Read and write mail in all mailboxes
Send mail as any user
Read all users' full profiles
Once the permissions are added, click the
save button on the bottom of the page and double-check that the permissions that are listed.
Step 2: Grant admin consent
The permissions are added but admin consent must still be granted. To do this, click the button
Grant admin consent for <organization> and click the
Grant button in the resulting pop-up. All added permissions should now show
Granted for <organization>
By default, when using the settings above, your application will have access to all mailboxes
in your O365 tenant. You can restrict this further by configuring "ApplicationAccessPolicy".
How to configure your email account in the helpdesk email configuration
Configuration\Email Settings and click the
add E-mail account button. You can also change an existing configuration by hitting the
edit button. Fill out DisplayName and E-mail address in the General Settings tab.
The email address entered in the General Settings tab will be the email address used for sending and receiving email.
Last, click on the outgoing tab and select the Microsoft Graph (REST API) as protocol. Fill out the
Tenant ID, and
Client Secret, and click the
OK button to save your helpdesk email account.
The Client Secret entered in the Incoming and Outgoing tabs should contain the Secret Value and not the Secret ID.
How to configure your email account to send Email Alerts
Configuration\Email Alerts and select the Microsoft Graph (REST API) protocol in the E-mail Server section. Fill in the
Tenant ID, and
Client Secret. These values can be gathered when creating the Microsoft Cloud Services application.
The email address entered in the
From address field will be used to send the Email alerts.