【发布时间】:2019-12-20 11:16:00
【问题描述】:
我正在使用 ews-javascript-api 更新约会(会议)作为交换。我收到一条错误消息:
请求模式验证失败:未声明 \'SuppressReadReceipts\' 属性。
我在文档中找不到任何说明如何执行此操作的内容。
我上网查了一下,没有找到任何有用的东西。
async updateExchangeItem(_json: any): Promise<any>{
EwsLogging.DebugLogEnabled = false;
service.ImpersonatedUserId = new ews.ImpersonatedUserId(ews.ConnectingIdType.SmtpAddress, "myconferenceroom@me.com");
var id = 'abcdefg';
var mailbox = new Mailbox("myconferenceroom@me.com");
var primaryCal = Folder.Bind(service, new FolderId(WellKnownFolderName.Calendar, mailbox), new PropertySet());
var meeting = await Appointment.Bind(service, new ItemId(id), ).then((response) =>{
if (response) {
response.Subject = 'my subject';
response.Start = new ews.DateTime('08/28/2019 8:00 am');
response.End = new ews.DateTime('08/28/2019 9:00 am');
response.Update(ConflictResolutionMode.AlwaysOverwrite, SendInvitationsOrCancellationsMode.SendToAllAndSaveCopy).then(response =>{
console.log("worked");
return("worked");
}).catch((error) => {
console.log(error);
});
}
});
return("done");
}
这是完整的错误信息:
SoapFaultDetails {
message: 'The request failed schema validation.',
InnerException: null,
faultCode: 'a:ErrorSchemaValidation',
faultString:
{ 'xml:lang': 'en-US',
faultstring:
'The request failed schema validation: The \'SuppressReadReceipts\' attribute is not declared.' },
faultActor: null,
responseCode: 355,
errorCode: 0,
exceptionType: null,
lineNumber: 1,
positionWithinLine: 541,
errorDetails:
DictionaryWithStringKey {
keys: [ 'Violation' ],
keysToObjs: { Violation: 'Violation' },
objects:
{ Violation: 'The \'SuppressReadReceipts\' attribute is not declared.' },
keyPicker: [Function] },
HttpStatusCode: 500 }
【问题讨论】:
标签: javascript exchangewebservices ews-javascript-api