stripe-http-client-2.4.0: Stripe API for Haskell - http-client backend

Safe HaskellNone
LanguageHaskell2010

Web.Stripe.Client.HttpClient

Contents

Synopsis

Documentation

data StripeRequest a #

Stripe Request holding Method, URL and Params for a Request. Also includes the function needed to decode the response.

Constructors

StripeRequest 

Fields

data StripeConfig #

Stripe config

Constructors

StripeConfig 

Fields

Instances
Eq StripeConfig 
Instance details

Defined in Web.Stripe.Client

Data StripeConfig 
Instance details

Defined in Web.Stripe.Client

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> StripeConfig -> c StripeConfig #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c StripeConfig #

toConstr :: StripeConfig -> Constr #

dataTypeOf :: StripeConfig -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c StripeConfig) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c StripeConfig) #

gmapT :: (forall b. Data b => b -> b) -> StripeConfig -> StripeConfig #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> StripeConfig -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> StripeConfig -> r #

gmapQ :: (forall d. Data d => d -> u) -> StripeConfig -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> StripeConfig -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> StripeConfig -> m StripeConfig #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> StripeConfig -> m StripeConfig #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> StripeConfig -> m StripeConfig #

Ord StripeConfig 
Instance details

Defined in Web.Stripe.Client

Read StripeConfig 
Instance details

Defined in Web.Stripe.Client

Show StripeConfig 
Instance details

Defined in Web.Stripe.Client

stripe :: FromJSON (StripeReturn a) => StripeConfig -> StripeRequest a -> IO (Either StripeError (StripeReturn a)) Source #

Create a request to Stripes API.

This function uses the global TLS manager from http-client-tls via getGlobalManager.

stripeManager :: FromJSON (StripeReturn a) => Manager -> StripeConfig -> StripeRequest a -> IO (Either StripeError (StripeReturn a)) Source #

Create a request to Stripes API using a Manager.

stripeConn :: FromJSON (StripeReturn a) => Manager -> StripeConfig -> StripeRequest a -> IO (Either StripeError (StripeReturn a)) Source #

Create a request to Stripes API using a Manager.

This function is used to maintain compatibility w/ stripe-http-streams. However, the terminology in http-streams uses Connection whereas http-client uses connection Manager.

low-level

callAPI :: Manager -> (Value -> Result b) -> StripeConfig -> StripeRequest a -> IO (Either StripeError b) Source #

Create a request to Stripes API using an existing Manager

This is a low-level function. In most cases you probably want to use stripe or stripeManager.