Unify Integrations
Logo
Connection setup

Connection setup

Logo

10 mins READ

The Microsoft Outlook connector supports the following authentication types:

  • Authorization code grant authentication (OAuth 2.0)

  • Authorization code grant authentication with custom credentials (OAuth 2.0)

  • Authorization code grant authentication, public client (OAuth 2.0 with PKCE)

  • Client credentials-based authentication (OAuth 2.0): app-only access

  • Client certificate credentials-based authentication: app-only access

Authentication type

Runs as

Use when

OAuth 2.0 (Authorization)

The signed-in user

You want to connect one mailbox quickly. No Azure access is needed.

OAuth 2.0 (Authorization) With Custom Credentials

The signed-in user

Your organization requires its own app registration, and a client secret is acceptable.

OAuth 2.0 (Authorization – Public client)

The signed-in user

Your organization requires its own app registration, but a client secret isn't allowed or desired.

OAuth 2.0 (Client Credentials)

The app itself

You need backend automation across mailboxes with nobody signed in, for example a shared support inbox.

Client certificate credentials with config

The app itself

Same as Client Credentials, but your security policy disallows client secrets.

Common fields: every connection needs a Connection name, for example MyAppOutlookIntegration. Leave Connection on Directly unless UnifyApps must reach Microsoft Graph through an on-premises agent; in that case choose Via On-Prem Agent and select an On-Prem Group. Tenant ID is optional on every type except Client certificate credentials with config, where it is required. If you leave it blank, common is used, which lets users of any organization sign in.

Authorization code grant authentication (OAuth 2.0)

Use this method to connect with your own Microsoft account without registering an app in Azure.

This authentication method uses the following field for tenant-specific account types:

  • Tenant ID/Domain (optional)

Minimum and default scopes

Select the scopes based on the actions and triggers you plan to use. The Scopes reference at the end of this section lists the scope each action and trigger needs. offline_access is always added automatically so the connection can refresh its token.

The following minimum scopes are required to establish a connection using authorization code grant authentication:

  • User.Read

  • offline_access

  • Mail.Read (or Mail.ReadWrite), because the connection is validated by listing messages

Connect to Microsoft Outlook with authorization code grant authentication

Complete the following steps to connect to Microsoft Outlook:

  1. Enter a Connection name.

  2. Select OAuth 2.0 (Authorization) as the Authentication type.

  3. Leave Tenant ID blank (common), or enter your tenant ID to restrict sign-in to one organization.

  4. Select the Scopes the connection needs.

  5. Keep Delegated scopes turned on, so actions run as the signed-in user.

  6. Click Authorize. You are redirected to the Microsoft sign-in page.

  7. Sign in with the Microsoft account whose mailbox the connection should use.

  8. Review the permissions requested on the consent screen and click Accept.

  9. You are redirected back to UnifyApps with a confirmation that the account is connected.

Authorization code grant authentication with custom credentials (OAuth 2.0)

Use this method when your organization wants the connection to use its own Azure app registration, while actions still run on behalf of a signed-in user.

This authentication method requires the following fields:

  • Client ID

  • Client secret

  • Tenant ID (use your Directory (tenant) ID for a single-tenant app; leave blank only for a multitenant app)

Minimum and default scopes

Select the same scopes in UnifyApps that you add as Delegated permissions in the Azure portal. The minimum scopes are the same as for authorization code grant authentication: User.Read, offline_access and Mail.Read (or Mail.ReadWrite).

Microsoft Outlook setup for custom credentials

Complete the following steps to set up Microsoft Outlook:

  • Register the app in the Azure portal

  • Assign permissions to your app

  • Generate a client secret

  • Obtain the Application (client) ID and Directory (tenant) ID from the Azure portal

Register the app in the Azure portal

  1. Log in to the Azure portal, search for App registrations and click New registration.

  2. Enter a name and choose the supported account type: single tenant (only your organization) or multitenant (any Microsoft Entra ID tenant).

  3. Under Redirect URI, choose platform Web and paste the Callback URL shown at the top of the connection form. It is copyable and differs per environment.

  4. Click Register.

Register an application form with the app name, supported account type and redirect URI
Register an application form with the app name, supported account type and redirect URI

Obtain the Application (client) ID and Directory (tenant) ID

  1. On the Overview tab of the registered app, copy the Application (client) ID.

  2. Copy the Directory (tenant) ID.

Assign permissions to your app

  1. Go to API permissions → Add a permission → Microsoft Graph → Delegated permissions.

  2. Add offline_access and the permissions the connection needs, for example Mail.Read and Mail.Send.

  3. Click Grant admin consent if your tenant requires it.

API permissions page with the delegated Microsoft Graph permissions for the app
API permissions page with the delegated Microsoft Graph permissions for the app

Generate a client secret

  1. Go to Certificates & secrets → New client secret.

  2. Add a description and expiry, and click Add.

  3. Copy the secret Value immediately and store it securely. It is not shown again.

Connect to Microsoft Outlook with custom credentials

  1. Open Connections → New Connection → Microsoft Outlook and enter a Connection name.

  2. Select OAuth 2.0 (Authorization) With Custom Credentials as the Authentication type.

  3. Enter the Client ID and Client secret copied from Azure.

  4. Enter the Tenant ID.

  5. Select the same Scopes you added as delegated permissions in Azure.

  6. Keep Delegated scopes turned on.

  7. Click Authorize, sign in with Microsoft and accept the consent screen.

  8. Confirm the success message after the redirect back to UnifyApps.

Authorization code grant authentication, public client (OAuth 2.0 with PKCE)

Use this method when your organization requires its own Azure app registration, but you'd rather not manage a client secret. The connection uses the OAuth authorization code flow with PKCE, so only a Client ID is needed. No secret is entered, stored, or sent anywhere. Actions run on behalf of a signed-in user.

This authentication method requires the following fields:

  • Client ID

  • Tenant ID (optional)

Minimum and default scopes

The minimum scopes are User.Read, offline_access and Mail.Read (or Mail.ReadWrite). PKCE and offline_access are used automatically, so a refresh token is issued without a client secret.

Microsoft Outlook setup for public client

  • Register the app in the Azure portal

  • Configure the redirect URI and enable public client flows

Register the app in the Azure portal

  1. Log in to the Azure portal, search for App registrations and click New registration.

  2. Register the app and open it.

Configure the redirect URI and enable public client flows

  1. Go to Authentication.

  2. Add the Callback URL shown at the top of the connection form as a redirect URI, under Mobile and desktop applications. Do not use Web or Single-page application.

  3. Set Allow public client flows to Yes.

Authentication page with the Redirect URI configuration, showing Mobile and desktop applications
Authentication page with the Redirect URI configuration, showing Mobile and desktop applications

Authentication page Settings tab with Allow public client flows enabled
Authentication page Settings tab with Allow public client flows enabled

Connect to Microsoft Outlook with public client authentication

  1. Select OAuth 2.0 (Authorization – Public client) as the Authentication type.

  2. Enter the Application (client) ID from Azure as the Client ID. Leave Tenant ID blank (common), or enter it to restrict sign-in to one organization.

  3. Select the Scopes the connection needs.

  4. Click Authorize and sign in.

Limitation: this authentication type is user-delegated only. For app-only access, or access to another user's mailbox, use client credentials-based authentication or client certificate credentials-based authentication instead.

Client credentials-based authentication (OAuth 2.0)

Use this method for app-only access that does not depend on a signed-in user, for example a workflow that reads a shared support mailbox. The app acts as itself with Application permissions, and needs admin consent.

This method requires the following fields:

  • Tenant ID (use your actual tenant ID; the default common is meant for sign-in based flows)

  • Client ID

  • Client secret

  • Run-time user (optional): the email address of the mailbox the connection acts on. If you leave it blank, actions use the mailbox given in the action, or the mailbox of the UnifyApps user who runs it.

Minimum and default scopes

Select the Application permissions that match the actions and triggers you plan to use, for example Mail.Read and Mail.Send. You must assign these permissions to the app as Application permissions in the Azure portal. The following minimum scope is required to establish a connection with client credentials-based authentication:

  • Mail.Read

Note: Application permissions such as Mail.Read let the app read every mailbox in the organization. To limit the app to specific mailboxes, an Exchange administrator can use RBAC for Applications in Exchange Online.

Microsoft Outlook setup for client credentials-based authentication

Complete the following steps to set up Microsoft Outlook:

  • Register the app in the Azure portal

  • Assign permissions to your app

  • Generate a client secret

  • Obtain the Application (client) ID and Directory (tenant) ID from the Azure portal

Register the app in the Azure portal

  1. Log in to the Azure portal, search for App registrations and click New registration.

  2. Enter a name and supported account type, and click Register. No redirect URI is needed for this flow.

Obtain the Application (client) ID and Directory (tenant) ID

  1. From Overview, copy the Application (client) ID.

  2. Copy the Directory (tenant) ID.

Assign permissions to your app

  1. Go to API permissions → Add a permission → Microsoft Graph → Application permissions.

  2. Add the permissions the connection needs, for example Mail.Read and Mail.Send.

  3. Click Grant admin consent. Application permissions do not work until an administrator grants consent.

API permissions page showing Mail.Read as an application permission
API permissions page showing Mail.Read as an application permission

Generate a client secret

  1. Go to Certificates & secrets → New client secret.

  2. Click Add, and copy the secret Value immediately.

Connect to Microsoft Outlook with client credentials-based authentication

  1. Select OAuth 2.0 (Client Credentials) as the Authentication type.

  2. Enter the Client ID and Client secret.

  3. Enter the Tenant ID.

  4. Enter the Run-time user, if needed.

  5. Turn off Delegated scopes (it is on by default). With app-only access there is no signed-in user to act as.

  6. Click Test Connection to validate the credentials, then click Create.

Client certificate credentials-based authentication

Use this method for app-only access like client credentials-based authentication, but with a certificate instead of a client secret. Microsoft recommends certificates over client secrets for production.

This method requires the following fields:

  • Tenant ID (required)

  • Client ID

  • Thumbprint

  • Private key

Minimum and default scopes

Assign the permissions as Application permissions in the Azure portal. The minimum scope is Mail.Read, the same as for client credentials-based authentication.

Microsoft Outlook setup for client certificate credentials-based authentication

Complete the following steps to set up Microsoft Outlook:

  • Register the app in the Azure portal

  • Assign permissions to your app

  • Generate a certificate and upload it

  • Obtain the Application (client) ID and Directory (tenant) ID from the Azure portal

Register the app in the Azure portal

  1. Log in to the Azure portal, search for App registrations and click New registration.

  2. Enter a name and supported account type, and click Register. No redirect URI is needed.

  3. From Overview, copy the Application (client) ID and Directory (tenant) ID.

Assign permissions to your app

  1. Go to API permissions → Add a permission → Microsoft Graph → Application permissions.

  2. Add the permissions the connection needs, and click Grant admin consent.

Generate a certificate and upload it

  1. Have a certificate ready as a .cer, .pem or .crt file, together with its private key in PEM format. You can generate a key pair from the terminal:

openssl genrsa -out private.key 2048
openssl req -new -x509 -key private.key -out certificate.crt -days 365

  1. Go to Certificates & secrets → Certificates → Upload certificate, select the certificate file and click Add.

  2. Copy the certificate's Thumbprint from the list.

Connect to Microsoft Outlook with client certificate credentials-based authentication

  1. Select Client certificate credentials with config as the Authentication type.

  2. Enter the Client ID and the Tenant ID (both required).

  3. Enter the Thumbprint copied from Azure. The hex value shown in the Azure portal, with or without colons, or a base64url value is accepted.

  4. Paste the Private key that belongs to the uploaded certificate.

  5. Leave Delegated scopes turned off (the default for this type). Actions use the mailbox given in the action, or the mailbox of the UnifyApps user who runs it.

  6. Click Test Connection to validate the credentials, then click Create.

Scopes reference

Every additional scope widens what the connection can access. The Actions and Triggers sections below show the exact scope each one needs.

Tier

Scope

Needed for

Mandatory

User.Read

Sign-in and connection health checks. Every sign-in (delegated) connection needs this.

Mandatory

offline_access

Keeps the connection alive without reauthorizing. Added automatically.

Mandatory

Mail.Read

List, search and read messages, attachments and folders.

Mail

Mail.ReadWrite

Move, update, delete or send messages, or manage folders.

Mail

Mail.Send

Send, reply to, or forward email.

Mail

MailboxSettings.Read

Read mailbox automatic-reply and timezone settings.

Contacts

Contacts.ReadWrite

Create, update, delete or search contacts.

Tasks

Tasks.ReadWrite

Outlook Tasks actions and triggers.

Sensitive (org-wide)

User.ReadBasic.All / Directory.Read.All

Look up other users and groups, for example shared mailbox or people-picker actions.

Sensitive (org-wide)

Group.Read.All

Group-membership based actions and triggers only.

App-only connections (client credentials and client certificate) use Application permissions instead of the delegated scopes above. These can have different names; the Actions and Triggers sections show the Application-permission name of each one.

Required to create the connection: clicking Authorize (sign-in based types) or Test Connection (client credentials, client certificate) validates the connection by listing messages. Mail.Read (or Mail.ReadWrite) must be included in your selected scopes even if the actions you plan to use need only a narrower scope. Without it, the connection fails to validate even when sign-in or the credentials themselves are correct.