[英]The requested web method is unavailable to this caller or application thrown when using `GetConversationItems`
In my outlook web add-in I use Office.js's getCallbackTokenAsync
to get the token before connecting to EWS
in my asp.net back end. 在我的Outlook Web加载项中,在连接到asp.net后端中的
EWS
之前,我使用Office.js的getCallbackTokenAsync
获取令牌。
ExchangeService service = new ExchangeService();
service.Url = new Uri(mailItem.ewsUrl);
service.Credentials = new OAuthCredentials(mailItem.ewsToken);
PropertySet ps = new PropertySet(
ItemSchema.Subject,
);
_email = EmailMessage.Bind(service, new ItemId(mailItem.itemID),ps);
//the following throws error
ConversationResponse response = service.GetConversationItems(convId,
properties,
null,
foldersToIgnore,
ConversationSortOrder.TreeOrderDescending);
Seems like this GetConversationItems
method is not allowed when I used the token retrieved by Office.js to initialize the EWS service. 当我使用Office.js检索的令牌初始化EWS服务时,似乎不允许使用这种
GetConversationItems
方法。 I tried to updated the manifest permission to the highest level to ReadWriteMailBox
but still not working. 我试图将清单权限更新为
ReadWriteMailBox
的最高级别,但仍然无法正常工作。 Seems like I can only use Office.js to call EWS
? 好像我只能使用Office.js调用
EWS
?
The token you get from getCallbackTokenAsync is only used to retrieve attachments on the current item or on the current item. 从getCallbackTokenAsync获得的令牌仅用于检索当前项目或当前项目上的附件。 For more information, please see the following link:
有关更多信息,请参见以下链接:
getCallbackTokenAsync getCallbackTokenAsync
Best Regards, 最好的祝福,
Evan 埃文
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.