Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now

Reply
nishanttayal
Frequent Visitor

In Power BI Embedded (App Owns Data) how to update Sharepoint credentials?

Hi,

I am developing an custom app embedding Power BI using App Owns Data (Embed for your customers). In that I want to publish the report using custom app through service principle and then I am looking for way to update the Sharepoint connection of the report published through service principle as we want to refresh it at regular frequency.
I am able to publish the report using REST API's but as it is published through Service Principle so the Sharepoint credentials has become invalid. How can I update them using REST API's? 
I have read REST API documentation of Update Parameters in Group and Update Data Sources in Group but none of them making sense to me for Sharepoint.

2 REPLIES 2
v-yueyunzh-msft
Community Support
Community Support

Hi , @nishanttayal 

As far as I know, SharePoint is also a cloud service product of Microsoft, which uses your tenant's AAD account to log in and uses AAD tokens to access cloud services and embedded Power BI content, and the AAD tokens it uses expire every hour. At your convenience, you can try reading this document to explore ways to refresh your AAD token regularly to ensure that AAD tokens remain valid in your solution:

Microsoft identity platform refresh tokens - Microsoft Entra | Microsoft Learn

 

Thank you for your time and sharing, and thank you for your support and understanding of PowerBI! 

 

Best Regards,

Aniya Zhang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly

Hey @v-yueyunzh-msft ,
Thanks for your response.
The above solution would work when we use AAD Tokens on PBI Desktop to connect with Sharepoint. 
However, I am looking for way to refresh data source credentials while publishing the report through service principle using Organization AD User and Password like the way it ask when we connect Sharepoint Data through Power BI Desktop.

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

February Power BI Update Carousel

Power BI Monthly Update - February 2026

Check out the February 2026 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.