Introduction
In order for Gravity SMTP to send messages from your Microsoft 365 / Outlook account, you will need to create an application in Azure Portal and provide the plugin with a token. You must complete this step before configuring the Microsoft 365 / Outlook Integration within Gravity SMTP. This article outlines steps for creating a web app in your Azure Portal.
Prerequisites
- A Microsoft Azure account with a valid subscription.
- A Microsoft-based email address with email-sending permissions (Hotmail, Live, Outlook, Microsoft 365).
Step 1: Create an Azure Account
- Visit Azure Portal: Open your browser and go to Azure Portal.
- Sign In or Create an Account: If you have an existing Microsoft email account, log in with your credentials. If you need to create a new account, sign up for a free Microsoft Azure account here.
Step 2: Create an Application ID
- Open Azure Portal: Once logged in, navigate to your Azure Portal if not automatically redirected.
- Search for App Registrations: In the search bar at the top of the page, type “App registrations”.
- Create a New Registration: Click on “+ New registration” at the top of the App Registrations page.
- Fill Out the Registration Form: Complete registration according to account type (personal or school/work).
- Name: Enter a name like “Gravity SMTP” for your organization.
- Supported Account Types: If app is being created with a Personal Account, then select “Accounts in any organizational directory (Any Microsoft Entra ID tenant – Multitenant) and personal Microsoft accounts (e.g. Skype, Xbox)”. If creating with a School or Work Account, select “Accounts in any organizational directory (Any Microsoft Entra ID tenant – Multitenant)”.
- Redirect URI: For the first dropdown, set to “Web”. For the second field, copy/paste the value from your Gravity SMTP settings (found under the Outlook / 365 section in the Redirect URI field). Be sure to use the Redirect URI specific to your account type.
- Register the Application: Click “Register” to proceed.
- Verify Settings: After registration, go to the “Authentication” tab to double-check the “Supported account types” and “Redirect URI”. Ensure these are correctly configured.
Step 3: Copy Application (Client) ID
- Navigate to Overview: After registration, you’ll be redirected to the Overview page.
- Copy Application ID: Find and copy your Application (client) ID from the Overview page. You will need this value later for the Gravity SMTP settings in the Application ID field.
Step 4: Create an Application Password
- Navigate to Certificates & Secrets: In the left sidebar, click on “Certificates & secrets”.
- Create a New Client Secret: Click on “+ New client secret”.
- Fill out the form with the following details:
- Description: Enter a logical name like “app_password”.
- Expires: Select “365 days (12 months)”.
- Add: Click the Add button to save the description and expiration
- Get Your Application Password:
- Copy the password from the “Value” column (not the Secret ID column).
- Store this value securely, as it will not be accessible after you leave the page. You will need this value later for the Gravity SMTP settings in the Client Secret field.
Supported Account Types
When configuring an app to connect with Gravity SMTP, you must choose either personal accounts or work/school accounts.
Gravity SMTP does not support handling both at the same time. In order to ensure the app is configured for use by work/school accounts, follow these steps:
- Go to Manage → Manifest in the app.
- Find the
signInAudience
property and change it toAzureADMultipleOrgs
. - Save the Manifest.
- Return to the Authentication section and ensure that the Supported account types is set to “Accounts in any organizational directory (Any Microsoft Entra ID tenant – Multitenant).”
- Add the associated Redirect URI (with query string parameters) from Gravity SMTP into the app again.
API & Permission
The following APIs and Permissions must be enabled in the App