Slash command not registered
I use code from discord js guide, but command not registered.
Code: https://pastebin.com/MLS0AxEB
Pastebin
// discord/index.jsconst fs = require('node:fs');const path = requi...
Pastebin.com is the number one paste tool since 2002. Pastebin is a website where you can store text online for a set period of time.
27 Replies
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Run index.js
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
register-commands.js?
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Oh, thanks
I'm so sorry...
Could you at the same time tell me how to remove these commands? I don't have them in my code.
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
didn't help
same commands in list
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
A new command appeared, but older didn't disappear
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Restarted. The same problem
Same with the phone
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Yes, when I was just testing slash commands
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Commands were run using another bot with discord js
Nothing has changed
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
If you have duplicate commands on your server, you registered both global and guild commands.
You can remove the duplicates by resetting either the global or guild commands
• Resetting global commands:
rest.put(Routes.applicationCommands(clientId), { body: [] })
• Resetting guild commands: rest.put(Routes.applicationGuildCommands(clientId, guildId), { body: [] })
Those commands were cleared, but for some reason the old one remained, which doesn't exist and a new one was added
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
Thank you for the help!
I'm having the same issue
Should the guildId in REST be string or int?
My old commands won't disappear for the past couple days, now I can't add commands either
Just realised I was using applicationCommands for guild 🤦