Outlook OAuth Authentication
This article details the process of Outlook OAuth authentication in Invent ERP.
Step-by-Step Process
Step 1: Register an App in Microsoft Azure
- Go to Microsoft Azure and sign in.
- Navigate to Azure Active Directory → App registrations.
- Click Add → App registration.
- Fill in the Name field and choose a Supported Account Type.
Step 2: Configure Redirect URI
- In Invent ERP, go to Configuration → Settings → Technical → Mail Server → Mail Servers.
- Click Add, fill in the Mail Server Description.
- Choose Outlook OAuth Authentication under Authenticate Using.
- Enter your Outlook email as the Username.
- Copy the OAuth2 Redirect URL.
- Back in Azure, select Web as the platform and paste the redirect URL.
- Click Register.
Step 3: Add API Permissions
- In Azure, go to API Permissions → Add a permission → Microsoft Graph → Delegated Permissions.
- Search for and select SMTP.Send and IMAP.AccessAsUser.All.
- Click Add permissions.
Step 4: Assign Users
- Go to Overview → Managed Application in Local Directory → User and groups.
- Click Add user/group, search for and select the users who will send emails.
- Click Assign.
Step 5: Get Client ID and Client Secret
- From Overview, copy the Application ID as the Client ID.
- Go to Certificates & secrets → New client secret.
- Enter a description, set the expiration date, and click Add.
- Copy the Value as the Client Secret.
:::warning If the client secret expires, a new one must be created and configured to avoid service interruption. :::
Step 6: Finalize in Invent ERP
- Paste the Client ID and Client Secret in the Mail Server form.
- Click Create.
- Scroll down and click Connect Your Outlook Account.
- Accept any permissions request.
- Verify that Token Valid is displayed next to Connect Your Outlook Account.