@ably/chat - v0.14.1
    Preparing search index...

    Interface Message

    Represents a single message in a chat room.

    interface Message {
        action: ChatMessageAction;
        clientId: string;
        headers: MessageHeaders;
        metadata: JsonObject;
        reactions: MessageReactionSummary;
        serial: string;
        text: string;
        timestamp: Date;
        version: MessageVersion;
        copy(params?: MessageCopyParams): Message;
        with(
            event: ChatMessageEvent | Message | MessageReactionSummaryEvent,
        ): Message;
    }
    Index

    Properties

    The action type of the message. This can be used to determine if the message was created, updated, or deleted.

    clientId: string

    The clientId of the user who created the message.

    The headers of a chat message. Headers enable attaching extra info to a message, which can be used for various features such as linking to a relative point in time of a livestream video or flagging this message as important or pinned.

    Headers are part of the Ably realtime message extras.headers and they can be used for Filtered Subscriptions and similar.

    This value is always set. If there are no headers, this is an empty object.

    Do not use the headers for authoritative information. There is no server-side validation. When reading the headers, treat them like user input.

    metadata: JsonObject

    The metadata of a chat message. Allows for attaching extra info to a message, which can be used for various features such as animations, effects, or simply to link it to other resources such as images, relative points in time, etc.

    Metadata is part of the Ably Pub/sub message content and is not read by Ably.

    This value is always set. If there is no metadata, this is an empty object.

    Do not use metadata for authoritative information. There is no server-side validation. When reading the metadata treat it like user input.

    The reactions summary for this message.

    serial: string

    The unique identifier of the message.

    text: string

    The text of the message.

    timestamp: Date

    The timestamp at which the message was created.

    Information about the latest version of this message.

    Methods