import type { DefaultSession } from 'next-auth' declare module 'next-auth' { interface Session { aiSessionConsent?: boolean user: DefaultSession['user'] & { id?: string role?: string } } } declare module 'next-auth/jwt' { interface JWT { id?: string role?: string sessionVersion?: number aiSessionConsent?: boolean } }