Last active
October 9, 2016 18:01
-
-
Save mattjbray/f2aaa92bfc8158b90799c0091fb7c639 to your computer and use it in GitHub Desktop.
Servant URLs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
type API = "users" :> (Capture "id" Int :> Get '[JSON] User | |
:<|> Get '[JSON] [User]) | |
urlForUser :<|> urlForUsers = urlHelpersFor (Proxy :: Proxy API) | |
-- urlForUser :: Int -> URI | |
-- urlForUsers :: URI |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment