I am trying to add new permissions to the newly created application. I am the owner of the app.
Try it with az ad app permission add
Add-AzADAppPermission
.No success, receive that error Az.MSGraph.internal\Get-AzADApplication : Insufficient privileges to complete the operation.
.
Tried it to add permissions from previously asked questions here and Git Hub, but with no success.
azure-cli version:2.44.1
What I'm missing?
Thank you!
CodePudding user response:
I tried to reproduce the same in my environment and got the same error as below:
Even if the user is the owner
of the Application, Insufficient privileges error will still occur:
Note that: To assign permissions the user account must have
Application Administrator
orGlobal Administrator role
.
To resolve the error, I assigned Application Administrator
role to the user account like below:
Go to Azure AD roles and administrators -> Select Application Administrator -> Add assignments -> Select members -> Select
After assigning the role, I am able to assign API permission to the Azure AD Application like below:
Connect-AzAccount
Add-AzADAppPermission -ObjectId ObjectID -ApiId 00000003-0000-0000-c000-000000000000 -PermissionId 5f8c59db-677d-491f-a6b8-5f174b11ec1d
The Group.Read.All
API permission added successfully in the Azure Portal like below:
CodePudding user response:
Rukmini Thank you for your response, I precipitated and follow all steps you made in the screenshots, but I receive a new error. Correct me if I am wrong