从Azure订阅中检索所有用户信息 [英] Retrieving the all the users information from Azure Subscription

查看:63
本文介绍了从Azure订阅中检索所有用户信息的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们可以获取所有用户列表 使用以下文章从Azure订阅中删除.

I want to retrieve all the user information from Subscription. We can get all the user list from an Azure subscription using below article.

但在上面URl检索所有用户GUID的列表(以及更多信息),但在这里我希望用户显示 名称,邮件ID等.

But above URl retrieves list of all User GUIDs(and some more information) but here i want user display name, mailid, etc.

请帮助我,我该怎么做.

Please help me How can i do this.

我们可以将此用户GUID发送到graph API来检索用户信息,但需要得到租户管理员的同意,我们还需要再进行两次额外的调用(一个是获取Graph Bearer访问令牌,另一个是使用上面列出的对实际Graph API的调用用户GUID). 因此,我该如何在没有图形API的情况下执行此操作.

We can send this user GUIDs to graph API to retrieve the User information but it needs consent from Tenant admin and also we need two more extra calls(one is to get Graph bearer access token and other is call to actual graph api with above list of User GUIDs). So how can i do this with out graph API.

推荐答案

您可以检查执行此操作的PowerShell方法- https://docs.microsoft.com/en-us/rest/api/graphrbac/users/get#user 这确实使用了Graph API.

You may check the PowerShell way to do it - https://docs.microsoft.com/en-us/powershell/module/azurerm.resources/get-azurermaduser?view=azurermps-6.6.0 let us know if that helps. In addition to that you can try this link - https://docs.microsoft.com/en-us/rest/api/graphrbac/users/get#user this does uses Graph API. 

--------------------------------------------------- -------------------------------------------------- ----------------------------------
如果此答案有帮助,请单击"标记为答案",然后单击投票.要提供有关您的论坛体验的其他反馈,请单击 这里 

-----------------------------------------------------------------------------------------------------------------------------------
If this answer was helpful, click "Mark as Answer" and Up-Vote. To provide additional feedback on your forum experience, click here 


这篇关于从Azure订阅中检索所有用户信息的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆