cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Kadd
Resolver III
Resolver III

Adding newly create site to "Site Permissions" section ( XXX/_layouts/15/user.aspx )

Hello !

 

Hope you are all doing well.

 

I managed to use Power Automate to create SP groups and add users to them. 

The problem i have is the newly created groups are created at the "root" 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.

 

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

 

Thanks a lot in advance !!

 

1 ACCEPTED SOLUTION

Accepted Solutions
Kadd
Resolver III
Resolver III

Hello @jinivthakkar ,

 

Thanks a lot for you answer.

 

I don't want to add the group to the panel, i simply want to add it to the site, on the "user.aspx" page. because if the group is not at the site level, users have access to the library you grant them access to but they do not see any site (it's like they open a OneDrive with restricted access)

 

I created flows to automate permission assignment at the root, list, library  and item level  and this works great but i was always missing the site level so people couldn't see the left handed menu and navigate through the site..

 

But i found the way (thanks to someone from another forum who made me understand this 😄 ) and, in fact ,that was very simple... just using "web" in the URI field of the HTTP request, you have to put: 

 

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

 

I never figured out that "web" will just add to the site 😛  but...this does the trick !

 

 

voila ! 🙂

View solution in original post

2 REPLIES 2
jinivthakkar
Super User
Super User

I don't think you can add your custom group here in the site permissions panel, it will only show owners/members/visitors.

 

You can find your group by clicking on Advanced permission settings.

 

jinivthakkar_0-1610962550733.png

Try SPFX but I am not sure about it too.

Kadd
Resolver III
Resolver III

Hello @jinivthakkar ,

 

Thanks a lot for you answer.

 

I don't want to add the group to the panel, i simply want to add it to the site, on the "user.aspx" page. because if the group is not at the site level, users have access to the library you grant them access to but they do not see any site (it's like they open a OneDrive with restricted access)

 

I created flows to automate permission assignment at the root, list, library  and item level  and this works great but i was always missing the site level so people couldn't see the left handed menu and navigate through the site..

 

But i found the way (thanks to someone from another forum who made me understand this 😄 ) and, in fact ,that was very simple... just using "web" in the URI field of the HTTP request, you have to put: 

 

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

 

I never figured out that "web" will just add to the site 😛  but...this does the trick !

 

 

voila ! 🙂

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

New Ideas Forum MPA.jpg

A new place to submit your Ideas for Power Automate

Announcing a new way to share your feedback with the Power Automate Team.

MPA Virtual Workshop Carousel 768x460.png

Register for a Free Workshop

Learn to digitize and optimize business processes and connect all your applications to share data in real time.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Users online (5,078)