Skip to content

Commit

Permalink
Use the correct HTTP method
Browse files Browse the repository at this point in the history
  • Loading branch information
ngua committed Jan 26, 2022
1 parent b8711fa commit 27d8006
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions server/src/Api.hs
Expand Up @@ -6,7 +6,9 @@ import Control.Monad.Except (throwError)
import Control.Monad.IO.Class (liftIO)
import Control.Monad.Reader (runReaderT)
import Servant (
Application,
Capture,
Get,
Handler,
HasServer (ServerT),
JSON,
Expand All @@ -16,12 +18,13 @@ import Servant (
ServerError (errBody),
err400,
hoistServer,
type (:>), Application, serve
serve,
type (:>),
)
import Types
import Utils

type Api = "fees" :> Capture "tx" Cbor :> Post '[JSON] Fee
type Api = "fees" :> Capture "tx" Cbor :> Get '[JSON] Fee

app :: Env -> Application
app = serve api . appServer
Expand Down

0 comments on commit 27d8006

Please sign in to comment.