forked from GerManRavio/NG-Playercounter
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathremove-commands.js
More file actions
25 lines (18 loc) · 930 Bytes
/
Copy pathremove-commands.js
File metadata and controls
25 lines (18 loc) · 930 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
require('dotenv').config();
const { REST, Routes } = require('discord.js');
const token = process.env.DISCORD_TOKEN;
const clientId = process.env.CLIENT_ID;
const guildId = process.env.GUILD_ID;
const rest = new REST().setToken(token);
rest.delete(Routes.applicationGuildCommand(clientId, guildId, '1208488340219760700'))
.then(() => console.log('Successfully deleted guild command'))
.catch(console.error);
rest.delete(Routes.applicationGuildCommand(clientId, guildId, '1208488340219760701'))
.then(() => console.log('Successfully deleted guild command'))
.catch(console.error);
rest.delete(Routes.applicationGuildCommand(clientId, guildId, '1208488340219760702'))
.then(() => console.log('Successfully deleted guild command'))
.catch(console.error);
rest.delete(Routes.applicationCommand(clientId, '1208488340219760700'))
.then(() => console.log('Successfully deleted application command'))
.catch(console.error);