Safe Haskell | None |
---|---|
Language | Haskell2010 |
Synopsis
- get :: ToPath a => a -> Request
- getQuery :: (ToPath a, ToQuery a) => a -> Request
- post :: ToPath a => a -> Request
- postBody :: ToPath a => a -> [(Text, Text)] -> Request
- postJSON :: (ToPath a, ToJSON a) => a -> Request
- delete :: ToPath a => a -> Request
- setHost :: ByteString -> Request -> Request
- setPort :: Int -> Request -> Request
Creating HTTP requests
getQuery :: (ToPath a, ToQuery a) => a -> Request Source #
GET request with a collection of query parameters.
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
.