added basic user auth flow
This commit is contained in:
parent
faa7372887
commit
5d2c668bad
7 changed files with 394 additions and 2 deletions
9
app/api/auth/logout/route.ts
Normal file
9
app/api/auth/logout/route.ts
Normal file
|
|
@ -0,0 +1,9 @@
|
|||
// app/app/api/auth/logout/route.ts
|
||||
import { NextRequest, NextResponse } from "next/server";
|
||||
import { clearAuthCookies } from "@/lib/auth-cookies";
|
||||
|
||||
export async function POST(_req: NextRequest) {
|
||||
let res = NextResponse.json({ ok: true });
|
||||
res = clearAuthCookies(res);
|
||||
return res;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue