luizkc / firebase-discord-oauth2-example

An example of how to setup Discord, or any external oAuth2 provider, with your Firebase app.
https://us-central1-discord-oauth-demo.cloudfunctions.net/api/login
MIT License
116 stars 14 forks source link

Invalide scope : relationships.read #7

Closed QuentinSc closed 3 years ago

QuentinSc commented 3 years ago

Hello and thank you for your work.

Got an issue and can't find why. If I add "relationships.read" in oauthKeys.scopes I got the following error

AuthorizationError: The requested scope is invalid, unknown, or malformed. at Strategy.OAuth2Strategy.authenticate (/workspace/node_modules/passport-oauth2/lib/strategy.js:137:25) at attempt (/workspace/node_modules/passport/lib/middleware/authenticate.js:366:16) at authenticate (/workspace/node_modules/passport/lib/middleware/authenticate.js:367:7) at Layer.handle [as handle_request] (/workspace/node_modules/express/lib/router/layer.js:95:5) at next (/workspace/node_modules/express/lib/router/route.js:137:13) at Route.dispatch (/workspace/node_modules/express/lib/router/route.js:112:3) at Layer.handle [as handle_request] (/workspace/node_modules/express/lib/router/layer.js:95:5)

No problem if my scope is only ["identify", "email", "guilds"]

relationships.read is not a supported scope ?

Thank you!

QuentinSc commented 3 years ago

My bas, need to be whitelisted by discord