An Azure service that provides hosted, universal storage for Azure app configurations.
Hi @Ihor Vinokur ,
Welcome to the Microsoft Q&A Platform! Thank you for asking your question here.
Please find the cause and possible solution below. Please let me know if it works and if any issues, let me know in comments.
The Cause
When you use the Microsoft identity platform v2.0 endpoint (https://login.microsoftonline.com/common/oauth2/v2.0/authorize), it requires scopes to be fully qualified with the App ID URI (Resource ID) of the API you are trying to access.
While vso.code_full is a valid Azure DevOps OAuth scope, passing it bare (e.g., scope=vso.code_full) works for the older Azure DevOps-specific OAuth flow, but it will result in an invalid_scope error in the Entra ID v2.0 flow because Entra ID doesn't know which resource the scope belongs to.
The Solution
To fix this, you must prefix the scope with the official Azure DevOps App ID URI, which is 499b84ac-1321-427f-aa17-267ca6975798.
Change your scope parameter in the authorization request to: scope=499b84ac-1321-427f-aa17-267ca6975798/vso.code_full
(Note: Depending on your exact Entra ID API permission configuration, you might also be able to use scope=499b84ac-1321-427f-aa17-267ca6975798/.default to grant all scopes configured statically on the app registration).
Updated Authorization Request Example:
https://login.microsoftonline.com/common/oauth2/v2.0/authorize?client_id=<application id>&redirect_uri=<redirect uri>&response_type=code&scope=499b84ac-1321-427f-aa17-267ca6975798/vso.code_full&state=<state>
References
- Microsoft Identity Platform Scopes: The v2.0 endpoint requires scopes formatted as
resourceAppIdUri/scope. You can read more in the Microsoft identity platform and OAuth 2.0 authorization code flow docs. - Azure DevOps Scopes: OAuth 2.0 authentication for Azure DevOps REST APIs.