/**
 * @module @arcis/node/stores/redis
 * Redis rate limit store
 *
 * Note: This is a reference implementation. You'll need to install
 * the 'ioredis' or 'redis' package and pass your client instance.
 */
import type { RateLimitStore, RateLimitEntry } from '../core/types';
/** Generic Redis client interface (works with ioredis, redis, etc.) */
export interface RedisClientLike {
    get(key: string): Promise<string | null>;
    /**
     * SET with optional flags. Supports both `set(key, value)` and
     * `set(key, value, 'EX', seconds, 'NX')` shapes for atomic
     * set-if-not-exists with TTL. Returns 'OK' on success; null when NX
     * is supplied and the key already exists.
     */
    set(key: string, value: string, ...args: Array<string | number>): Promise<string | null | unknown>;
    setex(key: string, seconds: number, value: string): Promise<unknown>;
    expire(key: string, seconds: number): Promise<unknown>;
    incr(key: string): Promise<number>;
    decr(key: string): Promise<number>;
    del(key: string): Promise<number>;
    ttl(key: string): Promise<number>;
    quit?(): Promise<unknown>;
    disconnect?(): Promise<unknown>;
}
export interface RedisStoreOptions {
    /** Redis client instance */
    client: RedisClientLike;
    /** Key prefix. Default: 'arcis:rl:' */
    prefix?: string;
    /** Window size in milliseconds. Default: 60000 */
    windowMs?: number;
}
/**
 * Redis rate limit store for distributed deployments.
 *
 * @example
 * import Redis from 'ioredis';
 *
 * const redis = new Redis();
 * const store = new RedisStore({ client: redis });
 * const limiter = createRateLimiter({ store });
 *
 * // Cleanup on shutdown
 * process.on('SIGTERM', async () => {
 *   await store.close();
 * });
 */
export declare class RedisStore implements RateLimitStore {
    private client;
    private prefix;
    private windowMs;
    private windowSec;
    constructor(options: RedisStoreOptions);
    private getKey;
    get(key: string): Promise<RateLimitEntry | null>;
    set(key: string, entry: RateLimitEntry): Promise<void>;
    increment(key: string): Promise<number>;
    decrement(key: string): Promise<void>;
    reset(key: string): Promise<void>;
    close(): Promise<void>;
}
/**
 * Create a Redis store with the given options.
 * Convenience function for functional programming style.
 *
 * @example
 * const store = createRedisStore({ client: redisClient });
 */
export declare function createRedisStore(options: RedisStoreOptions): RedisStore;
//# sourceMappingURL=redis.d.ts.map