Forum Discussion
Anonymous
4 years agoNot applicable
Power BI REST API gives 403 forbidden (use service principal)
Hi everyone, I want to get the powerbi dataset refresh history programmatically so I need to call the Power BI API using the below method, GET https://api.powerbi.com/v1.0/myorg/groups...
- 4 years ago
Have you considered using AAD auth instead?
Also, there's this:
lbendlin
4 years agoSuper User
"added the app (service principal) as admin in my Power BI Workspace,"
But you are using an API call against Premium workspaces. Does your service principal have access to the Premium workspaces you are trying to access?
Anonymous
4 years agoNot applicable
Hi lbendlin , I granted my service principal as admin role in this premium workspace (as figure 3) so I believe it can access the content.