#Cors error when adding user to guild

6 messages · Page 1 of 1 (latest)

elder patio
#

• 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.

cyan hazel
#

you could, but requires oauth

autumn fogBOT
#

method GuildMemberManager#add()
Adds a user to the guild using OAuth2. <info>This method requires the PermissionFlagsBits.CreateInstantInvite permission.

cyan hazel
#

I misread your question, not really djs related

#

still would be under the oauth2 spec

languid minnow
#

Yeah this isn't a djs question. CORS means Discord isn't allowing the request from your domain, but that shouldn't be an issue if you're doing it properly from the server-side