recurly-client-0.1.0.0: Client for Recurly subscription management
Safe HaskellSafe-Inferred
LanguageHaskell2010

RecurlyClient.Operations.Create_purchase

Description

Contains the different functions to run the operation create_purchase

Synopsis

Documentation

create_purchase Source #

Arguments

:: forall m. MonadHTTP m 
=> PurchaseCreate

The request body to send

-> ClientT m (Response Create_purchaseResponse)

Monadic computation which returns the result of the operation

POST /purchases

A purchase is a checkout containing at least one or more subscriptions or one-time charges (line items) and supports both coupon and gift card redemptions. All items purchased will be on one invoice and paid for with one transaction.

data Create_purchaseResponse Source #

Represents a response of the operation create_purchase.

The response constructor is chosen by the status code of the response. If no case matches (no specific case for the response code, no range case, no default case), Create_purchaseResponseError is used.

Constructors

Create_purchaseResponseError String

Means either no matching case available or a parse error

Create_purchaseResponse201 InvoiceCollection

Returns the new invoices

Create_purchaseResponse400 Error

Bad request; perhaps missing or invalid parameters.

Create_purchaseResponse422 Error

Purchase cannot be completed for the specified reason.

Create_purchaseResponseDefault Error

Unexpected error.

create_purchaseWithConfiguration Source #

Arguments

:: forall m. MonadHTTP m 
=> Configuration

The configuration to use in the request

-> PurchaseCreate

The request body to send

-> m (Response Create_purchaseResponse)

Monadic computation which returns the result of the operation

POST /purchases

The same as create_purchase but accepts an explicit configuration.

create_purchaseRaw Source #

Arguments

:: forall m. MonadHTTP m 
=> PurchaseCreate

The request body to send

-> ClientT m (Response ByteString)

Monadic computation which returns the result of the operation

POST /purchases

The same as create_purchase but returns the raw ByteString.

create_purchaseWithConfigurationRaw Source #

Arguments

:: forall m. MonadHTTP m 
=> Configuration

The configuration to use in the request

-> PurchaseCreate

The request body to send

-> m (Response ByteString)

Monadic computation which returns the result of the operation

POST /purchases

The same as create_purchase but accepts an explicit configuration and returns the raw ByteString.