Ask coding questions

← Back to all posts
Discord.js delete user message?
Squirrel777

So I have been making a Discord bot and it has some commands. You know how in Minecraft when you type a command lets say /tp @s ~ ~ ~. It executes the command but the command typed in doesn't show in the chat? Well, is there any way to do that in discord.js? Such as deleting the user's message?

Answered by 19wintersp [earned 5 cycles]
View Answer
Voters
CuberMagic
Squirrel777
Comments
hotnewtop
19wintersp

You can just delete the message if you have a handle to it.

Squirrel777

that's the documentation for discord.py, not discord.js! @19wintersp

19wintersp

@Squirrel777 Oh, sorry, I'm stupid; here you go.

Squirrel777

ok thanks! @19wintersp