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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
lucadelicio
Impactful Individual
Impactful Individual

Import Sharepoint userid - userGroupId from Sharepoint REST API with scheduled refresh

Hi everybody,
to obtain the user list of a sharepoint site in this format:
UserId - GroupId
i create a parametric function that invoke a rest api with the groupId as parameter:
https://mysite.sharepoint.com/sites/mysite/_api/web/SiteGroups/GetById(groupNumber)/Users
I use the "invoke custom function" to invoke my function on the table with all the id group and with some transformations of the json files returned, i arrive to a table with all the users by group of the site in the format that i need:
 UserId - GroupId

lucadelicio_0-1710167087161.png

But the problem is on the authentication.
Everytime that i call the REST API it needs a specific authentication and so if a new group come in i have to put the authentication credential on the power bi desktop and service.

There is a way to authenticate every REST API call only one time, in consideration that the credential (user and password) are the same and have the dataset refresh on power bi service?
The api call is the same but it change the group number id.
Someone as an idea to resolve?
Exist for example a call that returns every user of the sharepoint site with is GroupId?
Thank you in advice!



Luca D'Elicio

LinkedIn Profile
1 REPLY 1
Anonymous
Not applicable

Hi @lucadelicio ,

Sorry, so far, to my knowledge, this may not be achieveable.

 

But you could submit idea in this site Home (microsoft.com), if a idea is high voted there by other customers, it will be promising that Microsoft Product Team will take it into consideration when designing the next version in the future.

 

Best regards,
Community Support Team_Binbin Yu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Top Solution Authors
Top Kudoed Authors