On this page
JavaScript API
message
Text message context object in BDJS scripts.
The message global is available when a command runs from a text message trigger.
Properties
| Property | Description |
|---|---|
content |
Message text |
author.id |
Author user ID |
author.username |
Author username |
Methods
await message.reply(content)
Reply in the same channel.
const args = message.content.split(' ');
const body = args.slice(1).join(' ');
await message.reply(body || 'Usage: !echo <text>');