cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Frequent Visitor

Remove member of a sharepoint Team site group using "send http request to sharepoint"

Hi,

 

I am looking for a way to remove a member of a group inside of a sharepoint using "send http request to sharepoint".

I know how to add a member to that group using http request (if it can help others) :

 

flow_send_http_request_remove_member.png

 

I tried using delete Method with the same Uri and Body but it's not working.

 

Hope someone can help.

Thanks in advance,

Sriks

 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Dual Super User II
Dual Super User II

Re: Remove member of a sharepoint Team site group using "send http request to sharepoint"

Here's what worked for me

screenshot.png

I'm using the ID's of the group and the user.  NOTE: This will remove the user from the group everywhere in the site collection.  There is no way to remove a user from a group for one permission assignment.  The group membership is stored at the site collection level.



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

View solution in original post

4 REPLIES 4
Highlighted
Super User II
Super User II

Re: Remove member of a sharepoint Team site group using "send http request to sharepoint"

try post instead of get

try added this to your headers:

 

"X-HTTP-Method""DELETE" 

Highlighted
Frequent Visitor

Re: Remove member of a sharepoint Team site group using "send http request to sharepoint"

@Gristy 

Thanks for the help.

my new headers looks like that :

 

"headers": {
"accept": "application/json;odata=verbose",
"content-type": "application/json;odata=verbose",
"X-HTTP-Method": "DELETE"
}

 

Sadly, i got an error running the flow : 

"Microsoft.SharePoint.Client.InvalidClientQueryException"
Highlighted
Dual Super User II
Dual Super User II

Re: Remove member of a sharepoint Team site group using "send http request to sharepoint"

Here's what worked for me

screenshot.png

I'm using the ID's of the group and the user.  NOTE: This will remove the user from the group everywhere in the site collection.  There is no way to remove a user from a group for one permission assignment.  The group membership is stored at the site collection level.



-------------------------------------------------------------------------
If I have answered your question, please mark your post as Solved.
If you like my response, please give it a Thumbs Up.

View solution in original post

Frequent Visitor

Re: Remove member of a sharepoint Team site group using "send http request to sharepoint"

@Pstork1 

Thanks a lot, it's working !

Helpful resources

Announcements
FirstImage

Microsoft Ignite 2020

Check out the announcement of Power Platform content at Microsoft Ignite!

thirdImage

Experience what's new for Power Automate

Join us for an in-depth look at the new Power Automate features and capabilities at the free Microsoft Business Applications Launch Event.

firstImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Users online (6,608)