简体   繁体   English

访问Azure Active Directory用户和角色

[英]Accessing Azure Active directory users and roles

As Azure REST APIs helps to retrieve the users and corresponding roles information at subscription level. 由于Azure REST API有助于在订阅级别检索用户和相应角色信息。

I would like to know that I have manually created a few users and assigned them different roles in Azure Active directory and i want to access those information from azure active directory through REST API calls or in a programmatic way. 我想知道我已经手动创建了一些用户,并在Azure Active Directory中为他们分配了不同的角色,我想通过REST API调用或以编程方式从Azure活动目录中访问这些信息。

How can I access that information at azure active directory level to retrieve the user list ? 如何在Azure活动目录级别访问该信息以检索用户列表? is there any API calls available ? 有没有可用的API调用? what about GRAPH API on this scenario and how it can be used ? GRAPH API在这种情况下又如何使用呢?

Please input your suggestions. 请输入您的建议。 Thanks All ! 谢谢大家!

Yes, you can do this via the REST API. 是的,您可以通过REST API执行此操作。

There are two APIs available: 有两种可用的API:

  1. Azure Active Directory Graph API - graph.windows.net (old) Azure Active Directory Graph API-graph.windows.net (旧)
  2. Microsoft Graph graph.microsoft.com (new). Microsoft Graph graph.microsoft.com (新)。

You should go with the new graph.microsoft.com API (check whether the new API covers all your requirements). 您应该使用新的 graph.microsoft.com API(检查新API是否满足您的所有要求)。

See Working with users in Microsoft Graph 请参阅使用Microsoft Graph中的用户

You can use Microsoft Graph to list all users: https://developer.microsoft.com/en-us/graph/docs/api-reference/v1.0/api/user_list 您可以使用Microsoft Graph列出所有用户: https : //developer.microsoft.com/zh-cn/graph/docs/api-reference/v1.0/api/user_list

https://graph.microsoft.com/v1.0/users/

You can give it a try with the Graph Explorer at https://developer.microsoft.com/en-us/graph/graph-explorer 您可以在https://developer.microsoft.com/zh-cn/graph/graph-explorer上使用Graph Explorer进行尝试

You will need an access token to call Microsoft Graph, more information about obtaining an access token can be found here: https://developer.microsoft.com/en-us/graph/docs/concepts/auth_overview 您将需要访问令牌才能调用Microsoft Graph,有关获取访问令牌的更多信息,请参见: https : //developer.microsoft.com/zh-cn/graph/docs/concepts/auth_overview

You could use the Azure AD Graph API to retrieve users list and corresponding roles by using GET https://graph.windows.net/myorganization/users?api-version=1.6 . 您可以通过使用GET https://graph.windows.net/myorganization/users?api-version=1.6来使用Azure AD Graph API检索用户列表和相应的角色。 For the details, please read here . 有关详细信息,请在此处阅读。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 将批量用户上传从本地数据库移动到 JAVA 中的 azure b2c 活动目录 - move bulk users upload from local db to azure b2c active directory in JAVA JWT CSOM / REST Azure活动目录 - JWT CSOM/REST Azure Active Directory 将Microsoft帐户添加到Azure Active Directory - Adding Microsoft Accounts to Azure Active Directory 基本身份验证而不是 AAD(Azure Active Directory)身份验证 - Basic Authentication instead of AAD (Azure Active Directory) Authentication 用于更改 Azure Active Directory 用户个人资料图片的 REST API - REST API to change Azure Active Directory user profile picture OneDrive API 和 Azure Active Directory 设置以作为个人帐户上传 - OneDrive API and Azure Active Directory setup to upload as personal account SCIM 端点和用户配置与 Azure Active Directory 和 Symfony - SCIM endpoint and user provisioning with Azure Active Directory & Symfony Azure Active Directory 用于保护自定义 JS 前端和 Java Rest ZDB974238714CA8ADE4D638 - Azure Active Directory for securing Custom JS Frontend and Java Rest API 通过SharePoint Online上的SP.WebRequestInfo调用Azure活动目录图REST api - azure active directory graph REST api call through SP.WebRequestInfo on SharePoint Online 使用Azure Active Directory作为Spring-boot REST服务的OAUTH2身份验证服务 - Using Azure Active Directory as an OAUTH2 Authentication service for a Spring-boot REST service
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM