如何从AAD组获得小组会员资格
我正在尝试从AAD获取所有小组成员资格。我必须命名要寻找的父组,但是我需要获取该父母子组中的用户。我已经尝试了Mayosoft文档上的可能的事情,但是找不到找到这些组的正确请求。
这是一个尝试:
var groups = await graphClient.Groups.Request().Filter($"startswith(displayName, '{Se_groupName}')").GetAsync(); //Fetch the parent group
var groupMembers = await graphClient.Groups[groups.FirstOrDefault().Id].Members.Request().GetAsync(); //Try to fetch the groups inside the first group, but its always empty
我想知道是否有这样的请求:
graphClient.Groups[groups.FirstOrDefault().Id].groupMemberships
I'm trying to fetch all group memberships from an AAD. I have to name of the parent group I want to look for, but I need to fetch the users that are in sub groups of that parent. I've tried may things on the Microsoft docs, but I can't find the right request to find those groups.
This is a try:
var groups = await graphClient.Groups.Request().Filter(quot;startswith(displayName, '{Se_groupName}')").GetAsync(); //Fetch the parent group
var groupMembers = await graphClient.Groups[groups.FirstOrDefault().Id].Members.Request().GetAsync(); //Try to fetch the groups inside the first group, but its always empty
I was wondering is there a request like:
graphClient.Groups[groups.FirstOrDefault().Id].groupMemberships
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
要查找嵌套组和用户,您可以使用
trantivembers
endpoint列表组传递成员
获取https://graph.microsoft.com/v1.0/groups/groups/ {groupiD} /TransitiveMbers
To find the nested groups and users you can use the
transitiveMembers
endpointList group transitive members
GET https://graph.microsoft.com/v1.0/groups/{groupId}/transitiveMembers