Abhinav A
Abhinav A

Reputation: 21

Timeout Feature Discord.js

How do I add the timeout function in discord.js ?

Please note I'm talking about the new timeout feature, not like assigning a mutedrole

Upvotes: 0

Views: 16207

Answers (1)

Turtlepaw
Turtlepaw

Reputation: 583

According to discord.js's documentation, you need to use GuildMember#timeout, so your code should look something like this:

guildMember.timeout(5 * 60 * 1000)
.then(() => console.log("Member has been timed out"))
.catch(console.log);

Upvotes: 7

Related Questions