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 September 15. Request your voucher.
This is a small feature request for better error messages from the Power BI API. Specifically I am hoping for an improvement in this API call:
- 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 bad PageName (Microsoft.PowerBI.Api.Models.ExportReportPage.PageName) (bad simply in that the PageName 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. The error message should instead say something like "PageName not found in report."
This has been a pain point for me. I have a fully functional process (to export PNG assets from a report) can break if when company's Power BI report developers release what they think is an inconsequential change that alters a report identifier. That's not great, but it becomes worse when the API error message doesn't help identify the cause of the problem.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.