Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Trying to use the Add Datasource User operation (https://docs.microsoft.com/en-us/rest/api/power-bi/gateways/adddatasourceuser)
I am an owner of the data gateway in question, and I can read the gateway info and datasources fine using the API, but when I try to add a service principal to a datasource I get a 401 error (with no additional detail in the response).
Are there any special permissions required for adding a user to a datasource?
The documentation only mentions users and email enabled security groups. Service principals are not mentioned.
https://docs.microsoft.com/en-us/power-bi/connect-data/service-gateway-data-sources#manage-users
Check out the July 2025 Power BI update to learn about new features.
User | Count |
---|---|
6 | |
6 | |
3 | |
2 | |
2 |
User | Count |
---|---|
6 | |
5 | |
4 | |
4 | |
3 |