compose

This message composition window API first appeared in Thunderbird 67 (see bug 1503423).

Functions

beginNew([details])

Parameters
[details]

beginReply(messageId, [replyType])

Parameters
messageId
(integer)
The message to reply to, as retrieved using other APIs.
[replyType]
(string)

Supported values:

replyToSender
replyToList
replyToAll

beginForward(messageId, [forwardType], [details])

Parameters
messageId
(integer)
The message to forward, as retrieved using other APIs.
[forwardType]
(string)

Supported values:

forwardInline
forwardAsAttachment
[details]

Types

ComposeParams

object
[bcc]
(array of ComposeRecipient)
[body]
(string)
[cc]
(array of ComposeRecipient)
[replyTo]
(string)
[subject]
(string)
[to]
(array of ComposeRecipient)

ComposeRecipient

string
A name and email address in the format “Name <email@example.com>”, or just an email address.

OR

object
id
(string)
The ID of a contact or mailing list from the contacts and mailingLists APIs.
type
(string)

Which sort of object this ID is for.

Supported values:

contact
mailingList