Interface: RetryPolicy
Documentation Index
Fetch the complete documentation index at: https://docs.typesafe.ai/llms.txt Use this file to discover all available pages before exploring further.
Interface: RetryPolicy
Retry configuration. Partial overrides inherit unset fields from the client or SDK defaults.
Properties
apiConnectionError
readonly apiConnectionError: boolean;Retry connection failures, including interrupted response bodies (APIConnectionError). Default: true.
apiTimeoutError
readonly apiTimeoutError: boolean;Whether to retry APITimeoutError. Default: true.
backoffInitialMs
readonly backoffInitialMs: number;First backoff delay in milliseconds, doubled up to backoffMaxMs. Default: 500.
backoffJitter
readonly backoffJitter: number;Fraction of each backoff delay randomly subtracted, from 0 to 1. Default: 0.25.
backoffMaxMs
readonly backoffMaxMs: number;Maximum backoff delay in milliseconds. Default: 5000.
httpStatuses
readonly httpStatuses: ReadonlySet<number>;HTTP status codes to retry. Default: 408, 429, and 500–599.
maxRetries
readonly maxRetries: number;Maximum retries after the initial attempt; 0 disables retries. Default: 2.
maxRetryAfterMs
readonly maxRetryAfterMs: number;Maximum server retry delay in milliseconds; longer delays use backoff. Default: 60000.
respectRetryAfter
readonly respectRetryAfter: boolean;Honor Retry-After and retry-after-ms up to maxRetryAfterMs. Default: true.