UNPKG

@alisdigital/types-library

Version:

TypeScript type definitions for Papilet ecosystem with session soft delete and event management features

23 lines (22 loc) 812 B
import { IUserModelAttributes } from "../entity/user.entity"; type UserAttributes = Omit<IUserModelAttributes, "createdAt" | "updatedAt" | "lastLogin" | "loginAttempts" | "lockUntil" | "isActive" | "isTFAEnabled" | "_id" | "image" | "favorites" | "googlePassword" | "applePassword" | "otpSecret" | "shareCount">; export interface IUserUpsertRequest extends UserAttributes { } export type IUserUpsertRequestWithValidation = Omit<IUserUpsertRequest, "email" | "phoneNumber"> & ({ registerType: "credential"; phoneNumber: string; email: string; } | { registerType: "credential-email"; email: string; } | { registerType: "credential-phoneNumber"; phoneNumber: string; } | { registerType: "google"; email: string; } | { registerType: "apple"; email: string; }); export {};