import { GraphQLSchema } from 'graphql';
import { ApolloLink } from 'apollo-link';
import { Map } from 'immutable';
export interface TracingSchemaTuple {
    schema: GraphQLSchema;
    tracingSupported: boolean;
}
export interface SchemaFetchProps {
    endpoint: string;
    headers?: string;
}
export declare type LinkGetter = (session: SchemaFetchProps) => {
    link: ApolloLink;
};
export declare class SchemaFetcher {
    cache: Map<string, TracingSchemaTuple>;
    linkGetter: LinkGetter;
    fetching: Map<string, Promise<any>>;
    constructor(linkGetter: LinkGetter);
    fetch(session: SchemaFetchProps): Promise<any>;
    refetch(session: SchemaFetchProps): Promise<{
        schema: GraphQLSchema;
        tracingSupported: boolean;
    } | null>;
    hash(session: SchemaFetchProps): string;
    private fetchSchema(session);
}
