Outlook Add-in REST API In Shared Inbox Fails: ErrorInvalidMailboxItemId - Item Id doesn't belong to the current mailbox

拈花ヽ惹草 提交于 2021-02-08 10:12:10

问题


We have an Outlook (Office JS) Add-in with a manifest configured to support shared folders, i.e.

<SupportsSharedFolders>true</SupportsSharedFolders>

The add-in has been running flawlessly, for many months, on a number of machines that meet the minimum requirement set of 1.8 for shared folder support. Since 22-Apr-2020 it has returned the following error when selecting an email in a shared email inbox:

Status Code: 404
ErrorInvalidMailboxItemId - Item Id doesn't belong to the current mailbox

The REST API call that returns this error is:

https://outlook.office.com/api/v2.0/me/messages/<RestID>/

Where <RestID> is created from: Office.context.mailbox.convertToRestId(Office.context.mailbox.item.itemId, Office.MailboxEnums.RestVersion.v2_0)

Has an API change been documented anywhere?

Do we need to modify our code?


回答1:


This is not a recent change. The REST URL should be constructed based on the SharedProperties descrbied here https://docs.microsoft.com/en-us/javascript/api/outlook/office.sharedproperties?view=outlook-js-1.8 Note that the SharedProperties API is only available for shared items.



来源:https://stackoverflow.com/questions/61597663/outlook-add-in-rest-api-in-shared-inbox-fails-errorinvalidmailboxitemid-item

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!