简体   繁体   English

Microsoft graph API:查询以使用用户 ID 获取已在邮箱上为特定用户创建的订阅列表

[英]Microsoft graph API: Query to get list of subscriptions already created on mailbox for a specific user using userID

Is there any way to get list of subscriptions specific to a users mailbox like we have one for user's one-drive similar to the code below.有什么方法可以获取特定于用户邮箱的订阅列表,就像我们有一个用于用户的单驱动器的订阅列表,类似于下面的代码。

The is one end point available to fetch out all the subscriptions as https://graph.microsoft.com/v1.0/subscriptions but I want to get only mailbox specific subscriptions.这是一个可用于提取所有订阅的端点,如https://graph.microsoft.com/v1.0/subscriptions但我只想获取特定于邮箱的订阅。

IDriveItemSubscriptionsCollectionPage subscriptions = await graphClient.Users[{UserId}]
                                                                               .Drive
                                                                               .Root
                                                                               .Subscriptions
                                                                               .Request()
                                                                               .GetAsync();
'''

Thank you for reaching out.感谢您伸出援手。 To my knowledge, there isn't currently a way to do this with MS Graph, since listing the subscriptions doesn't support the OData query params.据我所知,目前没有办法使用 MS Graph 执行此操作,因为列出订阅不支持 OData 查询参数。 As a workaround, I would suggest fetching the list then filtering by the resource param client side once the response is sent by graph:作为一种解决方法,我建议获取列表,然后在通过图形发送响应后通过resource参数客户端进行过滤:

/users/{UserId}/messages /用户/{UserId}/消息

Would you consider filing a feature request on the M365 developer platform so this can be looked into?您会考虑在 M365 开发者平台上提交功能请求以便对此进行调查吗?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 允许用户使用 c# 中的图形 api 访问共享邮箱 - Allow user to access shared mailbox using Graph api in c# 如何使用 Microsoft Graph API 获取所有组的用户名? - How to get user names of all groups using Microsoft Graph API? 如何获取用户的组名是使用 Microsoft Graph API 的成员? - How to get group names of the user is a member of using Microsoft Graph API? 通过 C# 代码 403 错误阅读已使用 Microsoft-Graph-Api 创建的在线会议 - Read already created online meetings using Microsoft-Graph-Api thru C# code-403 error 以特定用户身份查询AAD Graph API - Query the AAD Graph API as a specific user 使用 Microsoft Graph 获取用户状态 - Get user presence using Microsoft Graph 使用UWP中的microsoft Graph API为登录用户获取特定日期的会议邀请和事件 - Getting meeting invites & events for the specific day for the logged in user using microsoft Graph API in UWP 如何在 Microsoft Store 中获取唯一用户 ID API - How to get a unique userid in Microsoft Store API 使用 Azure 图表 API 获取用户下的用户列表 - Get list of users under a user using Azure graph API 如何从已经与机器人交互的用户的“列表聊天”图 API 获取团队唯一 ID - How to get the Teams Unique ID based from “List chats” Graph API of the User who already interacted with the bot
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM