I was having the same problem. To fix it, when I created the personal access token, I had to select All accessible organizations for the Organization.
VS30063: You are not authorized to access https://dev.azure.com? Error while trying to register Private agent Pool in Azure DevOps Project using PAT token
VS30063: You are not authorized to access https://dev.azure.com? Error while trying to register Private agent Pool in Azure DevOps Project using PAT token.
6 answers
Sort by: Most helpful
-
-
BhargaviAnnadevara-MSFT 5,466 Reputation points
2021-02-15T03:42:47.287+00:00 @Shachindra N Yadav Thanks for reaching out. This could be happening because the generated Personal Access Token has expired or wasn't created with the right Scope.
For registering a self-hosted agent, please generate a PAT as follows:
- Sign in to your Azure DevOps organization
(https://dev.azure.com/{your_organization})
with the user account you plan to use. - Open your user settings from the home page and select Personal access tokens.
- Create a PAT.
- For the scope select Agent Pools (read, manage) and make sure all the other boxes are cleared. If it's a deployment group agent, for the scope select Deployment group (read, manage) and make sure all the other boxes are cleared.
Select Show all scopes at the bottom of the Create a new personal access token window window to see the complete list of scopes.
Please check if this helps. If you have further questions, please post your question in the following forum where the Azure DevOps team and DevOps community are actively answering questions: https://developercommunity.visualstudio.com/spaces/21/index.html as Azure DevOps and its services are not supported on the Microsoft Q&A platform.
- Sign in to your Azure DevOps organization
-
Cesar Medina 15 Reputation points
2023-09-26T23:24:07.71+00:00 Not sure if that helps but I was entering the wrong URL, a slash was missing at the end
I put: https://dev.azure.com/*myorg*
The correct value is: https://dev.azure.com/myorg/
Hope this helps to somone!
-
Elisa Anzelmo 1 Reputation point Microsoft Employee
2022-06-16T23:14:08.193+00:00 Having the same issue when running an unattended configuration through a Custom Script Extension and passing the PAT as an input parameter for the script.
I've discovered that PAT string was joined with a "," (comma) at the end. Solved removing the unwanted character:
$PatFormatted = $PersonalAccessToken.Trim(",") and specifying $PatFormatted in the configure --unattended command. -
Chintu Sasmal 5 Reputation points
2023-06-20T08:05:56.67+00:00 Probably , there must be wrong server URL name, cross check that once.