el.xwx.moe/pages/api/v1/getToken.ts

11 lines
418 B
TypeScript
Raw Normal View History

2023-11-02 00:52:49 -05:00
import { NextApiRequest, NextApiResponse } from "next";
import { getToken } from "next-auth/jwt";
2023-11-02 00:52:49 -05:00
export default async (req: NextApiRequest, res: NextApiResponse) => {
// if using `NEXTAUTH_SECRET` env variable, we detect it, and you won't actually need to `secret`
// const token = await getToken({ req })
2023-11-02 13:59:31 -05:00
// const token = await getToken({ req });
// console.log("JSON Web Token", token);
// res.end();
2023-11-02 00:52:49 -05:00
};