0

I managed to use Power Automate to create SP groups and add users to them using the HTTP request action.

The problem I have is the newly created groups are created at the "root" (in People and Groups section) level but not in the site in the "Site Permissions" section so user that i add to the group still do not have access to the site.

I created a flow that adds the group(s) to "site Pages" , "Site assets" and to the specific libraries but they don't have access to the site itself since the groups are not in "Site Permissions".

Does anyone know how to add a newly created group to "Site Permissions"?

1

After creating a SharePoint group, you need to assign the permissions to it at site (web) level.

Add a new action 'Send HTTP request to SharePoint' and configure the action to use endpoint as below:

/_api/web/roleassignments/addroleassignment(principalid=<GROUPID>, roledefid=1073741827)

roledefid is for Permission Levels which are as follows:

1073741829 - Full Control

073741827 - Contribute

1073741826 - Read

<GroupID> is the id of the group.

Reference: SharePoint Group Operations in Microsoft Flow

1
  • Hi @Ganesh Sanap, thanks a lot for your help !! It works ! I manage to add custom permissions to lists, libraries and items but i didn't figure out simply using "web" would add to the site :-P thanks a lot !!! – Kaddrik Jan 18 at 10:51

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.