A message in the ActivityPub network. It is a thin wrapper around
a Fedify object: an Article
, a ChatMessage
, a Note
, or a Question
.
T extends MessageClass
The class of the message. One of Article
, ChatMessage
,
Note
, or Question
.
visibility: MessageVisibility
The visibility of the message.
language: LanguageTag
The language of the message if the content is tagged with a language.
replyTarget: Message<MessageClass, TContextData>
The original message in reply to, if the message is a reply.
attachments: readonly Document[]
The media attachments of the message.
quoteTarget: Message<MessageClass, TContextData>
The message quoted by this message, if any.
published: Temporal.Instant
The published time of the message.
updated: Temporal.Instant
The updated time of the message, if it is updated.
reply(text: Text<"block", TContextData>,options?: SessionPublishOptions<TContextData>,): Promise<AuthorizedMessage<Note, TContextData>>
Publishes a reply to the message.
reply<T extends MessageClass>(text: Text<"block", TContextData>,options?: SessionPublishOptionsWithClass<T, TContextData>,): Promise<AuthorizedMessage<T, TContextData>>
Publishes a reply to the message.
Likes the message.
react(emoji: ): Promise<AuthorizedReaction<TContextData>>
Reacts to the message with a Unicode emoji or a custom emoji.