The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
I have implemeted Power BI Embedded sample "App-Own-Data" available at Power BI-Microsoft Docs, At the time of authenticate only that users are allowed that are added in workspace created in Power BI service, I want that all member Azure AD should able to authenticate and able to see reports based on roles, how can i authencate through azure AD in Power BI Embedded Application? As well roles are here hardcoded can we make them dynamic in code? Below is code for HomeController.cs -
generateTokenRequestParameters = new GenerateTokenRequest("View", null, identities: new List<EffectiveIdentity> { new EffectiveIdentity(username: "username", roles: new List<string> { username == "mohit.gupta@systematixindia.com" ? "Manager" : "Manager1" }, datasets: new List<string> { "bd725bc3-09b4-4c21-84b4-727d84a3f131" }) });
Solved! Go to Solution.
Hi @shanu_123,
If you are embedding for non-Power BI users (app owns data), which is typically an ISV scenario, then you should be able to follow this article to implement RLS. You will need to configure the embed token to account for the user and role.
As well roles are here hardcoded can we make them dynamic in code?
Based on my understanding, if you could store all the app user info with the corresponding user name, roles, and datasets in your database or somewhere else. Then you should be able to get the required info (by retrieving the database) to generate the TokenRequest for the current app user dynamically.
Regards
Hi @shanu_123,
If you are embedding for non-Power BI users (app owns data), which is typically an ISV scenario, then you should be able to follow this article to implement RLS. You will need to configure the embed token to account for the user and role.
As well roles are here hardcoded can we make them dynamic in code?
Based on my understanding, if you could store all the app user info with the corresponding user name, roles, and datasets in your database or somewhere else. Then you should be able to get the required info (by retrieving the database) to generate the TokenRequest for the current app user dynamically.
Regards