FetchClientBuilder

org.http4s.dom.FetchClientBuilder
See theFetchClientBuilder companion object
sealed abstract class FetchClientBuilder[F[_]]

Configure and obtain a FetchClient

Value parameters

cache

how the request will interact with the browser’s HTTP cache

credentials

what browsers do with credentials (cookies, HTTP authentication entries, and TLS client certificates)

mode

mode you want to use for the request, e.g., cors, no-cors, or same-origin

redirect

how to handle a redirect response

referrer

referrer of the request

referrerPolicy

referrer policy to use for the request

requestTimeout

maximum duration from the submission of a request through reading the body before a timeout.

Attributes

Companion
object
Source
FetchClientBuilder.scala
Graph
Supertypes
class Object
trait Matchable
class Any

Members list

Value members

Concrete methods

def create: Client[F]

Creates a Client.

Creates a Client.

Attributes

Source
FetchClientBuilder.scala
override def resource: Resource[F, Client[F]]

Returns the backend as a resource.

Returns the backend as a resource. Resource acquire waits until the backend is ready to process requests.

Attributes

Definition Classes
Source
FetchClientBuilder.scala
def withCache(cache: RequestCache): FetchClientBuilder[F]

Attributes

Source
FetchClientBuilder.scala
def withCacheOption(cache: Option[RequestCache]): FetchClientBuilder[F]

Attributes

Source
FetchClientBuilder.scala
def withCredentials(credentials: RequestCredentials): FetchClientBuilder[F]

Attributes

Source
FetchClientBuilder.scala
def withCredentialsOption(credentials: Option[RequestCredentials]): FetchClientBuilder[F]

Attributes

Source
FetchClientBuilder.scala
def withMode(mode: RequestMode): FetchClientBuilder[F]

Attributes

Source
FetchClientBuilder.scala
def withModeOption(mode: Option[RequestMode]): FetchClientBuilder[F]

Attributes

Source
FetchClientBuilder.scala
def withRedirect(redirect: RequestRedirect): FetchClientBuilder[F]

Attributes

Source
FetchClientBuilder.scala
def withRedirectOption(redirect: Option[RequestRedirect]): FetchClientBuilder[F]

Attributes

Source
FetchClientBuilder.scala

Attributes

Source
FetchClientBuilder.scala
def withReferrerPolicy(referrerPolicy: ReferrerPolicy): FetchClientBuilder[F]

Attributes

Source
FetchClientBuilder.scala
def withReferrerPolicyOption(referrerPolicy: Option[ReferrerPolicy]): FetchClientBuilder[F]

Attributes

Source
FetchClientBuilder.scala
def withRequestTimeout(requestTimeout: Duration): FetchClientBuilder[F]

Attributes

Source
FetchClientBuilder.scala

Inherited methods

def stream: Stream[F, A]

Returns the backend as a single-element stream.

Returns the backend as a single-element stream. The stream does not emit until the backend is ready to process requests. The backend is shut down when the stream is finalized.

Attributes

Inherited from:
BackendBuilder (hidden)
Source
BackendBuilder.scala

Deprecated and Inherited methods

def allocated: F[(A, F[Unit])]

Returns an effect that allocates a backend and an F[Unit] to release it.

Returns an effect that allocates a backend and an F[Unit] to release it. The returned F waits until the backend is ready to process requests. The second element of the tuple shuts down the backend when run.

Unlike resource and stream, there is no automatic release of the backend. This function is intended for REPL sessions, tests, and other situations where composing a cats.effect.Resource or fs2.Stream is not tenable. resource or stream is recommended wherever possible.

Attributes

Deprecated
true
Inherited from:
BackendBuilder (hidden)
Source
BackendBuilder.scala

Concrete fields

val cache: Option[RequestCache]

Attributes

Source
FetchClientBuilder.scala
val credentials: Option[RequestCredentials]

Attributes

Source
FetchClientBuilder.scala
val mode: Option[RequestMode]

Attributes

Source
FetchClientBuilder.scala
val redirect: Option[RequestRedirect]

Attributes

Source
FetchClientBuilder.scala
val referrer: Option[FetchReferrer]

Attributes

Source
FetchClientBuilder.scala
val referrerPolicy: Option[ReferrerPolicy]

Attributes

Source
FetchClientBuilder.scala
val requestTimeout: Duration

Attributes

Source
FetchClientBuilder.scala
val streamingRequests: Boolean

Attributes

Source
FetchClientBuilder.scala