SOLVED

How to query to find all users who are managed by a specified individual

Iron Contributor

Hi,

Wondering if it is possible to query (using PnP JS) to get user profiles for all users who are managed by a specified individual?

Im guessing it can done using clientPeoplePickerSearchUser (https://pnp.github.io/pnpjs/sp/profiles/#search-a-user-or-group), but I am not sure how to structure a query based on the Manager profile

Thanks!

2 Replies
best response confirmed by Nigel Witherdin (Iron Contributor)
Solution

@Nigel Witherdin

Achieved this with MS Graph API call to get a users "directReports" 

@Nigel Witherdin  there's also the Office 365 Users Get Direct reports (V2) action in Power Automate which will get the list quickly and easily.

 

Rob
Los Gallardos
Microsoft Power Automate Community Super User

1 best response

Accepted Solutions
best response confirmed by Nigel Witherdin (Iron Contributor)
Solution

@Nigel Witherdin

Achieved this with MS Graph API call to get a users "directReports" 

View solution in original post