hlivy-1.0.0: Client library for the Apache Livy REST API.

Safe HaskellNone
LanguageHaskell2010

Network.Livy.Request

Contents

Synopsis

Creating HTTP requests

get :: ToPath a => a -> Request Source #

Basic GET request.

getQuery :: (ToPath a, ToQuery a) => a -> Request Source #

GET request with a collection of query parameters.

post :: ToPath a => a -> Request Source #

Basic POST request.

postBody Source #

Arguments

:: ToPath a 
=> a

The basic request.

-> [(Text, Text)]

The desired request body.

-> Request 

POST request with a given request body specified as key-value pairs.

postJSON :: (ToPath a, ToJSON a) => a -> Request Source #

POST request with a RequestBody derived from an instance of ToJSON.

delete :: ToPath a => a -> Request Source #

Basic DELETE request.

Modifying requests

setHost :: ByteString -> Request -> Request Source #

Set the hostname in the request.

setPort :: Int -> Request -> Request Source #

Set the port in the request.