Skip to content

TypeScript code snippet – How to delete a message by its id?

// ASSUMPTIONS:
// channel: the channel you want the message to be sent in
// lastmsg: the id of the last poll message

channel.fetchMessage(lastmsg).then(msg => msg.delete());
See also  How to visualize decision tree in Python?

Leave a Reply

Your email address will not be published.

This site uses Akismet to reduce spam. Learn how your comment data is processed.