Вопрос

I am trying to use Power Automate to delete a bunch of SharePoint site groups but it does not seem to be working. My flow is successful but the group(s) are not removed. Google results seem to be more related to removing users from groups, not removing the groups themselves.

Can anyone explain what I've done wrong with my flow action?

My knowledge of REST is very limited at this stage.

My Site group:

Text

My Flow action:

Text

The Flow output:

Text

Это было полезно?

Решение

Try using your flow like below. This works for me:

enter image description here

OR simply like:

enter image description here

Group Settings:

enter image description here

Notable Points:

  1. I have used endpoint like: /_api/web/sitegroups/removebyid('<group-id>'). Group ID is enclosed by single quote (').
  2. In my case I am the owner for both group and flow.

Другие советы

You can ignore the flow output in this case, all you have to do is to remove the Headers part from your Flow action, everything else looks OK. All you need is the POST method to the _api/web/sitegroups/removebyid([id])

Note the headers accepts JSON string, but you're providing it as a JS object. Removing it altogether will make it work.

As long as you're getting Status code 200, it means your flow ran successfully and it actually deleted your group.

Лицензировано под: CC-BY-SA с атрибуция
Не связан с sharepoint.stackexchange
scroll top