Email Verification
Guys, need help.
Token for email verification should be stored in database automatically? In my case Verification table is empty.
http://localhost:3000/api/auth/verify-email?token=eyJhbGciOiJIUzI1NiJ9.eyJlbWFpbCI6Iml2bEBhcnl6ZS5pbyIsImlhdCI6MTc0NDA0MDI3NywiZXhwIjoxNzQ0MDQzODc3fQ.bMcHk2rUSoCAVZaD2ChR4ypTQpkZg7YS4pW_2gEgGMY&callbackURL=%2Fverification%3Fflow%3Dkyc
2 Replies
Can you provide any code that could be relevant? It's unclear on any of the details from what you've provided.
I have default config like this. Everything works fine but i dont understand if we have some token verification by default and why Verification table is empty. Should i implement all verification logic by myself? Thanks for the answer
emailVerification: {
required: true,
sendOnSignUp: true,
autoSignInAfterVerification: true,
expiresIn: 3600, // 1 hour
sendVerificationEmail: async ({ user, url }) => {
console.log('Sending verification email to', user.email);
}
}
model Verification {
id String @id @default(cuid())
identifier String
value String
expiresAt DateTime
createdAt DateTime?
updatedAt DateTime?
@@map("verification")
}