HttpClient

pillars.httpclient.HttpClient
See theHttpClient companion object
final case class HttpClient[F[_]](config: Config)(client: Client[F])(implicit evidence$1: Async[F]) extends Module[F], Client[F]

Attributes

Companion
object
Source
httpclient.scala
Graph
Supertypes
trait Serializable
trait Product
trait Equals
trait Client[F]
trait Module[F]
class Object
trait Matchable
class Any
Show all

Members list

Type members

Types

override type ModuleConfig = Config

Attributes

Source
httpclient.scala

Value members

Concrete methods

def call[SI, I, EO, O, R](endpoint: PublicEndpoint[I, EO, O, R], uri: Option[Uri], handler: FailureHandler[F, EO, O])(input: I): F[Either[EO, O]]

Attributes

Source
httpclient.scala
def callSecure[SI, I, EO, O, R](endpoint: Endpoint[SI, I, EO, O, R], uri: Option[Uri], handler: FailureHandler[F, EO, O])(securityInput: SI, input: I): F[Either[EO, O]]

Attributes

Source
httpclient.scala

Inherited methods

Attributes

Inherited from:
Module
Source
modules.scala
final def expectOptionOrT[A](req: Request[F])(onError: Response[F] => F[Throwable])(implicit d: EntityDecoder[F, A]): OptionT[F, A]

As expectOptionOr, but defined in terms of cats.data.OptionT.

As expectOptionOr, but defined in terms of cats.data.OptionT.

Attributes

Inherited from:
Client
Source
Client.scala
final def expectOptionT[A](req: Request[F])(implicit d: EntityDecoder[F, A]): OptionT[F, A]

As expectOption, but defined in terms of cats.data.OptionT.

As expectOption, but defined in terms of cats.data.OptionT.

Attributes

Inherited from:
Client
Source
Client.scala
def probes: List[Probe[F]]

Attributes

Inherited from:
Module
Source
modules.scala

Attributes

Inherited from:
Product

Attributes

Inherited from:
Product
def translate[G[_]](fk: FunctionK[F, G])(gK: FunctionK[G, F])(implicit F: MonadCancelThrow[F]): Client[G]

Translates the effect type of this client from F to G

Translates the effect type of this client from F to G

Attributes

Inherited from:
Client
Source
Client.scala

Exports

Defined exports

def toHttpApp: HttpApp[F]
Exported from Client

Returns this client as an HttpApp. It is the responsibility of callers of this service to run the response body to release the underlying HTTP connection.

Returns this client as an HttpApp. It is the responsibility of callers of this service to run the response body to release the underlying HTTP connection.

This is intended for use in proxy servers. run, [[fetchAsA*]], toKleisli, and stream are safer alternatives, as their signatures guarantee release of the HTTP connection.

Attributes

Source
Client.scala
def toKleisli[A](f: Response[F] => F[A]): Kleisli[F, Request[F], A]
Exported from Client

Returns this client as a cats.data.Kleisli. All connections created by this service are released on completion of callback task f.

Returns this client as a cats.data.Kleisli. All connections created by this service are released on completion of callback task f.

This method effectively reverses the arguments to run followed by use, and is preferred when an HTTP client is composed into a larger Kleisli function, or when a common response callback is used by many call sites.

Attributes

Source
Client.scala