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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
DustineTolete
Frequent Visitor

DMTS_DatasourceAccessRightIsNotSupportedError when trying to grant SPN account access to gateway

Hello. I am getting an issue when trying to grant an SPN account access to a gateway. I am creating a request using the PowerBI Rest API, as we can't explicitly grant an SPN account access to a gateway. I am following these steps on granting the SPN gateway access. Other than that, I don't see anything that is related to this. 

 

When I am running the request, I am getting this error: 

 

gdas.gif

 

I'm not sure if this is a setting. Can anyone help me? 

3 REPLIES 3
Anonymous
Not applicable

Hi @DustineTolete ,

Regarding your problem - after making an update of Gateway to the newest October 2019 (Release 2) version and completing the request with additional attribute "principalType": "App" I was able to successfully POST the request with ServicePrincipal:

 

{
"identifier": "<your SPN Id>",
"datasourceAccessRight": "ReadOverrideEffectiveIdentity",
"principalType": "App"
}

Jayendran
Solution Sage
Solution Sage

Hi @DustineTolete ,

 

Yes currently SPN don't support for Gateways and the data sources. Thats why you are getting these error

 

Capture.JPG

Anonymous
Not applicable

So it's impossible to let a Service Principal manage a gateway (have read/write access)? When I read this I thought it'd be possible: https://github.com/MicrosoftDocs/powerbi-docs/issues/1067

 

What I want to achieve is be able to change a  datasource in a dataset, that's connected through a gateway, using the .net nuget package and the Service Principal, I hope this makes some sence

 

Edit: Also this example shows, pretty clearly according to me, that it should work https://docs.microsoft.com/en-us/rest/api/power-bi/gateways/adddatasourceuser#example-for-giving-rea...

 

Edit 2: Noticed my user, the user i'm using to add the SP to the dataset, only have Read access. Tried chaning it to ReadOverrideEffectiveIdentity but I get the same error as before (same as Original poster got)

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

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

Top Kudoed Authors