我们有一个用户查询访问了过去几个月一直在工作的/beta端点,在过去几天的某个时间里,它停止工作并返回一个Authorization_RequestDenied错误。
使用图形探索者,我把范围缩小到使用accountEnabled eq true filter子句。如果删除此filter子句,则查询工作。
完整的查询是:
https://graph.microsoft.com/beta/users?$filter=(startswith(givenName,%27sim%27)%20or%20startswith(surname,%27sim%27)%20or%20startswith(displayName,%27sim%27))%20and%20accountEnabled%20eq%20true&$select=id,userPrincipalName,givenName,surname,displayName,mail,userType
我做了一个快速的搜索,但没有在变化中找到任何东西。
确切的错误是:
{
"error": {
"code": "Authorization_RequestDenied",
"message": "Insufficient privileges to complete the operation.",
"innerError": {
"request-id": "d04d57d3-6e43-4e73-860a-ef721636929b",
"date": "2018-05-12T20:02:57"
}
}
}发布于 2018-05-11 05:39:00
从列表用户API那里。
重要:MicrosoftGraph中/beta版本下的API处于预览状态,可能会发生更改。不支持在生产应用程序中使用这些API。
我不能用你提供的完整查询来复制它。对我来说是正确的。

https://stackoverflow.com/questions/50174301
复制相似问题