org.http4s

client

package client

Provides extension methods for using the a http4s org.http4s.client.Client

import scalaz.concurrent.Task
import org.http4s._
import org.http4s.client._
import org.http4s.Http4s._
import org.http4s.Status._
import org.http4s.Method._
import org.http4s.EntityDecoder

def client: Client = ???

val r: Task[String] = client(GET(uri("https://www.foo.bar/"))).as[String]
val r2: DecodeResult[String] = client(GET(uri("https://www.foo.bar/"))).attemptAs[String] // implicitly resolve the decoder
val req1 = r.run
val req2 = r.run // Each invocation fetches a new Result based on the behavior of the Client
Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. client
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Type Members

  1. final case class Client(open: Service[Request, DisposableResponse], shutdown: Task[Unit]) extends Product with Serializable

    A Client submits Requests to a server and processes the Response.

  2. trait Connection extends AnyRef

  3. type ConnectionBuilder[A <: Connection] = (RequestKey) ⇒ Task[A]

  4. trait ConnectionManager[A <: Connection] extends AnyRef

    Type that is responsible for the client lifecycle

  5. final case class DisposableResponse(response: Response, dispose: Task[Unit]) extends Product with Serializable

    Contains a Response that needs to be disposed of to free the underlying HTTP connection.

  6. type Middleware = (Client) ⇒ Client

  7. implicit final class NoBodySyntax extends AnyVal with EmptyRequestGenerator

  8. final case class RequestKey(scheme: Scheme, authority: Authority) extends Product with Serializable

    Represents a key for requests that can conceivably share a Connection.

  9. final case class UnexpectedStatus(status: Status) extends RuntimeException with NoStackTrace with Product with Serializable

  10. implicit final class WithBodySyntax extends AnyVal with EntityRequestGenerator

    Syntax classes to generate a request directly from a Method

Value Members

  1. object Client extends Serializable

  2. object ConnectionManager

  3. object RequestKey extends Serializable

  4. package impl

  5. package middleware

  6. package oauth1

    Basic OAuth1 message signing support

  7. implicit def wHeadersDec[T](implicit decoder: EntityDecoder[T]): EntityDecoder[(Headers, T)]

Inherited from AnyRef

Inherited from Any

Ungrouped