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

Microsoft is giving away 50,000 FREE Microsoft Certification exam vouchers. Get Fabric certified for FREE! Learn more

Reply
HFT
Helper I
Helper I

Dynamic API call

I want to make the API call dynamic in import mode, to get the data in the power bi data model using a slicer. I tried to achieve that using the parameters, which i build them in power query, but cant relate parameters to slicers, till desktop version parameters are easy to use, I can click on transform data from there edit parameters and change the values accordingly, but how can I do that after publishing the report to workspace where parmeters do not work, so slicers would be good to have in report to change the data dynamically.

 

Please help me in resolving the issue.

1 ACCEPTED SOLUTION
v-mengmli-msft
Community Support
Community Support

Hi @HFT ,

 

As far as I know this is not possible, the processing and cleaning of the data is done in PowerQuery. You need to import all the tables first and then create a Field parameter in the Desktop to dynamically switch the data source of the visual display.

vmengmlimsft_0-1731485566356.png

 

 

Here is my test and attached pbix file for your refernce.

When I selected Date column of Table1, the visual showed data of Table1.

vmengmlimsft_1-1731485960979.png

When I selected Test1 column of Table2, the visual showed data of Table2.

vmengmlimsft_2-1731485976248.png

 

 

 

Best regards,

Mengmeng Li

View solution in original post

3 REPLIES 3
v-mengmli-msft
Community Support
Community Support

Hi @HFT ,

 

As far as I know this is not possible, the processing and cleaning of the data is done in PowerQuery. You need to import all the tables first and then create a Field parameter in the Desktop to dynamically switch the data source of the visual display.

vmengmlimsft_0-1731485566356.png

 

 

Here is my test and attached pbix file for your refernce.

When I selected Date column of Table1, the visual showed data of Table1.

vmengmlimsft_1-1731485960979.png

When I selected Test1 column of Table2, the visual showed data of Table2.

vmengmlimsft_2-1731485976248.png

 

 

 

Best regards,

Mengmeng Li

HFT
Helper I
Helper I

Is there any workaround to make a dynamic API call based on slicer? I know we can make a parameter in Power Query and then bind a field to that parameter and link that field to a slicer. However, this is only supported in Direct Query mode and, from my understanding, APIs do not support Direct Query in Power BI. Is there any alternative solution to this such as using Power Automate/Flow or any other Microsoft/third-party services?

mattiasdesmet
Resolver II
Resolver II

Hi, could you provide some more concrete detail? The slicer acts on data in the model, and wouldn't determine what API to import. You can import all different APIs and potentially add a field from which API the data is coming, which is then used in the slicers. The import operation happens when the dataset is refreshed, not at slicer change time.

Helpful resources

Announcements
Notebook Gallery Carousel1

NEW! Community Notebooks Gallery

Explore and share Fabric Notebooks to boost Power BI insights in the new community notebooks gallery.

April2025 Carousel

Fabric Community Update - April 2025

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

Top Solution Authors