Showing results for 
Search instead for 
Did you mean: 
Regular Visitor

Power BI API Full Refresh Dataset Fails


1. Created a service principal - API Permssions Dataset.ReadWrite.All and Report.ReadWrite.All

2. Enabled service principals access to Power BI tenant

3. Added the service principal into Workspace Dev

4. Imported dataset model and reports to a Workspace Dev - Success

5. Update Parameters and Datasources via API - Success

6. Full Refresh API kicks off after several seconds always Failed. Incremental Refresh run for a minute and completes.


error view on the Power BI service, I can't find a detailed error log for a meaningful information. Any idea to troubleshoot this process, I have exhausted google search.


Data source error:Retry attempts for failures while executing the refresh exceeded the retry limit set on the request.


Power BI API on Post refreshes return 202 accepted.


$report = Get-PowerBIReport -Name $ReportName -WorkspaceId $workspace.Id -Verbose

$templateUrl = "{workspaceId}/datasets/{datasetId}/refreshes"
$urlPostRefresh = $templateUrl.Replace("{datasetId}", $report.DatasetId).Replace("{workspaceId}", $workspace.Id)

$refreshBody = @'
"type": "{type}",
"retryCount": 2
$body = $refreshBody.Replace("{type}", $type)   ===> is replace with either Full or Automatic


Invoke-PowerBIRestMethod -Url $urlPostRefresh -Method Post -Body $body -Verbose



Super User
Super User

Is this in a Pro or Premium workspace? With Pro you're limited to 8 refreshes per day so maybe you consumed them while testing? Does it work when you refresh that dataset manually?

1. How to get your question answered quickly - good questions get good answers!
2. Learning how to fish > being spoon-fed without active thinking.
3. Please accept as a solution posts that resolve your questions.
More tips and guidance in my Power BI architecture and development blog

The client has Embedded PowerBI, upon manual refresh got error "Scheduled refresh has been disabled". The owner of dataset is the service principal which has worked on creating/updating datasets and reports and updating Parameter and Datasource for each workspace Dev/Uat.

Power BI dataset/report solution is the cloud but I have read to allow manually refresh fo service principal requires to be added on the managed gateways data source as list of users but again client solution is on the cloud.

On a dataset its Datasource was replaced successfully correct database and database server which is the one trying to do a Full refresh via API. Interesting enough needs further investigation on another dataset same Workspace updating database and server, it worked but it kept the old configuration database and server; hence I do have two entries, search how to fix this one cause would have issues Incremental/Full Refresh.

I have read this as well, 


Bootstrapping the initial refresh operation either through Tabular Editor or creating an empty query in Power Query to allow the service to create partition objects for the incremental refresh table, but not load and process historical data.


Helpful resources

November 2022 Update

Check it Out!

Click here to read more about the November 2022 updates!

Power BI Dev Camp Session 27

Ted's Dev Camp

This session walks through creating a new Azure AD B2C tenant and configuring it with user flows and custom policies.

Health and Life Sciences Power BI User Group

Health and Life Sciences Power BI User Group

Power BI specialists at Microsoft have created a community user group where customers in the provider, payor, pharma, health solutions, and life science industries can collaborate.

Top Solution Authors
Top Kudoed Authors