///
///
///
///
///
///
///
///
///
///
///
///
///
///
///
///
///
///
///
///
///
///
///
///
///
import { FilterQuery } from 'mongoose';
import type { IUser, BalanceConfig, CreateUserRequest, UserDeleteResult } from '~/types';
/** Default JWT session expiry: 15 minutes in milliseconds */
export declare const DEFAULT_SESSION_EXPIRY: number;
/** Factory function that takes mongoose instance and returns the methods */
export declare function createUserMethods(mongoose: typeof import('mongoose')): {
findUser: (searchCriteria: FilterQuery, fieldsToSelect?: string | string[] | null) => Promise;
findUsers: (searchCriteria: FilterQuery, fieldsToSelect?: string | string[] | null, options?: {
limit?: number;
offset?: number;
sort?: Record;
}) => Promise;
countUsers: (filter?: FilterQuery) => Promise;
createUser: (data: CreateUserRequest, balanceConfig?: BalanceConfig, disableTTL?: boolean, returnUser?: boolean) => Promise>;
updateUser: (userId: string, updateData: Partial) => Promise;
searchUsers: ({ searchPattern, limit, fieldsToSelect, }: {
searchPattern: string;
limit?: number | undefined;
fieldsToSelect?: string | string[] | null | undefined;
}) => Promise<{
_id: unknown;
__v: number;
}[]>;
getUserById: (userId: string, fieldsToSelect?: string | string[] | null) => Promise;
generateToken: (user: IUser, expiresIn?: number) => Promise;
deleteUserById: (userId: string) => Promise;
updateUserPlugins: (userId: string, plugins: string[] | undefined, pluginKey: string, action: 'install' | 'uninstall') => Promise;
toggleUserMemories: (userId: string, memoriesEnabled: boolean) => Promise;
};
export type UserMethods = ReturnType;