Error DiscordAPIError[50001]: Missing Access
Code:
Error: DiscordAPIError[50001]: Missing Access
at handleErrors (/root/Projects/Fate/Main/node_modules/@discordjs/rest/dist/index.js:722:13)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async SequentialHandler.runRequest (/root/Projects/Fate/Main/node_modules/@discordjs/rest/dist/index.js:1120:23)
at async SequentialHandler.queueRequest (/root/Projects/Fate/Main/node_modules/@discordjs/rest/dist/index.js:953:14)
at async _REST.request (/root/Projects/Fate/Main/node_modules/@discordjs/rest/dist/index.js:1266:22)
at async Guild.fetchVanityData (/root/Projects/Fate/Main/node_modules/discord.js/src/structures/Guild.js:657:18)
at async InviteManager.updateInvites (/root/Projects/Fate/Main/dist/struct/managers/InviteManaget.js:64:24)
at async /root/Projects/Fate/Main/dist/app/Economy/Events/Ready.js:15:5
9 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 staffI can’t figure out what the error is.
your bot seems to be missing the required permissions to fetch the invites
The bot has all the rights as well as intents
If it were so easy, I wouldn’t write this appeal here :15cutemdaa:
Not relevant, I fixed this bug
and what was the issue?
it was that there were 13 boosts on the server and not 14 and the bot did not find the link, I just added a check for this and now everything is fine, the code does not crash
Weird, it shouldn't even throw that error with no code set according to discord documentation
I didn’t understand it myself at first to be honest :smeshno:
According to discord's documentation, it should just return null instead of the code, not missing access
but well, when was discord ever consistent