Answer the question
In order to leave comments, you need to log in
How to remove a role from a user after time expires?
async def ping(ctx):
role = ctx.guild.get_role(863103946063478824)
await ctx.author.add_roles(role, reason=None)
Answer the question
In order to leave comments, you need to log in
Try like this
import asyncio
async def ping(ctx):
role = ctx.guild.get_role(863103946063478824)
await ctx.author.add_roles(role, reason=None)
await asyncio.sleep(300)
await ctx.author.remove_roles(role, reason=None)
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question