0

How to persist notifications on outlook web application

I'm using the following function. Message persists on the Outlook Desktop application, but on the Outlook web application disappears when switching between email messages or reloading the page.

plus icon also not appear on web, which is the correct icon resolution for the web because 80x80 appears on Desktop app

const addNotificationMessage=(text)=>{
    const message = {
        type: Office.MailboxEnums.ItemNotificationMessageType.InformationalMessage,
        message: text,
        persistent: true,
        icon: "Icon80",
      };
      Office.context.mailbox.item.notificationMessages.replaceAsync("action", message);
    }
Eugene Astafiev
  • 47,483
  • 3
  • 24
  • 45
Yousuf Ali
  • 23
  • 4

1 Answers1

1

Looks like a bug. I've reproduced this issue in Outlook for the web and Outlook for desktop on Windows. So, I've filed it as an issue. You may track it at https://github.com/OfficeDev/office-js/issues/3155 .

Be aware, the documentation states that in modern Outlook on the web, you can add an InsightMessage notification only in Compose mode.

At present, the custom icon is displayed in Outlook on Windows only and not on other clients (e.g., Mac, web browser).

Eugene Astafiev
  • 47,483
  • 3
  • 24
  • 45