Search code examples
javascriptoutlookoutlook-addinoutlook-web-addins

Set Delay Delivery on emails using Outlook Javascript API


I am testing some code on Outlook 2016 & Outlook Web using Script Lab.

My use case is simple: when I click on a button in my addin, I want the email to be delivered 2 days after today when it is sent. I know it is possible directly in the interface but this is just a test for a biggest addin later.

I am trying to set the Delay Delivery (or Send Later on Outlook Web) feature on emails through the Javascript API. I went on the API reference but I was not able to find how to change the Delay Delivery property of emails.

Is it possible to edit this property using the API? Does anyone know how to do that?

Thank you for your help


Solution

  • OfficeJS doesn't provide anything for that out of the box. But you may consider using EWS, see Call web services from an Outlook add-in for more information. The How to: Delay sending an email message by using the EWS Managed API 2.0 article explains how to delay sending an email message by using the EWS Managed API.

    Another possible option is Graph API.