电源报告嵌入的未授权错误401 [英] unauthorized error 401 for power reports embedding
问题描述
我正在尝试使用以下链接 https://docs.microsoft.com/en-us/power-bi/developer/embed-sample-for-customers ,我能够获得access_token但由于出现 401未经授权错误而无法检索基于组ID的仪表板或报告。
I am trying to Embedding my Power Bi Reports in my MVC application using the following link https://docs.microsoft.com/en-us/power-bi/developer/embed-sample-for-customers and i am able to get the access_token but unable to retrieve the dashboards or reports based on Group Id because of 401 Unauthorized error.
让我知道我在做错什么。
Let me know what I am doing wrong.
推荐答案
在Power BI Embedded实施过程中,我遇到了完全相同的问题。我的问题是没有为Azure Active Directory中的已注册应用程序授予足够的权限。请确保已执行以下步骤:
I faced the exact same issue during my Power BI Embedded implementation. The issue in my case was that adequate Permission were not granted for the registered app in Azure Active Directory. Please ensure you have performed the following steps:
- 在Azure Active中注册您的应用(本机或Web应用)应用程序注册下的目录。 或使用Power BI开发人员控制台执行此操作-首选Azure Active Directory
- 将 Power BI API 从权限选项。
- 选择并委派Power BI API的所有必需权限
- 最重要将所有权限授予已注册的应用程序。 如果您没有对Azure Portal的管理员访问权限,则将无法授予权限
- Register your App (Native or Web App) in Azure Active Directory under App Registrations. Or use the Power BI Developer Console to do that - Azure Active Directory Preferred
- Added the Power BI API to the registered app from Permissions Option.
- Select and Delegate all the required permissions for the Power BI API
- Most Important Grant All Permissions to the Registered App. If you don't have Admin Access to Azure Portal, you will not able able to grant the permissions
更多详细信息可以在此处找到。
More details can be found here.
这篇关于电源报告嵌入的未授权错误401的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!