pub fn connect(
host: String,
port: Int,
timeout: Int,
) -> Result(Connection(a), Error)
pub fn get_response(
conn: Connection(a),
ref: Reference,
) -> #(Connection(a), Result(Response(Option(Body(a))), Error))
pub fn receive(
conn: Connection(a),
timeout: Int,
) -> Connection(a)
pub fn request(
conn: Connection(a),
request: Request(Option(Body)),
options: List(RequestOption(a)),
) -> Result(#(Connection(a), Reference), Error)
pub fn shutdown(
conn: Connection(a),
) -> Result(
List(#(Reference, Result(Response(Option(Body(a))), Error))),
Error,
)