import type { Algorithm } from 'jsonwebtoken'; export interface User { id: string; email: string; createdAt: Date; updatedAt: Date; } export interface Session { id: string; userId: string; token: string; expiresAt: Date; createdAt: Date; updatedAt: Date; invalidated: boolean; ipAddress?: string; userAgent?: string; } export interface OTP { id: string; email: string; code: string; expiresAt: Date; used: boolean; } export interface AuthConfig { jwt: { secret: string; algorithm?: Algorithm; }; session: { ttl: number; refreshInterval: number; cookieName?: string; secure?: boolean; sameSite?: 'lax' | 'strict' | 'none'; }; otp: { ttl: number; length?: number; }; } export interface AuthStorage { createUser(email: string): Promise; getUserById(id: string): Promise; getUserByEmail(email: string): Promise; createSession(userId: string, token: string, expiresAt: Date, ipAddress?: string, userAgent?: string): Promise; getSessionById(sessionId: string): Promise; updateSession(sessionId: string, data: { token: string; expiresAt: Date; }): Promise; invalidateSession(sessionId: string): Promise; invalidateUserSessions(userId: string): Promise; createOTP(email: string, code: string, expiresAt: Date): Promise; verifyOTP(otpId: string, email: string, code: string): Promise; } export interface EmailProvider { sendOTP(email: string, code: string): Promise; } export interface CookieOptions { httpOnly?: boolean; secure?: boolean; sameSite?: 'lax' | 'strict' | 'none'; maxAge?: number; path?: string; } export interface FrameworkAdapter { setCookie(name: string, value: string, options?: CookieOptions): Promise; getCookie(name: string): Promise; deleteCookie(name: string): Promise; redirect(url: string): Promise; } //# sourceMappingURL=types.d.ts.map