Grandstream IPPBX – Microsoft Outlook Authentication Guide

  • Updated on July 7, 2026

OVERVIEW

Grandstream IPPBX supports integration with Microsoft Outlook, allowing users to receive important email notifications directly from the PBX.

This guide describes setting up and configuring the authentication between Grandstream IPPBX and Microsoft 365, ensuring efficient and secure email communication using modern OAuth2 authentication.

This guide is divided into three parts, each performed in a different administrative portal:

  • Microsoft 365 Admin Center
  • Azure Portal / Microsoft Entra ID
  • Grandstream PBX Web UI

PREREQUISITES

Before starting, confirm the following:

  • A Microsoft account with global administrator permissions is available.
  • The global administrator account has been assigned a Microsoft Entra ID P1 or P2 license.
  • The email sending account that will be used by the PBX has an Exchange Online license.

This integration requires two separate Microsoft licenses that serve different purposes and must not be confused:

  • Microsoft Entra ID: Required for the administrator account performing the Azure app registration and authentication configuration. This is an identity and access management license only. It does NOT include email or mailbox functionality.
  • Exchange Online license: Required for the account that will be used to send emails from the PBX. This provides the actual mailbox and SMTP sending capability.

MICROSOFT 365 ADMIN CENTER SETUP

This part covers three tasks that must be completed before touching the Azure Portal:

  1. Enabling Modern Authentication
  2. Verifying licenses
  3. Enabling Authenticated SMTP on the sending account

Step 1: Enable Modern Authentication

Modern authentication is the foundation of the OAuth2 flow used in this guide. Without it, the authorization process will not work.

  1. Log in to the Microsoft 365 Admin Center using your global administrator account.
  2. In the left navigation menu, go to Settings → Org Settings.
  3. Under the Services tab, locate and click Modern Authentication.
Microsoft 365 admin center: left nav Settings > Org settings highlighted; main list shows services, Modern authentication selected.
Microsoft 365 Admin Center Org Settings
  1. In the Modern Authentication panel that appears, check the box for Turn on modern authentication for Outlook 2013 for Windows and later (recommended).
  2. Click Save.
Settings dialog 'Modern authentication' with a checked option to turn on modern authentication for Outlook 2013+; Save button visible.
Modern Authentication Configuration Tab

Step 2: Verify License Assignment

Before enabling Authenticated SMTP, confirm that the email sending account has the correct Exchange Online license assigned.

  1. In the left navigation menu, go to Users → Active Users.
  2. Locate and click on the account that will be used to send emails from the PBX.
  3. In the user details panel, click the Licenses and apps tab.
Microsoft 365 admin center: Active users list with a selected user named 'PBX Account' and its username pbx@g sdoc.onmicrosoft.com in the row. Right panel shows account licenses (Microsoft 365 Business Basic and Microsoft Entra ID P2).
User Details Panel Licenses and apps Tab
  1. Confirm that an Exchange Online license is listed and enabled. Acceptable licenses include:
    • Exchange Online Plan 1
    • Exchange Online Plan 2
    • Microsoft 365 Business Basic
    • Microsoft 365 Business Standard
    • Microsoft 365 Business Premium

Step 3: Enable Authenticated SMTP

This step grants the account permission to connect to Microsoft’s SMTP server and send emails on behalf of the PBX.

  1. On the same user account, click the Mail tab.
  2. Click Manage email apps.
Mailbox settings screen with Mail tab selected; 'Manage email apps' link highlighted below the list of mail options.
User Details Panel Mail Tab
  1. In the Manage email apps panel, check the box for Authenticated SMTP.
  2. Click Save changes.
Manage email apps settings: Authenticated SMTP is selected; click Save changes to apply.
Authenticated SMTP Checkbox

MICROSOFT ENTRA ID SETUP

This part registers the Grandstream PBX as an application in Microsoft Entra ID, grants it the necessary permissions to send email, and generates the credentials the PBX will use to authenticate.

Step 1: Register the Application in Microsoft Entra ID

  1. Log in to the Azure Portal using your global administrator account.
  2. In the top search bar, search for and select Microsoft Entra ID.
Screenshot of the Microsoft Azure portal homepage with a search dropdown open, showing Microsoft Entra ID highlighted in the results.
Azure Portal Search Bar with Microsoft Entra ID
  1. In the left navigation of the Microsoft Entra ID page, click App registrations, then click New registration.
Azure portal: App registrations page (GSDOC) with the "New registration" button highlighted, ready to create a new app.
App Registrations Page
  1. On the Register an application page, fill in the following fields:

Field

Value

Name

Enter a display name for the application (e.g. “Grandstream UCM”)

Supported account types

Select Accounts in this organization’s directory only.

Redirect URI

Select Web from the platform dropdown and enter the Redirect URI (see note below).

Redirect URI

The Redirect URI is a landing page where Microsoft sends your browser after a successful login, with the authorization code appended to the URL as a parameter.

You will manually copy this authorization code from the browser and paste it into the PBX. The Redirect URI you enter here in Azure must exactly match the URI you later enter in the PBX Email Settings.

  • Recommended URI: Use Grandstream’s dedicated OAuth landing page (https://ucm.grandstream.com/googleoauth/). After login, this page automatically extracts and displays the authorization code for easy copying.
  • Alternative URIs: Any HTTPS URL can be used (https://example.grandstream.com). After login, Microsoft redirects your browser to that page with the code in the URL. You will need to manually copy it from the address bar. See [Step 3: Get the Authorization Code] section for detailed instructions on extracting the code.

Azure portal: Register an application form showing Name, account type, and Redirect URI sections.
Register an Application Page
  1. Click Register.
  2. After registration is complete, you will be taken to the application overview page. Note down the following values as you will need them in Part 3:
    • Application (Client) ID
    • Directory (Tenant) ID
Azure App registrations: Grandstream UCM with client ID and tenant ID shown
Application Overview Page

Step 2: Assign API Permissions

  1. In the left navigation of the application page, click API permissions, then click Add a permission.
Azure portal: Grandstream UCM API permissions page with a highlighted Add a permission button on the Configured permissions section.
API Permissions Page
  1. In the Request API permissions panel, click APIs my organization uses, then search for and select Office 365 Exchange Online.
Dialog to request API permissions; shows a list of Office 365 apps with Exchange Online highlighted in red.
Request API Permissions Panel
  1. Select Application permissions.
  2. In the permissions list, search for SMTP and expand the SMTP section. Check SMTP.SendAsApp.
Dialog to request API permissions for Office 365 Exchange Online, highlighting Application permissions and SMTP.SendAsApp.
SMTPSendAsApp Permission
  1. Click Add permissions.

This step requires you to be logged in to the Azure Portal with a global administrator account. If the account currently logged in is not a global administrator, log out and sign back in with the correct account, or contact your organization’s global administrator to complete this step on your behalf

  1. Back on the API permissions page, click Grant admin consent for [your organization name].
  2. Click Yes to confirm.
Azure portal Grandstream UCM API permissions page with grant admin consent confirmation dialog for GSDOC.
Grant Admin Consent for API Permission
  1. After granting consent, the status column for SMTP.SendAsApp should show a green checkmark indicating “Granted for [organization]”.
Screenshot of a permissions configuration page showing two API permissions: Microsoft Graph User.Read (Delegated) with sign-in access, Granted for GSDOC; and Office 365 Exchange Online SMTP.SendAsApp (Application) with SMTP access, Admin consent Yes, Granted for GSDOC.
Admin Consent Granted Successfully

Step 4: Create a Client Secret

  1. In the left navigation of the application page, click Certificates & secrets, then click New client secret.
Azure portal: Grandstream UCM, Certificates & secrets page with the "+ New client secret" action available.
Certificates Secrets Page
  1. In the Add a client secret panel, fill in the following:

Field

Value

Description

Enter a description label (e.g. “Grandstream UCM Outlook”)

Expires

Select an expiration period (recommended: 180 days/6 months)

Dialog: Add a client secret. Description shows 'Grandstream UCM Outlook'; expiration set to 180 days; buttons Add and Cancel at the bottom.
Add a Client Secret Panel
  1. Click Add.
  2. The new client secret will appear in the list. Copy the value shown in the “Value” column and store it securely.
Note:

This value is only displayed in full immediately after creation. Once you navigate away from this page, the value will be permanently hidden and cannot be retrieved. If lost, you must create a new client secret.

Azure portal: Grandstream UCM Certificates & secrets page; Client secrets tab shows one secret (Grandstream UCM Outlook), expires 12/27/2026, Secret ID visible.
Client Secret Created

GRANDSTREAM PBX CONFIGURATION

This part enters all the credentials gathered into the PBX, completes the OAuth authorization flow, and verifies the configuration with a test email.

Step 1: Configure Email Settings

  1. Log in to the PBX Web UI.
  2. Navigate to System Settings → Email Settings.
  3. In the Mail Server Providers drop-down, select Microsoft.
Screenshot of UCM6302 Email Settings page showing SMTP details and a drop-down with Microsoft selected in the Mail Server Providers menu on the right; left navigation highlights Email Settings.
PBX Web UI System Settings → Email Settings page
  1. The Server Authorization section will appear showing that authentication is incomplete. Click De-authorization to open the Microsoft Server Licensing configuration dialog.

Step 2: Enter Authorization Information

In the Microsoft Server Licensing dialog, fill in the following fields:

Field

Value

Redirect URIs

The exact same URI registered in Microsoft Entra ID Setup, Step 1 (e.g. https://ucm.grandstream.com/googleoauth/)

Tenant ID

The Directory (Tenant) ID from the Azure application overview page

Username

The Microsoft 365 email address of the sending account that was configured in Microsoft 365 Admin Center Setup

The Application (Client) ID

The Application (Client) ID from the Azure application overview page

The client password

The client secret Value copied in Step 4 (Create a Client Secret)

Microsoft Server Licensing Dialog
Note:

The Redirect URI entered here must be identical to the one registered in Azure. Any mismatch including an extra slash will cause the authorization to fail.

Step 3: Get the Authorization Code

Once the information is correctly entered, please follow the steps below to complete the authorization flow:

  1. Click Get Authorization Code.
  2. A new browser window or tab will open and redirect you to Microsoft’s login page.
  3. Sign in using the email sending account (the Microsoft 365 account configured).
Microsoft sign-in dialog with email field and blue Next button on a light backdrop; 'Sign in' header and options below
Microsoft Login Page
  1. After successfully signing in, Microsoft will redirect your browser to the Redirect URI you configured. What you see next depends on which Redirect URI you used:

If you used the Grandstream redirect URI (https://ucm.grandstream.com/googleoauth/): The page will display the authorization code directly on screen in a text box, ready to copy.

Authorization Code heading with a long string of unreadable characters beneath it.
Grandstream OAuth Page Displaying the Authorization Code

If you used any other HTTPS URI (e.g. https://your.example.com): Your browser will land on that page. Copy the link from the browser’s address bar the full URL will look like this:

https://your.example.com/?code=1.AXoAxL12e1BK0Emw...LONGCODE...&state=GrandStream&session_state=xxxxx

Copy only the value that starts after code= and ends before &state=. This is your authorization code. Do not include &state= or anything after it.

If the page shows an error or “Server Not Found”: This is expected if your Redirect URI points to a non-existent page. The authorization code is still present in the browser address bar. Copy the value as described above.

Step 4: Complete Authorization

  1. Paste the copied authorization code into the Authorization Code field in the PBX dialog.
Microsoft Server Licensing authorization dialog requesting an authorization code; the blue 'Authorization' button is highlighted at the bottom.
Code Pasted Into The Authorization Code Field
  1. Click Authorization.
  2. Click Save, then click Apply Changes for the configuration to take effect.

After completing authorization, the Email Settings page will show the authorized Microsoft account under Server Authorization.

Admin panel Email Settings page showing server authorization with Authorized Account: pbx@gsdoc.onmicrosoft.com highlighted; delivery settings include HTML format and Display Name: PBX.
Email Settings Page Showing the Authorized Account

Step 5: Send a Test Email

  1. On the Email Settings page, click Test.
  2. In the Test dialog, enter a recipient email address in the Receive Email field.
  3. Click Test.
Screen of Email Settings page showing a Test dialog; the test email field is highlighted in red with a sample address entered (testuser@grandstream.com).
Test Email Dialog with a Recipient Address
  1. Check the recipient inbox to confirm the email was received. The sender will appear as your Microsoft sending account.
Email preview titled 'UCM email test' from PBX with body 'This is a test email.' and three buttons: 'It works!', 'Got it!', 'Success!'
Test Email Received in Inbox

SUPPORTED MODELS

Supported Devices

Firmware version

SoftwareUCM

1.0.27.18+

UCM6300/A Series

1.0.27.20+

CloudUCM

1.0.29.7+


Was this article helpful?

Related Articles

Need Support?
Can’t find the answer you’re looking for? Don’t worry we’re here to help!
Contact Support