khronoz's picture
V.0.2.0 (#23)
b4297ca unverified
raw
history blame contribute delete
659 Bytes
import NextAuth from 'next-auth'
declare module 'next-auth' {
// Returned by `useSession`, `getSession` and received as a prop on the `SessionProvider` React Context
interface Session {
// A JWT which can be used as Authorization header with supabase-js for RLS.
supabaseAccessToken?: string
jwt?: string
id?: string
user: {
id: string
email: string
name: string
image: string
} & DefaultSession["user"]
}
}
declare module 'next-auth/jwt' {
interface JWT {
id_token?: string
provider?: string
accessToken?: string
}
}