Insufficient privileges to complete the operation

Keith Guo 26 Reputation points
2022-06-22T11:46:39.497+00:00

az ad sp create-for-rbac --name "azure-devops-spn-for-practitioner" --sdk-auth --role contributor --scopes /subscriptions/6ea073f1-8e88-49fc-b63d-a1e7d1919141
This command or command group has been migrated to Microsoft Graph API. Please carefully review all breaking changes introduced during this migration: https://learn.microsoft.com/cli/azure/microsoft-graph-migration
Option '--sdk-auth' has been deprecated and will be removed in a future release.
Insufficient privileges to complete the operation.

Community Center | Not monitored
{count} votes

Accepted answer
  1. Alfredo Revilla - Upwork Top Talent | IAM SWE SWA 27,526 Reputation points Moderator
    2022-06-22T19:14:44.607+00:00

    Hello @Keith Guo , the error is caused by your account not being assigned Azure AD built-in roles such as Global Administrator, Application Administrator or Cloud Application Administrator or not being assigned Azure RBAC roles, such as User Access Administrator or Owner to the scoped subscription.

    Please take a look to Assign a role to a user and Assign Azure roles using the Azure portal to assign the required roles.

    Let us know if this answer was helpful to you or if you need additional assistance. If it was helpful, please remember to accept it so that others in the community with similar questions can more easily find a solution.


0 additional answers

Sort by: Most helpful

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.