@aikidosec/firewall
Version:
Zen by Aikido is an embedded Web Application Firewall that autonomously protects Node.js apps against common and critical attacks
17 lines (16 loc) • 626 B
TypeScript
import { ReportingAPI, ReportingAPIResponse } from "./ReportingAPI";
import { Token } from "./Token";
import { Event } from "./Event";
type ThrottleOptions = {
maxEventsPerInterval: number;
intervalInMs: number;
};
export declare class ReportingAPIRateLimitedClientSide implements ReportingAPI {
private readonly api;
private readonly maxEventsPerInterval;
private readonly intervalInMs;
private events;
constructor(api: ReportingAPI, { maxEventsPerInterval, intervalInMs }: ThrottleOptions);
report(token: Token, event: Event, timeoutInMS: number): Promise<ReportingAPIResponse>;
}
export {};