Feature: Test the Microsoft 365 connection 

Description 

The connection test of the Microsoft 365 integration checks that Microsoft Entra ID answers, that it accepts the app registration, that the application may send mail and, when it may read users, that the sender mailbox exists. A refusal is reported with the error of Entra ID, and a missing permission names the permission. A permission granted a minute ago counts at once. A client secret past its expiry date is reported as expired without asking Microsoft.

Impact 

Admins see the result of each check when they switch the integration on or test it, and the integration shows as failing until the problem is fixed.