cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
mantastg08876
Responsive Resident
Responsive Resident

Power Automate to Check if a person exists in a SharePoint group

Hi all, 

 

I am creating a flow which would check whether  selected person is included in the SharePoint group, and if yes, then send an email.

 

My approach, which fails at step 3:

1. get the email as string value from the Sharepoint by initializing and appending string variable;

2. get the members of a SharePoint group by sending HTTP request to SharePoint

3. create a condition which would check whether the body from step 2 contains the email address retrieved in step 1

 

2020-09-24_16-01-04.png

 

I have also tried using O365 List group members connector, but i enter my group's id as a custom, I get the error: 

Flow save failed with code 'OpenApiOperationParameterValidationFailed' and message 'Input parameter 'groupId' validation failed in workflow operation 'List_group_members': The parameter with value '"ResponsibleManagers_CNS"' in path 'groupId' with type/format 'String' is not convertible to type/format 'String/uuid'.'.

 

Also tried filtering the "Send an HTTP request to SharePoint" out to array using the following expression, but failed. 

contains(string(item()?['Email']),'@{@{triggerBody()?['Responsible_manager']?['Email']}')

 

Could someone please advice what could the possible solution? 

2 ACCEPTED SOLUTIONS

Accepted Solutions
PrasadAthalye
Super User
Super User

@mantastg08876  - Unfortunately, Power Automate does not have any actions that work with SharePoint group. Its a must add. 

 

Try following link and see if you can use REST API...

https://powerusers.microsoft.com/t5/Power-Automate-Community-Blog/SharePoint-Group-Operations-in-Mic...

 

Please like and mark this as solution if it resolves your issue.

Please Like and Mark this as Answer if it resolves your Issue.

Power Automate Community

View solution in original post

@PrasadAthalye, many thanks for the link! I also found some example and solution on YT: 

Get Email Addresses for Members of a SharePoint Group with Power Automate (Microsoft Flow) 

 

Final solution looked liked this:

2020-09-25_10-59-16.png

 

 

 

 

View solution in original post

3 REPLIES 3
PrasadAthalye
Super User
Super User

@mantastg08876  - Unfortunately, Power Automate does not have any actions that work with SharePoint group. Its a must add. 

 

Try following link and see if you can use REST API...

https://powerusers.microsoft.com/t5/Power-Automate-Community-Blog/SharePoint-Group-Operations-in-Mic...

 

Please like and mark this as solution if it resolves your issue.

Please Like and Mark this as Answer if it resolves your Issue.

Power Automate Community

View solution in original post

@PrasadAthalye, many thanks for the link! I also found some example and solution on YT: 

Get Email Addresses for Members of a SharePoint Group with Power Automate (Microsoft Flow) 

 

Final solution looked liked this:

2020-09-25_10-59-16.png

 

 

 

 

View solution in original post

I am glad it helped...

Please Like and Mark this as Answer if it resolves your Issue.

Power Automate Community

Helpful resources

Announcements
MPA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

V3_PVA CAmpaign Carousel.png

Community Challenge - Giveaways!

Participate in the Power Virtual Agents Community Challenge

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

PowerPlatform 768x460.png

Microsoft Learn

Check out our new Discover Your Career Path blog post series and get all the details.

Top Solution Authors
Users online (1,169)