ReferenceError: interaction is not defined
DiscordAPIError: Invalid Form Body error when i load my slash commands into my discord bot
34 Replies
• What's your exact discord.js
npm list discord.js
and node node -v
version?
• Post the full error stack trace, not just the top part!
• Show your code!
• Explain what exactly your issue is.
• Not a discord.js issue? Check out #useful-servers.node -v : v16.16.0
discord.js: [email protected]
Show full error
alright here
so
whenever i do a slash command
it give this error
and in my terminal
it says
@Danial
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
the terminal says this
whenever i do a slash command
with my bot
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
it says ReferenceError: interaction is not defined
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
wdym
you want the code?
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
alright
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
here is the code
@Danial
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
bro i did
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
alr
it says the error directly to u
interaction is not defined
where is handleButton getting called from
interactioncreate
and run?
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
something is not right, if interaction is undefined
yeah either stack trace or more code idk
easiest way to get it right is debug interaction
Unknown User•2y ago
Message Not Public
Sign In & Join Server To View
This code part isn't in your module code
You can check in your index.js, with line num in the error
that is the error
do you want me to show you my index.js?
alr
@Dinnerfork Ik this is kina late but... did it get solved in the end?