mirror of
https://github.com/SrIzan10/next-auth.git
synced 2026-05-01 10:55:20 +00:00
9 lines
202 B
JavaScript
9 lines
202 B
JavaScript
import jwt from 'next-auth/jwt'
|
|
|
|
const secret = process.env.SECRET
|
|
|
|
export default async (req, res) => {
|
|
const token = await jwt.getToken({ req, secret })
|
|
res.send(JSON.stringify(token, null, 2))
|
|
}
|