Ask coding questions

← Back to all posts
Sending dm messages
KeremGuven (0)

How can my bot send dm messages?

Answered by ch1ck3n (1626) [earned 5 cycles]
View Answer
Comments
hotnewtop
ch1ck3n (1626)
async def send_dm(ctx, member: discord.Member, *, content):
    channel = await member.create_dm()
    await channel.send(content)