如何使用Azure Active Directory图形客户端在Azure B2C中删除具有相同用户名\电子邮件地址的所有用户?

问题描述 投票:0回答:1

B2C Azure AD的用户具有与'[email protected]'相同的电子邮件地址。

User name                User type       Source                
[email protected]       Member          Azure Active Directory
[email protected]       Member          Microsoft Account
[email protected]       Member          Facebook

请注意,Source列有所不同。电子邮件是相同的。

现在,当我进行这样的搜索时:

GET https://graph.windows.net/myb2ctenant.onmicrosoft.com/users?api-version=1.6&$filter=signInNames/any(x:x/value%20eq%20%[email protected]%27)

我仅得到一行:来源为= Azure Active Directory的那一行,但外部身份提供商(IDP)的另外两行没有。

我如何一次检索与该用户名\电子邮件地址匹配的3行?

一旦获得这3个用户,我想将其删除。

#######编辑####### >>

来自Chris Padget answer,我可以这样获得以Facebook为发行人的用户:

Get-User $filter=userIdentities/any(x:x/issuer%20eq%20%27facebook.com%27)

B2C Azure AD的用户具有与'[email protected]'相同的电子邮件地址。用户名用户类型来源[email protected]成员Azure ...

c# azure-active-directory azure-ad-b2c delete-row
1个回答
0
投票

在摆弄了$filter选项之后,我像这样单张拍摄:

© www.soinside.com 2019 - 2024. All rights reserved.