Renumber APIs in the tutorial to be in order
This commit is contained in:
parent
5a65563d9a
commit
e8c7158600
1 changed files with 2 additions and 2 deletions
|
@ -321,7 +321,7 @@ data BasicAuth (realm :: Symbol) (userData :: *)
|
||||||
Which is used like so:
|
Which is used like so:
|
||||||
|
|
||||||
``` haskell
|
``` haskell
|
||||||
type ProtectedAPI12
|
type ProtectedAPI11
|
||||||
= UserAPI -- this is public
|
= UserAPI -- this is public
|
||||||
:<|> BasicAuth "my-realm" User :> UserAPI2 -- this is protected by auth
|
:<|> BasicAuth "my-realm" User :> UserAPI2 -- this is protected by auth
|
||||||
```
|
```
|
||||||
|
@ -334,7 +334,7 @@ you want to plug a [wai `Application`](http://hackage.haskell.org/package/wai)
|
||||||
into your webservice:
|
into your webservice:
|
||||||
|
|
||||||
``` haskell
|
``` haskell
|
||||||
type UserAPI11 = "users" :> Get '[JSON] [User]
|
type UserAPI12 = "users" :> Get '[JSON] [User]
|
||||||
-- a /users endpoint
|
-- a /users endpoint
|
||||||
|
|
||||||
:<|> Raw
|
:<|> Raw
|
||||||
|
|
Loading…
Reference in a new issue