NextAuth Google Provider not working

I am trying to set up a sign in with google button I have the GOOGLE ID and Secret thing in the env and I console.log-ed it and it shows, but for some reason when I try log in, it just puts that error in the terminal.
adapter: PrismaAdapter(prisma),
providers: [
GoogleProvider({
clientId: env.NEXTAUTH_SECRET_GOOGLE_CLIENT_ID,
clientSecret: env.NEXTAUTH_SECRET_GOOGLE_SECRET,
}),
],
//ERROR
`[next-auth][error][SIGNIN_OAUTH_ERROR]
https://next-auth.js.org/errors#signin_oauth_error "ikm" must be at least one byte in length {
error: {
message: '"ikm" must be at least one byte in length',
stack: 'TypeError: "ikm" must be at least one byte in length\n' +`
adapter: PrismaAdapter(prisma),
providers: [
GoogleProvider({
clientId: env.NEXTAUTH_SECRET_GOOGLE_CLIENT_ID,
clientSecret: env.NEXTAUTH_SECRET_GOOGLE_SECRET,
}),
],
//ERROR
`[next-auth][error][SIGNIN_OAUTH_ERROR]
https://next-auth.js.org/errors#signin_oauth_error "ikm" must be at least one byte in length {
error: {
message: '"ikm" must be at least one byte in length',
stack: 'TypeError: "ikm" must be at least one byte in length\n' +`
8 Replies
rocawear
rocawear3y ago
You need to set your SERCET also on .env NEXTAUTH_SECRET
1916Eco
1916EcoOP3y ago
they are both set up
rocawear
rocawear3y ago
NEXTAUTH_SECRET
1916Eco
1916EcoOP3y ago
Oh
rocawear
rocawear3y ago
I think its commented out by default(?)
1916Eco
1916EcoOP3y ago
Right yea
rocawear
rocawear3y ago
A bit odd to me that the discord ones are not but that is!
1916Eco
1916EcoOP3y ago
Yep that worked Thank YOU
Want results from more Discord servers?
Add your server