export type Plan = 'byok' | 'pro'; export type SubscriptionStatus = 'active' | 'trialing' | 'past_due' | 'canceled' | 'unpaid'; export interface StoredRefreshToken { tokenHash: string; expiresAt: string; } export interface StoredMagicToken { tokenHash: string; expiresAt: string; } export interface UserRecord { id: string; email: string; passwordHash: string; passwordSalt: string; plan: Plan; byokKeys: Record; vaultPath: string; createdAt: string; refreshTokens: StoredRefreshToken[]; magicTokens: StoredMagicToken[]; stripeCustomerId?: string; stripeSubscriptionId?: string; subscriptionStatus?: SubscriptionStatus; currentPeriodEnd?: string; } export declare function createUser(email: string, passwordHash: string, passwordSalt: string, plan: Plan): Promise; export declare function findUserByEmail(email: string): Promise; export declare function findUserById(id: string): Promise; export declare function findUserByStripeCustomerId(customerId: string): Promise; export declare function updateUser(id: string, patch: Partial): Promise; export declare function addRefreshToken(userId: string, rawToken: string, expiresAt: string): Promise; export declare function consumeRefreshToken(userId: string, rawToken: string): Promise; export declare function revokeAllRefreshTokens(userId: string): Promise; export declare function addMagicToken(userId: string, rawToken: string, expiresAt: string): Promise; export declare function consumeMagicToken(rawToken: string): Promise; //# sourceMappingURL=user-store.d.ts.map