📜  microsoft graph 到“ldap” - 任何代码示例

📅  最后修改于: 2022-03-11 14:56:53.489000             🧑  作者: Mango

代码示例1
private static async Task GetUserGroupsAsync(HttpClient client, string user)
        {
            var payload = await client.GetStringAsync(
                $"https://graph.microsoft.com/v1.0/users/{user}/memberOf");
            var obj = JsonConvert.DeserializeObject(payload);
            var groupDescription = from g in obj["value"]
                                   select g["displayName"].Value();

            return groupDescription.ToArray();
        }