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

Safe HaskellSafe-Inferred
LanguageHaskell2010

Servant.API.Patch

Synopsis

Documentation

data Patch contentTypes a Source

Endpoint for PATCH requests. The type variable represents the type of the response body (not the request body, use ReqBody for that).

If the HTTP response is empty, only () is supported.

Example:

>>> -- PATCH /books
>>> -- with a JSON encoded Book as the request body
>>> -- returning the just-created Book
>>> type MyApi = "books" :> ReqBody '[JSON] Book :> Patch '[JSON] Book

Instances

Typeable ([*] -> * -> *) Patch