---
title: "Register Purview Sync with Azure"
feature: "Purview Sync"
audience: ["end user", "developer", "system analyst", "system administrator", "system engineer"]
version: "Relativity aiR"
type: ["User Guide", "Tutorial"]
url: "https://help.relativity.com/RelativityaiR/Content/Relativity/Purview_Sync/Register.htm"
lastModified: "2026-11-20"
---

# Register Purview Sync with Azure

Purview Sync uses two Microsoft APIs, and each needs its own delegated permission:

- Microsoft Graph — eDiscovery.ReadWrite.All. Purview Sync uses Microsoft Graph to list eDiscovery cases, review sets, and searches in the job wizard, to create the export, and to check the export status.
- MicrosoftPurviewEDiscovery — eDiscovery.Download.Read. Purview Sync uses this service to download the exported files.

For why Purview Sync needs these permissions, see [Permissions](https://help.relativity.com/RelativityaiR/Content/Relativity/Purview_Sync/Purview_sync.md#Permissi).

For more information on Microsoft Graph API, see [Microsoft's documentation](https://learn.microsoft.com/en-us/graph/use-the-api).

> **Note:** This documentation contains references to third-party software, or technologies. While efforts are made to keep third-party references updated, the images, documentation, or guidance in this topic may not accurately represent the current behavior or user interfaces of the third-party software. For more considerations regarding third-party software, such as copyright and ownership, see [Terms of Use](https://www.relativity.com/terms-of-use/).

To connect Purview Sync to Microsoft, you must register an application in Azure Active Directory and grant the required permissions. An Azure user with administrator rights must complete this configuration.

> **Note:** Before you begin, open a text editor or Word document. You will copy and paste several values during this process and will need them later when configuring Purview Sync in Relativity aiR.

There are two ways to register Purview Sync application with Azure:

- **Automated script**—run a PowerShell script as an Azure administrator. This script will create the app registration and configure all required permissions automatically.
- **Manual setup**—sign in to the Azure portal as an administrator and complete the app registration manually, including assigning the necessary permissions.

> **Note:** The person completing the application registration process must be an Azure Administrator with sufficient privileges. Refer to [Microsoft’s documentation](https://learn.microsoft.com/en-us/partner-center/enroll/become-global-admin) for more details.

When registering the Purview Sync app in Azure:

- **Authority URI**—specifies the Microsoft tenant that handles authentication. It ensures sign-in is processed by your organization’s trusted identity provider—Microsoft Entra ID.
- **Redirect URI**—defines the secure endpoint where Microsoft sends the authentication response after sign-in. This allows Purview Sync to receive authorization tokens and complete the login process.

After completing the app registration process, whether automated or manual, collect the final values required for configuring Relativity aiR Purview Sync. Store these values securely for future use.

The following are examples of those values:

- **Client ID:** 1234567890abcdef1234567890abcdef
- **Authority URI:** https://login.microsoftonline.com/abcdef1234567890ab1234567890abcd
- **Redirect URI:** https://kcura.relativity.one/Relativity/CustomPages/4985c522-5931-41ba-bf67-7d58ee96e6d1/index.html
- **Client Secret:** w7X...\<onlyshownonce>...

## Automate Purview Sync registration in Azure Active Directory with a script

You can automate your Purview Sync registration in Azure Active Directory using the provided PowerShell script: [PvS-MSFT-Automation-Script.ps1](https://help.relativity.com/RelativityaiR/Content/Relativity/Purview_Sync/PvS-MSFT-Automation-Script.ps1). After you run the script, the registration process will complete automatically.

If your organization restricts script execution, check with your IT or security team before running the script.

### Requirements

Before running the script, confirm you have the following:

- Azure AD Global Administrator.
- PowerShell 5.1 or later with an execution policy that allows local scripts
- Internet access to login.microsoftonline.com and graph.microsoft.com.
- Install-module privileges. The script auto-installs Microsoft.Graph modules if missing.

### Automate the registration

To register the app with the PowerShell script, follow the steps:

1. Download the [PvS-MSFT-Automation-Script.ps1](https://help.relativity.com/RelativityaiR/Content/Relativity/Purview_Sync/PvS-MSFT-Automation-Script.ps1) file.
2. Open PowerShell Window.
3. Run the following command. Change *TenantRoot* to your Relativity instance name and AppName to the name you want to use for the Azure App Registration.  
   .\\PvS-MSFT-Automation-Script.ps1 -TenantRoot "https://kcura.relativity.one" -AppName "RelativityOne Purview Sync"
4. After the script is run, copy the values from the PowerShell output to a safe location. You will need them to configure Purview Sync in Relativity aiR later.

![PowerShell script for Purview Sync registration with Azure.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_AutomatedRegistrationWithAzureScript.png "Click to expand.")

For more details, refer to the Community article [Relativity aiR - Purview Sync: Azure Active Directory Registration Script](https://community.relativity.com/s/article/RelativityOne---Purview-Sync).

## Register an Azure application and credentials manually

Complete the steps in this section to create an app registration for email integration and syncing with Microsoft Entra ID.

To generate your Application (Client) ID and Client Secret, you must have Application Administrator privileges to sign in to the Azure portal and register the application. Store the Application ID and Client Secret securely. You will need them in Relativity aiR.

To register your app:

1. Open your [Azure Portal](https://portal.azure.com/).
2. Click **Microsoft Entra ID**.  
   Alternatively, search for *Microsoft Entra ID* using the search bar on top of the page.  
   ![Microsoft Entra ID in Azure Portal.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_AzureServices.png "Click to expand.")
3. In the left-navigation menu, select **App registrations**.
4. Click **New Registration**.  
   This will open the Register an application page.  
   ![Navigate to the App Registrations page and click New registration.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_AppRegistration.png "Click to expand.")
5. Enter an application name in the **Name** field. For example, *Relativity aiR Purview Sync*.
6. Select **Accounts in this organizational directory only - Single tenant** as the supported account type.
7. In the *Redirct URI* section, select **Single-page application (SPA)** from the drop-down menu.
8. In the **Redirect URI field**, enter *https://\[RelativityOne URL* up to the word relativity forward slash\] + *CustomPages/ 4985c522-5931-41ba-bf67- 7d58ee96e6d1/index.html* for the Redirect URI field.  
   For example, *https://company.relativity.one/Relativity/CustomPages/4985c522-5931-41ba-bf67-7d58ee96e6d1/index.html*.

   > **Note:** You add this index.html URI to the Single-page application section in Azure. Later, in the Authentication section, you add the ms-auth-popup-redirect.html URI to the same section. When you finish both sections, both URIs appear under Single-page application in Azure. You also enter this index.html URI in the Redirect URI field when you set up Purview Sync in Relativity aiR.
9. Click **Register**.

When you complete the application registration, take note of the Application (client) ID field and Directory (tenant) ID field. These will be later used in Relativity.

![The Application ID and Directory ID.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_Essentials.png "Click to expand.")

For more information on registering an application in Azure, see [Microsoft's documentation](https://docs.microsoft.com/en-us/azure/active-directory/develop/quickstart-register-app) or [Microsoft's authentication documentation](https://docs.microsoft.com/en-us/exchange/client-developer/exchange-web-services/how-to-authenticate-an-ews-application-by-using-oauth).

### Add authentication URIs

For authentication, you must add two redirect URIs. Each URI must go in a specific section in Azure. Placing a URI in the wrong section causes authentication to fail.

- **Single-page application**—ms-auth-pop-redirect.html URI
- **Web**—auth-response URI

To add a redirect URI:

1. Select **Authentication (Preview)** from the left-side menu.  
   ![The Authentication (Preview) tab under Manage.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_Authentication_Preview_Tab.png)
2. Locate the **Single-page application** box and select **Add URI**.
   - This is the same section where your index.html URI from registration already appears.
   - Do not use the Web section for this step.

   > **Note:** The *ms-auth-popup-redirect.html URI* must go in the Single-page application section, not the Web section. Placing it in the wrong section causes authentication to fail.
3. In the new **Redirect URI** field, enter the ms-auth-popup-redirect.html URI using this pattern:  
   *https://\[RelativityOne URL* up to the word relativity forward slash\] + *CustomPages/ 4985c522-5931-41ba-bf67-7d58ee96e6d1/ms-auth-popup-redirect.html*.  
   For example, *https://company.relativity.one/Relativity/CustomPages/4985c522-5931-41ba-bf67-7d58ee96e6d1/ms-auth-popup-redirect.html*.
4. Under *Web*, select **Add URI**.
   - This is a separate section from Single-page application.
   - The auth-response URI goes here only.

   > **Notes:** If you do not see the Web box, you need to create a new platform. Select **Add Redirect URI** and then select **Web platform**. Then, continue to step 5.

   ![The Web box and Add Redirect URI link.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_WebPlatformBox.png)
5. In the **Redirect URI** field, enter:  
   *https://\[RelativityOne URL* without including the word relativity forward slash\] *+ purview-sync-services/api/v1/AppConfiguration/auth-response*.  
   For example, *https://company.relativity.one/purview-sync-services/api/v1/AppConfiguration/auth-response*.  
   ![The Redirect URI field and Configure button.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_RedirectURIField.png)
6. Click **Save**.  
   Exemplary added URIs look as follows.  
   ![The added redirect URIs.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_AddedRedirectURIs.png)
7. If you plan to use the same app registration on another tenant, add another two corresponding redirect URIs, Single-page URI and Web URI, for that tenant in this section.  
   ![Adding additional redirect URIs.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_AdditionalRedirectURIs.png)

After saving, confirm Azure lists the following redirect URIs. If a URI is in the wrong section, authentication will fail.

- **Single-page application**—index.html URI and ms-auth-popup-redirect.html URI
- **Web**—auth-response URI

If a URI is missing or listed under the wrong platform type, select **Add URI** in the correct section and re-enter the value before proceeding.

### Create a client secret

You need a client secret to integrate Microsoft and Relativity aiR.

To create a client secret:

1. In the left-navigation menu, click **Certificates & secrets**.
2. Select to the **Client secrets** tab.
3. Click the **New Client Secret** button.

   > **Note:** Do not navigate away from the page once the client secret is created.
4. Populate the **Description** and **Expires** fields.  
   You can leave the default, or recommended, values.
5. Click the **Add** button.  
   If the client secret was successfully created, Microsoft will display the Client Secret on the table and the Value field in plain text.
6. Copy the **Value** field and securely store it.

Microsoft hides the Value field if you leave the page and then come back to get the value. At this point, you cannot copy it.

You can repeat steps 3-5 to generate a new client secret.

### Set API permissions

Open the application to view the application's homepage. From the application's page, add permissions to the web API.

To add permissions:

1. Click **API permissions**.
2. Click **+ Add a permission**.  
   ![Add an API permission.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_AddPermission.png "Click to expand.")
3. Click **Microsoft Graph**.
4. Select **Delegated Permissions**.
5. Select the **eDiscovery.ReadWrite.All** option from the Delegated Permissions section.
6. Click **Add Permissions**.  
   ![The Request API permissions screen.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_DelegatedPermissions.png "Click to expand.")
7. Click **Grant admin consent for \[Tenant Name\]**.

   > **Notes:** You need the *Global Administration* role to complete this action.

At this point the Application should be fully configured. It can take a few minutes to update.

### Create the service principal

The eDiscovery.Download.Read permission, which lets Purview Sync transfer data, is not available in an app registration by default. You must create a service principal for your Azure tenant to make it available. For more information, see Microsoft's [Service Principal](https://learn.microsoft.com/en-us/graph/api/resources/serviceprincipal?view=graph-rest-1.0) documentation.

We recommend using Microsoft Graph Explorer to do this. The address to graph explorer is [https://developer.microsoft.com/en-us/graph/graph-explorer](https://developer.microsoft.com/en-us/graph/graph-explorer).

Before using Microsoft Graph Explorer, you need an account that has *Application.ReadWrite.All* permission. If you are not sure, ask someone in your organization with the Global Administrator role in your Azure tenant. For more information on the required permissions, see Microsoft's [Service Principals](https://learn.microsoft.com/en-us/graph/api/serviceprincipal-post-serviceprincipals) documentation.

To create the service principal:

1. Navigate to *https://developer.microsoft.com/en-us/graph/graph-explorer*.
2. Click on the avatar icon on the top right.  
   This opens a login window, where you can login with your credentials.  
   ![The Microsoft Graph user.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_ServicePrincipal.png "Click to expand.")
3. Click on the blue **GET** button. Select **POST** as the query method.
4. Enter **https://graph.microsoft.com/v1.0/servicePrincipals** in the URI field.
5. Under Request body, enter: **{ "appId": "b26e684c-5068-4120-a679-64a5d2c909d9" }**.

   > **Note:** Do not forget the curly brackets.
6. Press the **Run query** button.  
   ![Graph API run query screen.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_RunQuery.png "Click to expand.")
7. Confirm you received one of the following responses:
   - **Created – 201**—the service principal was created.
   - **Conflict – 409**—the service principal already exists. Both responses are acceptable.

#### Configure permissions

Now you need to add the *eDiscovery.Download.Read* permission we made available by adding the service principal in the *Create a Service Principal* section.

Navigate back to Microsoft Azure Portal, to the application registration you set up earlier.

1. Click the **API permissions** in the left-hand side menu.
2. Click **+ Add a permission**.
3. Select the **APIs my organization uses** tab.
4. In the search bar, enter *MicrosoftPurviewEDiscovery*.
5. Select the application **MicrosoftPurviewEDiscovery** search result.  
   ![The Request API Permissions screen.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_RequestAPIPermissions.png "Click to expand.")
6. Select the **Delegated Permissions** box.
7. Select **eDiscovery.Download.Read**.
8. Click **Add permissions**.
9. Click **Grant admin consent for \[TENANT NAME\]**.

   > **Notes:** You need the *Global Administration* role to complete this action.
10. In the pop-up modal that appears, click **Yes**.

You completed configuring the application registration with Azure. Now onto Relativity.

## Grant users eDiscovery permissions in Microsoft Purview

There are two distinct permissions sets to use the Purview Sync app:

- **Permissions for the admin configuring access**—required only by the person who sets up the role groups described below.
- **Permissions for Purview Sync users**—required by users who actually run Purview Sync jobs in Relativity aiR.

These are kept separate so that Purview Sync users do not receive broader access than they need.

### Considerations

Be aware of the following when granting users eDiscovery permissions.

- If there is already a user with Azure eDiscovery Admin permissions to create cases within Purview eDiscovery Premium, you can skip this section and move to Configure the Connection Between Relativity aiR and Purview eDiscovery Premium.
- If you see a screen that the Microsoft compliance portal is retired, it might mean that you are using the old Microsoft compliance portal that was disabled in November 2024. Navigate to the new [Microsoft Purview](https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Fpurview.microsoft.com%2F&data=05%7C02%7Ctim.leahy%40relativity.com%7C564e7e2e41bc4829150808df0e9a7924%7C8afe73f90d934821a898c5c2dc320953%7C1%7C0%7C639245728792744653%7CUnknown%7CTWFpbGZsb3d8eyJFbXB0eU1hcGkiOnRydWUsIlYiOiIwLjAuMDAwMCIsIlAiOiJXaW4zMiIsIkFOIjoiTWFpbCIsIldUIjoyfQ%3D%3D%7C0%7C%7C%7C&sdata=%2FEdfcos840BhtyjB4hh6lYoxauQKt0svN2t1juv7s%2F0%3D&reserved=0) instead.

### Permissions for the admin configuring access

The person performing the configuration steps below must hold:

- **Compliance Administrator** (Microsoft Entra ID role)—to read, configure, and manage compliance permissions in Microsoft Purview.
- **Compliance Data Administrator** (Microsoft Entra ID role)—to create and manage compliance content in Microsoft Purview.

These roles are required only for the configuration steps below. They are not required for users running Purview Sync jobs and should not be assigned to them.

> **Note:** If you see a screen that the Microsoft compliance portal is retired, it might mean that you are using the old Microsoft compliance portal that was disabled in November 2024. Please navigate to the new Microsoft Purview instead.

### Setting up Compliance Admin roles

To set up Compliance Admin roles to use Azure AD:

1. Navigate to [https://purview.microsoft.com](https://purview.microsoft.com/) and log in.
2. Click **Settings** > **Roles and scopes** > **Role groups**.  
   ![Select the Compliance Administrator role.](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_ComplianceAdministratorRole.png)
3. Click the **Compliance Administrator role** > **Edit** > **Choose users**.
   - Ensure all users and service accounts that will be managing compliance permissions in Microsof Purview are assigned this role.
   - To add users, click the **Add assignments**.
   - Close the Assignments page once complete .

   \[Role groups for Purview solutions.\]
4. Click the **Compliance Data Administrator role** > **Edit** > **Choose users**.
   - Ensure all users, including service accounts that will be managing compliance content in Microsoft Purview are assigned this role.
   - To add users, click the **Add assignments**.
   - Close the Assignments page once complete.

### Permissions for Purview Sync users

This is how to grant Purview permissions needed to run Purview Sync jobs: eDiscovery Manager and eDiscovery Administrator.

### Grant Purview Sync users access

Follow the steps to grant Purview Sync users access:

1. Navigate to [https://purview.microsoft.com](https://purview.microsoft.com/) and login.
2. Click **Settings** > **Roles and scopes** > **Role** groups under the Microsoft Purview solutions section.
3. Click **eDiscovery Manager**.
4. Select **Edit**.
5. Assign that user to the **eDiscovery Manager** role by following these sub-tasks if you want a user to be able create cases in Purview eDiscovery Premium, but not see other cases.  
   If not, skip to step 6:
   1. Click the **Choose users** button.  
      ![Choose users for the eDiscovery Managers](https://help.relativity.com/RelativityaiR/Content/Resources/Images/Features/Purview_Sync/SCR_ChooseUsers.png)
   2. Select the users to add to the **eDiscovery Manager** role in the right-side menu.
   3. Click the **Select** button.
   4. Click the **Next** button at the bottom of the page until you navigate through Manage eDiscovery Administrator and Review and finish options.
   5. Click the **Save** button.
6. If you want to allow a user the capability to create cases and see cases that other users have created, then assign that user to the **eDiscovery Administrator** role by following these sub-tasks, otherwise skip to the next section.
   1. Click the **Next** button to navigate to the **Manage eDiscovery Administrator** options.
   2. Click the **Choose users** button.
   3. Select the users to add to the **eDiscovery Administrator** role in the right-side menu.
   4. Click the **Select** button.
   5. Click the **Save** button.

You have now granted a service or user eDiscovery permissions in Microsoft Purview.
