web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Automate / How To filter people i...
Power Automate
Unanswered

How To filter people in flow from people field of sharepoint

(0) ShareShare
ReportReport
Posted on by 43

Hi all,

 

I am creating flow fetching details of different sites owned by different owners and admins. I want to emails to different owners and admins at differnt times . how can I filter the users based on the no of ownership and send email to that particular no of owned site . To give more insite tomy requirement ., My one scenario would like , if there is 0 site aadmin and 1 owner then i want to send emails to 1 owners of respective sites . same is the case with other scenarios.

 

Any leads would be appreciated

@yashag2255 @RezaDorrani 

Categories:
  • v-albai-msft Profile Picture
    Microsoft Employee on at

    Hi @KanwalKaurSaini 

    What do you mean about site admin? Do you mean the users who have SharePoint admin role configured in Microsoft 365?

    From your information, I think you want to send email to all site owners in a specified site. If yes, you can use “Send an HTTP request to SharePoint” action to get a list of site owners and then you can send emails to them.

    Since you want to send emails at different times, I create a Scheduled flow for a test.

    1. add a “Send an HTTP request to SharePoint” action, select “Get” of Method, and set Uri to below(testpowerapp is my site name):

    _api/Web/SiteGroups/GetByName('yoursitename Owners')/users

    valbaimsft_0-1626341142430.png

     

    2. Add a Array Variable called users, using this expression:

    body('Send_an_HTTP_request_to_SharePoint')['d']['results']

    valbaimsft_1-1626341142432.png

     

    3. Addanother  two variables:

    valbaimsft_2-1626341142434.png

     

    4. Append each email into the user variable:

    concat(variables('users')[variables('i')]['Email'],';') 

    valbaimsft_3-1626341142437.png

     

    Here is the full flow:

    valbaimsft_4-1626341142440.png

     

    In the last of the flow, send email directly using the user variable(I add a compose action to check the result):

    valbaimsft_5-1626341142443.png

     

    valbaimsft_6-1626341142444.png

    Reference:

    https://www.portiva.nl/portiblog/2018/06/05/microsoft-flow-perform-actions-on-users-in-a-sharepoint-group-using-the-api

    Best regards,

    Allen

  • KanwalKaurSaini Profile Picture
    43 on at

    Hi ,

     

    In my Use case I have one master list having details of different sites with their primary and secondary admins and owners. They can be admin of either one site or owners of multiple sites .Either of the case it could be . I need to send 1 email only to owners (if there is no site admin for that sites ) & admins (if there is atleast one admin and 1 owner) to provide details of other admins and owners as part of our SHarePoint governance . How could this be achieved without sending multiple emails to users . How could I get unigue list of users in this case.

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Automate

#1
David_MA Profile Picture

David_MA 227 Super User 2026 Season 2

#2
11manish Profile Picture

11manish 221 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 132

Last 30 days Overall leaderboard