import type { BackoffOptions } from 'exponential-backoff';
export interface RetryConfig<T = unknown> {
    maxAttempts: number;
    delayMs: number | ((attempt: number) => number);
    retryIf?: (t: T) => boolean;
    retryOnError?: (error: Error) => boolean;
}
export declare function retry<T>(fn: () => T, { maxAttempts, delayMs, retryIf, retryOnError }: RetryConfig<T>): Promise<T>;
export declare function retryWithBackoff<T extends () => any>(fn: T, options?: BackoffOptions): Promise<ReturnType<T>>;
export declare function httpRetryStrategy(error: unknown, _attemptNumber: number): boolean;
