next_action\<\/code>s are handled by the client, no additional
-- confirmation is required to complete the payment.\<\/p>
--
-- \If the \confirmation_method\<\/code> is \manual\<\/code>, all payment attempts must be
-- initiated using a secret key.
-- If any actions are required for the payment, the PaymentIntent will
-- return to the \requires_confirmation\<\/code> state
-- after those actions are completed. Your server needs to then
-- explicitly re-confirm the PaymentIntent to initiate the next payment
-- attempt. Read the \expanded documentation\<\/a>
-- to learn more about manual confirmation.\<\/p>
postPaymentIntentsIntentConfirm ::
forall m.
StripeAPI.Common.MonadHTTP m =>
-- | intent | Constraints: Maximum length of 5000
Data.Text.Internal.Text ->
-- | The request body to send
GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBody ->
-- | Monadic computation which returns the result of the operation
StripeAPI.Common.ClientT m (Network.HTTP.Client.Types.Response PostPaymentIntentsIntentConfirmResponse)
postPaymentIntentsIntentConfirm
intent
body =
GHC.Base.fmap
( \response_0 ->
GHC.Base.fmap
( Data.Either.either PostPaymentIntentsIntentConfirmResponseError GHC.Base.id
GHC.Base.. ( \response body ->
if
| (\status_1 -> Network.HTTP.Types.Status.statusCode status_1 GHC.Classes.== 200) (Network.HTTP.Client.Types.responseStatus response) ->
PostPaymentIntentsIntentConfirmResponse200
Data.Functor.<$> ( Data.Aeson.eitherDecodeStrict body ::
Data.Either.Either
GHC.Base.String
PaymentIntent
)
| GHC.Base.const GHC.Types.True (Network.HTTP.Client.Types.responseStatus response) ->
PostPaymentIntentsIntentConfirmResponseDefault
Data.Functor.<$> ( Data.Aeson.eitherDecodeStrict body ::
Data.Either.Either
GHC.Base.String
Error
)
| GHC.Base.otherwise -> Data.Either.Left "Missing default response type"
)
response_0
)
response_0
)
(StripeAPI.Common.doBodyCallWithConfigurationM (Data.Text.toUpper GHC.Base.$ Data.Text.pack "POST") (Data.Text.pack ("/v1/payment_intents/" GHC.Base.++ (Data.ByteString.Char8.unpack (Network.HTTP.Types.URI.urlEncode GHC.Types.True GHC.Base.$ (Data.ByteString.Char8.pack GHC.Base.$ StripeAPI.Common.stringifyModel intent)) GHC.Base.++ "/confirm"))) GHC.Base.mempty body StripeAPI.Common.RequestBodyEncodingFormData)
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBody = PostPaymentIntentsIntentConfirmRequestBody
{ -- | client_secret: The client secret of the PaymentIntent.
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyClientSecret :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | error_on_requires_action: Set to \`true\` to fail the payment attempt if the PaymentIntent transitions into \`requires_action\`. This parameter is intended for simpler integrations that do not handle customer actions, like [saving cards without authentication](https:\/\/stripe.com\/docs\/payments\/save-card-without-authentication).
postPaymentIntentsIntentConfirmRequestBodyErrorOnRequiresAction :: (GHC.Maybe.Maybe GHC.Types.Bool),
-- | expand: Specifies which fields in the response should be expanded.
postPaymentIntentsIntentConfirmRequestBodyExpand :: (GHC.Maybe.Maybe ([Data.Text.Internal.Text])),
-- | mandate: ID of the mandate to be used for this payment.
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyMandate :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | mandate_data: This hash contains details about the Mandate to create
postPaymentIntentsIntentConfirmRequestBodyMandateData :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyMandateData'),
-- | off_session: Set to \`true\` to indicate that the customer is not in your checkout flow during this payment attempt, and therefore is unable to authenticate. This parameter is intended for scenarios where you collect card details and [charge them later](https:\/\/stripe.com\/docs\/payments\/cards\/charging-saved-cards).
postPaymentIntentsIntentConfirmRequestBodyOffSession :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyOffSession'Variants),
-- | payment_method: ID of the payment method (a PaymentMethod, Card, or [compatible Source](https:\/\/stripe.com\/docs\/payments\/payment-methods\/transitioning\#compatibility) object) to attach to this PaymentIntent.
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethod :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | payment_method_data: If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
-- in the [payment_method](https:\/\/stripe.com\/docs\/api\/payment_intents\/object\#payment_intent_object-payment_method)
-- property on the PaymentIntent.
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'),
-- | payment_method_options: Payment-method-specific configuration for this PaymentIntent.
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'),
-- | payment_method_types: The list of payment method types (e.g. card) that this PaymentIntent is allowed to use.
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodTypes :: (GHC.Maybe.Maybe ([Data.Text.Internal.Text])),
-- | receipt_email: Email address that the receipt for the resulting payment will be sent to. If \`receipt_email\` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https:\/\/dashboard.stripe.com\/account\/emails).
postPaymentIntentsIntentConfirmRequestBodyReceiptEmail :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyReceiptEmail'Variants),
-- | return_url: The URL to redirect your customer back to after they authenticate or cancel their payment on the payment method\'s app or site.
-- If you\'d prefer to redirect to a mobile application, you can alternatively supply an application URI scheme.
-- This parameter is only used for cards and other redirect-based payment methods.
postPaymentIntentsIntentConfirmRequestBodyReturnUrl :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | setup_future_usage: Indicates that you intend to make future payments with this PaymentIntent\'s payment method.
--
-- Providing this parameter will [attach the payment method](https:\/\/stripe.com\/docs\/payments\/save-during-payment) to the PaymentIntent\'s Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https:\/\/stripe.com\/docs\/api\/payment_methods\/attach) to a Customer after the transaction completes.
--
-- When processing card payments, Stripe also uses \`setup_future_usage\` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https:\/\/stripe.com\/docs\/strong-customer-authentication).
--
-- If \`setup_future_usage\` is already set and you are performing a request using a publishable key, you may only update the value from \`on_session\` to \`off_session\`.
postPaymentIntentsIntentConfirmRequestBodySetupFutureUsage :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'),
-- | shipping: Shipping information for this PaymentIntent.
postPaymentIntentsIntentConfirmRequestBodyShipping :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyShipping'Variants),
-- | use_stripe_sdk: Set to \`true\` only when using manual confirmation and the iOS or Android SDKs to handle additional authentication steps.
postPaymentIntentsIntentConfirmRequestBodyUseStripeSdk :: (GHC.Maybe.Maybe GHC.Types.Bool)
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBody where
toJSON obj = Data.Aeson.Types.Internal.object ("client_secret" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyClientSecret obj : "error_on_requires_action" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyErrorOnRequiresAction obj : "expand" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyExpand obj : "mandate" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandate obj : "mandate_data" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData obj : "off_session" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyOffSession obj : "payment_method" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethod obj : "payment_method_data" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData obj : "payment_method_options" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions obj : "payment_method_types" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodTypes obj : "receipt_email" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyReceiptEmail obj : "return_url" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyReturnUrl obj : "setup_future_usage" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodySetupFutureUsage obj : "shipping" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping obj : "use_stripe_sdk" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyUseStripeSdk obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("client_secret" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyClientSecret obj) GHC.Base.<> (("error_on_requires_action" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyErrorOnRequiresAction obj) GHC.Base.<> (("expand" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyExpand obj) GHC.Base.<> (("mandate" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandate obj) GHC.Base.<> (("mandate_data" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData obj) GHC.Base.<> (("off_session" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyOffSession obj) GHC.Base.<> (("payment_method" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethod obj) GHC.Base.<> (("payment_method_data" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData obj) GHC.Base.<> (("payment_method_options" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions obj) GHC.Base.<> (("payment_method_types" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodTypes obj) GHC.Base.<> (("receipt_email" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyReceiptEmail obj) GHC.Base.<> (("return_url" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyReturnUrl obj) GHC.Base.<> (("setup_future_usage" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodySetupFutureUsage obj) GHC.Base.<> (("shipping" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping obj) GHC.Base.<> ("use_stripe_sdk" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyUseStripeSdk obj)))))))))))))))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBody where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBody" (\obj -> ((((((((((((((GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBody GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "client_secret")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "error_on_requires_action")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "expand")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "mandate")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "mandate_data")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "off_session")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "payment_method")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "payment_method_data")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "payment_method_options")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "payment_method_types")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "receipt_email")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "return_url")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "setup_future_usage")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "shipping")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "use_stripe_sdk"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBody' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBody :: PostPaymentIntentsIntentConfirmRequestBody
mkPostPaymentIntentsIntentConfirmRequestBody =
PostPaymentIntentsIntentConfirmRequestBody
{ postPaymentIntentsIntentConfirmRequestBodyClientSecret = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyErrorOnRequiresAction = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyExpand = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyMandate = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyMandateData = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyOffSession = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethod = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodTypes = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyReceiptEmail = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyReturnUrl = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodySetupFutureUsage = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyShipping = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyUseStripeSdk = GHC.Maybe.Nothing
}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.mandate_data.anyOf@ in the specification.
--
-- This hash contains details about the Mandate to create
data PostPaymentIntentsIntentConfirmRequestBodyMandateData' = PostPaymentIntentsIntentConfirmRequestBodyMandateData'
{ -- | customer_acceptance
postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance')
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyMandateData' where
toJSON obj = Data.Aeson.Types.Internal.object ("customer_acceptance" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("customer_acceptance" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyMandateData' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyMandateData'" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyMandateData' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "customer_acceptance"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyMandateData'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyMandateData' :: PostPaymentIntentsIntentConfirmRequestBodyMandateData'
mkPostPaymentIntentsIntentConfirmRequestBodyMandateData' = PostPaymentIntentsIntentConfirmRequestBodyMandateData' {postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance = GHC.Maybe.Nothing}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.mandate_data.anyOf.properties.customer_acceptance@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance' = PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'
{ -- | accepted_at
postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'AcceptedAt :: (GHC.Maybe.Maybe GHC.Types.Int),
-- | offline
postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Offline :: (GHC.Maybe.Maybe Data.Aeson.Types.Internal.Object),
-- | online
postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'),
-- | type
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type :: PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance' where
toJSON obj = Data.Aeson.Types.Internal.object ("accepted_at" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'AcceptedAt obj : "offline" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Offline obj : "online" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online obj : "type" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("accepted_at" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'AcceptedAt obj) GHC.Base.<> (("offline" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Offline obj) GHC.Base.<> (("online" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online obj) GHC.Base.<> ("type" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type obj))))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'" (\obj -> (((GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "accepted_at")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "offline")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "online")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "type"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance' ::
-- | 'postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'
PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type' ->
PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'
mkPostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance' postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type =
PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'
{ postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'AcceptedAt = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Offline = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type = postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type
}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.mandate_data.anyOf.properties.customer_acceptance.properties.online@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online' = PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'
{ -- | ip_address
postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'IpAddress :: Data.Text.Internal.Text,
-- | user_agent
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'UserAgent :: Data.Text.Internal.Text
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online' where
toJSON obj = Data.Aeson.Types.Internal.object ("ip_address" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'IpAddress obj : "user_agent" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'UserAgent obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("ip_address" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'IpAddress obj) GHC.Base.<> ("user_agent" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'UserAgent obj))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'" (\obj -> (GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "ip_address")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "user_agent"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online' ::
-- | 'postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'IpAddress'
Data.Text.Internal.Text ->
-- | 'postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'UserAgent'
Data.Text.Internal.Text ->
PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'
mkPostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online' postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'IpAddress postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'UserAgent =
PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'
{ postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'IpAddress = postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'IpAddress,
postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'UserAgent = postPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Online'UserAgent
}
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.mandate_data.anyOf.properties.customer_acceptance.properties.type@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"offline"@
PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'EnumOffline
| -- | Represents the JSON value @"online"@
PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'EnumOnline
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'EnumOffline) = "offline"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'EnumOnline) = "online"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "offline" -> PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'EnumOffline
| val GHC.Classes.== "online" -> PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'EnumOnline
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyMandateData'CustomerAcceptance'Type'Other val
)
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.off_session.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"one_off"@
PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2EnumOneOff
| -- | Represents the JSON value @"recurring"@
PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2EnumRecurring
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2 where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2EnumOneOff) = "one_off"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2EnumRecurring) = "recurring"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2 where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "one_off" -> PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2EnumOneOff
| val GHC.Classes.== "recurring" -> PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2EnumRecurring
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2Other val
)
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.off_session.anyOf@ in the specification.
--
-- Set to \`true\` to indicate that the customer is not in your checkout flow during this payment attempt, and therefore is unable to authenticate. This parameter is intended for scenarios where you collect card details and [charge them later](https:\/\/stripe.com\/docs\/payments\/cards\/charging-saved-cards).
data PostPaymentIntentsIntentConfirmRequestBodyOffSession'Variants
= PostPaymentIntentsIntentConfirmRequestBodyOffSession'Bool GHC.Types.Bool
| PostPaymentIntentsIntentConfirmRequestBodyOffSession'PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2 PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyOffSession'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyOffSession'Bool a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyOffSession'PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2 a) = Data.Aeson.Types.ToJSON.toJSON a
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyOffSession'Variants where
parseJSON val = case (PostPaymentIntentsIntentConfirmRequestBodyOffSession'Bool Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> ((PostPaymentIntentsIntentConfirmRequestBodyOffSession'PostPaymentIntentsIntentConfirmRequestBodyOffSession'OneOf2 Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched") of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data@ in the specification.
--
-- If provided, this hash will be used to create a PaymentMethod. The new PaymentMethod will appear
-- in the [payment_method](https:\/\/stripe.com\/docs\/api\/payment_intents\/object\#payment_intent_object-payment_method)
-- property on the PaymentIntent.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'
{ -- | acss_debit
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'),
-- | afterpay_clearpay
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AfterpayClearpay :: (GHC.Maybe.Maybe Data.Aeson.Types.Internal.Object),
-- | alipay
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Alipay :: (GHC.Maybe.Maybe Data.Aeson.Types.Internal.Object),
-- | au_becs_debit
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'),
-- | bacs_debit
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'),
-- | bancontact
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Bancontact :: (GHC.Maybe.Maybe Data.Aeson.Types.Internal.Object),
-- | billing_details
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'),
-- | boleto
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto'),
-- | eps
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'),
-- | fpx
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'),
-- | giropay
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Giropay :: (GHC.Maybe.Maybe Data.Aeson.Types.Internal.Object),
-- | grabpay
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Grabpay :: (GHC.Maybe.Maybe Data.Aeson.Types.Internal.Object),
-- | ideal
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'),
-- | interac_present
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'InteracPresent :: (GHC.Maybe.Maybe Data.Aeson.Types.Internal.Object),
-- | metadata
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Metadata :: (GHC.Maybe.Maybe Data.Aeson.Types.Internal.Object),
-- | oxxo
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Oxxo :: (GHC.Maybe.Maybe Data.Aeson.Types.Internal.Object),
-- | p24
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24 :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'),
-- | sepa_debit
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit'),
-- | sofort
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'),
-- | type
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData' where
toJSON obj = Data.Aeson.Types.Internal.object ("acss_debit" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit obj : "afterpay_clearpay" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AfterpayClearpay obj : "alipay" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Alipay obj : "au_becs_debit" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit obj : "bacs_debit" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit obj : "bancontact" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Bancontact obj : "billing_details" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails obj : "boleto" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto obj : "eps" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps obj : "fpx" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx obj : "giropay" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Giropay obj : "grabpay" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Grabpay obj : "ideal" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal obj : "interac_present" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'InteracPresent obj : "metadata" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Metadata obj : "oxxo" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Oxxo obj : "p24" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24 obj : "sepa_debit" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit obj : "sofort" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort obj : "type" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("acss_debit" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit obj) GHC.Base.<> (("afterpay_clearpay" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AfterpayClearpay obj) GHC.Base.<> (("alipay" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Alipay obj) GHC.Base.<> (("au_becs_debit" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit obj) GHC.Base.<> (("bacs_debit" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit obj) GHC.Base.<> (("bancontact" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Bancontact obj) GHC.Base.<> (("billing_details" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails obj) GHC.Base.<> (("boleto" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto obj) GHC.Base.<> (("eps" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps obj) GHC.Base.<> (("fpx" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx obj) GHC.Base.<> (("giropay" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Giropay obj) GHC.Base.<> (("grabpay" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Grabpay obj) GHC.Base.<> (("ideal" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal obj) GHC.Base.<> (("interac_present" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'InteracPresent obj) GHC.Base.<> (("metadata" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Metadata obj) GHC.Base.<> (("oxxo" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Oxxo obj) GHC.Base.<> (("p24" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24 obj) GHC.Base.<> (("sepa_debit" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit obj) GHC.Base.<> (("sofort" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort obj) GHC.Base.<> ("type" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type obj))))))))))))))))))))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'" (\obj -> (((((((((((((((((((GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "acss_debit")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "afterpay_clearpay")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "alipay")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "au_becs_debit")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "bacs_debit")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "bancontact")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "billing_details")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "boleto")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "eps")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "fpx")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "giropay")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "grabpay")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "ideal")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "interac_present")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "metadata")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "oxxo")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "p24")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "sepa_debit")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "sofort")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "type"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData' ::
-- | 'postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type' ->
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData' postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type =
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'
{ postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AfterpayClearpay = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Alipay = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Bancontact = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Giropay = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Grabpay = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'InteracPresent = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Metadata = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Oxxo = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24 = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type = postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type
}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.acss_debit@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'
{ -- | account_number
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'AccountNumber :: Data.Text.Internal.Text,
-- | institution_number
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'InstitutionNumber :: Data.Text.Internal.Text,
-- | transit_number
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'TransitNumber :: Data.Text.Internal.Text
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit' where
toJSON obj = Data.Aeson.Types.Internal.object ("account_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'AccountNumber obj : "institution_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'InstitutionNumber obj : "transit_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'TransitNumber obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("account_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'AccountNumber obj) GHC.Base.<> (("institution_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'InstitutionNumber obj) GHC.Base.<> ("transit_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'TransitNumber obj)))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'" (\obj -> ((GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "account_number")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "institution_number")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "transit_number"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit' ::
-- | 'postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'AccountNumber'
Data.Text.Internal.Text ->
-- | 'postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'InstitutionNumber'
Data.Text.Internal.Text ->
-- | 'postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'TransitNumber'
Data.Text.Internal.Text ->
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit' postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'AccountNumber postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'InstitutionNumber postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'TransitNumber =
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'
{ postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'AccountNumber = postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'AccountNumber,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'InstitutionNumber = postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'InstitutionNumber,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'TransitNumber = postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AcssDebit'TransitNumber
}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.au_becs_debit@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'
{ -- | account_number
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'AccountNumber :: Data.Text.Internal.Text,
-- | bsb_number
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'BsbNumber :: Data.Text.Internal.Text
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit' where
toJSON obj = Data.Aeson.Types.Internal.object ("account_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'AccountNumber obj : "bsb_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'BsbNumber obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("account_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'AccountNumber obj) GHC.Base.<> ("bsb_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'BsbNumber obj))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'" (\obj -> (GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "account_number")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "bsb_number"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit' ::
-- | 'postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'AccountNumber'
Data.Text.Internal.Text ->
-- | 'postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'BsbNumber'
Data.Text.Internal.Text ->
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit' postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'AccountNumber postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'BsbNumber =
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'
{ postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'AccountNumber = postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'AccountNumber,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'BsbNumber = postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'AuBecsDebit'BsbNumber
}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.bacs_debit@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'
{ -- | account_number
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'AccountNumber :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | sort_code
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'SortCode :: (GHC.Maybe.Maybe Data.Text.Internal.Text)
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit' where
toJSON obj = Data.Aeson.Types.Internal.object ("account_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'AccountNumber obj : "sort_code" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'SortCode obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("account_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'AccountNumber obj) GHC.Base.<> ("sort_code" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'SortCode obj))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'" (\obj -> (GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "account_number")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "sort_code"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit' :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit' =
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'
{ postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'AccountNumber = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BacsDebit'SortCode = GHC.Maybe.Nothing
}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.billing_details@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'
{ -- | address
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'Variants),
-- | email
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Email :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | name
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Name :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | phone
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Phone :: (GHC.Maybe.Maybe Data.Text.Internal.Text)
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails' where
toJSON obj = Data.Aeson.Types.Internal.object ("address" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address obj : "email" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Email obj : "name" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Name obj : "phone" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Phone obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("address" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address obj) GHC.Base.<> (("email" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Email obj) GHC.Base.<> (("name" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Name obj) GHC.Base.<> ("phone" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Phone obj))))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'" (\obj -> (((GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "address")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "email")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "name")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "phone"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails' :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails' =
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'
{ postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Email = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Name = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Phone = GHC.Maybe.Nothing
}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.billing_details.properties.address.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1
{ -- | city
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1City :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | country
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1Country :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | line1
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1Line1 :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | line2
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1Line2 :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | postal_code
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1PostalCode :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | state
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1State :: (GHC.Maybe.Maybe Data.Text.Internal.Text)
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1 where
toJSON obj = Data.Aeson.Types.Internal.object ("city" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1City obj : "country" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1Country obj : "line1" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1Line1 obj : "line2" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1Line2 obj : "postal_code" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1PostalCode obj : "state" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1State obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("city" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1City obj) GHC.Base.<> (("country" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1Country obj) GHC.Base.<> (("line1" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1Line1 obj) GHC.Base.<> (("line2" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1Line2 obj) GHC.Base.<> (("postal_code" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1PostalCode obj) GHC.Base.<> ("state" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1State obj))))))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1 where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1" (\obj -> (((((GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1 GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "city")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "country")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "line1")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "line2")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "postal_code")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "state"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1 :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1 =
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1
{ postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1City = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1Country = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1Line1 = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1Line2 = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1PostalCode = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1State = GHC.Maybe.Nothing
}
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.billing_details.properties.address.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1 PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1 a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'BillingDetails'Address'OneOf1 Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.boleto@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto'
{ -- | tax_id
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto'TaxId :: Data.Text.Internal.Text
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto' where
toJSON obj = Data.Aeson.Types.Internal.object ("tax_id" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto'TaxId obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("tax_id" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto'TaxId obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto'" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "tax_id"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto' ::
-- | 'postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto'TaxId'
Data.Text.Internal.Text ->
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto' postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto'TaxId = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto' {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto'TaxId = postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Boleto'TaxId}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.eps@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'
{ -- | bank
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank')
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps' where
toJSON obj = Data.Aeson.Types.Internal.object ("bank" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("bank" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "bank"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps' :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps' {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank = GHC.Maybe.Nothing}
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.eps.properties.bank@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"arzte_und_apotheker_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumArzteUndApothekerBank
| -- | Represents the JSON value @"austrian_anadi_bank_ag"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumAustrianAnadiBankAg
| -- | Represents the JSON value @"bank_austria"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBankAustria
| -- | Represents the JSON value @"bankhaus_carl_spangler"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBankhausCarlSpangler
| -- | Represents the JSON value @"bankhaus_schelhammer_und_schattera_ag"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBankhausSchelhammerUndSchatteraAg
| -- | Represents the JSON value @"bawag_psk_ag"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBawagPskAg
| -- | Represents the JSON value @"bks_bank_ag"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBksBankAg
| -- | Represents the JSON value @"brull_kallmus_bank_ag"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBrullKallmusBankAg
| -- | Represents the JSON value @"btv_vier_lander_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBtvVierLanderBank
| -- | Represents the JSON value @"capital_bank_grawe_gruppe_ag"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumCapitalBankGraweGruppeAg
| -- | Represents the JSON value @"dolomitenbank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumDolomitenbank
| -- | Represents the JSON value @"easybank_ag"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumEasybankAg
| -- | Represents the JSON value @"erste_bank_und_sparkassen"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumErsteBankUndSparkassen
| -- | Represents the JSON value @"hypo_alpeadriabank_international_ag"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoAlpeadriabankInternationalAg
| -- | Represents the JSON value @"hypo_bank_burgenland_aktiengesellschaft"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoBankBurgenlandAktiengesellschaft
| -- | Represents the JSON value @"hypo_noe_lb_fur_niederosterreich_u_wien"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoNoeLbFurNiederosterreichUWien
| -- | Represents the JSON value @"hypo_oberosterreich_salzburg_steiermark"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoOberosterreichSalzburgSteiermark
| -- | Represents the JSON value @"hypo_tirol_bank_ag"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoTirolBankAg
| -- | Represents the JSON value @"hypo_vorarlberg_bank_ag"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoVorarlbergBankAg
| -- | Represents the JSON value @"marchfelder_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumMarchfelderBank
| -- | Represents the JSON value @"oberbank_ag"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumOberbankAg
| -- | Represents the JSON value @"raiffeisen_bankengruppe_osterreich"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumRaiffeisenBankengruppeOsterreich
| -- | Represents the JSON value @"schoellerbank_ag"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumSchoellerbankAg
| -- | Represents the JSON value @"sparda_bank_wien"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumSpardaBankWien
| -- | Represents the JSON value @"volksbank_gruppe"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumVolksbankGruppe
| -- | Represents the JSON value @"volkskreditbank_ag"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumVolkskreditbankAg
| -- | Represents the JSON value @"vr_bank_braunau"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumVrBankBraunau
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumArzteUndApothekerBank) = "arzte_und_apotheker_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumAustrianAnadiBankAg) = "austrian_anadi_bank_ag"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBankAustria) = "bank_austria"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBankhausCarlSpangler) = "bankhaus_carl_spangler"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBankhausSchelhammerUndSchatteraAg) = "bankhaus_schelhammer_und_schattera_ag"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBawagPskAg) = "bawag_psk_ag"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBksBankAg) = "bks_bank_ag"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBrullKallmusBankAg) = "brull_kallmus_bank_ag"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBtvVierLanderBank) = "btv_vier_lander_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumCapitalBankGraweGruppeAg) = "capital_bank_grawe_gruppe_ag"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumDolomitenbank) = "dolomitenbank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumEasybankAg) = "easybank_ag"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumErsteBankUndSparkassen) = "erste_bank_und_sparkassen"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoAlpeadriabankInternationalAg) = "hypo_alpeadriabank_international_ag"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoBankBurgenlandAktiengesellschaft) = "hypo_bank_burgenland_aktiengesellschaft"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoNoeLbFurNiederosterreichUWien) = "hypo_noe_lb_fur_niederosterreich_u_wien"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoOberosterreichSalzburgSteiermark) = "hypo_oberosterreich_salzburg_steiermark"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoTirolBankAg) = "hypo_tirol_bank_ag"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoVorarlbergBankAg) = "hypo_vorarlberg_bank_ag"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumMarchfelderBank) = "marchfelder_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumOberbankAg) = "oberbank_ag"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumRaiffeisenBankengruppeOsterreich) = "raiffeisen_bankengruppe_osterreich"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumSchoellerbankAg) = "schoellerbank_ag"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumSpardaBankWien) = "sparda_bank_wien"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumVolksbankGruppe) = "volksbank_gruppe"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumVolkskreditbankAg) = "volkskreditbank_ag"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumVrBankBraunau) = "vr_bank_braunau"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "arzte_und_apotheker_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumArzteUndApothekerBank
| val GHC.Classes.== "austrian_anadi_bank_ag" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumAustrianAnadiBankAg
| val GHC.Classes.== "bank_austria" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBankAustria
| val GHC.Classes.== "bankhaus_carl_spangler" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBankhausCarlSpangler
| val GHC.Classes.== "bankhaus_schelhammer_und_schattera_ag" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBankhausSchelhammerUndSchatteraAg
| val GHC.Classes.== "bawag_psk_ag" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBawagPskAg
| val GHC.Classes.== "bks_bank_ag" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBksBankAg
| val GHC.Classes.== "brull_kallmus_bank_ag" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBrullKallmusBankAg
| val GHC.Classes.== "btv_vier_lander_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumBtvVierLanderBank
| val GHC.Classes.== "capital_bank_grawe_gruppe_ag" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumCapitalBankGraweGruppeAg
| val GHC.Classes.== "dolomitenbank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumDolomitenbank
| val GHC.Classes.== "easybank_ag" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumEasybankAg
| val GHC.Classes.== "erste_bank_und_sparkassen" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumErsteBankUndSparkassen
| val GHC.Classes.== "hypo_alpeadriabank_international_ag" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoAlpeadriabankInternationalAg
| val GHC.Classes.== "hypo_bank_burgenland_aktiengesellschaft" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoBankBurgenlandAktiengesellschaft
| val GHC.Classes.== "hypo_noe_lb_fur_niederosterreich_u_wien" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoNoeLbFurNiederosterreichUWien
| val GHC.Classes.== "hypo_oberosterreich_salzburg_steiermark" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoOberosterreichSalzburgSteiermark
| val GHC.Classes.== "hypo_tirol_bank_ag" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoTirolBankAg
| val GHC.Classes.== "hypo_vorarlberg_bank_ag" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumHypoVorarlbergBankAg
| val GHC.Classes.== "marchfelder_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumMarchfelderBank
| val GHC.Classes.== "oberbank_ag" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumOberbankAg
| val GHC.Classes.== "raiffeisen_bankengruppe_osterreich" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumRaiffeisenBankengruppeOsterreich
| val GHC.Classes.== "schoellerbank_ag" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumSchoellerbankAg
| val GHC.Classes.== "sparda_bank_wien" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumSpardaBankWien
| val GHC.Classes.== "volksbank_gruppe" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumVolksbankGruppe
| val GHC.Classes.== "volkskreditbank_ag" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumVolkskreditbankAg
| val GHC.Classes.== "vr_bank_braunau" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'EnumVrBankBraunau
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Eps'Bank'Other val
)
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.fpx@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'
{ -- | bank
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx' where
toJSON obj = Data.Aeson.Types.Internal.object ("bank" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("bank" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "bank"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx' ::
-- | 'postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank' ->
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx' postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx' {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank = postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank}
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.fpx.properties.bank@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"affin_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumAffinBank
| -- | Represents the JSON value @"alliance_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumAllianceBank
| -- | Represents the JSON value @"ambank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumAmbank
| -- | Represents the JSON value @"bank_islam"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumBankIslam
| -- | Represents the JSON value @"bank_muamalat"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumBankMuamalat
| -- | Represents the JSON value @"bank_rakyat"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumBankRakyat
| -- | Represents the JSON value @"bsn"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumBsn
| -- | Represents the JSON value @"cimb"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumCimb
| -- | Represents the JSON value @"deutsche_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumDeutscheBank
| -- | Represents the JSON value @"hong_leong_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumHongLeongBank
| -- | Represents the JSON value @"hsbc"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumHsbc
| -- | Represents the JSON value @"kfh"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumKfh
| -- | Represents the JSON value @"maybank2e"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumMaybank2e
| -- | Represents the JSON value @"maybank2u"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumMaybank2u
| -- | Represents the JSON value @"ocbc"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumOcbc
| -- | Represents the JSON value @"pb_enterprise"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumPbEnterprise
| -- | Represents the JSON value @"public_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumPublicBank
| -- | Represents the JSON value @"rhb"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumRhb
| -- | Represents the JSON value @"standard_chartered"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumStandardChartered
| -- | Represents the JSON value @"uob"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumUob
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumAffinBank) = "affin_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumAllianceBank) = "alliance_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumAmbank) = "ambank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumBankIslam) = "bank_islam"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumBankMuamalat) = "bank_muamalat"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumBankRakyat) = "bank_rakyat"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumBsn) = "bsn"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumCimb) = "cimb"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumDeutscheBank) = "deutsche_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumHongLeongBank) = "hong_leong_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumHsbc) = "hsbc"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumKfh) = "kfh"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumMaybank2e) = "maybank2e"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumMaybank2u) = "maybank2u"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumOcbc) = "ocbc"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumPbEnterprise) = "pb_enterprise"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumPublicBank) = "public_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumRhb) = "rhb"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumStandardChartered) = "standard_chartered"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumUob) = "uob"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "affin_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumAffinBank
| val GHC.Classes.== "alliance_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumAllianceBank
| val GHC.Classes.== "ambank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumAmbank
| val GHC.Classes.== "bank_islam" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumBankIslam
| val GHC.Classes.== "bank_muamalat" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumBankMuamalat
| val GHC.Classes.== "bank_rakyat" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumBankRakyat
| val GHC.Classes.== "bsn" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumBsn
| val GHC.Classes.== "cimb" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumCimb
| val GHC.Classes.== "deutsche_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumDeutscheBank
| val GHC.Classes.== "hong_leong_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumHongLeongBank
| val GHC.Classes.== "hsbc" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumHsbc
| val GHC.Classes.== "kfh" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumKfh
| val GHC.Classes.== "maybank2e" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumMaybank2e
| val GHC.Classes.== "maybank2u" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumMaybank2u
| val GHC.Classes.== "ocbc" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumOcbc
| val GHC.Classes.== "pb_enterprise" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumPbEnterprise
| val GHC.Classes.== "public_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumPublicBank
| val GHC.Classes.== "rhb" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumRhb
| val GHC.Classes.== "standard_chartered" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumStandardChartered
| val GHC.Classes.== "uob" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'EnumUob
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Fpx'Bank'Other val
)
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.ideal@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'
{ -- | bank
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank')
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal' where
toJSON obj = Data.Aeson.Types.Internal.object ("bank" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("bank" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "bank"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal' :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal' {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank = GHC.Maybe.Nothing}
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.ideal.properties.bank@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"abn_amro"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumAbnAmro
| -- | Represents the JSON value @"asn_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumAsnBank
| -- | Represents the JSON value @"bunq"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumBunq
| -- | Represents the JSON value @"handelsbanken"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumHandelsbanken
| -- | Represents the JSON value @"ing"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumIng
| -- | Represents the JSON value @"knab"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumKnab
| -- | Represents the JSON value @"moneyou"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumMoneyou
| -- | Represents the JSON value @"rabobank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumRabobank
| -- | Represents the JSON value @"regiobank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumRegiobank
| -- | Represents the JSON value @"revolut"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumRevolut
| -- | Represents the JSON value @"sns_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumSnsBank
| -- | Represents the JSON value @"triodos_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumTriodosBank
| -- | Represents the JSON value @"van_lanschot"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumVanLanschot
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumAbnAmro) = "abn_amro"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumAsnBank) = "asn_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumBunq) = "bunq"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumHandelsbanken) = "handelsbanken"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumIng) = "ing"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumKnab) = "knab"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumMoneyou) = "moneyou"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumRabobank) = "rabobank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumRegiobank) = "regiobank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumRevolut) = "revolut"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumSnsBank) = "sns_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumTriodosBank) = "triodos_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumVanLanschot) = "van_lanschot"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "abn_amro" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumAbnAmro
| val GHC.Classes.== "asn_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumAsnBank
| val GHC.Classes.== "bunq" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumBunq
| val GHC.Classes.== "handelsbanken" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumHandelsbanken
| val GHC.Classes.== "ing" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumIng
| val GHC.Classes.== "knab" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumKnab
| val GHC.Classes.== "moneyou" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumMoneyou
| val GHC.Classes.== "rabobank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumRabobank
| val GHC.Classes.== "regiobank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumRegiobank
| val GHC.Classes.== "revolut" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumRevolut
| val GHC.Classes.== "sns_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumSnsBank
| val GHC.Classes.== "triodos_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumTriodosBank
| val GHC.Classes.== "van_lanschot" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'EnumVanLanschot
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Ideal'Bank'Other val
)
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.p24@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'
{ -- | bank
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank')
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24' where
toJSON obj = Data.Aeson.Types.Internal.object ("bank" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("bank" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "bank"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24' :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24' {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank = GHC.Maybe.Nothing}
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.p24.properties.bank@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"alior_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumAliorBank
| -- | Represents the JSON value @"bank_millennium"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBankMillennium
| -- | Represents the JSON value @"bank_nowy_bfg_sa"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBankNowyBfgSa
| -- | Represents the JSON value @"bank_pekao_sa"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBankPekaoSa
| -- | Represents the JSON value @"banki_spbdzielcze"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBankiSpbdzielcze
| -- | Represents the JSON value @"blik"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBlik
| -- | Represents the JSON value @"bnp_paribas"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBnpParibas
| -- | Represents the JSON value @"boz"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBoz
| -- | Represents the JSON value @"citi_handlowy"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumCitiHandlowy
| -- | Represents the JSON value @"credit_agricole"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumCreditAgricole
| -- | Represents the JSON value @"envelobank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumEnvelobank
| -- | Represents the JSON value @"etransfer_pocztowy24"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumEtransferPocztowy24
| -- | Represents the JSON value @"getin_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumGetinBank
| -- | Represents the JSON value @"ideabank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumIdeabank
| -- | Represents the JSON value @"ing"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumIng
| -- | Represents the JSON value @"inteligo"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumInteligo
| -- | Represents the JSON value @"mbank_mtransfer"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumMbankMtransfer
| -- | Represents the JSON value @"nest_przelew"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumNestPrzelew
| -- | Represents the JSON value @"noble_pay"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumNoblePay
| -- | Represents the JSON value @"pbac_z_ipko"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumPbacZIpko
| -- | Represents the JSON value @"plus_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumPlusBank
| -- | Represents the JSON value @"santander_przelew24"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumSantanderPrzelew24
| -- | Represents the JSON value @"tmobile_usbugi_bankowe"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumTmobileUsbugiBankowe
| -- | Represents the JSON value @"toyota_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumToyotaBank
| -- | Represents the JSON value @"volkswagen_bank"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumVolkswagenBank
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumAliorBank) = "alior_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBankMillennium) = "bank_millennium"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBankNowyBfgSa) = "bank_nowy_bfg_sa"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBankPekaoSa) = "bank_pekao_sa"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBankiSpbdzielcze) = "banki_spbdzielcze"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBlik) = "blik"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBnpParibas) = "bnp_paribas"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBoz) = "boz"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumCitiHandlowy) = "citi_handlowy"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumCreditAgricole) = "credit_agricole"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumEnvelobank) = "envelobank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumEtransferPocztowy24) = "etransfer_pocztowy24"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumGetinBank) = "getin_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumIdeabank) = "ideabank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumIng) = "ing"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumInteligo) = "inteligo"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumMbankMtransfer) = "mbank_mtransfer"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumNestPrzelew) = "nest_przelew"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumNoblePay) = "noble_pay"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumPbacZIpko) = "pbac_z_ipko"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumPlusBank) = "plus_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumSantanderPrzelew24) = "santander_przelew24"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumTmobileUsbugiBankowe) = "tmobile_usbugi_bankowe"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumToyotaBank) = "toyota_bank"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumVolkswagenBank) = "volkswagen_bank"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "alior_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumAliorBank
| val GHC.Classes.== "bank_millennium" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBankMillennium
| val GHC.Classes.== "bank_nowy_bfg_sa" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBankNowyBfgSa
| val GHC.Classes.== "bank_pekao_sa" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBankPekaoSa
| val GHC.Classes.== "banki_spbdzielcze" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBankiSpbdzielcze
| val GHC.Classes.== "blik" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBlik
| val GHC.Classes.== "bnp_paribas" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBnpParibas
| val GHC.Classes.== "boz" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumBoz
| val GHC.Classes.== "citi_handlowy" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumCitiHandlowy
| val GHC.Classes.== "credit_agricole" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumCreditAgricole
| val GHC.Classes.== "envelobank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumEnvelobank
| val GHC.Classes.== "etransfer_pocztowy24" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumEtransferPocztowy24
| val GHC.Classes.== "getin_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumGetinBank
| val GHC.Classes.== "ideabank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumIdeabank
| val GHC.Classes.== "ing" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumIng
| val GHC.Classes.== "inteligo" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumInteligo
| val GHC.Classes.== "mbank_mtransfer" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumMbankMtransfer
| val GHC.Classes.== "nest_przelew" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumNestPrzelew
| val GHC.Classes.== "noble_pay" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumNoblePay
| val GHC.Classes.== "pbac_z_ipko" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumPbacZIpko
| val GHC.Classes.== "plus_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumPlusBank
| val GHC.Classes.== "santander_przelew24" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumSantanderPrzelew24
| val GHC.Classes.== "tmobile_usbugi_bankowe" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumTmobileUsbugiBankowe
| val GHC.Classes.== "toyota_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumToyotaBank
| val GHC.Classes.== "volkswagen_bank" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'EnumVolkswagenBank
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'P24'Bank'Other val
)
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.sepa_debit@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit'
{ -- | iban
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit'Iban :: Data.Text.Internal.Text
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit' where
toJSON obj = Data.Aeson.Types.Internal.object ("iban" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit'Iban obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("iban" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit'Iban obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit'" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "iban"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit' ::
-- | 'postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit'Iban'
Data.Text.Internal.Text ->
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit' postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit'Iban = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit' {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit'Iban = postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'SepaDebit'Iban}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.sofort@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'
{ -- | country
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort' where
toJSON obj = Data.Aeson.Types.Internal.object ("country" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("country" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "country"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort' ::
-- | 'postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country' ->
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort' postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort' {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country = postPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country}
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.sofort.properties.country@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"AT"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumAT
| -- | Represents the JSON value @"BE"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumBE
| -- | Represents the JSON value @"DE"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumDE
| -- | Represents the JSON value @"ES"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumES
| -- | Represents the JSON value @"IT"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumIT
| -- | Represents the JSON value @"NL"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumNL
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumAT) = "AT"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumBE) = "BE"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumDE) = "DE"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumES) = "ES"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumIT) = "IT"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumNL) = "NL"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "AT" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumAT
| val GHC.Classes.== "BE" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumBE
| val GHC.Classes.== "DE" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumDE
| val GHC.Classes.== "ES" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumES
| val GHC.Classes.== "IT" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumIT
| val GHC.Classes.== "NL" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'EnumNL
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Sofort'Country'Other val
)
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_data.properties.type@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"acss_debit"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumAcssDebit
| -- | Represents the JSON value @"afterpay_clearpay"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumAfterpayClearpay
| -- | Represents the JSON value @"alipay"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumAlipay
| -- | Represents the JSON value @"au_becs_debit"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumAuBecsDebit
| -- | Represents the JSON value @"bacs_debit"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumBacsDebit
| -- | Represents the JSON value @"bancontact"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumBancontact
| -- | Represents the JSON value @"boleto"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumBoleto
| -- | Represents the JSON value @"eps"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumEps
| -- | Represents the JSON value @"fpx"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumFpx
| -- | Represents the JSON value @"giropay"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumGiropay
| -- | Represents the JSON value @"grabpay"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumGrabpay
| -- | Represents the JSON value @"ideal"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumIdeal
| -- | Represents the JSON value @"oxxo"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumOxxo
| -- | Represents the JSON value @"p24"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumP24
| -- | Represents the JSON value @"sepa_debit"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumSepaDebit
| -- | Represents the JSON value @"sofort"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumSofort
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumAcssDebit) = "acss_debit"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumAfterpayClearpay) = "afterpay_clearpay"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumAlipay) = "alipay"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumAuBecsDebit) = "au_becs_debit"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumBacsDebit) = "bacs_debit"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumBancontact) = "bancontact"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumBoleto) = "boleto"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumEps) = "eps"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumFpx) = "fpx"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumGiropay) = "giropay"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumGrabpay) = "grabpay"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumIdeal) = "ideal"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumOxxo) = "oxxo"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumP24) = "p24"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumSepaDebit) = "sepa_debit"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumSofort) = "sofort"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "acss_debit" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumAcssDebit
| val GHC.Classes.== "afterpay_clearpay" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumAfterpayClearpay
| val GHC.Classes.== "alipay" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumAlipay
| val GHC.Classes.== "au_becs_debit" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumAuBecsDebit
| val GHC.Classes.== "bacs_debit" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumBacsDebit
| val GHC.Classes.== "bancontact" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumBancontact
| val GHC.Classes.== "boleto" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumBoleto
| val GHC.Classes.== "eps" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumEps
| val GHC.Classes.== "fpx" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumFpx
| val GHC.Classes.== "giropay" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumGiropay
| val GHC.Classes.== "grabpay" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumGrabpay
| val GHC.Classes.== "ideal" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumIdeal
| val GHC.Classes.== "oxxo" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumOxxo
| val GHC.Classes.== "p24" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumP24
| val GHC.Classes.== "sepa_debit" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumSepaDebit
| val GHC.Classes.== "sofort" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'EnumSofort
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodData'Type'Other val
)
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options@ in the specification.
--
-- Payment-method-specific configuration for this PaymentIntent.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'
{ -- | acss_debit
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'Variants),
-- | afterpay_clearpay
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'Variants),
-- | alipay
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay'Variants),
-- | bancontact
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'Variants),
-- | boleto
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'Variants),
-- | card
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'Variants),
-- | card_present
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent'Variants),
-- | oxxo
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'Variants),
-- | p24
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24 :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'Variants),
-- | sepa_debit
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'Variants),
-- | sofort
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'Variants)
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions' where
toJSON obj = Data.Aeson.Types.Internal.object ("acss_debit" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit obj : "afterpay_clearpay" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay obj : "alipay" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay obj : "bancontact" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact obj : "boleto" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto obj : "card" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card obj : "card_present" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent obj : "oxxo" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo obj : "p24" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24 obj : "sepa_debit" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit obj : "sofort" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("acss_debit" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit obj) GHC.Base.<> (("afterpay_clearpay" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay obj) GHC.Base.<> (("alipay" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay obj) GHC.Base.<> (("bancontact" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact obj) GHC.Base.<> (("boleto" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto obj) GHC.Base.<> (("card" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card obj) GHC.Base.<> (("card_present" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent obj) GHC.Base.<> (("oxxo" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo obj) GHC.Base.<> (("p24" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24 obj) GHC.Base.<> (("sepa_debit" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit obj) GHC.Base.<> ("sofort" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort obj)))))))))))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'" (\obj -> ((((((((((GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "acss_debit")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "afterpay_clearpay")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "alipay")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "bancontact")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "boleto")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "card")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "card_present")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "oxxo")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "p24")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "sepa_debit")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "sofort"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions' :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions' =
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'
{ postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24 = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort = GHC.Maybe.Nothing
}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.acss_debit.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1
{ -- | mandate_options
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'),
-- | verification_method
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod')
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1 where
toJSON obj = Data.Aeson.Types.Internal.object ("mandate_options" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions obj : "verification_method" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("mandate_options" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions obj) GHC.Base.<> ("verification_method" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod obj))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1 where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1" (\obj -> (GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1 GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "mandate_options")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "verification_method"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1 :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1 =
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1
{ postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod = GHC.Maybe.Nothing
}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.acss_debit.anyOf.properties.mandate_options@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'
{ -- | custom_mandate_url
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl'Variants),
-- | interval_description
--
-- Constraints:
--
-- * Maximum length of 500
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'IntervalDescription :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | payment_schedule
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'),
-- | transaction_type
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType')
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions' where
toJSON obj = Data.Aeson.Types.Internal.object ("custom_mandate_url" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl obj : "interval_description" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'IntervalDescription obj : "payment_schedule" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule obj : "transaction_type" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("custom_mandate_url" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl obj) GHC.Base.<> (("interval_description" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'IntervalDescription obj) GHC.Base.<> (("payment_schedule" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule obj) GHC.Base.<> ("transaction_type" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType obj))))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'" (\obj -> (((GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "custom_mandate_url")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "interval_description")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "payment_schedule")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "transaction_type"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions' :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions' =
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'
{ postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'IntervalDescription = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType = GHC.Maybe.Nothing
}
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.acss_debit.anyOf.properties.mandate_options.properties.custom_mandate_url.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl'Text Data.Text.Internal.Text
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl'Text a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'CustomMandateUrl'Text Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.acss_debit.anyOf.properties.mandate_options.properties.payment_schedule@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"combined"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'EnumCombined
| -- | Represents the JSON value @"interval"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'EnumInterval
| -- | Represents the JSON value @"sporadic"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'EnumSporadic
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'EnumCombined) = "combined"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'EnumInterval) = "interval"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'EnumSporadic) = "sporadic"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "combined" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'EnumCombined
| val GHC.Classes.== "interval" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'EnumInterval
| val GHC.Classes.== "sporadic" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'EnumSporadic
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'PaymentSchedule'Other val
)
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.acss_debit.anyOf.properties.mandate_options.properties.transaction_type@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"business"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType'EnumBusiness
| -- | Represents the JSON value @"personal"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType'EnumPersonal
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType'EnumBusiness) = "business"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType'EnumPersonal) = "personal"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "business" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType'EnumBusiness
| val GHC.Classes.== "personal" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType'EnumPersonal
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1MandateOptions'TransactionType'Other val
)
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.acss_debit.anyOf.properties.verification_method@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"automatic"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'EnumAutomatic
| -- | Represents the JSON value @"instant"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'EnumInstant
| -- | Represents the JSON value @"microdeposits"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'EnumMicrodeposits
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'EnumAutomatic) = "automatic"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'EnumInstant) = "instant"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'EnumMicrodeposits) = "microdeposits"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "automatic" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'EnumAutomatic
| val GHC.Classes.== "instant" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'EnumInstant
| val GHC.Classes.== "microdeposits" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'EnumMicrodeposits
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1VerificationMethod'Other val
)
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.acss_debit.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1 PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1 a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AcssDebit'OneOf1 Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.afterpay_clearpay.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1
{ -- | reference
--
-- Constraints:
--
-- * Maximum length of 128
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1Reference :: (GHC.Maybe.Maybe Data.Text.Internal.Text)
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1 where
toJSON obj = Data.Aeson.Types.Internal.object ("reference" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1Reference obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("reference" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1Reference obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1 where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1 GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "reference"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1 :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1 {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1Reference = GHC.Maybe.Nothing}
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.afterpay_clearpay.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1 PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1 a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'AfterpayClearpay'OneOf1 Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.alipay.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay'Object Data.Aeson.Types.Internal.Object
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay'Object a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Alipay'Object Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.bancontact.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1
{ -- | preferred_language
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage')
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1 where
toJSON obj = Data.Aeson.Types.Internal.object ("preferred_language" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("preferred_language" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1 where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1 GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "preferred_language"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1 :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1 {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage = GHC.Maybe.Nothing}
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.bancontact.anyOf.properties.preferred_language@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"de"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'EnumDe
| -- | Represents the JSON value @"en"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'EnumEn
| -- | Represents the JSON value @"fr"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'EnumFr
| -- | Represents the JSON value @"nl"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'EnumNl
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'EnumDe) = "de"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'EnumEn) = "en"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'EnumFr) = "fr"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'EnumNl) = "nl"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "de" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'EnumDe
| val GHC.Classes.== "en" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'EnumEn
| val GHC.Classes.== "fr" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'EnumFr
| val GHC.Classes.== "nl" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'EnumNl
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1PreferredLanguage'Other val
)
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.bancontact.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1 PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1 a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Bancontact'OneOf1 Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.boleto.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1
{ -- | expires_after_days
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1ExpiresAfterDays :: (GHC.Maybe.Maybe GHC.Types.Int)
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1 where
toJSON obj = Data.Aeson.Types.Internal.object ("expires_after_days" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1ExpiresAfterDays obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("expires_after_days" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1ExpiresAfterDays obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1 where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1 GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "expires_after_days"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1 :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1 {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1ExpiresAfterDays = GHC.Maybe.Nothing}
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.boleto.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1 PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1 a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Boleto'OneOf1 Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.card.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1
{ -- | cvc_token
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1CvcToken :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | installments
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'),
-- | network
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'),
-- | request_three_d_secure
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure')
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1 where
toJSON obj = Data.Aeson.Types.Internal.object ("cvc_token" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1CvcToken obj : "installments" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments obj : "network" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network obj : "request_three_d_secure" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("cvc_token" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1CvcToken obj) GHC.Base.<> (("installments" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments obj) GHC.Base.<> (("network" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network obj) GHC.Base.<> ("request_three_d_secure" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure obj))))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1 where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1" (\obj -> (((GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1 GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "cvc_token")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "installments")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "network")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "request_three_d_secure"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1 :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1 =
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1
{ postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1CvcToken = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure = GHC.Maybe.Nothing
}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.card.anyOf.properties.installments@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments' = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'
{ -- | enabled
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Enabled :: (GHC.Maybe.Maybe GHC.Types.Bool),
-- | plan
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'Variants)
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments' where
toJSON obj = Data.Aeson.Types.Internal.object ("enabled" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Enabled obj : "plan" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("enabled" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Enabled obj) GHC.Base.<> ("plan" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan obj))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'" (\obj -> (GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "enabled")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "plan"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments' :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments' =
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'
{ postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Enabled = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan = GHC.Maybe.Nothing
}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.card.anyOf.properties.installments.properties.plan.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1
{ -- | count
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1Count :: GHC.Types.Int
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1 where
toJSON obj = Data.Aeson.Types.Internal.object ("count" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1Count obj : "interval" Data.Aeson.Types.ToJSON..= Data.Aeson.Types.Internal.String "month" : "type" Data.Aeson.Types.ToJSON..= Data.Aeson.Types.Internal.String "fixed_count" : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("count" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1Count obj) GHC.Base.<> (("interval" Data.Aeson.Types.ToJSON..= Data.Aeson.Types.Internal.String "month") GHC.Base.<> ("type" Data.Aeson.Types.ToJSON..= Data.Aeson.Types.Internal.String "fixed_count")))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1 where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1 GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "count"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1 ::
-- | 'postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1Count'
GHC.Types.Int ->
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1 postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1Count = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1 {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1Count = postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1Count}
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.card.anyOf.properties.installments.properties.plan.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1 PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1 a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Installments'Plan'OneOf1 Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.card.anyOf.properties.network@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"amex"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumAmex
| -- | Represents the JSON value @"cartes_bancaires"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumCartesBancaires
| -- | Represents the JSON value @"diners"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumDiners
| -- | Represents the JSON value @"discover"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumDiscover
| -- | Represents the JSON value @"interac"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumInterac
| -- | Represents the JSON value @"jcb"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumJcb
| -- | Represents the JSON value @"mastercard"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumMastercard
| -- | Represents the JSON value @"unionpay"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumUnionpay
| -- | Represents the JSON value @"unknown"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumUnknown
| -- | Represents the JSON value @"visa"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumVisa
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumAmex) = "amex"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumCartesBancaires) = "cartes_bancaires"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumDiners) = "diners"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumDiscover) = "discover"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumInterac) = "interac"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumJcb) = "jcb"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumMastercard) = "mastercard"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumUnionpay) = "unionpay"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumUnknown) = "unknown"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumVisa) = "visa"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "amex" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumAmex
| val GHC.Classes.== "cartes_bancaires" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumCartesBancaires
| val GHC.Classes.== "diners" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumDiners
| val GHC.Classes.== "discover" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumDiscover
| val GHC.Classes.== "interac" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumInterac
| val GHC.Classes.== "jcb" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumJcb
| val GHC.Classes.== "mastercard" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumMastercard
| val GHC.Classes.== "unionpay" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumUnionpay
| val GHC.Classes.== "unknown" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumUnknown
| val GHC.Classes.== "visa" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'EnumVisa
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1Network'Other val
)
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.card.anyOf.properties.request_three_d_secure@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"any"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure'EnumAny
| -- | Represents the JSON value @"automatic"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure'EnumAutomatic
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure'EnumAny) = "any"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure'EnumAutomatic) = "automatic"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "any" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure'EnumAny
| val GHC.Classes.== "automatic" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure'EnumAutomatic
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1RequestThreeDSecure'Other val
)
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.card.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1 PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1 a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Card'OneOf1 Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.card_present.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent'Object Data.Aeson.Types.Internal.Object
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent'Object a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'CardPresent'Object Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.oxxo.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1
{ -- | expires_after_days
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1ExpiresAfterDays :: (GHC.Maybe.Maybe GHC.Types.Int)
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1 where
toJSON obj = Data.Aeson.Types.Internal.object ("expires_after_days" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1ExpiresAfterDays obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("expires_after_days" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1ExpiresAfterDays obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1 where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1 GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "expires_after_days"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1 :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1 {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1ExpiresAfterDays = GHC.Maybe.Nothing}
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.oxxo.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1 PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1 a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Oxxo'OneOf1 Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.p24.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1
{ -- | tos_shown_and_accepted
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1TosShownAndAccepted :: (GHC.Maybe.Maybe GHC.Types.Bool)
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1 where
toJSON obj = Data.Aeson.Types.Internal.object ("tos_shown_and_accepted" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1TosShownAndAccepted obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("tos_shown_and_accepted" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1TosShownAndAccepted obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1 where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1 GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "tos_shown_and_accepted"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1 :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1 {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1TosShownAndAccepted = GHC.Maybe.Nothing}
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.p24.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1 PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1 a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'P24'OneOf1 Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.sepa_debit.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1
{ -- | mandate_options
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1MandateOptions :: (GHC.Maybe.Maybe Data.Aeson.Types.Internal.Object)
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1 where
toJSON obj = Data.Aeson.Types.Internal.object ("mandate_options" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1MandateOptions obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("mandate_options" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1MandateOptions obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1 where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1 GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "mandate_options"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1 :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1 {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1MandateOptions = GHC.Maybe.Nothing}
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.sepa_debit.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1 PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1 a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'SepaDebit'OneOf1 Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.sofort.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1
{ -- | preferred_language
postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage :: (GHC.Maybe.Maybe PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage')
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1 where
toJSON obj = Data.Aeson.Types.Internal.object ("preferred_language" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs ("preferred_language" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage obj)
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1 where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1" (\obj -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1 GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "preferred_language"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1 :: PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1
mkPostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1 {postPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage = GHC.Maybe.Nothing}
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.sofort.anyOf.properties.preferred_language@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @"de"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumDe
| -- | Represents the JSON value @"en"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumEn
| -- | Represents the JSON value @"es"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumEs
| -- | Represents the JSON value @"fr"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumFr
| -- | Represents the JSON value @"it"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumIt
| -- | Represents the JSON value @"nl"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumNl
| -- | Represents the JSON value @"pl"@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumPl
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumDe) = "de"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumEn) = "en"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumEs) = "es"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumFr) = "fr"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumIt) = "it"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumNl) = "nl"
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumPl) = "pl"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "de" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumDe
| val GHC.Classes.== "en" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumEn
| val GHC.Classes.== "es" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumEs
| val GHC.Classes.== "fr" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumFr
| val GHC.Classes.== "it" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumIt
| val GHC.Classes.== "nl" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumNl
| val GHC.Classes.== "pl" -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'EnumPl
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1PreferredLanguage'Other val
)
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.payment_method_options.properties.sofort.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1 PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1 a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'PostPaymentIntentsIntentConfirmRequestBodyPaymentMethodOptions'Sofort'OneOf1 Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.receipt_email.anyOf@ in the specification.
--
-- Email address that the receipt for the resulting payment will be sent to. If \`receipt_email\` is specified for a payment in live mode, a receipt will be sent regardless of your [email settings](https:\/\/dashboard.stripe.com\/account\/emails).
data PostPaymentIntentsIntentConfirmRequestBodyReceiptEmail'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyReceiptEmail'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyReceiptEmail'Text Data.Text.Internal.Text
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyReceiptEmail'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyReceiptEmail'Text a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyReceiptEmail'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyReceiptEmail'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyReceiptEmail'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyReceiptEmail'Text Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Defines the enum schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.setup_future_usage@ in the specification.
--
-- Indicates that you intend to make future payments with this PaymentIntent\'s payment method.
--
-- Providing this parameter will [attach the payment method](https:\/\/stripe.com\/docs\/payments\/save-during-payment) to the PaymentIntent\'s Customer, if present, after the PaymentIntent is confirmed and any required actions from the user are complete. If no Customer was provided, the payment method can still be [attached](https:\/\/stripe.com\/docs\/api\/payment_methods\/attach) to a Customer after the transaction completes.
--
-- When processing card payments, Stripe also uses \`setup_future_usage\` to dynamically optimize your payment flow and comply with regional legislation and network rules, such as [SCA](https:\/\/stripe.com\/docs\/strong-customer-authentication).
--
-- If \`setup_future_usage\` is already set and you are performing a request using a publishable key, you may only update the value from \`on_session\` to \`off_session\`.
data PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'
= -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'Other Data.Aeson.Types.Internal.Value
| -- | This constructor can be used to send values to the server which are not present in the specification yet.
PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'Typed Data.Text.Internal.Text
| -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'EnumEmptyString
| -- | Represents the JSON value @"off_session"@
PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'EnumOffSession
| -- | Represents the JSON value @"on_session"@
PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'EnumOnSession
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage' where
toJSON (PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'Other val) = val
toJSON (PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'Typed val) = Data.Aeson.Types.ToJSON.toJSON val
toJSON (PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'EnumEmptyString) = ""
toJSON (PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'EnumOffSession) = "off_session"
toJSON (PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'EnumOnSession) = "on_session"
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage' where
parseJSON val =
GHC.Base.pure
( if
| val GHC.Classes.== "" -> PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'EnumEmptyString
| val GHC.Classes.== "off_session" -> PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'EnumOffSession
| val GHC.Classes.== "on_session" -> PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'EnumOnSession
| GHC.Base.otherwise -> PostPaymentIntentsIntentConfirmRequestBodySetupFutureUsage'Other val
)
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.shipping.anyOf@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1 = PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1
{ -- | address
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address :: PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address',
-- | carrier
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Carrier :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | name
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Name :: Data.Text.Internal.Text,
-- | phone
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Phone :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | tracking_number
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1TrackingNumber :: (GHC.Maybe.Maybe Data.Text.Internal.Text)
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1 where
toJSON obj = Data.Aeson.Types.Internal.object ("address" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address obj : "carrier" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Carrier obj : "name" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Name obj : "phone" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Phone obj : "tracking_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1TrackingNumber obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("address" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address obj) GHC.Base.<> (("carrier" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Carrier obj) GHC.Base.<> (("name" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Name obj) GHC.Base.<> (("phone" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Phone obj) GHC.Base.<> ("tracking_number" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1TrackingNumber obj)))))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1 where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1" (\obj -> ((((GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1 GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "address")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "carrier")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "name")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "phone")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "tracking_number"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1 ::
-- | 'postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'
PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address' ->
-- | 'postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Name'
Data.Text.Internal.Text ->
PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1
mkPostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1 postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Name =
PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1
{ postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address = postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address,
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Carrier = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Name = postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Name,
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Phone = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1TrackingNumber = GHC.Maybe.Nothing
}
-- | Defines the object schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.shipping.anyOf.properties.address@ in the specification.
data PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address' = PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'
{ -- | city
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'City :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | country
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Country :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | line1
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Line1 :: Data.Text.Internal.Text,
-- | line2
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Line2 :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | postal_code
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'PostalCode :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
-- | state
--
-- Constraints:
--
-- * Maximum length of 5000
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'State :: (GHC.Maybe.Maybe Data.Text.Internal.Text)
}
deriving
( GHC.Show.Show,
GHC.Classes.Eq
)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address' where
toJSON obj = Data.Aeson.Types.Internal.object ("city" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'City obj : "country" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Country obj : "line1" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Line1 obj : "line2" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Line2 obj : "postal_code" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'PostalCode obj : "state" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'State obj : GHC.Base.mempty)
toEncoding obj = Data.Aeson.Encoding.Internal.pairs (("city" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'City obj) GHC.Base.<> (("country" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Country obj) GHC.Base.<> (("line1" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Line1 obj) GHC.Base.<> (("line2" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Line2 obj) GHC.Base.<> (("postal_code" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'PostalCode obj) GHC.Base.<> ("state" Data.Aeson.Types.ToJSON..= postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'State obj))))))
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address' where
parseJSON = Data.Aeson.Types.FromJSON.withObject "PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'" (\obj -> (((((GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address' GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "city")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "country")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..: "line1")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "line2")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "postal_code")) GHC.Base.<*> (obj Data.Aeson.Types.FromJSON..:? "state"))
-- | Create a new 'PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'' with all required fields.
mkPostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address' ::
-- | 'postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Line1'
Data.Text.Internal.Text ->
PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'
mkPostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address' postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Line1 =
PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'
{ postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'City = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Country = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Line1 = postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Line1,
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'Line2 = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'PostalCode = GHC.Maybe.Nothing,
postPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1Address'State = GHC.Maybe.Nothing
}
-- | Defines the oneOf schema located at @paths.\/v1\/payment_intents\/{intent}\/confirm.POST.requestBody.content.application\/x-www-form-urlencoded.schema.properties.shipping.anyOf@ in the specification.
--
-- Shipping information for this PaymentIntent.
data PostPaymentIntentsIntentConfirmRequestBodyShipping'Variants
= -- | Represents the JSON value @""@
PostPaymentIntentsIntentConfirmRequestBodyShipping'EmptyString
| PostPaymentIntentsIntentConfirmRequestBodyShipping'PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1 PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1
deriving (GHC.Show.Show, GHC.Classes.Eq)
instance Data.Aeson.Types.ToJSON.ToJSON PostPaymentIntentsIntentConfirmRequestBodyShipping'Variants where
toJSON (PostPaymentIntentsIntentConfirmRequestBodyShipping'PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1 a) = Data.Aeson.Types.ToJSON.toJSON a
toJSON (PostPaymentIntentsIntentConfirmRequestBodyShipping'EmptyString) = ""
instance Data.Aeson.Types.FromJSON.FromJSON PostPaymentIntentsIntentConfirmRequestBodyShipping'Variants where
parseJSON val =
if
| val GHC.Classes.== "" -> GHC.Base.pure PostPaymentIntentsIntentConfirmRequestBodyShipping'EmptyString
| GHC.Base.otherwise -> case (PostPaymentIntentsIntentConfirmRequestBodyShipping'PostPaymentIntentsIntentConfirmRequestBodyShipping'OneOf1 Data.Functor.<$> Data.Aeson.Types.FromJSON.fromJSON val) GHC.Base.<|> Data.Aeson.Types.Internal.Error "No variant matched" of
Data.Aeson.Types.Internal.Success a -> GHC.Base.pure a
Data.Aeson.Types.Internal.Error a -> Control.Monad.Fail.fail a
-- | Represents a response of the operation 'postPaymentIntentsIntentConfirm'.
--
-- 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), 'PostPaymentIntentsIntentConfirmResponseError' is used.
data PostPaymentIntentsIntentConfirmResponse
= -- | Means either no matching case available or a parse error
PostPaymentIntentsIntentConfirmResponseError GHC.Base.String
| -- | Successful response.
PostPaymentIntentsIntentConfirmResponse200 PaymentIntent
| -- | Error response.
PostPaymentIntentsIntentConfirmResponseDefault Error
deriving (GHC.Show.Show, GHC.Classes.Eq)