The client with object id does not have authorization to perform action 'Microsoft.DataFactory/datafactories/datapipelines/read' over scope

后端 未结 8 1798
星月不相逢
星月不相逢 2021-02-02 08:33

I was trying to invoke data factory pipeline from azure function programmatically. Its throwing following error.

link: http://eatcodelive.com/2016/02/24

8条回答
  •  借酒劲吻你
    2021-02-02 08:55

    Solution:

    1. Step 1: Register an app in Azure Active directory.
    2. Step 2: Assign 'Data Factory Contributor' role to the same app. we can achieve this by using power shell.

    The below code works for me. Please try out in power shell after logged in with Azure credential.
    Implementation:

    1. Step 1: $azureAdApplication = New-AzureRmADApplication -DisplayName -HomePage -IdentifierUris -Password
    2. Step 2: New-AzureRmRoleAssignment -RoleDefinitionName "Data Factory Contributor" -ServicePrincipalName $azureAdApplication.ApplicationId

提交回复
热议问题