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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Korlay37
Frequent Visitor

PBI parametrized datasource report Upload with REST API and modify datasource through API Bad Req

Hello, 

I have an application and I am implementing a report upload with the PBI REST API functionality which is working but I notice that once I import the pbix report with parametrized server and database information (which are just text) in Fabric if I go and check the semantic model settings there ARENT any parameters there.

Korlay37_0-1724956730649.png

 

In my desktop app I have the parameters with "Enable load":

Korlay37_1-1724956832337.png

And when I click the Semantic model in fabric I can see the parameters there as tables:

Korlay37_2-1724956908241.png

And if I try to update the parameters with the PBI Rest API (https://learn.microsoft.com/en-us/rest/api/power-bi/datasets/update-parameters-in-group ) I get a bad request:

Korlay37_3-1724957061192.png

The flow that I need:
User uploads a report through my app where I use REST API, Then I need my app to make a series of changes using the REST API for refresh and to set the correct datasource because the Users datasource will be some localhost port. I use parameters because the PBI API says that I should use the Update parameters in group to update the Datasource in my use case:

Korlay37_4-1724957296846.png

I hope someone can help me out!

5 REPLIES 5
muhssamy
Resolver I
Resolver I

I can see you defined the data source as a table not a parameter this is the reason

you should create parameter in power query for the source and use it in the connection

@muhssamy How so?

I created the parameters when defining the  origin of my data, there they show as parameters and they are selectable when I select parameters as my connection information:

Korlay37_2-1725025004021.png

If I go to Transform Data -> Edit parameters they show there: 

 

Korlay37_1-1725024887756.png

If I open the transform data I see them there as parameters, I do not see any indication of them being tables:

Korlay37_0-1725024877618.png

 

i am using it like this could you please test it 

after creating paramters i am using it in the connections

 

NOTE:- this is a dummy example the server connection may need the port as you typed before

muhssamy_0-1725193494035.png

 

I did what you did but I tried 2 scenarios with exactly the same report:
* Publishing the report from the desktop application, it works and I can see the parameters there.

* Publishing the report using my app and the Power Bi REST API, I cannot see the parameters.

 

Unfortunately my flow needs to be through the REST API so I am trying to find out why the same report does not show parameters if I use the Post Import in Group. If you know the answer or if you have any suggestions please let me know! 

@muhssamy After some testing it seems it is because I am publishing/importing it using the REST API instead of using publish from the desktop app... If I try and publish using the desktop app the parameters show up. So I am trying to understand why they do not show up when I use the REST API

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.