从Office 365日历中获取所有事件

时间:2018-02-22 12:12:27

标签: rest calendar office365 microsoft-graph office365api

我需要获取Office 365日历中的所有事件。

目前GET请求:

https://graph.microsoft.com/v1.0/users/ {的UserPrincipalName} /事件

当我们调用API

时,

仅返回 10 个事件

1 个答案:

答案 0 :(得分:1)

如何首先计算事件数量,然后使用$ top查询参数进行另一次调用?

https://graph.microsoft.com/v1.0/users/me/events?$count=true

以上api为您提供了事件数量" @ odata.count":173(例如)然后您拨打此电话:

https://graph.microsoft.com/v1.0/users/me/events?$top=173