Thunderbird WebExtensions: API tosend an event notifying new emails

I am looking for the API (if it exists) to send me an event to notify when a new email has been received. I guess I could abuse of the message API to periodically list messages and make a diff to know which message is new. But it would be much more efficient to get a notification when a new message/email arrive.

This is the tracking bug for all the APIs which have been requested: https://bugzilla.mozilla.org/show_bug.cgi?id=1396172
(You can mouseover the numbers to get a brief description.)

A few of those has been implemented in TB74: https://thunderbird.topicbox.com/groups/addons/T50a94d9a0540d290/updates-and-additions-apis-in-thunderbird-74
If you can’t find an API to do what you want you could raise a request bug.

That topicbox forum is the best place to ask.

1 Like

Thanks a lot @DaveRo. I can see an issue has already been filed for this request: https://bugzilla.mozilla.org/show_bug.cgi?id=1599380