Skip to content

Commit ffa35e7

Browse files
committed
improve, update, create include for PAT reduction, recommend Microsoft entra usage
1 parent e35cf62 commit ffa35e7

13 files changed

+159
-127
lines changed

docs/boards/github/connect-on-premises-to-github.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -297,10 +297,10 @@ Consider the following resolutions:
297297
Delete and recreate the connection to the GitHub repository. This recreated connection causes GitHub to prompt to reauthorize Azure Boards.
298298

299299
- **If the connection is using a PAT:**
300-
- The PAT might be revoked or the required permission scopes changed and are insufficient.
300+
- The PAT was revoked or the required permission scopes changed and are insufficient.
301301
- The user perhaps lost administrative permissions on the GitHub repository.
302302

303-
Recreate the PAT and ensure the scope for the token includes the required permissions: `repo, read:user, user:email, admin:repo_hook`.
303+
Recreate the PAT and ensure the scope for the token includes the required permissions: `repo, read:user, user:email, admin:repo_hook`. For more information, see [Best practices for using PATs](../../organizations/accounts/use-personal-access-tokens-to-authenticate.md#best-practices-for-using-pats).
304304

305305
<a id="update-wits"></a>
306306

docs/boards/github/connect-to-github.md

+5-3
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,9 @@ To change the configuration or manage the Azure Boards app for GitHub, see [Cha
124124

125125
## Add a GitHub connection using PAT
126126

127-
We recommend using your GitHub account credentials to connect to your GitHub repository. If you need to use a PAT, do the following steps.
127+
[!INCLUDE [use-microsoft-entra-reduce-pats](../../includes/use-microsoft-entra-reduce-pats.md)]
128+
129+
We recommend using your GitHub account credentials to connect to your GitHub repository.
128130

129131
> [!TIP]
130132
> When you create your GitHub PAT, make sure that you include these scopes: `repo, read:user, user:email, admin:repo_hook`.
@@ -343,10 +345,10 @@ To resolve this issue, consider the following items:
343345
Delete and recreate the connection to the GitHub repository. This recreated connection causes GitHub to prompt to reauthorize Azure Boards.
344346

345347
- **If the connection is using a PAT:**
346-
- The PAT might be revoked or the required permission scopes changed and are insufficient.
348+
- The PAT was revoked or the required permission scopes changed and are insufficient.
347349
- The user might not have admin permissions on the GitHub repo.
348350

349-
Recreate the PAT and ensure the scope for the token includes the required permissions: `repo, read:user, user:email, admin:repo_hook`.
351+
Recreate the PAT and ensure the scope for the token includes the required permissions: `repo, read:user, user:email, admin:repo_hook`. For more information, see [Best practices for using PATs](../../organizations/accounts/use-personal-access-tokens-to-authenticate.md#best-practices-for-using-pats).
350352

351353
<a id="ghe-dataimport"></a>
352354

docs/cli/log-in-via-pat.md

+3-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ ms.manager: mijacobs
88
ms.author: chcomley
99
author: chcomley
1010
monikerRange: 'azure-devops'
11-
ms.date: 08/10/2023
11+
ms.date: 01/08/2025
1212
---
1313

1414
# Sign in with a personal access token (PAT)
@@ -17,6 +17,8 @@ ms.date: 08/10/2023
1717

1818
You can sign in using an Azure DevOps personal access token (PAT). To create a PAT, see [Use personal access tokens](../organizations/accounts/use-personal-access-tokens-to-authenticate.md#create-a-pat).
1919

20+
[!INCLUDE [use-microsoft-entra-reduce-pats](../includes/use-microsoft-entra-reduce-pats.md)]
21+
2022
To use a PAT with the Azure DevOps CLI, use one of these options:
2123

2224
* Use `az devops login` and be [prompted for the PAT token](#user-prompted-to-use-az-devops-login).

docs/extend/develop/upload-tasks.md

+1
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,7 @@ To upload tasks to project collection, you need prerequisites:
3131
npm install -g tfx-cli
3232
```
3333
- Permissions to update required project collection, PAT generated with scope **Environment (Read & Write)** to be able to upload tasks to the project collection.
34+
[!INCLUDE [use-microsoft-entra-reduce-pats](../../includes/use-microsoft-entra-reduce-pats.md)]
3435

3536
## Tfx-cli sign in with personal access token
3637

Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
ms.topic: include
3+
---
4+
5+
> [!IMPORTANT]
6+
> We recommend using [Microsoft Entra tokens](../integrate/get-started/authentication/entra.md). For more information about our efforts to reduce PAT usage, see [our blog](https://devblogs.microsoft.com/devops/reducing-pat-usage-across-azure-devops/).
7+
> Review our [authentication guidance](../integrate/get-started/authentication/authentication-guidance.md) to choose the appropriate authentication mechanism for your needs.
Original file line numberDiff line numberDiff line change
@@ -1,49 +1,59 @@
11
---
2-
ms.topic: how-to
3-
title: Building a Microsoft Entra OAuth app for Azure DevOps
2+
title: Building Azure DevOps integrations with Microsoft Entra OAuth apps
43
description: Use Microsoft Entra authentication to integrate with Azure DevOps Services.
54
ms.assetid: 19285121-1805-4421-B7C4-63784C9A7CFA
65
ms.subservice: azure-devops-security
6+
ms.topic: conceptual
77
monikerRange: 'azure-devops'
88
ms.author: chcomley
99
author: chcomley
10-
ms.date: 10/28/2024
10+
ms.date: 01/08/2025
1111
---
1212

13-
# Building for Azure DevOps with Microsoft Entra OAuth Apps
13+
# Build Azure DevOps integrations with Microsoft Entra OAuth apps
1414

15-
## Entra OAuth Tokens
16-
The Microsoft Identity platform offers many ways to authenticate users via [the OAuth 2.0 protocol](/entra/identity-platform/v2-protocols). In these docs, we use OAuth tokens to colloquially refer to [on-behalf-of user flows](/entra/identity-platform/v2-oauth2-on-behalf-of-flow), also known as [delegated flows](/entra/identity-platform/delegated-access-primer), for apps that request tokens to perform actions for their users. The rest of this guide offers helpful resources for these app developers.
15+
[!INCLUDE [version-eq-azure-devops](../../../includes/version-eq-azure-devops.md)]
16+
17+
This guide provides information and links to more information on building a Microsoft Entra OAuth app for Azure DevOps. Microsoft Entra ID offers robust identity and access management capabilities, which allow you to authenticate users and perform actions on their behalf using OAuth tokens. Use this information to apply Microsoft Entra OAuth tokens for various app flows, including delegated access and service principal-based access.
18+
19+
## Use Microsoft Entra OAuth tokens
20+
21+
The Microsoft identity platform offers many ways to authenticate users via [the OAuth 2.0 protocol](/entra/identity-platform/v2-protocols). In these docs, we use OAuth tokens to colloquially refer to [on-behalf-of user flows](/entra/identity-platform/v2-oauth2-on-behalf-of-flow), also known as [delegated flows](/entra/identity-platform/delegated-access-primer), for apps that request tokens to perform actions for their users. The rest of this guide offers helpful resources for these app developers.
1722

1823
Another common app flow we support is building [on-behalf-of app using service principals and managed identities](service-principal-managed-identity.md).
19-
Entra tokens can also be used for [ad-hoc requests with the Azure CLI](entra.md#acquire-user-tokens-in-azure-cli) or [git operations through the Git Credential Manager](entra.md#git-operations-with-git-credential-manager).
24+
Microsoft Entra tokens can also be used for [ad-hoc requests with the Azure CLI](entra.md#acquire-user-tokens-in-azure-cli) or [git operations through the Git Credential Manager](entra.md#git-operations-with-git-credential-manager).
2025

2126
> [!IMPORTANT]
2227
> When creating a new OAuth 2.0 app, start here with Microsoft Entra OAuth apps, as [Azure DevOps OAuth apps](azure-devops-oauth.md) are planned for deprecation in 2026. [Learn more in our blog post](https://devblogs.microsoft.com/devops/no-new-azure-devops-oauth-apps-beginning-february-2025/).
2328
24-
## Helpful resources
29+
## Resources for developers
2530

26-
### For developers
27-
* [Quickstart: Register an application with the Microsoft identity platform](/entra/identity-platform/quickstart-register-app)
28-
* [Add permissions to access Microsoft Graph](/entra/identity-platform/quickstart-configure-app-access-web-apis#add-permissions-to-access-microsoft-graph): Useful to learn how to add delegated permissions from an Azure resource. Instead of Microsoft Graph, select `Azure DevOps` from the list of resources instead.
29-
* [Scopes and permissions in the Microsoft identity platform](/entra/identity-platform/scopes-oidc): Read up on the `.default` scope. See the scopes available for Azure DevOps in [our list of scopes](oauth.md#scopes).
30-
* [Requesting permissions through consent](/entra/identity-platform/consent-types-developer)
31-
* [Authentication libraries](/entra/identity-platform/reference-v2-libraries) and [code samples](/entra/identity-platform/sample-v2-code?tabs=apptype)
32-
* [Manage personal access tokens via API](../../../organizations/accounts/manage-personal-access-tokens-via-api.md): Using the PAT lifecycle management APIs requires Microsoft Entra tokens and our docs and the [associated sample app](https://github.com/microsoft/azure-devops-auth-samples/tree/master/PersonalAccessTokenAPIAppSample) might be a helpful example for setting up a Microsoft Entra app to use Azure DevOps REST APIs.
33-
* [Support and help options for developers](/entra/identity-platform/developer-support-help-options)
31+
* [Register an application with the Microsoft identity platform](/entra/identity-platform/quickstart-register-app)
32+
* [Add permissions for access to Microsoft Graph](/entra/identity-platform/quickstart-configure-app-access-web-apis#add-permissions-to-access-microsoft-graph): Learn how to add delegated permissions from an Azure resource. Instead of Microsoft Graph, select `Azure DevOps` from the list of resources.
33+
* [Read about scopes and permissions in the Microsoft identity platform](/entra/identity-platform/scopes-oidc): Understand the `.default` scope. See the scopes available for Azure DevOps in [our list of scopes](oauth.md#scopes).
34+
* [Request permissions through consent](/entra/identity-platform/consent-types-developer)
35+
* [Use authentication libraries](/entra/identity-platform/reference-v2-libraries) and [code samples](/entra/identity-platform/sample-v2-code?tabs=apptype)
36+
* [Manage personal access tokens via API](../../../organizations/accounts/manage-personal-access-tokens-via-api.md): Use the PAT lifecycle management APIs with Microsoft Entra tokens. Our docs and the [associated sample app](https://github.com/microsoft/azure-devops-auth-samples/tree/master/PersonalAccessTokenAPIAppSample) provide examples for setting up a Microsoft Entra app to use Azure DevOps REST APIs.
37+
* [Explore support and help options for developers](/entra/identity-platform/developer-support-help-options)
3438

35-
### For admins
36-
* [What is application management in Microsoft Entra ID?](/entra/identity/enterprise-apps/what-is-application-management)
37-
* [Quickstart: Add an enterprise application](/entra/identity/enterprise-apps/add-application-portal)
38-
* [Consent experience for applications in Microsoft Entra ID](/entra/identity-platform/application-consent-experience)
39+
### Resources for admins
40+
41+
* [Understand application management in Microsoft Entra ID](/entra/identity/enterprise-apps/what-is-application-management)
42+
* [Add an enterprise application](/entra/identity/enterprise-apps/add-application-portal)
43+
* [Explore the consent experience for applications in Microsoft Entra ID](/entra/identity-platform/application-consent-experience)
44+
45+
## Tips for building & migrating
3946

40-
## Building & migrating tips
4147
> [!NOTE]
42-
> Microsoft Entra OAuth apps doesn't natively support MSA users for Azure DevOps REST APIs. If you are building an app that must cater to MSA users or supports both Microsoft Entra and MSA users, [Azure DevOps OAuth apps](azure-devops-oauth.md) remains your best option. We are currently working on native support for MSA users through Microsoft Entra OAuth.
48+
> Microsoft Entra OAuth apps don't natively support Microsoft account (MSA) users for Azure DevOps REST APIs. If you're building an app that must cater to MSA users or support both Microsoft Entra and MSA users, [Azure DevOps OAuth apps](azure-devops-oauth.md) remain your best option. We're currently working on native support for MSA users through Microsoft Entra OAuth.
4349
44-
* **Good-to-know Azure DevOps IDs:**
50+
* **Important Azure DevOps IDs:**
4551
* Microsoft Entra resource identifier: `499b84ac-1321-427f-aa17-267ca6975798`
46-
* Resource Uri: `https://app.vssps.visualstudio.com`
52+
* Resource URI: `https://app.vssps.visualstudio.com`
4753
* Use the `.default` scope when requesting a token with all scopes that the app is permissioned for.
48-
* When migrating an existing app, you may be using Azure DevOps user identifiers that don't exist in Microsoft Entra. Use the [ReadIdentities API](/rest/api/azure/devops/ims/identities/read-identities) to resolve and match the different identities in use by each identity provider.
54+
* When you migrate an existing app, you might use Azure DevOps user identifiers that don't exist in Microsoft Entra. Use the [ReadIdentities API](/rest/api/azure/devops/ims/identities/read-identities) to resolve and match the different identities used by each identity provider.
55+
56+
## Related articles
4957

58+
- [Authenticate to Azure DevOps with Microsoft Entra](entra.md)
59+
- [Use service principals & managed identities in Azure DevOps](service-principal-managed-identity.md)

0 commit comments

Comments
 (0)