node.js - 无法使用 Graph API 在混合环境中的本地对象上创建事件
问题描述
我们有一个 O365 应用程序(使用 OAuth2 凭证流)并使用 Graph API 读写 Exchange 日历。适用于多个租户的在线委托人。
最近(在新租户上)我们尝试使用此处描述的设置访问本地日历。
经过一些修改(例如删除 $select)读取工作,但是每当我们尝试编写事件时,我们都会收到以下错误:
{
"error": {
"code": "RequestBodyRead",
"message": "The property 'start' does not exist on type 'Microsoft.OutlookServices.Event'. Make sure to only use property names that are defined by the type or mark the type as open type. REST APIs for this mailbox are currently in preview. You can find more information about the preview REST APIs at https://dev.outlook.com/.",
"innerError": {
"date": "2021-05-25T12:51:52",
"request-id": "e7bc74d6-d482-4d12-83aa-edec47765158",
"client-request-id": "e7bc74d6-d482-4d12-83aa-edec47765158"
}
}
}
用于故障排除的标题:
{
'request-id': 'fdc5e7ee-3227-44c6-93c0-e23f5fa52432',
'client-request-id': 'fdc5e7ee-3227-44c6-93c0-e23f5fa52432',
'x-ms-ags-diagnostic': '{"ServerInfo":{"DataCenter":"West Europe","Slice":"E","Ring":"5","ScaleUnit":"001","RoleInstance":"AM4PEPF0000DE1F"}}'
}
该帖子的正文如下所示:
{
Start: {
DateTime: "2021-05-25T10:00:00.000Z",
TimeZone: 'UTC'
},
End: {
DateTime: "2021-05-25T10:30:00.000Z",
TimeZone: 'UTC'
},
Subject: 'Test Booking'
}
设置 @odata.type="microsoft.graph.event" 会产生不同的错误:
A type named 'microsoft.graph.event' could not be resolved by the model. When a model is available, each type name must resolve to a valid type.
似乎有其他人报告相同的错误,但没有解决方案:
解决方案
推荐阅读
- c++ - 迭代期间同时修改映射
- google-cloud-platform - 从 datalab 实例内部创建实例
- visual-studio-code - 如何在 Vscode 中重新绑定 vim 命令
- swift - 如何像 Swift 包管理器一样从系统中读取 swift 文件作为配置文件?
- wordpress - 如何使内容出现在 wordpress 视觉/文本编辑器上?
- dotnetnuke-9 - 是否可以使用 PortalID NULL 创建 ProfilePropertyDefinition?
- java - 新行通过 JDBC 连接进入时未执行 MySql 触发器?
- java - 在 WebClient 中,我可以将请求与响应匹配吗?
- xamarin - Xamarin.Forms DataBinding 在其他任务运行时更新
- css - Firefox中的无响应超链接