Next.js Discord

Discord Forum

How to change default scopes for discord

Unanswered
Transvaal lion posted this in #help-forum
Open in Discord
Transvaal lionOP
I'm trying to change the scopes for discord authorization to identify & guilds, but I am still getting the default identify & email when I log in.

import NextAuth from "next-auth"
import Discord from "next-auth/providers/discord"
 
export const { handlers, signIn, signOut, auth } = NextAuth({
  providers: [Discord({
    authorization: { params: { scope: 'identify guilds' } },
  })],
})

1 Reply

Transvaal lionOP
Also how can I automatically redirect users to the discord sign in page if they are not authenticated?