Documentation

Hale.HttpConduit.Network.HTTP.Client.Conduit

Execute an HTTP request and stream the response body as a conduit source. The connection is established, the request is sent, headers are read, and the body bytes are yielded in chunks.

$$\text{httpSource} : \text{Request} \to \text{ConduitT}\ i\ \text{ByteArray}\ \text{IO}\ \text{Response}$$

Returns the Response (with empty body field) after all body bytes have been yielded downstream.

Equations
  • One or more equations did not get rendered due to their size.
Instances For

    Execute an HTTP request with a callback that processes the response. The connection is automatically closed when the callback returns.

    $$\text{withResponse} : \text{Request} \to (\text{Response} \to \text{IO}\ \alpha) \to \text{IO}\ \alpha$$

    Equations
    • One or more equations did not get rendered due to their size.
    Instances For

      Execute an HTTP request and collect the full response body as a ByteArray, using conduit for composition.

      $$\text{httpSink} : \text{Request} \to \text{ConduitT}\ i\ o\ \text{IO}\ (\text{Response} \times \text{ByteArray})$$

      Equations
      • One or more equations did not get rendered due to their size.
      Instances For