2018-06-30 21:17:08 +02:00
|
|
|
{-# LANGUAGE FlexibleContexts #-}
|
|
|
|
{-# LANGUAGE GADTs #-}
|
|
|
|
{-# LANGUAGE ScopedTypeVariables #-}
|
2018-03-11 13:03:27 +01:00
|
|
|
module Servant.Client.Free (
|
|
|
|
client,
|
|
|
|
ClientF (..),
|
|
|
|
module Servant.Client.Core.Reexport,
|
|
|
|
) where
|
|
|
|
|
2018-06-30 21:17:08 +02:00
|
|
|
import Control.Monad.Free
|
|
|
|
import Data.Proxy
|
|
|
|
(Proxy (..))
|
|
|
|
import Servant.Client.Core
|
|
|
|
import Servant.Client.Core.Reexport
|
2019-02-18 18:08:13 +01:00
|
|
|
import Servant.Client.Core.RunClient
|
2018-03-11 13:03:27 +01:00
|
|
|
|
|
|
|
client :: HasClient (Free ClientF) api => Proxy api -> Client (Free ClientF) api
|
|
|
|
client api = api `clientIn` (Proxy :: Proxy (Free ClientF))
|