Properties
Optional
adapter
adapter?: AxiosAdapterConfig | AxiosAdapterConfig[]
Optional
auth
auth?: AxiosBasicCredentials
Optional
axios-retry
axios-retry?: IAxiosRetryConfig
Optional
baseURL
baseURL?: string
Optional
beforeRedirect
beforeRedirect?: ((options, responseDetails) => void)
Type declaration
- (options, responseDetails): void
Parameters
- options: Record<string, any>
- responseDetails: {
headers: Record<string, string>;
statusCode: HttpStatusCode;
}headers: Record<string, string>
statusCode: HttpStatusCode
Returns void
Optional
cancelToken
cancelToken?: CancelToken
Optional
customMeta
customMeta?: Record<string, unknown>
Optional
decompress
decompress?: boolean
Optional
domain
domain?: string | symbol
Optional
env
env?: {
FormData?: (new (...args) => object);
}
Type declaration
Optional
FormData?: (new (...args) => object)
- new (...args): object
Returns object
Optional
family
family?: AddressFamily
Optional
formSerializer
formSerializer?: FormSerializerOptions
Optional
headers
headers?: AxiosHeaders | Partial<RawAxiosHeaders & {
Accept: AxiosHeaderValue;
Authorization: AxiosHeaderValue;
Content-Encoding: AxiosHeaderValue;
Content-Length: AxiosHeaderValue;
User-Agent: AxiosHeaderValue;
} & {
Content-Type: ContentType;
}> & Partial<{
delete: AxiosHeaders;
get: AxiosHeaders;
head: AxiosHeaders;
link: AxiosHeaders;
options: AxiosHeaders;
patch: AxiosHeaders;
post: AxiosHeaders;
purge: AxiosHeaders;
put: AxiosHeaders;
unlink: AxiosHeaders;
} & {
common: AxiosHeaders;
}>
Optional
httpAgent
httpAgent?: any
Optional
httpsAgent
httpsAgent?: any
Optional
insecureHTTPParser
insecureHTTPParser?: boolean
Optional
lookup
lookup?: ((hostname, options, cb) => void) | ((hostname, options) => Promise<LookupAddress | [address: LookupAddressEntry | LookupAddressEntry[], family?: AddressFamily]>)
Type declaration
- (hostname, options, cb): void
Parameters
- hostname: string
- options: object
- cb: ((err, address, family?) => void)
- (err, address, family?): void
Parameters
- err: null | Error
- address: LookupAddress | LookupAddress[]
Optional
family: AddressFamily
Returns void
Returns void
Type declaration
- (hostname, options): Promise<LookupAddress | [address: LookupAddressEntry | LookupAddressEntry[], family?: AddressFamily]>
Parameters
- hostname: string
- options: object
Returns Promise<LookupAddress | [address: LookupAddressEntry | LookupAddressEntry[], family?: AddressFamily]>
Optional
maxBodyLength
maxBodyLength?: number
Optional
maxContentLength
maxContentLength?: number
Optional
maxRate
maxRate?: number | [number, number]
Optional
maxRedirects
maxRedirects?: number
Optional
method
method?: string
Optional
onDownloadProgress
onDownloadProgress?: ((progressEvent) => void)
Type declaration
- (progressEvent): void
Parameters
- progressEvent: AxiosProgressEvent
Returns void
Optional
onUploadProgress
onUploadProgress?: ((progressEvent) => void)
Type declaration
- (progressEvent): void
Parameters
- progressEvent: AxiosProgressEvent
Returns void
Optional
params
params?: any
Optional
paramsSerializer
paramsSerializer?: CustomParamsSerializer | ParamsSerializerOptions
Optional
paths
paths?: Record<string, string>
Optional
proxy
proxy?: false | AxiosProxyConfig
Optional
responseEncoding
responseEncoding?: string
Optional
responseType
responseType?: ResponseType
Optional
signal
signal?: GenericAbortSignal
Optional
socketPath
socketPath?: null | string
Optional
timeout
timeout?: number
Optional
timeoutErrorMessage
timeoutErrorMessage?: string
Optional
transformRequest
transformRequest?: AxiosRequestTransformer | AxiosRequestTransformer[]
Optional
transformResponse
transformResponse?: AxiosResponseTransformer | AxiosResponseTransformer[]
Optional
transitional
transitional?: TransitionalOptions
Optional
transport
transport?: any
Optional
validateStatus
validateStatus?: null | ((status) => boolean)
Type declaration
- (status): boolean
Returns boolean
Optional
withCredentials
withCredentials?: boolean
Optional
withXSRFToken
withXSRFToken?: boolean | ((config) => undefined | boolean)
Type declaration
- (config): undefined | boolean
Parameters
- config: InternalAxiosRequestConfig<any>
Returns undefined | boolean
Optional
xsrfCookieName
xsrfCookieName?: string
Optional
xsrfHeaderName
xsrfHeaderName?: string
自定义元数据