[英]Microsoft graph API: Accessing presences information via an Application scope
I'm trying to access user's presence off of https://docs.microsoft.com/en-us/graph/api/presence-get?view=graph-rest-1.0&tabs=http我正在尝试从https://docs.microsoft.com/en-us/graph/api/presence-get?view=graph-rest-1.0&tabs=http访问用户的存在
I've granted my AD app Presence.ReadWrite.All which is described as "Allows the app to read all presence information and write activity and availability of all users in the directory without a signed-in user. Presence information includes activity, availability, status note, calendar out-of-office message, time zone and location. ".我已授予我的 AD 应用 Presence.ReadWrite.All,它被描述为“允许该应用在没有登录用户的情况下读取目录中所有用户的所有状态信息并写入活动和可用性。状态信息包括活动、可用性、状态说明、日历外出消息、时区和位置。”。
There seems to be a bit of a conflict between the docs and what the permission's name is - the docs seem to imply it doesn't work with an application scope, while the permission name/description seems to say it does.文档与权限名称之间似乎存在一些冲突 - 文档似乎暗示它不适用于应用程序范围,而权限名称/描述似乎说它可以。
The error i'm getting is Forbidden
.我得到的错误是
Forbidden
。 This seems to be different from accessing a resource with insufficient permissions (which straight up says InsufficientPermissions).这似乎与访问权限不足的资源(直接说 InsufficientPermissions)不同。
The docs are clear that you can't do this with Application scope.文档很清楚,您不能在 Application 范围内执行此操作。 That means even if the particular permission seems like it should work, it might be because it's used in that way for another endpoint.
这意味着即使特定权限看起来应该有效,也可能是因为它以这种方式用于另一个端点。 Notice that, for instance setPresence and clearPresence both support
Presence.ReadWrite.All
.请注意,例如setPresence和clearPresence都支持
Presence.ReadWrite.All
。
What's really crazy though is that neither getPresence (your endpoint) nor (get Presence for Multiple Users)[https://docs.microsoft.com/en-us/graph/api/cloudcommunications-getpresencesbyuserid?view=graph-rest-1.0&tabs=http] support Presence.*Read*Write.All
- there is no supported read scenario!真正疯狂的是getPresence (您的端点)和(获取多个用户的存在)[https://docs.microsoft.com/en-us/graph/api/cloudcommunications-getpresencesbyuserid?view=graph-rest-1.0 &tabs=http] 支持
Presence.*Read*Write.All
- 没有支持的读取场景!
From what I can see, your best bet is to keep an eye on this request and to upvote it.据我所知,您最好的选择是密切关注此请求并对其进行投票。 Microsoft (Darrel Miller) is quite active there from last year - perhaps there's an update coming.
微软(Darrel Miller)从去年开始就非常活跃——也许会有更新。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.