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
dkakhanouski
Frequent Visitor

Share Dataset (or Report) from API to users

Hi!

I develop dataset stored in SSAS tabular with live connection to it (through On-prem Gateway)
I want to give users possibility to create their own reports based on this dataset.
For now I investing possibilities how to do that. That's what i already tried:

1. Workspaces.
I created workspace and added some template report with my dataset. It works fine for all users in workspace! But users can be added dynamically to SSAS model and according to requirements I should add this users to workspace. The problem is I can't do it in programmatically way (by any API call or something like that).
I tried workaround to add domain group to this workspace and then add users to it programmatically. But in this case those users should ask permission to view report that is unacceptable.

2. Apps.
I encapsulated some template report with my dataset to app. I published this app to organizational (domain) level. In this case users can see report from this app. But they cannot create other reports based on my dataset.

3. Programmatically share report to users by email.
But no any API for it.

Any ideas?

Thank you

1 ACCEPTED SOLUTION

@dkakhanouski ,

 

You can use Group rest api like 

POST https://api.powerbi.com/v1.0/myorg/groups/{groupId}/users

For more details, please refer to power bi rest api reference: 

https://docs.microsoft.com/en-us/rest/api/power-bi/groups/addgroupuser

 

Community Support Team _ Jimmy Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-yuta-msft
Community Support
Community Support

@dkakhanouski ,

 

You can assign those users as members and select "Members can edit Power Bi Content" in app workspace settings.

Capture.PNG 

 

Community Support Team _ Jimmy Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

@v-yuta-msft, thank you for answer.

I know about this way. On this way I can do it manually. But users can be added to SSAS dynamically (automatically, not from my side) on synchronization. I looking for some API or PowerShell script that I can add to process of synchronization and do the same thing programmatically. Is it possible somehow?

 

@dkakhanouski ,

 

You can use Group rest api like 

POST https://api.powerbi.com/v1.0/myorg/groups/{groupId}/users

For more details, please refer to power bi rest api reference: 

https://docs.microsoft.com/en-us/rest/api/power-bi/groups/addgroupuser

 

Community Support Team _ Jimmy Tao

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

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 Solution Authors
Top Kudoed Authors