@plyaz/types 1.27.9 → 1.27.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -802,9 +802,19 @@ export interface AuthUser {
802
802
  export interface UserRepository {
803
803
  findById(id: string): Promise<AuthUser | null>;
804
804
  findByEmail(email: string): Promise<AuthUser | null>;
805
+ findByProviderAccount(provider: string, providerAccountId: string): Promise<AuthUser | null>;
806
+ findByCredentials(email: string, passwordHash: string): Promise<AuthUser | null>;
805
807
  create(data: CreateUserData): Promise<AuthUser>;
806
808
  update(id: string, data: UpdateUserData): Promise<AuthUser>;
807
809
  delete(id: string): Promise<void>;
810
+ assignRole(userId: string, role: string, assignedBy?: string): Promise<void>;
811
+ removeRole(userId: string, role: string): Promise<void>;
812
+ getUserRoles(userId: string): Promise<string[]>;
813
+ checkPermission(roles: string[], permission: string): Promise<boolean>;
814
+ updateLastLogin(userId: string): Promise<void>;
815
+ updateOnboardingStatus(userId: string, status: 'completed' | 'pending' | 'skipped'): Promise<AuthUser>;
816
+ findByClerkId(clerkId: string): Promise<AuthUser | null>;
817
+ findByWalletAddress(address: string): Promise<AuthUser | null>;
808
818
  }
809
819
  export interface SessionRepository {
810
820
  create(data: CreateSessionData): Promise<Session>;