import type { Context } from '../context.js'; export interface RateLimitOptions { windowMs: number; max: number; message?: string; statusCode?: number; skipSuccessfulRequests?: boolean; skipFailedRequests?: boolean; keyGenerator?: (ctx: Context) => string; store?: RateLimitStore; } interface RateLimitEntry { count: number; resetTime: number; } export interface RateLimitStore { get(key: string): Promise; set(key: string, entry: RateLimitEntry): Promise; clear?(): Promise; } export declare function rateLimit(options: RateLimitOptions): (ctx: Context, next: () => Promise) => Promise; export declare class MemoryStore implements RateLimitStore { private store; get(key: string): Promise; set(key: string, entry: RateLimitEntry): Promise; clear(): Promise; } export {}; //# sourceMappingURL=rateLimit.d.ts.map