servant-0.16.1: A family of combinators for defining webservices APIs

Safe HaskellNone
LanguageHaskell2010

Servant.API.ReqBody

Synopsis

Documentation

type ReqBody = ReqBody' '[Required, Strict] Source #

Extract the request body as a value of type a.

Example:

>>> -- POST /books
>>> type MyApi = "books" :> ReqBody '[JSON] Book :> Post '[JSON] Book

data ReqBody' (mods :: [*]) (contentTypes :: [*]) (a :: *) Source #

Note: ReqBody' is always Required.

Instances
HasLink sub => HasLink (ReqBody' mods ct a :> sub :: Type) Source # 
Instance details

Defined in Servant.Links

Associated Types

type MkLink (ReqBody' mods ct a :> sub) a :: Type Source #

Methods

toLink :: (Link -> a0) -> Proxy (ReqBody' mods ct a :> sub) -> Link -> MkLink (ReqBody' mods ct a :> sub) a0 Source #

type MkLink (ReqBody' mods ct a :> sub :: Type) r Source # 
Instance details

Defined in Servant.Links

type MkLink (ReqBody' mods ct a :> sub :: Type) r = MkLink sub r