> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stackone.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Azure DevOps OAuth 2.0 (Microsoft Entra ID) (Multiple Companies) connector profile – StackOne setup guide

> Set up a connector profile using OAuth 2.0 (Microsoft Entra ID) (Multiple Companies) for Azure DevOps in StackOne to allow users to link their accounts.

> [!WARNING]
>
> You need permission to register applications in your Microsoft Entra ID tenant, and administrator rights to grant admin consent. Note: end users cannot grant consent to newly registered multitenant apps without verified publishers.

## Register a Microsoft Entra ID application

Create an app registration in Microsoft Entra ID to enable OAuth 2.0 authentication with Azure DevOps.

**1. Choose the supported account types**

Sign in to the [Microsoft Entra admin center](https://entra.microsoft.com/) with your Microsoft work account, then in the left sidebar under **Entra ID**, open **App registrations**.

<ul>
  <li>Click **+ New registration** in the toolbar.</li>
  <li>**Name**: A name for the app</li>
  <li>**Supported account types**: **Multiple Entra ID tenants** (shown as **Accounts in any organizational directory (Any Microsoft Entra ID tenant - Multitenant)**)</li>
  <li>Select **Allow all tenants**.</li>
</ul>

![Supported account types dropdown open with Multiple Entra ID tenants highlighted](https://mintcdn.com/stackone-60/y3JLAGTnfHYE9tQB/connectors/azuredevops/images/oauth2-setup-account-types.png?fit=max\&auto=format\&n=y3JLAGTnfHYE9tQB\&q=85\&s=fdf8b7e509eeb67b6a1a6716851009ed)

**2. Set the Redirect URI and register**

Set the redirect URI in the **Register an application** form.

<ul>
  <li>**Redirect URI (optional)**: select **Web**, then enter the **Callback URL** from your Connector Profile</li>
  <li>Click **Register**.</li>
</ul>

![Completed Register an application form with the Register button highlighted](https://mintcdn.com/stackone-60/y3JLAGTnfHYE9tQB/connectors/azuredevops/images/oauth2-setup-register-form.png?fit=max\&auto=format\&n=y3JLAGTnfHYE9tQB\&q=85\&s=48f0b9601974edbfc0d285c0f0ef741c)

**3. Add the user\_impersonation permission**

In the app's left menu under **Manage**, open **API permissions**.

<ul>
  <li>In the **Configured permissions** section, click **+ Add a permission**.</li>
  <li>In the **Request API permissions** panel, select the **Microsoft APIs** tab.</li>
  <li>Select the **Azure DevOps** tile ("Integrate with Azure DevOps and Azure DevOps server").</li>
  <li>Under **Delegated permissions**, check **user\_impersonation** ("Have full access to Visual Studio Team Services REST APIs").</li>
  <li>Click **Add permissions**.</li>
</ul>

![Delegated permissions list with user\_impersonation checked and highlighted](https://mintcdn.com/stackone-60/y3JLAGTnfHYE9tQB/connectors/azuredevops/images/oauth2-setup-user-impersonation.png?fit=max\&auto=format\&n=y3JLAGTnfHYE9tQB\&q=85\&s=8dc2e4d58267bfd4598d68f3f36181e4)

**4. Grant admin consent**

Admin consent is granted from the **Configured permissions** section of **API permissions**.

<ul>
  <li>Click **Grant admin consent for \[your tenant]**.</li>
  <li>Click **Yes** to confirm.</li>
</ul>

![Configured permissions with the Grant admin consent button highlighted](https://mintcdn.com/stackone-60/y3JLAGTnfHYE9tQB/connectors/azuredevops/images/oauth2-setup-grant-admin-consent.png?fit=max\&auto=format\&n=y3JLAGTnfHYE9tQB\&q=85\&s=1e181a330767c16c5c4749bff5e03e71)

**5. Copy the Client ID**

On the app's **Overview** page, in the **Essentials** panel.

<ul>
  <li>Copy the **Application (client) ID** to **Client ID** in your Connector Profile.</li>
</ul>

![App Overview Essentials panel with the Application (client) ID highlighted](https://mintcdn.com/stackone-60/y3JLAGTnfHYE9tQB/connectors/azuredevops/images/oauth2-setup-client-id.png?fit=max\&auto=format\&n=y3JLAGTnfHYE9tQB\&q=85\&s=812fcfa2d120ca16bfca92c0881b2525)

**6. Create a client secret**

In the app's left menu, open **Manage** > **Certificates & secrets**.

<ul>
  <li>On the **Client secrets** tab, click **+ New client secret**.</li>
  <li>**Description**: A name that identifies this secret</li>
  <li>**Expires**: **Recommended: 180 days (6 months)**, then create a new secret before it expires</li>
  <li>Click **Add**.</li>
</ul>

![Add a client secret panel with Description and Expires fields and the Add button highlighted](https://mintcdn.com/stackone-60/y3JLAGTnfHYE9tQB/connectors/azuredevops/images/oauth2-setup-add-client-secret.png?fit=max\&auto=format\&n=y3JLAGTnfHYE9tQB\&q=85\&s=ee847aa5fbfc48ed27a54de13889f3eb)

**7. Copy the Client Secret**

The **Client secrets** tab shows the new secret's **Value** only until you leave the page.

<ul>
  <li>Copy the **Value** to **Client Secret** in your Connector Profile.</li>
</ul>

![Client secrets tab with the one-time secret Value highlighted and redacted](https://mintcdn.com/stackone-60/y3JLAGTnfHYE9tQB/connectors/azuredevops/images/oauth2-setup-secret-value.png?fit=max\&auto=format\&n=y3JLAGTnfHYE9tQB\&q=85\&s=7b02966b80b17047409fa7d9821549a2)

## Create the StackOne Connector Profile

**1. Create a Connector Profile**

Enable the connector and create a Connector Profile in your project. See [Setup Connector Profile](https://docs.stackone.com/gateway/quickstart.md#setup-connector-profile).

**2. Link an Account**

Once the Connector Profile is created, continue to [link an account](https://docs.stackone.com/connectors/azuredevops/guides/link-account/oauth-2-0-microsoft-entra-id-multiple-companies.md).


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.