import { Prisma } from '@prisma/client';
import { Adapter } from './storage/index.js';
import { LogLevel } from './utils/logger.js';

/**
 * Options for `prisma-cache-nosql` extension.
 */
type CacheOptions = {
    /**
     * The adapter to use for caching.
     */
    adapter: Adapter;
    logLevel?: LogLevel;
    /**
     * Default cache options for all queries.
     */
    default?: CacheConfig;
    /**
     * Cache options for specific models.
     */
    models?: {
        [model: string]: CacheConfig;
    };
};
type CacheConfig = {
    set?: {
        /**
         * Time to live of the cached value in milliseconds.
         */
        ttl: number;
    } | boolean;
    get?: boolean | {
        /**
         * Maximum age of the cached value in milliseconds.
         */
        max: number;
    };
};
/**
 * Cache options for specific queries.
 */
type CacheQueryArgs = {
    cache: CacheConfig;
};
/**
 * Default cache options for all queries.
 */
declare const DefaultCacheConfig: CacheConfig;
type ClientMethodWithCache<Type, Operation extends SupportedOperation, Args> = (this: Type, args?: Prisma.Exact<Args, Prisma.Args<Type, Operation> & Partial<CacheQueryArgs>>) => Promise<Prisma.Result<Type, Omit<Args, 'cache'>, Operation>>;
/**
 * Supported operations for caching.
 */
declare const SupportedOperations: readonly ["findUnique", "findUniqueOrThrow", "findFirst", "findFirstOrThrow", "findMany", "count", "aggregate", "groupBy"];
type SupportedOperation = (typeof SupportedOperations)[number];

export { type CacheConfig, type CacheOptions, type CacheQueryArgs, type ClientMethodWithCache, DefaultCacheConfig, type SupportedOperation, SupportedOperations };
//# sourceMappingURL=types.d.ts.map
