import { SuperAgentRequest } from 'superagent'; /** * Create a Throttle class and assign it to each of the API clients to restrict the number of requests * that can be made per second, thereby preventing TooManyRequests errors from being returned by the API's * rate limiting defenses. */ export declare class Throttle { private throttles; /** * @param {ThrottleOpts[]} opts An array of ThrottleOpts that specify how throttling should be applied to requests */ constructor(opts: ThrottleOpts[]); /** * @param {number} requestPerSecond The maximum number of requests per second to allow. * @param {number} concurrency The maximum number of requests to do in parallel. */ constructor(requestsPerSecond?: number, concurrency?: number); private createExtendedSuperAgentThrottle; apply(method: string, request: SuperAgentRequest): void; } export interface ThrottleOpts { requestsPerSecond: number; concurrency: number; methods?: string[]; }