adding roles discord py
# If you need this in a bot command
@bot.command()
async def online(ctx):
role = discord.utils.get(bot.get_guild(ctx.guild.id).roles, id ="Role ID")
await member.add_roles(role)
adding roles discord py
# If you need this in a bot command
@bot.command()
async def online(ctx):
role = discord.utils.get(bot.get_guild(ctx.guild.id).roles, id ="Role ID")
await member.add_roles(role)
reaction role discord.py
@role.error
async def role_error(ctx, error):
if isinstance(error, MissingPermissions):
await ctx.send('**:x: | You do not have permission to use this command!**')
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us