Microsoft Graph - 列出人员的范围' API?

时间:2017-02-15 22:08:24

标签: microsoft-graph

使用Graph Explorer时,我可以使用' List People'像这样的API:

https://graph.microsoft.com/beta/users/<user id>/people

<user id>可以是组织中的任何用户。

但是,当我构建自己的应用程序时,我只能在登录用户上调用List People API。在另一个用户上调用它会得到一个拒绝许可的响应。

我应该使用什么范围,以便我可以在任何用户上使用列表人员?

根据List People API的文档

"The following scopes are required to execute this API: People.Read; People.ReadWrite"

但是People.Read只有"Allows the app to read a ranked list of relevant people of the signed-in user."People.ReadWrite并不存在于权限范围列表中。

2 个答案:

答案 0 :(得分:0)

答案 1 :(得分:0)

此调用类型需要People.Read.All,必须由管理员同意您的应用才能调用它。

文档在这里:MS Graph : List People