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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
supermarin
Regular Visitor

Power BI Rest API. Reports - Export To File In Group. Filters values STOPS working as documented

I am using the API for exporting a report to PDF ( API documentation). According to the documentation, filters should be passed in the body in the following (filter format documentation)

 

supermarin_1-1734003414489.png

 

 

However, this approach does not work as expected. If I remove the encoding from the filter values in the JSON body, everything works correctly.

supermarin_0-1734003358153.png

 

It’s important to note that no changes are observed when it comes to filter names—this issue only applies to filter values.

 

Could you clarify if this is a feature or a bug? Should we expect a return to the documented approach, or will the documentation be updated to reflect this behavior?

 

Thank you!

7 REPLIES 7
supermarin
Regular Visitor

NOTE:

The problem is that previously the API accepted filter values in an escaped format (e.g., spaces as %20), which aligns with the URL filtering behavior and requirement from documentation. This approach worked successfully up to December 10th.

 

As of today, the behavior has changed unexpectedly: the API now requires plain text filter values (e.g., spaces as regular spaces) in the request body. 

Anonymous
Not applicable

Hi, @supermarin 

After seeing the question you asked, I thought about it repeatedly. It wasn't until I realized that URLs and API request bodies are different concepts that I understood the reasoning.

Normally, when we filter a report by URL, the space is automatically transcoded to %20. This is because URLs must follow strict syntax rules and cannot contain special characters such as spaces.

When exporting a report using the export API, our filter criteria are placed in the request body. The data of the POST request is in the request body, not the URL. The JSON format itself is a lightweight data exchange format that is easy to read and write, as well as easy to machine parse and generate.

These two are different concepts, so it's easy for us to confuse them.

HTML URL Encoding Reference

POST - HTTP | MDN

 

Best Regards

Jianpeng Li

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

Thank you for the clarification. However, the issue here is not confusion between URL filters and API request bodies. The problem is that previously the API accepted filter values in an escaped format (e.g., spaces as %20), which aligns with the URL filtering behavior and requirement from documentation. This approach worked successfully up to December 10th.

 

As of today, the behavior has changed unexpectedly: the API now requires plain text filter values (e.g., spaces as regular spaces) in the request body. This change was not communicated or documented, which is causing issues.

 

Could you confirm whether this is an intentional change (a feature) or an unintended issue (a bug)? Clear communication or updated documentation would help us proceed correctly.

MariusMoscovici
New Member

It would be great to hear a response from Microsoft on this issue. Having stable, well-documented APIs is very important to those of us who rely on them for critical business functionality.  We have encountered this same issue, and the fact that this functionality is not working reliably prevents us from deploying it as a solution to a user base of 50,000 users.   Are there any plans to create a change log for API changes and to provide the community with notice in advance of having changes pushed into production?  This would go a long way towards supporting the community in developing stable and robust applications using Power BI.

gson
New Member

Hoping Microsoft will chime in on this! It's impacting a use-case with many many thousands of users at a large enterprise customer, so seeing constintent, stable behavior is important for us.

ibarrau
Super User
Super User

Hi. I don't think it's a bug. The API doc just explains the body parameters but it doesn't show specific example of the json or something like that. The filter report doc is for url filtering and not necessary for the api request. Many body parametters sometimes need reformat json or encode them. That doesn't mean the doc is wrong or there is a bug.

I don't think there will be a doc update for power bi rest api for that.

I'm glad you found a way to make it work and that you are sharing it right here 🙂

I hope that helps,


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

Happy to help!

LaDataWeb Blog

@ibarrau
If you follow the API documentation for properly building the export request, you will find that it states filters are accepted using the same syntax as URL filtering. Moreover, it includes a link to the relevant page.

Also, please note that the filters worked correctly in the format described in the documentation up to and including December 10th. However, starting today (or perhaps yesterday, I didn’t check), the behavior has changed, and they no longer work as expected.

I believe you’ll agree that changes in behavior should be explained or properly documented.

I would like to hear from someone on the Microsoft dev team: is this a bug, and can we expect these changes to be reverted, or is it a feature, and the documentation will be updated so we can proceed with the new approach?

Helpful resources

Announcements
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.