import { Repository } from 'typeorm';
import { NestAuthUser } from '../../user/entities/user.entity';
import { NestAuthIdentity } from '../../user/entities/identity.entity';
import { IAuthModuleOptions } from '../interfaces/auth-module-options.interface';
import { NestAuthLoginRequestDto } from 'src/lib/auth';
export interface AuthProviderUser {
    userId: string;
    email?: string;
    phone?: string;
    username?: string;
    metadata?: Record<string, any>;
}
export type LinkUserWith = 'email' | 'phone';
export declare abstract class BaseAuthProvider {
    protected readonly userRepository: Repository<NestAuthUser>;
    protected readonly authIdentityRepository: Repository<NestAuthIdentity>;
    abstract providerName: string;
    enabled: boolean;
    options: IAuthModuleOptions;
    skipMfa: boolean;
    constructor(userRepository: Repository<NestAuthUser>, authIdentityRepository: Repository<NestAuthIdentity>);
    linkToUser(userId: string, providerUserId: string, metadata?: Record<string, any>): Promise<void>;
    findIdentityByUserId(userId: string): Promise<NestAuthIdentity | null>;
    findIdentity(providerUserId: string): Promise<NestAuthIdentity | null>;
    abstract validate(credentials: NestAuthLoginRequestDto['credentials']): Promise<AuthProviderUser | null>;
    abstract getRequiredFields(): string[];
    linkUserWith(): LinkUserWith;
}
//# sourceMappingURL=base-auth.provider.d.ts.map