Azure active directory Azure CLI中的新AzureADServiceAppRoleAssignment?

Azure active directory Azure CLI中的新AzureADServiceAppRoleAssignment?,azure-active-directory,azure-cli,azure-managed-identity,Azure Active Directory,Azure Cli,Azure Managed Identity,Azure CLI世界中是否有以下命令的挂件 New-AzureADServiceAppRoleAssignment -ObjectId $clientManagedIdentityObjectId -Id $serverAppRoleId -ResourceId $serverEnterpriseAppObjectId -PrincipalId $clientManagedIdentityObjectId 我想向企业应用程序中的批准添加托管标识 似乎没有做正确的事情,或者我误解了文档中的参数

Azure CLI世界中是否有以下命令的挂件

New-AzureADServiceAppRoleAssignment -ObjectId $clientManagedIdentityObjectId -Id $serverAppRoleId -ResourceId $serverEnterpriseAppObjectId -PrincipalId $clientManagedIdentityObjectId
我想向企业应用程序中的批准添加托管标识


似乎没有做正确的事情,或者我误解了文档中的参数。

没有内置的cli命令来执行此操作,您可以选择使用直接调用Microsoft Graph

首先,将一个.json文件存储到powershell执行位置,如下所示,值的含义请参见。e、 g.我的位置是PS C:\Users\joyw>,我将文件存储在C:\Users\joyw文件夹中

然后运行命令

az rest --method POST --uri "https://graph.microsoft.com/v1.0/servicePrincipals/{object-id of your Managed identity}/appRoleAssignments" --headers 'Content-Type=application/json' --body `@body.json

没有内置的cli命令来执行此操作,您可以选择使用直接调用Microsoft Graph

首先,将一个.json文件存储到powershell执行位置,如下所示,值的含义请参见。e、 g.我的位置是PS C:\Users\joyw>,我将文件存储在C:\Users\joyw文件夹中

然后运行命令

az rest --method POST --uri "https://graph.microsoft.com/v1.0/servicePrincipals/{object-id of your Managed identity}/appRoleAssignments" --headers 'Content-Type=application/json' --body `@body.json
az ad app permission add应尽我所能完成此操作,但我只获得聚合应用程序的更新,此版本不允许。从它很难理解。az ad app permission add应该尽我所能理解文档,但我只得到聚合应用程序的更新,在这个版本中不允许。这是很难理解的。