Hi! I'm looking for a way to create a list of all users that belong to a SharePoint site. This is what I've made so far:
However, the request runs forever and the status message says BadGateway. The same thing happens if I change my address to the main page (that is, removing /sites/technology).
Anyone knows what I could be doing wrong?
Solved! Go to Solution.
@ErikPrimozone , as far as i know there isnt any out of the box trigger available to start the flow when users are assign permissions to site or subfolder.
However you can setup alert policies from M365 compliance center refer this blog https://www.anupams.net/alert-policies-office-365/ or you can setup alerts from audit logs based on activities refer following documentation
https://docs.microsoft.com/en-us/microsoft-365/compliance/create-activity-alerts?view=o365-worldwide
@ErikPrimozone , are you trying to get users from Technology Site Group, as you have GetByName('technology')/users in the Uri, please make sure technology group exist, or replace it with a valid group name. Also are you looking for all users of site or users of specific group? The Uri that you have used gives users of specific group.
Hi @annajhaveri and thanks for the quick reply.
Yes, I'm looking only to extract users from that group in particular. Although I'm not sure if the 'technology' is the correct term to use in GetByName. I simply assumed that the name would be the same as the last word in the URL. How can I be sure that I'm using a valid group name?
Are you looking to get users from specific SharePoint group? Then first go to following URL in your SharePoint site to see what SharePoint Groups exists in the site, replace <siteURL> with your site URL. On this page you will see the groups where type is mentioned as SharePoint group and use that name in the Uri of the Flow action.
https://<siteURL>/_layouts/15/user.aspx
Thanks @annajhaveri, your solution worked great for listing the user groups in an HTTP request.
I do realize that my inquiry should have been more detailed, however. My end goal here is to get a notification when additional permissions are added to any part of the site. Since the groups I find at https://<siteURL>/_layouts/15/user.aspx are only top-level, I can't tell when an indidivudal user has been granted unique permissions to a subfolder.
Do you have any ideas here?
@ErikPrimozone , as far as i know there isnt any out of the box trigger available to start the flow when users are assign permissions to site or subfolder.
However you can setup alert policies from M365 compliance center refer this blog https://www.anupams.net/alert-policies-office-365/ or you can setup alerts from audit logs based on activities refer following documentation
https://docs.microsoft.com/en-us/microsoft-365/compliance/create-activity-alerts?view=o365-worldwide
I am new to flow, Can you please share, how can I retrieve all users and their permissions of site?
@chandrashekar07 is this a one time process to be done or repetitive?
It has to be done on a repetitive twice a day.
User | Count |
---|---|
89 | |
40 | |
23 | |
20 | |
16 |
User | Count |
---|---|
130 | |
51 | |
48 | |
36 | |
26 |