Class: Message

Message

A Message represents a Message in a Channel.

Constructor

new Message()

Properties:
Name Type Description
author String The name of the user that authored this Message.
body String The body of the Message.
channel Channel The Channel the Message belongs to.
dateUpdated Date When the Message was updated.
index Number Index of Message in the Channel's messages stream.
lastUpdatedBy String The name of the last user updated this Message.
sid String The server-assigned unique identifier for the Message.
timestamp Date When the Message was sent.
Source:
Fires:

Methods

remove() → {Promise.<Message>}

Remove the Message.
Source:
Returns:
Type
Promise.<Message>

updateBody(body) → {Promise.<Message>}

Edit message body.
Parameters:
Name Type Description
body String new body of Message.
Source:
Returns:
Type
Promise.<Message>

Events

updated

Fired when the Message's fields have been updated.
Parameters:
Name Type Description
message Message
Source: