import { Model, InferAttributes, InferCreationAttributes, CreationOptional, NonAttribute, ModelStatic } from "vr-migrations"; import type { User } from "./user.models"; export declare const CONTACT_TYPES: readonly ["EMAIL", "PHONE", "WHATSAPP"]; export type ContactType = (typeof CONTACT_TYPES)[number]; export declare const VERIFICATION_METHODS: readonly ["SMS", "0AUTH", "EMAIL", "MANUAL", "N/A"]; export type VerificationMethod = (typeof VERIFICATION_METHODS)[number]; export interface VerificationMetadata { lastOtpSentAt?: Date; otpAttempts?: number; lastFailedAttemptAt?: Date; isLocked?: boolean; lockedUntil: Date | null; carrier?: string; countryCode?: string; deactivatedAt?: Date | null; deactivationReason?: string; verificationToken?: string | null; tokenExpiresAt?: Date | null; } export interface ContactAttributes { id: string; contactValue: string; type: ContactType; userId: string | null; isVerified: boolean; verifiedAt: Date | null; verificationMethod: VerificationMethod; isPrimary: boolean; isActive: boolean; otp: string | null; otpExpiresAt: Date | null; metadata: VerificationMetadata; createdAt: Date; updatedAt: Date; user?: NonAttribute; } export interface ContactCreationAttributes extends Omit { id?: string; metadata?: Partial; } export declare class Contact extends Model, InferCreationAttributes> implements ContactAttributes { id: CreationOptional; contactValue: string; type: ContactType; verificationMethod: VerificationMethod; userId: CreationOptional; isVerified: CreationOptional; verifiedAt: CreationOptional; isPrimary: CreationOptional; isActive: CreationOptional; otp: CreationOptional; otpExpiresAt: CreationOptional; metadata: CreationOptional; readonly createdAt: CreationOptional; readonly updatedAt: CreationOptional; user?: NonAttribute; static initialize(sequelize: any): void; static associate(models: Record>): void; deactivate(reason?: string): Promise; reactivate(): Promise; markAsVerified(): Promise; isLocked(): boolean; getRemainingLockTime(): number | null; isExpired(): boolean; getRemainingOTPTime(): number | null; static findByContactValue(contactValue: string, type: ContactType): Promise; static findVerifiedByContactValue(contactValue: string, type: ContactType): Promise; static getUserContacts(userId: string): Promise; static getUserPrimaryContact(userId: string): Promise; static isContactAvailable(contactValue: string, type: ContactType): Promise; static cleanupExpiredOTPs(): Promise; getDisplayValue(): string; getVerificationMethod(): string; } export type ContactModel = typeof Contact;