Maximum number of retry attempts. Default: 3
Base delay in ms (exponential back-off base). Default: 300
Maximum delay cap in ms. Default: 30_000
Jitter factor 0–1. Default: 0.3
HTTP status codes that trigger a retry. Default: [408,429,500,502,503,504]
Retry on network errors (ENETWORK). Default: true
Retry on timeout errors (ETIMEOUT). Default: false
Timeouts indicate the server is genuinely slow for this request.
Retrying will usually just time out again and burn the full
timeout × maxRetries budget. Set to true only if your server
has known transient latency spikes you want to ride out.
HTTP methods eligible for retry. Default: ["GET","HEAD","PUT","DELETE","OPTIONS","TRACE"]
OptionalshouldCustom predicate — overrides statuses + onNetworkError when provided.
Retry context with request, response, error, and attempt info.
OptionalonCalled before each retry with the upcoming delay.
Retry policy configuration.