Skip to content

Instantly share code, notes, and snippets.

@plamenbotev
Created August 12, 2022 05:26
Show Gist options
  • Save plamenbotev/696e789129837deec299962a4193172c to your computer and use it in GitHub Desktop.
Save plamenbotev/696e789129837deec299962a4193172c to your computer and use it in GitHub Desktop.
var req3 = "<?xml version='1.0' encoding='utf-8'?> \
<soap:Envelope xmlns:soap='http://schemas.xmlsoap.org/soap/envelope/' \
xmlns:t='http://schemas.microsoft.com/exchange/services/2006/types'> \
<soap:Header> \
<t:RequestServerVersion Version='Exchange2013'/> \
</soap:Header> \
<soap:Body> \
<GetItem xmlns='http://schemas.microsoft.com/exchange/services/2006/messages'> \
<ItemShape> \
<t:BaseShape>Default</t:BaseShape> \
<t:BodyType>Text</t:BodyType> \
<t:AdditionalProperties> \
<t:ExtendedFieldURI PropertyTag='0x007D' PropertyType='String' /> \
</t:AdditionalProperties> \
</ItemShape> \
<ItemIds><t:ItemId Id='" + Office.context.mailbox.convertToEwsId(Office.context.mailbox.item.itemId, Office.MailboxEnums.RestVersion.v2_0) + "'/></ItemIds> \
</GetItem> \
</soap:Body> \
</soap:Envelope>";
Office.context.mailbox.makeEwsRequestAsync(req3, async (res) => {
if (res.status === 'succeeded') {
console.log(res);
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment