cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
BP-PT
Helper III
Helper III

SharePoint Permissions Flow Clearing Folder Permissions and Adding a Group

Hello,

 

I have a flow, which feels like it's so close to being complete. The aim of the flow, simply put, is to do the following:

 

  1. Create a predefined parent folder. This parent folder then also has 5 other sub-folders generated (all as part of this same flow).
  2. Inheritance is then switched off for some of the subfolders of the newly created parent folder.
  3. Need help withNow that inheritance is switched off for the required subfolders, I need a way of clearing all existing permissions against them.
  4. Need help withFinally, I need to add a group called 'Management' to the same subfolders that the above has been actioned against, giving them just the usual edit permissions.

Would really, really appreciate any help on this, as this has been something I've been trying to work on and figure out for a long time.

 

Thanks,

Billy

 

5 REPLIES 5
tom_riha
Super User
Super User

Hello @BP-PT ,

you can remove permissions using HTTP requests as described here: https://tomriha.com/how-to-remove-permissions-from-a-sharepoint-folder-with-power-automate/.

The correct permissions can be then assigned back using the 'Grant access to an item or a folder' action. Or with a few more HTTP requests if the 'Management' group is a SharePoint group.



[ If I have answered your question, please Accept the post as a solution. ]
[ If you like my response, please give it a Thumbs Up. ]

[ I also blog about Power Automate solutions even for non-IT people. ]

Hi @tom_riha ,

 

Thank you so much for your response - this has been incredibly helpful.

 

I'm just stuck at the last step now, which is adding in the Management group with permissions. This is a O365 security group. Please can you help me with this and then I can be done with this 😄 

 

Thanks,

Billy

If it's an O365 security group then you can use the 'Grant access to an item or a folder' to assign the permission to each of the folders.



[ If I have answered your question, please Accept the post as a solution. ]
[ If you like my response, please give it a Thumbs Up. ]

[ I also blog about Power Automate solutions even for non-IT people. ]

@tom_riha , thank you for this, much appreciated.

 

Is there a way that I can basically apply this process (as per my original post) for 5 subfolders created without having to duplicate each seperate process in the flow for removal, listing and addition of permissions for each subfolder?

 

Thanks,

Billy

Hello @BP-PT ,

it depends on how you create the folders. If you create the subfolders in some loop then you could do all the permission settings right after you create the folders.



[ If I have answered your question, please Accept the post as a solution. ]
[ If you like my response, please give it a Thumbs Up. ]

[ I also blog about Power Automate solutions even for non-IT people. ]

Helpful resources

Announcements
Microsoft 365 Conference – December 6-8, 2022

Microsoft 365 Conference – December 6-8, 2022

Join us in Las Vegas to experience community, incredible learning opportunities, and connections that will help grow skills, know-how, and more.

Users online (4,834)