i would like to convert this code to support tree slash commands here is the code @client.command() async def poll(ctx, *, message): await ctx.channel.purge(limit=1) emb = discord.Embed(title=f"{message}", description=f"asked by @{ctx.message.author}", colour=random.choice(rcolor)) msg = await ctx.channel.send(embed=emb) await msg.add_reaction('') await msg.add_reaction('')
@client.tree.command(name="poll", description = "case a vote to decide something")
async def poll(interaction: discord.Interaction):
#i dont know what to put next
emb = discord.Embed(title=f"{message}",
description=f"asked by @{ctx.message.author}",
colour=random.choice(rcolor))
msg = await ctx.channel.send(embed=emb)
await msg.add_reaction('')
await msg.add_reaction('')
how can i do that?
my current command works but i would like to convert it to a slash command