问题描述
作为全局管理员,我正在尝试检索其他用户的 MS Teams 聊天列表,但无论我将哪个 id 传递给 GET/beta/users/{id}/chats
响应始终是经过身份验证的用户的聊天列表.您如何获取不同用户的聊天列表?
As a global administrator I'm attempting to retrieve the list of MS Teams chats for a different user, however no matter which id I pass to GET /beta/users/{id}/chats
the response is always the list of chats for the authenticated user. How do you get the list of chats for a different user?
API 文档(https://docs.microsoft.com/en-us/graph/api/chat-list?view=graph-rest-beta&tabs=http) 建议我应该可以调用 GET/beta/me/chats
检索我的聊天列表,GET/beta/users/{id}/chats
检索其他人的聊天列表.
The API documentation (https://docs.microsoft.com/en-us/graph/api/chat-list?view=graph-rest-beta&tabs=http) suggests that I should be able to call GET /beta/me/chats
to retrieve the list of my chats and GET /beta/users/{id}/chats
to retrieve the list of someone else's chats.
通过实验,我注意到我可以为 {id} 传递任何字符串,并且请求总是成功并响应 200 OK
,但会显示我的聊天列表.
Through experimentation I've noticed that I can pass any string for {id} and the request always succeeds with response 200 OK
, but with my list of chats.
推荐答案
目前不支持检索其他用户参与的聊天列表,这就是不支持应用程序级别权限的原因.
Retrieving the list of chats that another user is a part of isn't currently supported, that's why Application level permissions aren't supported.
这篇关于如何使用 Microsoft Graph API 检索其他用户的 MS Teams 聊天?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!