RequestOptions

Interface: RequestOptions<TData, ThrowOnError, Url>

Defined in: app/api/client/types.gen.ts:62

Extends

  • Config<{ throwOnError: ThrowOnError; }>.Pick<ServerSentEventsOptions<TData>, "onSseError" | "onSseEvent" | "sseDefaultRetryDelay" | "sseMaxRetryAttempts" | "sseMaxRetryDelay">

Type Parameters

TData

TData = unknown

ThrowOnError

ThrowOnError *extends* boolean = boolean

Url

Url *extends* string = string

Properties

adapter?

optional adapter?: AxiosAdapterConfig | AxiosAdapterConfig[]

Defined in: node_modules/axios/index.d.ts:380

Inherited from

Config.adapter


allowAbsoluteUrls?

optional allowAbsoluteUrls?: boolean

Defined in: node_modules/axios/index.d.ts:370

Inherited from

Config.allowAbsoluteUrls


allowedSocketPaths?

optional allowedSocketPaths?: string | string[] | null

Defined in: node_modules/axios/index.d.ts:406

Inherited from

Config.allowedSocketPaths


auth?

optional auth?: ((auth) => AuthToken | Promise<AuthToken>) | AuthToken

Defined in: app/api/core/types.gen.ts:46

Auth token or a function returning auth token. The resolved value will be added to the request payload as defined by its security array.

Inherited from

Config.auth


axios?

optional axios?: AxiosStatic | AxiosInstance

Defined in: app/api/client/types.gen.ts:31

Axios implementation. You can use this option to provide either an

AxiosStatic or an AxiosInstance.

Default

axios

Inherited from

Config.axios


baseURL?

optional baseURL?: unknown

Defined in: app/api/client/types.gen.ts:35

Base URL for all requests made by this client.

Inherited from

Config.baseURL


beforeRedirect?

optional beforeRedirect?: (options, responseDetails, requestDetails) => void

Defined in: node_modules/axios/index.d.ts:393

Parameters

options
Record<string, any>
responseDetails
headers
Record<string, string>
statusCode
[object Object]
requestDetails
headers
Record<string, string>
method
[object Object]
url
[object Object]

Returns

[object Object]

Inherited from

Config.beforeRedirect


body?

optional body?: unknown

Defined in: app/api/client/types.gen.ts:82

Any body that you want to add to your request.

https://developer.mozilla.org/docs/Web/API/fetch#body


bodySerializer?

optional bodySerializer?: BodySerializer | null

Defined in: app/api/core/types.gen.ts:51

A function for serializing request body parameter. By default, JSON.stringify() will be used.

Inherited from

Config.bodySerializer


cancelToken?

optional cancelToken?: CancelToken

Defined in: node_modules/axios/index.d.ts:411

Inherited from

Config.cancelToken


data?

optional data?: any

Defined in: node_modules/axios/index.d.ts:376

Inherited from

Config.data


decompress?

optional decompress?: boolean

Defined in: node_modules/axios/index.d.ts:412

Inherited from

Config.decompress


env?

optional env?: object

Defined in: node_modules/axios/index.d.ts:416

fetch?

optional fetch?: (input, init?) => Promise<Response>

Parameters
input
string | URL | Request
init?
[object Object]
Returns
Promise<Response>

FormData?

optional FormData?: (...args) => object

Parameters
args

...any[]

Returns
[object Object]

Request?

optional Request?: (input, init?) => Request

Parameters
input
string | URL | Request
init?
[object Object]
Returns
[object Object]

Response?

optional Response?: (body?, init?) => Response

Parameters
body?
string | ArrayBuffer | Blob | FormData | URLSearchParams | ArrayBufferView<ArrayBufferLike> | null
init?
[object Object]
Returns
[object Object]

Inherited from

Config.env


family?

optional family?: AddressFamily

Defined in: node_modules/axios/index.d.ts:426

Inherited from

Config.family


fetchOptions?

optional fetchOptions?: Record<string, any> | Omit<RequestInit, "headers" | "method" | "signal" | "body">

Defined in: node_modules/axios/index.d.ts:445

Inherited from

Config.fetchOptions


formDataHeaderPolicy?

optional formDataHeaderPolicy?: "legacy" | "content-only"

Defined in: node_modules/axios/index.d.ts:450

Inherited from

Config.formDataHeaderPolicy


formSerializer?

optional formSerializer?: FormSerializerOptions

Defined in: node_modules/axios/index.d.ts:425

Inherited from

Config.formSerializer


headers?

optional headers?: AxiosRequestHeaders | Record<string, unknown>

Defined in: app/api/client/types.gen.ts:42

An object containing any HTTP headers that you want to pre-populate your

Headers object with.

See more

Inherited from

Config.headers


http2Options?

optional http2Options?: Record<string, any> & object

Defined in: node_modules/axios/index.d.ts:447

Type Declaration

sessionTimeout?

optional sessionTimeout?: number

Inherited from

Config.http2Options


httpAgent?

optional httpAgent?: any

Defined in: node_modules/axios/index.d.ts:408

Inherited from

Config.httpAgent


httpsAgent?

optional httpsAgent?: any

Defined in: node_modules/axios/index.d.ts:409

Inherited from

Config.httpsAgent


httpVersion?

optional httpVersion?: 1 | 2

Defined in: node_modules/axios/index.d.ts:446

Inherited from

Config.httpVersion


insecureHTTPParser?

optional insecureHTTPParser?: boolean

Defined in: node_modules/axios/index.d.ts:415

Inherited from

Config.insecureHTTPParser


lookup?

optional lookup?: ((hostname, options, cb) => void) | ((hostname, options) => Promise<LookupAddress | [LookupAddressEntry | LookupAddressEntry[], AddressFamily]>)

Defined in: node_modules/axios/index.d.ts:427

Inherited from

Config.lookup


maxBodyLength?

optional maxBodyLength?: number

Defined in: node_modules/axios/index.d.ts:390

Inherited from

Config.maxBodyLength


maxContentLength?

optional maxContentLength?: number

Defined in: node_modules/axios/index.d.ts:388

Inherited from

Config.maxContentLength


maxRate?

optional maxRate?: number | [number, number]

Defined in: node_modules/axios/index.d.ts:392

Inherited from

Config.maxRate


maxRedirects?

optional maxRedirects?: number

Defined in: node_modules/axios/index.d.ts:391

Inherited from

Config.maxRedirects


method?

optional method?: "CONNECT" | "DELETE" | "GET" | "HEAD" | "OPTIONS" | "PATCH" | "POST" | "PUT" | "TRACE"

Defined in: app/api/core/types.gen.ts:75

The request method.

See more

Inherited from

Config.method


onDownloadProgress?

optional onDownloadProgress?: (progressEvent) => void

Defined in: node_modules/axios/index.d.ts:387

Parameters

progressEvent
[object Object]

Returns

[object Object]

Inherited from

Config.onDownloadProgress


onSseError?

optional onSseError?: (error) => void

Defined in: app/api/core/serverSentEvents.gen.ts:28

Callback invoked when a network or parsing error occurs during streaming.

This option applies only if the endpoint returns a stream of events.

Parameters

error
[object Object]

The error that occurred.

Returns

[object Object]

Inherited from

[object Object]

onSseEvent?

optional onSseEvent?: (event) => void

Defined in: app/api/core/serverSentEvents.gen.ts:37

Callback invoked when an event is streamed from the server.

This option applies only if the endpoint returns a stream of events.

Parameters

event

StreamEvent<TData>

Event streamed from the server.

Returns

[object Object]

Nothing (void).

Inherited from

[object Object]

onUploadProgress?

optional onUploadProgress?: (progressEvent) => void

Defined in: node_modules/axios/index.d.ts:386

Parameters

progressEvent
[object Object]

Returns

[object Object]

Inherited from

Config.onUploadProgress


params?

optional params?: any

Defined in: node_modules/axios/index.d.ts:374

Inherited from

Config.params


paramsSerializer?

optional paramsSerializer?: ParamsSerializerOptions | CustomParamsSerializer

Defined in: node_modules/axios/index.d.ts:375

Inherited from

Config.paramsSerializer


parseReviver?

optional parseReviver?: (this, key, value, context?) => any

Defined in: node_modules/axios/index.d.ts:444

Parameters

this
[object Object]
key
[object Object]
value
[object Object]
context?
source
[object Object]

Returns

[object Object]

Inherited from

Config.parseReviver


path?

optional path?: Record<string, unknown>

Defined in: app/api/client/types.gen.ts:83


proxy?

optional proxy?: false | AxiosProxyConfig

Defined in: node_modules/axios/index.d.ts:410

Inherited from

Config.proxy


query?

optional query?: Record<string, unknown>

Defined in: app/api/client/types.gen.ts:84


querySerializer?

optional querySerializer?: QuerySerializer | QuerySerializerOptions

Defined in: app/api/core/types.gen.ts:86

A function for serializing request query parameters. By default, arrays will be exploded in form style, objects will be exploded in deepObject style, and reserved characters are percent-encoded.

This method will have no effect if the native paramsSerializer() Axios API function is used.

View examples

Inherited from

Config.querySerializer


redact?

optional redact?: string[]

Defined in: node_modules/axios/index.d.ts:451

Inherited from

Config.redact


requestValidator?

optional requestValidator?: (data) => Promise<unknown>

Defined in: app/api/core/types.gen.ts:92

A function validating request data. This is useful if you want to ensure the request conforms to the desired shape, so it can be safely sent to the server.

Parameters

data
[object Object]

Returns

Promise<unknown>

Inherited from

Config.requestValidator


responseEncoding?

optional responseEncoding?: StringLiteralsOrString<responseEncoding>

Defined in: node_modules/axios/index.d.ts:383

Inherited from

Config.responseEncoding


responseTransformer?

optional responseTransformer?: (data) => Promise<unknown>

Defined in: app/api/core/types.gen.ts:97

A function transforming response data before it's returned. This is useful for post-processing data, e.g. converting ISO strings into Date objects.

Parameters

data
[object Object]

Returns

Promise<unknown>

Inherited from

Config.responseTransformer


responseType?

optional responseType?: ResponseType

Defined in: node_modules/axios/index.d.ts:382

Inherited from

Config.responseType


responseValidator?

optional responseValidator?: (data) => Promise<unknown>

Defined in: app/api/core/types.gen.ts:103

A function validating response data. This is useful if you want to ensure the response conforms to the desired shape, so it can be safely passed to the transformers and returned to the user.

Parameters

data
[object Object]

Returns

Promise<unknown>

Inherited from

Config.responseValidator


security?

optional security?: readonly Auth[]

Defined in: app/api/client/types.gen.ts:88

Security mechanism(s) to use for the request.


signal?

optional signal?: GenericAbortSignal

Defined in: node_modules/axios/index.d.ts:414

Inherited from

Config.signal


socketPath?

optional socketPath?: string | null

Defined in: node_modules/axios/index.d.ts:405

Inherited from

Config.socketPath


sseDefaultRetryDelay?

optional sseDefaultRetryDelay?: number

Defined in: app/api/core/serverSentEvents.gen.ts:46

Default retry delay in milliseconds.

This option applies only if the endpoint returns a stream of events.

Default

3000

Inherited from

[object Object]

sseMaxRetryAttempts?

optional sseMaxRetryAttempts?: number

Defined in: app/api/core/serverSentEvents.gen.ts:50

Maximum number of retry attempts before giving up.

Inherited from

[object Object]

sseMaxRetryDelay?

optional sseMaxRetryDelay?: number

Defined in: app/api/core/serverSentEvents.gen.ts:60

Maximum retry delay in milliseconds.

Applies only when exponential backoff is used.

This option applies only if the endpoint returns a stream of events.

Default

30000

Inherited from

[object Object]

throwOnError?

optional throwOnError?: ThrowOnError

Defined in: app/api/client/types.gen.ts:59

Throw an error instead of returning it in the response?

Default

false

Inherited from

Config.throwOnError


timeout?

optional timeout?: number

Defined in: node_modules/axios/index.d.ts:377

Inherited from

Config.timeout


timeoutErrorMessage?

optional timeoutErrorMessage?: string

Defined in: node_modules/axios/index.d.ts:378

Inherited from

Config.timeoutErrorMessage


transformRequest?

optional transformRequest?: AxiosRequestTransformer | AxiosRequestTransformer[]

Defined in: node_modules/axios/index.d.ts:371

Inherited from

Config.transformRequest


transformResponse?

optional transformResponse?: AxiosResponseTransformer | AxiosResponseTransformer[]

Defined in: node_modules/axios/index.d.ts:372

Inherited from

Config.transformResponse


transitional?

optional transitional?: TransitionalOptions

Defined in: node_modules/axios/index.d.ts:413

Inherited from

Config.transitional


transport?

optional transport?: any

Defined in: node_modules/axios/index.d.ts:407

Inherited from

Config.transport


url

[object Object]

Defined in: app/api/client/types.gen.ts:89

Overrides

Config.url


validateStatus?

optional validateStatus?: ((status) => boolean) | null

Defined in: node_modules/axios/index.d.ts:389

Inherited from

Config.validateStatus


withCredentials?

optional withCredentials?: boolean

Defined in: node_modules/axios/index.d.ts:379

Inherited from

Config.withCredentials


withXSRFToken?

optional withXSRFToken?: boolean | ((config) => boolean | undefined)

Defined in: node_modules/axios/index.d.ts:443

Inherited from

Config.withXSRFToken


xsrfCookieName?

optional xsrfCookieName?: string

Defined in: node_modules/axios/index.d.ts:384

Inherited from

Config.xsrfCookieName


xsrfHeaderName?

optional xsrfHeaderName?: string

Defined in: node_modules/axios/index.d.ts:385

Inherited from

Config.xsrfHeaderName

On this page

Interface: RequestOptions<TData, ThrowOnError, Url>ExtendsType ParametersTDataThrowOnErrorUrlPropertiesadapter?Inherited fromallowAbsoluteUrls?Inherited fromallowedSocketPaths?Inherited fromauth?Inherited fromaxios?DefaultInherited frombaseURL?Inherited frombeforeRedirect?ParametersoptionsresponseDetailsheadersstatusCoderequestDetailsheadersmethodurlReturnsInherited frombody?bodySerializer?Inherited fromcancelToken?Inherited fromdata?Inherited fromdecompress?Inherited fromenv?fetch?Parametersinputinit?ReturnsFormData?ParametersargsReturnsRequest?Parametersinputinit?ReturnsResponse?Parametersbody?init?ReturnsInherited fromfamily?Inherited fromfetchOptions?Inherited fromformDataHeaderPolicy?Inherited fromformSerializer?Inherited fromheaders?Inherited fromhttp2Options?Type DeclarationsessionTimeout?Inherited fromhttpAgent?Inherited fromhttpsAgent?Inherited fromhttpVersion?Inherited frominsecureHTTPParser?Inherited fromlookup?Inherited frommaxBodyLength?Inherited frommaxContentLength?Inherited frommaxRate?Inherited frommaxRedirects?Inherited frommethod?Inherited fromonDownloadProgress?ParametersprogressEventReturnsInherited fromonSseError?ParameterserrorReturnsInherited fromonSseEvent?ParameterseventReturnsInherited fromonUploadProgress?ParametersprogressEventReturnsInherited fromparams?Inherited fromparamsSerializer?Inherited fromparseReviver?Parametersthiskeyvaluecontext?sourceReturnsInherited frompath?proxy?Inherited fromquery?querySerializer?Inherited fromredact?Inherited fromrequestValidator?ParametersdataReturnsInherited fromresponseEncoding?Inherited fromresponseTransformer?ParametersdataReturnsInherited fromresponseType?Inherited fromresponseValidator?ParametersdataReturnsInherited fromsecurity?signal?Inherited fromsocketPath?Inherited fromsseDefaultRetryDelay?DefaultInherited fromsseMaxRetryAttempts?Inherited fromsseMaxRetryDelay?DefaultInherited fromthrowOnError?DefaultInherited fromtimeout?Inherited fromtimeoutErrorMessage?Inherited fromtransformRequest?Inherited fromtransformResponse?Inherited fromtransitional?Inherited fromtransport?Inherited fromurlOverridesvalidateStatus?Inherited fromwithCredentials?Inherited fromwithXSRFToken?Inherited fromxsrfCookieName?Inherited fromxsrfHeaderName?Inherited from