import { NextResponse } from "next/server"; import { auth } from "@/app/(auth)/auth"; export async function GET() { const session = await auth().catch(() => null); return NextResponse.json( { valid: Boolean(session?.user?.id), userType: session?.user?.type ?? null, }, { headers: { "Cache-Control": "no-store, max-age=0", }, } ); }