Skip to content
Discussion options

You must be logged in to vote

You can pass a custom scope when creating an instance of the strategy.

authenticator.use(
  new Auth0Strategy(
    {
      callbackURL: "https://example.com/auth/auth0/callback",
      clientID: "YOUR_AUTH0_CLIENT_ID",
      clientSecret: "YOUR_AUTH0_CLIENT_SECRET",
      domain: "YOUR_TENANT.us.auth0.com",
      scope: "custom scope", // here
    },
    async ({ accessToken, refreshToken, extraParams, profile }) => {
      // Get the user data from your DB or API using the tokens and profile
      return User.findOrCreate({ email: profile.emails[0].value });
    }
  )
);

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@mattmazzola
Comment options

@sergiodxa
Comment options

Answer selected by danestves
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
3 participants