Extracting Power BI Data with Power Automate – Fast and Simple
Extract Power BI Data with Power Automate
If you need to extract data from Power BI, Power Automate offers a surprisingly simple and effective approach. My user case is to add data from a Power BI workspace and add it to Dataverse.
While Dataflows are often considered for moving data into Dataverse, they can’t pull data directly from Power BI. Instead, you’d need a two-step process, which can be cumbersome.
A better alternative? Use Power Automate to call the Power BI REST API with a DAX query. Here’s how to do it:
1) Create a Scheduled Flow
Set up a scheduled flow to run at your required frequency.
2) Add the 'Run a query against a dataset' Action
Insert the “Run a query against a dataset” Power BI action.
Choose your workspace and semantic model (dataset).
Provide a DAX query. You can return all the data or alternatively, you can add a filter. You may want to filter on a particular parameter, or just extract the records that have been added in the previous 24 hours.
The query below returns the specified columns for all records:
Ensure that the account you use to run the flow has at least Build permission on the semantic model and Contributor access in the workspace. See here for more info
4) Parse the Output
Run the flow once and copy the output.
Add a Parse JSON action.
Paste in the output from the ‘Run a query against a dataset’ action to generate the JSON schema.
5) Handle the Data
You can now loop through the parsed output and perform any action—such as creating or updating records in Dataverse.
6) Performance & Tips
The API is fast! 15,000 records returned in under 2 seconds in my case.
Not confident with DAX? Tools like ChatGPT or other LLMs can help. Simply describe your semantic model and what data you need—the generated query typically works on the first try or with minor tweaks.