Forum Discussion
Guide to Implementing 3-Legged OAuth in Power BI Custom Visual
- 1 year ago
Hi Vishnu_G ,
Power BI does not provide a supported way to pass the access token from a custom connector (M extension) to a custom visual.
This is by design:
-
The access token lives in Power Query's credential store and is never exposed to the model or visuals.
-
Even if you return it as part of the dataset (e.g., in a column), it is considered a sensitive field and will be encrypted or stripped when published to the Power BI Service.
The other option is using the authentication API, but it is only available for certified visuals and also is only compatible with backends that use Entra ID authentication.
Additionally, you can follow
Custom Development Discussions to get an idea about your query.-
https://community.fabric.microsoft.com/t5/Custom-Visuals-Development/bd-p/CustomVisualsDevelopmentDiscussionAnd a smililar issue-
https://community.fabric.microsoft.com/t5/Developer/Authentication-API-with-Organizational-Custom-Visual/m-p/4634659
Hope this helps!
If you find this post helpful, please mark it as an "Accept as Solution" and give Kudo. Feel free to reach out if you need further assistance.
Thanks and Regards -