Failed to fetch error in @discordjs/rest
Hi, I'm using @discordjs/rest & discord-api-types, I'm following the documentation, but for some reason, I'm getting Failed to fetch error.
31 Replies
- 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 staffSo would you give error with stacktrace to better understand the issue?
![No description](https://cdn.answeroverflow.com/1197124027093893130/Screenshot_413.png)
hmm
does memberData return anything?
none, actually the error is coming from memberData
maybe try to put in rest options makeRequest: fetch
Make sure both memberId and guildId are valid snowflakes
yeah, I checked it. seems to be both Ids are valid
![No description](https://cdn.answeroverflow.com/1197127125321388102/Screenshot_414.png)
here is my full code
can you elaborate more?
in line 10 after key option in new REST call, so
version: '10'
put another option
makeRequest: fetch
by the way why the heck you either import and require packages?
![No description](https://cdn.answeroverflow.com/1197128082138611774/wut.png)
my godddd, damn. I didn't notice ![monkaS](https://cdn.discordapp.com/emojis/620823495844036618.png)
![monkaS](https://cdn.discordapp.com/emojis/620823495844036618.png)
np just curious
π
but also getting the same error tho π