/**
 * @enum {DropPolicy} Defines the behavior of the queue when the maximum size has been reached.
 */
export declare enum DropPolicy {
    Reject = 0,
    DropOldest = 1
}
/**
 * @param {number} id A queue identifier; actions in the same queue are rate-limited and executed sequentially, 0 is a reserved value.
 * @param {number} maxQueueSize Optional. Max size of the queue.
 * @param {DropPolicy} dropPolicy Optional. Policy when max size is reached: 'Reject' or 'DropOldest'.
 */
interface QueueSettings {
    id: number;
    maxQueueSize?: number;
    dropPolicy?: DropPolicy;
}
/**
 * @param {(...args: Args) => Result} action The action to be rate-limited.
 * @param {number} rateLimit The minimum interval in milliseconds between each execution.
 * @param {QueueSettings} settings Optional. Queue settings for rate limiting and execution.
 * @returns {(...args: Args) => Promise<Result>} An asynchronous function that executes the action and returns a promise with the result.
 */
export default function RateKeeper<Args extends unknown[], Result>(action: (...args: Args) => Result, rateLimit: number, settings?: QueueSettings): (...args: Args) => Promise<Result>;
export {};
//# sourceMappingURL=index.d.ts.map