mirror of
https://github.com/aydenjahola/discord-multipurpose-bot.git
synced 2024-11-23 01:05:56 +00:00
21 lines
486 B
TypeScript
21 lines
486 B
TypeScript
import NextAuth from "next-auth";
|
|
import DiscordProvider from "next-auth/providers/discord";
|
|
|
|
const options = {
|
|
providers: [
|
|
DiscordProvider({
|
|
clientId: process.env.DISCORD_CLIENT_ID!,
|
|
clientSecret: process.env.DISCORD_CLIENT_SECRET!,
|
|
authorization: {
|
|
params: {
|
|
scope: "identify guilds",
|
|
},
|
|
},
|
|
}),
|
|
],
|
|
secret: process.env.NEXTAUTH_SECRET,
|
|
};
|
|
|
|
const handler = NextAuth(options);
|
|
|
|
export { handler as GET, handler as POST };
|