import { HttpService } from '@nestjs/axios';
import { OAuthProvider } from '../interfaces/OAuthProvider';
import { OAuthProviderException } from '../oauth.errors';
export declare abstract class BaseOAuthProvider implements OAuthProvider {
    protected readonly http: HttpService;
    constructor(http: HttpService);
    abstract getAuthUrl(callbackPath: string): Promise<string>;
    abstract getProfile(code: string, type?: string): Promise<any>;
    abstract getProviderType(): string;
    protected fetchToken({ code, url, clientId, clientSecret, redirectUri, }: {
        code: string;
        url: string;
        clientId: string;
        clientSecret: string;
        redirectUri: string;
    }): Promise<any>;
    protected fetchProfile(accessToken: string, url: string): Promise<any>;
    protected mapProviderError(provider: string, error: any): OAuthProviderException;
    protected extractProviderError(error: any): any;
    protected extractProviderErrorCode(error: any): string;
    protected isConsumedAuthorizationCodeError(error: any): boolean;
    protected isInvalidAuthorizationCodeError(error: any): boolean;
}
//# sourceMappingURL=abstract.provider.d.ts.map