Safe Haskell | None |
---|---|
Language | Haskell2010 |
StripeAPI.Operations.GetCoupons
Description
Contains the different functions to run the operation getCoupons
Synopsis
- getCoupons :: forall m s. (MonadHTTP m, SecurityScheme s) => Configuration s -> Maybe String -> Maybe String -> Maybe String -> Maybe Integer -> Maybe String -> GetCouponsRequestBody -> m (Either HttpException (Response GetCouponsResponse))
- getCouponsRaw :: forall m s. (MonadHTTP m, SecurityScheme s) => Configuration s -> Maybe String -> Maybe String -> Maybe String -> Maybe Integer -> Maybe String -> GetCouponsRequestBody -> m (Either HttpException (Response ByteString))
- getCouponsM :: forall m s. (MonadHTTP m, SecurityScheme s) => Maybe String -> Maybe String -> Maybe String -> Maybe Integer -> Maybe String -> GetCouponsRequestBody -> ReaderT (Configuration s) m (Either HttpException (Response GetCouponsResponse))
- getCouponsRawM :: forall m s. (MonadHTTP m, SecurityScheme s) => Maybe String -> Maybe String -> Maybe String -> Maybe Integer -> Maybe String -> GetCouponsRequestBody -> ReaderT (Configuration s) m (Either HttpException (Response ByteString))
- data GetCouponsRequestBody = GetCouponsRequestBody {
- data GetCouponsResponse
- data GetCouponsResponseBody200 = GetCouponsResponseBody200 {}
- data GetCouponsResponseBody200Object'
Documentation
Arguments
:: (MonadHTTP m, SecurityScheme s) | |
=> Configuration s | The configuration to use in the request |
-> Maybe String | created: A filter on the list, based on the object `created` field. The value can be a string with an integer Unix timestamp, or it can be a dictionary with a number of different query options. |
-> Maybe String | ending_before: A cursor for use in pagination. `ending_before` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, starting with `obj_bar`, your subsequent call can include `ending_before=obj_bar` in order to fetch the previous page of the list. | Constraints: Maximum length of 5000 |
-> Maybe String | expand: Specifies which fields in the response should be expanded. |
-> Maybe Integer | limit: A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10. |
-> Maybe String | starting_after: A cursor for use in pagination. `starting_after` is an object ID that defines your place in the list. For instance, if you make a list request and receive 100 objects, ending with `obj_foo`, your subsequent call can include `starting_after=obj_foo` in order to fetch the next page of the list. | Constraints: Maximum length of 5000 |
-> GetCouponsRequestBody | The request body to send |
-> m (Either HttpException (Response GetCouponsResponse)) | Monad containing the result of the operation |
GET /v1/coupons
<p>Returns a list of your coupons.</p>
getCouponsRaw :: forall m s. (MonadHTTP m, SecurityScheme s) => Configuration s -> Maybe String -> Maybe String -> Maybe String -> Maybe Integer -> Maybe String -> GetCouponsRequestBody -> m (Either HttpException (Response ByteString)) Source #
GET /v1/coupons
The same as getCoupons
but returns the raw ByteString
getCouponsM :: forall m s. (MonadHTTP m, SecurityScheme s) => Maybe String -> Maybe String -> Maybe String -> Maybe Integer -> Maybe String -> GetCouponsRequestBody -> ReaderT (Configuration s) m (Either HttpException (Response GetCouponsResponse)) Source #
GET /v1/coupons
Monadic version of getCoupons
(use with runWithConfiguration
)
getCouponsRawM :: forall m s. (MonadHTTP m, SecurityScheme s) => Maybe String -> Maybe String -> Maybe String -> Maybe Integer -> Maybe String -> GetCouponsRequestBody -> ReaderT (Configuration s) m (Either HttpException (Response ByteString)) Source #
GET /v1/coupons
Monadic version of getCouponsRaw
(use with runWithConfiguration
)
data GetCouponsRequestBody Source #
Defines the data type for the schema getCouponsRequestBody
Constructors
GetCouponsRequestBody | |
Instances
Eq GetCouponsRequestBody Source # | |
Defined in StripeAPI.Operations.GetCoupons Methods (==) :: GetCouponsRequestBody -> GetCouponsRequestBody -> Bool # (/=) :: GetCouponsRequestBody -> GetCouponsRequestBody -> Bool # | |
Show GetCouponsRequestBody Source # | |
Defined in StripeAPI.Operations.GetCoupons Methods showsPrec :: Int -> GetCouponsRequestBody -> ShowS # show :: GetCouponsRequestBody -> String # showList :: [GetCouponsRequestBody] -> ShowS # | |
ToJSON GetCouponsRequestBody Source # | |
Defined in StripeAPI.Operations.GetCoupons Methods toJSON :: GetCouponsRequestBody -> Value # toEncoding :: GetCouponsRequestBody -> Encoding # toJSONList :: [GetCouponsRequestBody] -> Value # toEncodingList :: [GetCouponsRequestBody] -> Encoding # | |
FromJSON GetCouponsRequestBody Source # | |
Defined in StripeAPI.Operations.GetCoupons Methods parseJSON :: Value -> Parser GetCouponsRequestBody # parseJSONList :: Value -> Parser [GetCouponsRequestBody] # |
data GetCouponsResponse Source #
Represents a response of the operation getCoupons
.
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), GetCouponsResponseError
is used.
Constructors
GetCouponsResponseError String | Means either no matching case available or a parse error |
GetCouponsResponse200 GetCouponsResponseBody200 | Successful response. |
GetCouponsResponseDefault Error | Error response. |
Instances
Eq GetCouponsResponse Source # | |
Defined in StripeAPI.Operations.GetCoupons Methods (==) :: GetCouponsResponse -> GetCouponsResponse -> Bool # (/=) :: GetCouponsResponse -> GetCouponsResponse -> Bool # | |
Show GetCouponsResponse Source # | |
Defined in StripeAPI.Operations.GetCoupons Methods showsPrec :: Int -> GetCouponsResponse -> ShowS # show :: GetCouponsResponse -> String # showList :: [GetCouponsResponse] -> ShowS # |
data GetCouponsResponseBody200 Source #
Defines the data type for the schema GetCouponsResponseBody200
Constructors
GetCouponsResponseBody200 | |
Fields
|
Instances
Eq GetCouponsResponseBody200 Source # | |
Defined in StripeAPI.Operations.GetCoupons Methods (==) :: GetCouponsResponseBody200 -> GetCouponsResponseBody200 -> Bool # (/=) :: GetCouponsResponseBody200 -> GetCouponsResponseBody200 -> Bool # | |
Show GetCouponsResponseBody200 Source # | |
Defined in StripeAPI.Operations.GetCoupons Methods showsPrec :: Int -> GetCouponsResponseBody200 -> ShowS # show :: GetCouponsResponseBody200 -> String # showList :: [GetCouponsResponseBody200] -> ShowS # | |
ToJSON GetCouponsResponseBody200 Source # | |
Defined in StripeAPI.Operations.GetCoupons Methods toJSON :: GetCouponsResponseBody200 -> Value # toEncoding :: GetCouponsResponseBody200 -> Encoding # toJSONList :: [GetCouponsResponseBody200] -> Value # | |
FromJSON GetCouponsResponseBody200 Source # | |
Defined in StripeAPI.Operations.GetCoupons Methods parseJSON :: Value -> Parser GetCouponsResponseBody200 # parseJSONList :: Value -> Parser [GetCouponsResponseBody200] # |
data GetCouponsResponseBody200Object' Source #
Defines the enum schema GetCouponsResponseBody200Object'
String representing the object's type. Objects of the same type share the same value. Always has the value `list`.
Constructors
GetCouponsResponseBody200Object'EnumOther Value | |
GetCouponsResponseBody200Object'EnumTyped String | |
GetCouponsResponseBody200Object'EnumStringList |