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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
GregBoet
Frequent Visitor

Power BI API feature request: Better error messages for bad PageName identifiers

This is a feature request for the Power BI API. Please let me know if there is a better place for me to submit this.

 

This is a request for a better error message from the Power BI API for a specific scenario when calling the API to export a Power BI report to a file; specifically this API call is:
- https://learn.microsoft.com/en-us/power-bi/developer/embedded/export-to
- In NuGet package Microsoft.PowerBI.Api, this is PowerBIClient.Reports.ExportToFileInGroup

 

If I call this method and give it a list of pages, and if even one of the pages has a PageName (Microsoft.PowerBI.Api.Models.ExportReportPage.PageName) that doesn't exist in the report, I get an inner exception with message "Operation returned an invalid status code 'BadRequest'". "BadRequest" makes it sound like I've sent malformed JSON or something, whereas the syntax is perfect and one of the page identifiers isn't in the report, so I argue the error message should be improved.

 

This has been a pain point for me, because it can mean that my process breaks if my company's Power BI report developers release what they think is a very minor report change. If a report page identifier changes, I can understand how that could break my process, but at least the API should give me an error message that explains the problem in a more specific way.

1 ACCEPTED SOLUTION
v-karpurapud
Community Support
Community Support

Hi @GregBoet 


Thank you for reaching out to the Microsoft Fabric Community Forum.

Regarding the Power BI Export API, specifically around the handling of invalid PageName identifiers when calling the ExportToFileInGroup method from the Power BI REST API.We understand how receiving a generic BadRequest error without detailed context can make it challenging to diagnose issues, especially when report page names are subject to change by development teams.

As this is a feature request related to the Power BI API, we recommend submitting it to the official Power BI Ideas Forum, as suggested by @lbendlin 

Submissions through the Ideas Forum are actively reviewed by the Product Group , and highly voted suggestions are often taken into consideration for future releases. Be sure to include detailed context to help the team evaluate the need and prioritize accordingly.

If my response has resolved your query, please mark it as the Accepted Solution to assist others. Additionally, a 'Kudos' would be appreciated if you found my response helpful.

Thank You
 

 

View solution in original post

2 REPLIES 2
v-karpurapud
Community Support
Community Support

Hi @GregBoet 


Thank you for reaching out to the Microsoft Fabric Community Forum.

Regarding the Power BI Export API, specifically around the handling of invalid PageName identifiers when calling the ExportToFileInGroup method from the Power BI REST API.We understand how receiving a generic BadRequest error without detailed context can make it challenging to diagnose issues, especially when report page names are subject to change by development teams.

As this is a feature request related to the Power BI API, we recommend submitting it to the official Power BI Ideas Forum, as suggested by @lbendlin 

Submissions through the Ideas Forum are actively reviewed by the Product Group , and highly voted suggestions are often taken into consideration for future releases. Be sure to include detailed context to help the team evaluate the need and prioritize accordingly.

If my response has resolved your query, please mark it as the Accepted Solution to assist others. Additionally, a 'Kudos' would be appreciated if you found my response helpful.

Thank You
 

 

lbendlin
Super User
Super User

If this is important to you please consider voting for an existing idea or raising a new one at https://ideas.fabric.microsoft.com

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

Find out what's new and trending in the Fabric community.