import { ExecutionResult } from 'graphql';
import { Maybe, Plugin, PromiseOrValue } from 'graphql-yoga';
import { Cache as EnvelopCache, ResponseCacheExtensions as EnvelopResponseCacheExtensions, InMemoryCacheParameter, UseResponseCacheParameter as UseEnvelopResponseCacheParameter } from '@envelop/response-cache';
export type UseResponseCacheParameter = Omit<UseEnvelopResponseCacheParameter, 'getDocumentString' | 'session' | 'cache' | 'enabled'> & {
    cache?: Cache;
    session: (request: Request) => PromiseOrValue<Maybe<string>>;
    enabled?: (request: Request) => boolean;
};
export interface ResponseCachePluginExtensions {
    http?: {
        headers?: Record<string, string>;
    };
    responseCache: EnvelopResponseCacheExtensions;
    [key: string]: unknown;
}
interface Cache extends EnvelopCache {
    get(key: string): Promise<ExecutionResult<Record<string, unknown>, ResponseCachePluginExtensions> | undefined>;
}
export declare function useResponseCache(options: UseResponseCacheParameter): Plugin;
export { InMemoryCacheParameter } from '@envelop/response-cache';
export declare function createInMemoryCache(params?: InMemoryCacheParameter): Cache;
