Calling an API inside of module.exports
I am trying to make an api call inside a module.exports and keep on getting a unknown insteraction error see screenshot below. Is it not possible to call api inside of the code here since discord.js thinks it is discord call?

10 Replies
is the data logging in the first place

since discord.js thinks it is discord calland no, djs doesn't control what axios does
the data is logging correctly
sounds like it's taking more than 3s then
unreplied interactions only live for that amount of time
ah I see I will use the other call type then
yeah you should defer, then call your api, and then editReply with the response
I will give that a shot thank you, I forgot about the other response type
The thread owner has marked this issue as solved.