Share via

Outlook Web Based Add-ins: Retrieve original email/item ID in reply/forward composing tab

Md. Mohibur Rahman 0 Reputation points
2024-05-09T16:32:36.3066667+00:00

I am developing an Outlook web-based add-in with an OnMessageCompose event which triggers the messageCompose() function when the reply/reply all/forward button is clicked. Once the compose window opens and the OnMessageCompose event is caught, I need to retrieve the item ID of the selected/original email, not the currently responding email.

I found conversationId helpful to retrieve the whole mail chain, but I want to access the specific email I am replying to, not the entire thread. I also discovered that the In-Reply-To value from MIME content can provide the internetMessageId of the original email, which I can use to view the email details using the Graph API.

However, I am unsure if using In-Reply-To from MIME content is reliable for production use. Is In-Reply-To safe to use for production purposes, or is there an alternative method to retrieve the original email/item ID? I have posted related questions on Microsoft Answers and Stack Overflow.

Microsoft 365 and Office | Development | Other
Outlook | Windows | Classic Outlook for Windows | For business

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.