0.1.65 • Published 2 years ago

rayuu v0.1.65

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

Here's an example of a basic bot you can make with this library:

const { rayuu, INTENTS } = require('rayuu');

const client = new rayuu([ INTENTS.GUILDS, INTENTS.GUILD_MESSAGES, INTENTS.MESSAGE_CONTENT ]);

client.once('ready', () => {
    console.log(`Logged in!`);
});

client.on('messageCreate', message => {
    if (message.content === 'hello') {
        message.reply(`Hello ${message.author.username}!`);
    }
});

// you should store this token securely in a .env or config file
// this file should not be commited to version control or shared with anybody
// the token gives malicious actors access to your bot
client.login('token goes here');
0.1.65

2 years ago