import { IBetterLogger } from '@codiac.io/codiac-common/IBetterLogger';
import { TokenizedIdentity, IdentityProvider, IdentitySet } from '@codiac.io/codiac-relay-contracts';
import { npmrcIdentity } from './extensions/npm-identity-adapter-base';
/** Ensures that the correct rain dances are performed for an identity set */
export interface IIdentityHandlerNew {
    createIdentity(provider: IdentityProvider, token: string, input: any): TokenizedIdentity;
    syncIdentities(identities: IdentitySet): Promise<void>;
}
/** Performs the rain dance required by a given identity provider
 *  to enable tokenized authentication with that provider. */
export interface IIdentityAdapter {
    readonly provider: IdentityProvider;
    createIdentity(token: string, input: any): TokenizedIdentity;
    syncIdentities(identities: TokenizedIdentity[]): Promise<npmrcIdentity[]>;
}
/** Oversees the work required for all identity types,
 *  and ensures that identities are managed by the proper IIdentityHandler.
 *  Use this class to perform work on identities.
 */
export declare class IdentityAggregator implements IIdentityHandlerNew {
    private _projectRoot;
    private logger;
    constructor(_projectRoot: string, logger: IBetterLogger);
    createIdentity(provider: IdentityProvider, token: string, input: any): TokenizedIdentity;
    syncIdentities(identitySet: IdentitySet): Promise<void>;
    protected syncIdentitiesWithNpmrc(npmrcIdentities: npmrcIdentity[]): Promise<void>;
}
/** IOC for all supported Identity provider adpaters */
export declare class IdentityHandlerRegistry {
    private static getAll;
    static supportedProviders: string[];
    static getAdapterFor(provider: IdentityProvider, projectRoot: string, logger: IBetterLogger): IIdentityAdapter | undefined;
}
