Please help, can't figure out what my problem is.

I recieve this error message twice:
DiscordAPIError[10062]: Unknown interaction
at handleErrors (/home/minecraft/multicraft/servers/server640069/node_modules/@discordjs/rest/dist/index.js:640:13)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async BurstHandler.runRequest (/home/minecraft/multicraft/servers/server640069/node_modules/@discordjs/rest/dist/index.js:736:23)
at async REST.request (/home/minecraft/multicraft/servers/server640069/node_modules/@discordjs/rest/dist/index.js:1387:22)
at async ChatInputCommandInteraction.reply (/home/minecraft/multicraft/servers/server640069/node_modules/discord.js/src/structures/interfaces/InteractionResponses.js:111:5)
at async Object.execute (/home/minecraft/multicraft/servers/server640069/commands/fun/mines.js:149:13)
at async Client.<anonymous> (/home/minecraft/multicraft/servers/server640069/index.js:71:3) {
requestBody: { files: [], json: { type: 4, data: [Object] } },
rawError: { message: 'Unknown interaction', code: 10062 },
code: 10062,
status: 404,
method: 'POST',
url: 'https://discord.com/api/v10/interactions/1194884078114197585/aW50ZXJhY3Rpb246MTE5NDg4NDA3ODExNDE5NzU4NTpOOEYxRHdPRThQVmdpQXlXenJCTUR5SWpHUDJJVW1BSjBqQXZOUUVzN0tiT1hQdlBIc1R6NDRMRGNRNW93WkM3Rkh2RUdGOTNnOVphYWZjd1pqUkI5ZWlmcERpR0Q1UzVlUk1wRXVvSjdpUTN3akFoeWVVZkpkQm9VUTlxSVhWMQ/callback'
}
node:events:491
throw er; // Unhandled 'error' event
^
DiscordAPIError[10062]: Unknown interaction
at handleErrors (/home/minecraft/multicraft/servers/server640069/node_modules/@discordjs/rest/dist/index.js:640:13)
at processTicksAndRejections (node:internal/process/task_queues:96:5)
at async BurstHandler.runRequest (/home/minecraft/multicraft/servers/server640069/node_modules/@discordjs/rest/dist/index.js:736:23)
at async REST.request (/home/minecraft/multicraft/servers/server640069/node_modules/@discordjs/rest/dist/index.js:1387:22)
at async ChatInputCommandInteraction.reply (/home/minecraft/multicraft/servers/server640069/node_modules/discord.js/src/structures/interfaces/InteractionResponses.js:111:5)
at async Object.execute (/home/minecraft/multicraft/servers/server640069/commands/fun/mines.js:149:13)
at async Client.<anonymous> (/home/minecraft/multicraft/servers/server640069/index.js:71:3) {
requestBody: { files: [], json: { type: 4, data: [Object] } },
rawError: { message: 'Unknown interaction', code: 10062 },
code: 10062,
status: 404,
method: 'POST',
url: 'https://discord.com/api/v10/interactions/1194884078114197585/aW50ZXJhY3Rpb246MTE5NDg4NDA3ODExNDE5NzU4NTpOOEYxRHdPRThQVmdpQXlXenJCTUR5SWpHUDJJVW1BSjBqQXZOUUVzN0tiT1hQdlBIc1R6NDRMRGNRNW93WkM3Rkh2RUdGOTNnOVphYWZjd1pqUkI5ZWlmcERpR0Q1UzVlUk1wRXVvSjdpUTN3akFoeWVVZkpkQm9VUTlxSVhWMQ/callback'
}
node:events:491
throw er; // Unhandled 'error' event
^
Here is the code at that point: const client = new Client({ intents: [GatewayIntentBits.Guilds] }); I run all the commands the bot has and it's working fine and then randomly I'll come back and it's crashed, no clue why. Any help is very appreciated.
6 Replies
d.js toolkit
d.js toolkit14mo ago
- What's your exact discord.js npm list discord.js and node node -v version? - Not a discord.js issue? Check out #other-js-ts. - Consider reading #how-to-get-help to improve your question! - Explain what exactly your issue is. - Post the full error stack trace, not just the top part! - Show your code! - Issue solved? Press the button! - Marked as resolved by OP
Nwero
Nwero14mo ago
your problem is easy to figure out from the error name, it has nothing to do with your intents.
d.js docs
d.js docs14mo ago
Common causes of DiscordAPIError[10062]: Unknown interaction: - Initial response took more than 3 seconds ➞ defer the response *. - Wrong interaction object inside a collector. - Two processes handling the same command (the first consumes the interaction, so it won't be valid for the other instance) * Note: you cannot defer modal or autocomplete value responses
Nwero
Nwero14mo ago
based on the error stack trace, it seems to be coming from commands/fun/mines.js, line 149:column 13
skr002
skr002OP14mo ago
ohhh I'm stupid. Was just looking at the top line and immedietly went to my index.js file... thank you.
Nwero
Nwero14mo ago
yw

Did you find this page helpful?