OptionalauthOptionalbaseBase URL for all requests made by this client.
OptionalbodyAny body that you want to add to your request.
OptionalbodyA function for serializing request body parameter. By default, JSON.stringify() will be used.
OptionalcacheA string indicating how the request will interact with the browser's cache to set request's cache.
OptionalcredentialsA string indicating whether credentials will be sent with the request always, never, or only when sent to a same-origin URL. Sets request's credentials.
OptionalfetchFetch API implementation. You can use this option to provide a custom fetch instance.
OptionalheadersAn object containing any HTTP headers that you want to pre-populate your
Headers object with.
OptionalintegrityA cryptographic hash of the resource to be fetched by request. Sets request's integrity.
OptionalkeepaliveA boolean to set request's keepalive.
OptionalmethodThe request method.
OptionalmodeA string to indicate whether the request will use CORS, or will be restricted to same-origin URLs. Sets request's mode.
OptionalnextPlease don't use the Fetch client for Next.js applications. The next
options won't have any effect.
Install @hey-api/client-next instead.
OptionalparseReturn the response data parsed in a specified format. By default, auto
will infer the appropriate method from the Content-Type response header.
You can override this behavior with any of the Body methods.
Select stream if you don't want to parse response data at all.
OptionalpathOptionalpriorityOptionalqueryOptionalqueryA 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.
OptionalredirectA string indicating whether request follows redirects, results in an error upon encountering a redirect, or returns the redirect (in an opaque fashion). Sets request's redirect.
OptionalreferrerA string whose value is a same-origin URL, "about:client", or the empty string, to set request's referrer.
OptionalreferrerA referrer policy to set request's referrerPolicy.
OptionalresponseShould we return only data or multiple fields (data, error, response, etc.)?
OptionalresponseA function transforming response data before it's returned. This is useful for post-processing data, e.g. converting ISO strings into Date objects.
OptionalresponseA 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.
OptionalsecuritySecurity mechanism(s) to use for the request.
OptionalsignalAn AbortSignal to set request's signal.
OptionalthrowThrow an error instead of returning it in the response?
OptionalwindowCan only be null. Used to disassociate request from any Window.
Auth token or a function returning auth token. The resolved value will be added to the request payload as defined by its
securityarray.