Hi,
I'd like to automate some tasks in Power BI Service. Unfortunately, there is only a simple connector for Power BI. It means I have to write my own custom connector or create some HTTP request by myself (https://docs.microsoft.com/en-us/rest/api/power-bi/). That's ok for me.
But the problem is: I've registered an app in Azure and got client ID and client secret. But if I want to create an HTTP request with Active Directory OAuth, there is a field I don't understand: audience. I wasn't able to find out what I should write in. Does anybody have an idea what the field is for and what should be there?
Thank you for every hint.
@slx299The URL it's trying to redirect you to is the user-interactive M365 login page. Check your app registration settings in Entra ID.
yes, this worked
Hi
We're using similar set-up but continuously getting redirect error
Any idea?
{
"statusCode": 302,
"headers": {
"x-ms-proxy-app-id": "2cff5b2f-XXXX",
"x-ms-proxy-group-id": "e4a5613f-XXXX",
"x-ms-proxy-subscription-id": "f05d05b1-XXXX",
"x-ms-proxy-transaction-id": "b78db4ca-XXX",
"x-ms-proxy-service-name": "proxy-appproxy-FRC-XXX3",
"x-ms-proxy-data-center": "FRC",
"Nel": "{\"report_to\":\"network-errors\",\"max_age\":86400,\"success_fraction\":0.2,\"failure_fraction\":1.0}",
"Report-To": "{\"group\":\"network-errors\",\"max_age\":86400,\"endpoints\":[{\"url\":\https://ffde.nelreports.net/api/report?cat=proxy-appproxy-FRC-PAR03P-3\}]}",
"Set-Cookie": "AzureAppProxyPreauthSessionCookie_XXXXd_1.4=4|YCE4Hcw8OHX88FyfQ0XHyK+nRvRAX+Iij3lcIlVNIcfUjxC4/sBKpmCfbf0eF8FCfwMcucU269zfDGwhK44Zf+ZgiREzc5pOMBY0vG1O1nA2yaxmYNlvVzBSQ7RY+y/0j9Qh1w8vW5wPHIz5EsjQwHkuw5O2aUI4kcPqJ3NTFgQkyMjiCkEpfpJBF5ZfFMz7bFJmYZFKa3gcerGFE9sSTxJJXVKS49gqk/gOahVLO6aiS9DqPcvw2CROXaY0fx3VCwkH/T6bDBjrWoy6UAzgFgvzsOrjy4Vj9DseZL6JkFA=; expires=Thu, 20 Apr 2023 15:40:25 GMT; path=/; Secure; SameSite=None,AzureAppProxyAnalyticCookie_2cff5b2f-a47f-4211-972c-47756d35b164_https_1.3=4|S5I5lk58QFcl9UPrvJ8DZ7kGEieOSYuXhIrhLdzHt9e+hTyToDiHxtpb+uhZaeeHCXhMl0LiIe5Tajyb+jo40T5GGR8R9YbMriGLh81b4iCc9pWUkGtErQbQQ/Ffmi9ePetBkfIA87iiPGkLSPl6LQ==; path=/; Secure; SameSite=None",
"Date": "Thu, 20 Apr 2023 15:30:24 GMT",
"Content-Length": "0"
}
}
thank you
The solution is to make sure you added the api that you created in Azure to security group. That group also need to be allowed to use service principals and need to be added to environment as Member.
I came across this topic while searching for the answer to what to put in the Audience field in the Authentication object. I found this works for the Power BI API. Note there is no trailing / character, which exists in the API permissions in the App Registration:
Hello, I am also having trouble using the OAuth. I get the same error. Is there any solution on that?
Did you managed to find a solutions?
I have exactly same issue-Http request failed as there is an error getting AD OAuth token: 'AADSTS500011: The resource principal named "https://service.flow.microsoft.com" was not found in the tenant named swiftinit. This can happen if the
Hm. I'm not able to get this to work:
- Registered app in AAD:
- Setup HTTP action accordingly
Results:
Any ideas on what I'm missing?
WarrenBelz
146,745
Most Valuable Professional
RandyHayes
76,287
Super User 2024 Season 1
Pstork1
66,091
Most Valuable Professional