大网数据广告活动
域与目录服务

Microsoft Graph List Users API Only Return One User

· 52CE 我爱测

Provides a solution to an issue where the Microsoft Graph REST API List users only returns one user in a directory.

This article provides a solution to an issue where the Microsoft Graph REST API List users only returns one user in a directory.

Symptoms

Consider the following scenario:

  • You sign in to Microsoft Graph Explorer by selecting the profile icon at the top right.

    :::image type="content" source="media/only-one-user-returned-by-microsoft-graph-list-users-api/microsoft-graph-explorer-sign-in.png" alt-text="Screenshot that shows the sign-in button in Microsoft Graph Explorer." lightbox="media/only-one-user-returned-by-microsoft-graph-list-users-api/microsoft-graph-explorer-sign-in.png":::

  • After sign-in, you try to run this query GET https://graph.microsoft.com/v1.0/users to retrieve all users in your directory.

In this case, only one user is returned. The expected output is a list of multiple users from the directory.

Cause

This issue occurs because you sign in with a personal Microsoft account (MSA), as shown in the preceding screenshot. Personal accounts don't have access to organizational directory data in Microsoft Entra ID. As a result, the query only returns the user associated with the personal account.

Solution

To retrieve all users in the directory, you must sign in to Microsoft Graph Explorer using an organizational Microsoft Entra account, such as userPrincipalName = name@tenant.onmicrosoft.com.

Source: Microsoft Learn / IT Pro troubleshooting by Microsoft and contributors. Documentation licensed CC BY 4.0. Code samples are covered by the MIT License. Converted from Markdown, with links normalized and embedded media omitted.

资料来源与适用范围

资料来源
Microsoft Learn / IT Pro troubleshooting
适用范围
See source applicability · Source date 06/09/2025
内容语言
中文;命令、路径和错误标识保留技术原文
本地收录日期
2026-11-15
授权说明
CC BY 4.0 (documentation), MIT (code samples)

正文与所需资源由本站本地存储。查看来源及更新记录 ↗

请按适用版本和实际日志确认原因;本站没有对每一种系统或设备逐项执行文中的操作。