@@ -5,9 +5,9 @@ module Common where
6import Data.Proxy (Proxy (Proxy))
6import Data.Proxy (Proxy (Proxy))
7import Data.Text (Text)
7import Data.Text (Text)
8−import Servant.API ((:<|>), (:>), Capture, Get, GetNoContent, Header,
8+import Servant.API ((:<|>), (:>), Capture, Get, Header,
9 Header', Headers, JSON, Post,
9 Header', Headers, JSON, Post,
10− PostNoContent, Put, QueryFlag, QueryParam,
10+ Put, QueryFlag, QueryParam,
11 QueryParam', QueryParams, ReqBody, Required)
11 QueryParam', QueryParams, ReqBody, Required)
12import Servant.Elm (deriveBoth, defaultOptions)
12import Servant.Elm (deriveBoth, defaultOptions)
@@ -38,9 +38,11 @@ type TestApi =
38 :> Get '[JSON] [Book]
38 :> Get '[JSON] [Book]
39 :<|> "books"
39 :<|> "books"
40 :> ReqBody '[JSON] Book
40 :> ReqBody '[JSON] Book
41− :> PostNoContent '[JSON] ()
41+ -- :> PostNoContent '[JSON] ()
42 :<|> "nothing"
43 :<|> "nothing"
43− :> GetNoContent '[JSON] ()
45+ -- :> GetNoContent '[JSON] ()
44 :<|> "nothing"
46 :<|> "nothing"
45 :> Put '[JSON] () -- old way to specify no content
47 :> Put '[JSON] () -- old way to specify no content
46 :<|> "with-a-header"
48 :<|> "with-a-header"