除了检索用户日历的日历视图(代表用户)之外,我们还努力尝试通过 Graph API 使用
https://graph.microsoft.com/beta/users/room1@ourdomain.com/calendarView. 这是一个痛苦的过程,因为我们遇到了很多问题,目前被困在以下404响应中:
https://graph.microsoft.com:443/v1.0/users/room1@ourdomain.com/calendarView?startDateTime=2018-12-04T23:00:00.000Z&endDateTime=2019-02-10T22:59:59.999Z
{
"error": {
"code": "ErrorItemNotFound",
"message": "The specified object was not found in the store.",
"innerError": {
"request-id": "358a003a-57a4-4f0e-91da-edc17c1fa2d8",
"date": "2018-12-12T07:38:33"
}
}
}
Run Code Online (Sandbox Code Playgroud)
房间的电子邮件地址已经过双重检查并且资源存在,因为我们可以使用它创建约会,并且当我们检索在该位置有约会的用户的日历时,它甚至会在响应中返回。
应用程序权限和 OAuth2 范围设置为:openid email profile offline_access https://graph.microsoft.com/Calendars.Read https://graph.microsoft.com/Calendars.Read.Shared https://graph.microsoft.com/User.Read
https://graph.microsoft.com/User.ReadBasic.All https://graph.microsoft.com/User.Read.All,因此根据文档判断,这应该不是问题。
有谁知道如何解决这个问题?