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

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

Reply
Anonymous
Not applicable

Automation of power shell script using azure service principal

Hi All,

 

Last one month i am automating the power shell script using azure service principal to extract power bi workspace list. I am getting the output in csv file but today when i run the script i am getting the below error. Could please any one help me on this issue.

 

 

Ynr0225_1-1653330452623.png

 

Thanks in advance.

 

 

2 REPLIES 2
v-cazheng-msft
Community Support
Community Support

Hi @Anonymous,

 

Please check these info.

1 Check in Azure portal whether service principal is expired

2 Check in Admin portal whether Allow service principal to use Power BI APIs is disabled

 

If there is any post helps, then please consider Accept it as the solution to help the other members find it more quickly. If I misunderstand your needs or you still have problems on it, please let me know how. Thanks a lot!

 

Best Regards,

Community Support Team _ Caiyun

Anonymous
Not applicable

Hi @v-cazheng-msft,

Thanks for responding. I check the above two options in Azure portal, Service principal will expire in december 2022 and Allow service principal to use Power BI APIs is also enabled in Admin portal.

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 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.