I'm trying to query a specific Power BI dataset using the REST API and a Python script with a service account for authentication. However, I'm encountering an "Access Denied" error for this particular dataset.
Dataset details: The dataset uses dataflows as its data sources apart from this, there is nothing special with it. The workspace is a fabric workspace (this one is currently on trial)
Service Account: The service account I'm using has the necessary permissions and works correctly for other datasets within the same tenant and workspaces.
Azure App Permissions: I have already confirmed that the Azure app used by the service account has been granted Dataset.ReadWrite.All access.
Debugging steps so far:
- Queried other datasets within the same tenant using the same script and service account. No issues were encountered.
- Verified that the service account has access to the dataset and related resources (dataflows).
- Given these points, I suspect the issue might be related to how access tokens or permissions are configured for datasets that use dataflows as sources. Oddly when using dax studio or even Microsoft learn api explore with my user i get not issue.
My Questions
Are there any special permissions or configurations required for service accounts to access datasets with dataflows as sources?
Could this issue be related to the way access tokens are being validated for datasets with dataflows?
What steps would you recommend to debug or resolve this access issue?