import { type UserEntity } from '../entities/user.entity';

export const USER_REPOSITORY = Symbol('USER_REPOSITORY');

export interface IUserRepository {
  findById(id: string): Promise<UserEntity | null>;
  findByPhone(phone: string): Promise<UserEntity | null>;
  findByEmail(email: string): Promise<UserEntity | null>;
  save(user: UserEntity): Promise<void>;
  update(user: UserEntity): Promise<void>;
  updateMfaSecret(userId: string, secret: string | null): Promise<void>;
  updateMfaEnabled(userId: string, enabled: boolean, secret: string, backupCodes: string[]): Promise<void>;
  updateMfaDisabled(userId: string): Promise<void>;
  updateBackupCodes(userId: string, backupCodes: string[]): Promise<void>;
}
