Skip to main content
Version: v10.0.0

RequestRetryEventType

Event of a failed attempt which scheduled a retry. It comes after the response of that attempt and before the request waits delay milliseconds to be sent again.


Import
import { RequestRetryEventType } from "@hyper-fetch/core"

Preview​

type RequestRetryEventType<T> = RequestResponseEventType<T> & { delay: number; retry: number };

Structure​

RequestRetryEventType
NameTypeDescription
details
ResponseDetailsType
mutationContext
OptimisticCallbackResult<any>

Result of the optimistic callback - available in the callbacks of send() and in the request $hooks

request
T
requestId
string
response
ResponseType<ExtractResponseType<T>, ExtractErrorType<T>, ExtractAdapterType<T>>
delay
number

Time in milliseconds the request waits before it is sent again

retry
number

Number of the scheduled retry, counted from 1 - the request makes up to request.retry of them