import { ProviderError } from '../types/provider.js'; import type { RetryPolicy } from '../types/retry-policy.js'; export declare class DefaultRetryPolicy implements RetryPolicy { shouldRetry(err: Error | ProviderError, attempt: number): boolean; maxAttempts(err: Error | ProviderError): number; /** * Compute the retry delay. * * Precedence: * 1. If `err` is a `ProviderError` with a populated * `body.retryAfterMs`, honour it — clamped into * [0, MAX_RETRY_AFTER_MS]. The provider told us exactly when * to come back; we should listen. * 2. Otherwise fall through to the exponential-with-jitter * schedule (`1000 * 2^attempt + jitter`, capped at 30s). * * `err` is optional for back-compat with the existing interface; * callers should pass it whenever available. */ delayMs(attempt: number, err?: Error | ProviderError): number; } //# sourceMappingURL=retry-policy.d.ts.map