I have created a role and want to give it to the bot. How can I do this? I have the role as var 'role'. I can't figure out how to give the bot itself a role, just other members.
client.on('messageCreate', (message) => {
message.guild.members.cache.get("your bot id").roles.add("rol id")
})
Try this. When you post a message, you will add a role to your bot (discord v13). If you want an example for your case, post what you want exactly.