send messages through discord.js console code example
Example 1: send a message discordjs
message.channel.send("A message!");
message.reply("A message to the sender!");
Example 2: how to log all messages discord.js
const fetched = await client.channels.get("505989241600213012")
.fetchMessages({limit: 1})
.then(messages => console.log(`[${messages.first().author.name}]${messages.first().content}`));