π¦message
The message
event is triggered whenever the server sends a message, whether it is a private message or a channel message.
bot.on('message', (data) => {
// Your code here
});
Parameters
data.sender (string) β The sender of the message.
data.target (string) β The recipient of the message (channel or user).
data.content (string) β The content of the message.
data.raw (string) β The raw message data from the server.
Last updated