Type Alias: RetryContext
RetryContext =
object& ({error?:undefined;reason:"status";response:Response; } | {error:Error;reason:"network";response?:undefined; })
Defined in: src/types/options.ts:42
Context passed to RetryOptions.shouldRetry — the failure that may be retried. Exactly one of response / error is set, discriminated by reason.
Type Declaration
request
request:
Request
The request that failed (the template that will be re-sent)
retryCount
retryCount:
number
1-based number of the retry being considered (1 = first retry)