{-# LANGUAGE MultiWayIf #-}
-- CHANGE WITH CAUTION: This is a generated code file generated by https://github.com/Haskell-OpenAPI-Code-Generator/Haskell-OpenAPI-Client-Code-Generator.
{-# LANGUAGE OverloadedStrings #-}

-- | Contains the types generated from the schema PaymentIntent
module StripeAPI.Types.PaymentIntent where

import qualified Control.Monad.Fail
import qualified Data.Aeson
import qualified Data.Aeson as Data.Aeson.Encoding.Internal
import qualified Data.Aeson as Data.Aeson.Types
import qualified Data.Aeson as Data.Aeson.Types.FromJSON
import qualified Data.Aeson as Data.Aeson.Types.Internal
import qualified Data.Aeson as Data.Aeson.Types.ToJSON
import qualified Data.ByteString.Char8
import qualified Data.ByteString.Char8 as Data.ByteString.Internal
import qualified Data.Functor
import qualified Data.Scientific
import qualified Data.Text
import qualified Data.Text.Internal
import qualified Data.Time.Calendar as Data.Time.Calendar.Days
import qualified Data.Time.LocalTime as Data.Time.LocalTime.Internal.ZonedTime
import qualified GHC.Base
import qualified GHC.Classes
import qualified GHC.Int
import qualified GHC.Show
import qualified GHC.Types
import qualified StripeAPI.Common
import StripeAPI.TypeAlias
import {-# SOURCE #-} StripeAPI.Types.Account
import {-# SOURCE #-} StripeAPI.Types.Address
import {-# SOURCE #-} StripeAPI.Types.ApiErrors
import {-# SOURCE #-} StripeAPI.Types.Application
import {-# SOURCE #-} StripeAPI.Types.BankAccount
import {-# SOURCE #-} StripeAPI.Types.Card
import {-# SOURCE #-} StripeAPI.Types.Charge
import {-# SOURCE #-} StripeAPI.Types.Customer
import {-# SOURCE #-} StripeAPI.Types.DeletedCustomer
import {-# SOURCE #-} StripeAPI.Types.Invoice
import {-# SOURCE #-} StripeAPI.Types.PaymentIntentNextAction
import {-# SOURCE #-} StripeAPI.Types.PaymentIntentNextActionAlipayHandleRedirect
import {-# SOURCE #-} StripeAPI.Types.PaymentIntentNextActionBoleto
import {-# SOURCE #-} StripeAPI.Types.PaymentIntentNextActionDisplayOxxoDetails
import {-# SOURCE #-} StripeAPI.Types.PaymentIntentNextActionRedirectToUrl
import {-# SOURCE #-} StripeAPI.Types.PaymentIntentNextActionVerifyWithMicrodeposits
import {-# SOURCE #-} StripeAPI.Types.PaymentIntentPaymentMethodOptions
import {-# SOURCE #-} StripeAPI.Types.PaymentIntentPaymentMethodOptionsAcssDebit
import {-# SOURCE #-} StripeAPI.Types.PaymentIntentPaymentMethodOptionsCard
import {-# SOURCE #-} StripeAPI.Types.PaymentIntentPaymentMethodOptionsSepaDebit
import {-# SOURCE #-} StripeAPI.Types.PaymentMethod
import {-# SOURCE #-} StripeAPI.Types.PaymentMethodOptionsAfterpayClearpay
import {-# SOURCE #-} StripeAPI.Types.PaymentMethodOptionsBancontact
import {-# SOURCE #-} StripeAPI.Types.PaymentMethodOptionsBoleto
import {-# SOURCE #-} StripeAPI.Types.PaymentMethodOptionsOxxo
import {-# SOURCE #-} StripeAPI.Types.PaymentMethodOptionsSofort
import {-# SOURCE #-} StripeAPI.Types.Recipient
import {-# SOURCE #-} StripeAPI.Types.Review
import {-# SOURCE #-} StripeAPI.Types.SetupIntent
import {-# SOURCE #-} StripeAPI.Types.Shipping
import {-# SOURCE #-} StripeAPI.Types.Source
import {-# SOURCE #-} StripeAPI.Types.SourceCodeVerificationFlow
import {-# SOURCE #-} StripeAPI.Types.SourceOrder
import {-# SOURCE #-} StripeAPI.Types.SourceOwner
import {-# SOURCE #-} StripeAPI.Types.SourceReceiverFlow
import {-# SOURCE #-} StripeAPI.Types.SourceRedirectFlow
import {-# SOURCE #-} StripeAPI.Types.SourceTypeAchCreditTransfer
import {-# SOURCE #-} StripeAPI.Types.SourceTypeAchDebit
import {-# SOURCE #-} StripeAPI.Types.SourceTypeAcssDebit
import {-# SOURCE #-} StripeAPI.Types.SourceTypeAlipay
import {-# SOURCE #-} StripeAPI.Types.SourceTypeAuBecsDebit
import {-# SOURCE #-} StripeAPI.Types.SourceTypeBancontact
import {-# SOURCE #-} StripeAPI.Types.SourceTypeCard
import {-# SOURCE #-} StripeAPI.Types.SourceTypeCardPresent
import {-# SOURCE #-} StripeAPI.Types.SourceTypeEps
import {-# SOURCE #-} StripeAPI.Types.SourceTypeGiropay
import {-# SOURCE #-} StripeAPI.Types.SourceTypeIdeal
import {-# SOURCE #-} StripeAPI.Types.SourceTypeKlarna
import {-# SOURCE #-} StripeAPI.Types.SourceTypeMultibanco
import {-# SOURCE #-} StripeAPI.Types.SourceTypeP24
import {-# SOURCE #-} StripeAPI.Types.SourceTypeSepaDebit
import {-# SOURCE #-} StripeAPI.Types.SourceTypeSofort
import {-# SOURCE #-} StripeAPI.Types.SourceTypeThreeDSecure
import {-# SOURCE #-} StripeAPI.Types.SourceTypeWechat
import {-# SOURCE #-} StripeAPI.Types.TransferData
import qualified Prelude as GHC.Integer.Type
import qualified Prelude as GHC.Maybe

-- | Defines the object schema located at @components.schemas.payment_intent@ in the specification.
--
-- A PaymentIntent guides you through the process of collecting a payment from your customer.
-- We recommend that you create exactly one PaymentIntent for each order or
-- customer session in your system. You can reference the PaymentIntent later to
-- see the history of payment attempts for a particular session.
--
-- A PaymentIntent transitions through
-- [multiple statuses](https:\/\/stripe.com\/docs\/payments\/intents\#intent-statuses)
-- throughout its lifetime as it interfaces with Stripe.js to perform
-- authentication flows and ultimately creates at most one successful charge.
--
-- Related guide: [Payment Intents API](https:\/\/stripe.com\/docs\/payments\/payment-intents).
data PaymentIntent = PaymentIntent
  { -- | amount: Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https:\/\/stripe.com\/docs\/currencies\#zero-decimal) (e.g., 100 cents to charge \$1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is \$0.50 US or [equivalent in charge currency](https:\/\/stripe.com\/docs\/currencies\#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of \$999,999.99).
    PaymentIntent -> Int
paymentIntentAmount :: GHC.Types.Int,
    -- | amount_capturable: Amount that can be captured from this PaymentIntent.
    PaymentIntent -> Maybe Int
paymentIntentAmountCapturable :: (GHC.Maybe.Maybe GHC.Types.Int),
    -- | amount_received: Amount that was collected by this PaymentIntent.
    PaymentIntent -> Maybe Int
paymentIntentAmountReceived :: (GHC.Maybe.Maybe GHC.Types.Int),
    -- | application: ID of the Connect application that created the PaymentIntent.
    PaymentIntent -> Maybe PaymentIntentApplication'Variants
paymentIntentApplication :: (GHC.Maybe.Maybe PaymentIntentApplication'Variants),
    -- | application_fee_amount: The amount of the application fee (if any) that will be requested to be applied to the payment and transferred to the application owner\'s Stripe account. The amount of the application fee collected will be capped at the total payment amount. For more information, see the PaymentIntents [use case for connected accounts](https:\/\/stripe.com\/docs\/payments\/connected-accounts).
    PaymentIntent -> Maybe Int
paymentIntentApplicationFeeAmount :: (GHC.Maybe.Maybe GHC.Types.Int),
    -- | canceled_at: Populated when \`status\` is \`canceled\`, this is the time at which the PaymentIntent was canceled. Measured in seconds since the Unix epoch.
    PaymentIntent -> Maybe Int
paymentIntentCanceledAt :: (GHC.Maybe.Maybe GHC.Types.Int),
    -- | cancellation_reason: Reason for cancellation of this PaymentIntent, either user-provided (\`duplicate\`, \`fraudulent\`, \`requested_by_customer\`, or \`abandoned\`) or generated by Stripe internally (\`failed_invoice\`, \`void_invoice\`, or \`automatic\`).
    PaymentIntent -> Maybe PaymentIntentCancellationReason'
paymentIntentCancellationReason :: (GHC.Maybe.Maybe PaymentIntentCancellationReason'),
    -- | capture_method: Controls when the funds will be captured from the customer\'s account.
    PaymentIntent -> PaymentIntentCaptureMethod'
paymentIntentCaptureMethod :: PaymentIntentCaptureMethod',
    -- | charges: Charges that were created by this PaymentIntent, if any.
    PaymentIntent -> Maybe PaymentIntentCharges'
paymentIntentCharges :: (GHC.Maybe.Maybe PaymentIntentCharges'),
    -- | client_secret: The client secret of this PaymentIntent. Used for client-side retrieval using a publishable key.
    --
    -- The client secret can be used to complete a payment from your frontend. It should not be stored, logged, embedded in URLs, or exposed to anyone other than the customer. Make sure that you have TLS enabled on any page that includes the client secret.
    --
    -- Refer to our docs to [accept a payment](https:\/\/stripe.com\/docs\/payments\/accept-a-payment?integration=elements) and learn about how \`client_secret\` should be handled.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntent -> Maybe Text
paymentIntentClientSecret :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | confirmation_method
    PaymentIntent -> PaymentIntentConfirmationMethod'
paymentIntentConfirmationMethod :: PaymentIntentConfirmationMethod',
    -- | created: Time at which the object was created. Measured in seconds since the Unix epoch.
    PaymentIntent -> Int
paymentIntentCreated :: GHC.Types.Int,
    -- | currency: Three-letter [ISO currency code](https:\/\/www.iso.org\/iso-4217-currency-codes.html), in lowercase. Must be a [supported currency](https:\/\/stripe.com\/docs\/currencies).
    PaymentIntent -> Text
paymentIntentCurrency :: Data.Text.Internal.Text,
    -- | customer: ID of the Customer this PaymentIntent belongs to, if one exists.
    --
    -- Payment methods attached to other Customers cannot be used with this PaymentIntent.
    --
    -- If present in combination with [setup_future_usage](https:\/\/stripe.com\/docs\/api\#payment_intent_object-setup_future_usage), this PaymentIntent\'s payment method will be attached to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete.
    PaymentIntent -> Maybe PaymentIntentCustomer'Variants
paymentIntentCustomer :: (GHC.Maybe.Maybe PaymentIntentCustomer'Variants),
    -- | description: An arbitrary string attached to the object. Often useful for displaying to users.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntent -> Maybe Text
paymentIntentDescription :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | id: Unique identifier for the object.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntent -> Text
paymentIntentId :: Data.Text.Internal.Text,
    -- | invoice: ID of the invoice that created this PaymentIntent, if it exists.
    PaymentIntent -> Maybe PaymentIntentInvoice'Variants
paymentIntentInvoice :: (GHC.Maybe.Maybe PaymentIntentInvoice'Variants),
    -- | last_payment_error: The payment error encountered in the previous PaymentIntent confirmation. It will be cleared if the PaymentIntent is later updated for any reason.
    PaymentIntent -> Maybe PaymentIntentLastPaymentError'
paymentIntentLastPaymentError :: (GHC.Maybe.Maybe PaymentIntentLastPaymentError'),
    -- | livemode: Has the value \`true\` if the object exists in live mode or the value \`false\` if the object exists in test mode.
    PaymentIntent -> Bool
paymentIntentLivemode :: GHC.Types.Bool,
    -- | metadata: Set of [key-value pairs](https:\/\/stripe.com\/docs\/api\/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format. For more information, see the [documentation](https:\/\/stripe.com\/docs\/payments\/payment-intents\/creating-payment-intents\#storing-information-in-metadata).
    PaymentIntent -> Maybe Object
paymentIntentMetadata :: (GHC.Maybe.Maybe Data.Aeson.Types.Internal.Object),
    -- | next_action: If present, this property tells you what actions you need to take in order for your customer to fulfill a payment using the provided source.
    PaymentIntent -> Maybe PaymentIntentNextAction'
paymentIntentNextAction :: (GHC.Maybe.Maybe PaymentIntentNextAction'),
    -- | on_behalf_of: The account (if any) for which the funds of the PaymentIntent are intended. See the PaymentIntents [use case for connected accounts](https:\/\/stripe.com\/docs\/payments\/connected-accounts) for details.
    PaymentIntent -> Maybe PaymentIntentOnBehalfOf'Variants
paymentIntentOnBehalfOf :: (GHC.Maybe.Maybe PaymentIntentOnBehalfOf'Variants),
    -- | payment_method: ID of the payment method used in this PaymentIntent.
    PaymentIntent -> Maybe PaymentIntentPaymentMethod'Variants
paymentIntentPaymentMethod :: (GHC.Maybe.Maybe PaymentIntentPaymentMethod'Variants),
    -- | payment_method_options: Payment-method-specific configuration for this PaymentIntent.
    PaymentIntent -> Maybe PaymentIntentPaymentMethodOptions'
paymentIntentPaymentMethodOptions :: (GHC.Maybe.Maybe PaymentIntentPaymentMethodOptions'),
    -- | payment_method_types: The list of payment method types (e.g. card) that this PaymentIntent is allowed to use.
    PaymentIntent -> [Text]
paymentIntentPaymentMethodTypes :: ([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).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntent -> Maybe Text
paymentIntentReceiptEmail :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | review: ID of the review associated with this PaymentIntent, if any.
    PaymentIntent -> Maybe PaymentIntentReview'Variants
paymentIntentReview :: (GHC.Maybe.Maybe PaymentIntentReview'Variants),
    -- | 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).
    PaymentIntent -> Maybe PaymentIntentSetupFutureUsage'
paymentIntentSetupFutureUsage :: (GHC.Maybe.Maybe PaymentIntentSetupFutureUsage'),
    -- | shipping: Shipping information for this PaymentIntent.
    PaymentIntent -> Maybe PaymentIntentShipping'
paymentIntentShipping :: (GHC.Maybe.Maybe PaymentIntentShipping'),
    -- | statement_descriptor: For non-card charges, you can use this value as the complete description that appears on your customers’ statements. Must contain at least one letter, maximum 22 characters.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntent -> Maybe Text
paymentIntentStatementDescriptor :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | statement_descriptor_suffix: Provides information about a card payment that customers see on their statements. Concatenated with the prefix (shortened descriptor) or statement descriptor that’s set on the account to form the complete statement descriptor. Maximum 22 characters for the concatenated descriptor.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntent -> Maybe Text
paymentIntentStatementDescriptorSuffix :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | status: Status of this PaymentIntent, one of \`requires_payment_method\`, \`requires_confirmation\`, \`requires_action\`, \`processing\`, \`requires_capture\`, \`canceled\`, or \`succeeded\`. Read more about each PaymentIntent [status](https:\/\/stripe.com\/docs\/payments\/intents\#intent-statuses).
    PaymentIntent -> PaymentIntentStatus'
paymentIntentStatus :: PaymentIntentStatus',
    -- | transfer_data: The data with which to automatically create a Transfer when the payment is finalized. See the PaymentIntents [use case for connected accounts](https:\/\/stripe.com\/docs\/payments\/connected-accounts) for details.
    PaymentIntent -> Maybe PaymentIntentTransferData'
paymentIntentTransferData :: (GHC.Maybe.Maybe PaymentIntentTransferData'),
    -- | transfer_group: A string that identifies the resulting payment as part of a group. See the PaymentIntents [use case for connected accounts](https:\/\/stripe.com\/docs\/payments\/connected-accounts) for details.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntent -> Maybe Text
paymentIntentTransferGroup :: (GHC.Maybe.Maybe Data.Text.Internal.Text)
  }
  deriving
    ( Int -> PaymentIntent -> ShowS
[PaymentIntent] -> ShowS
PaymentIntent -> String
(Int -> PaymentIntent -> ShowS)
-> (PaymentIntent -> String)
-> ([PaymentIntent] -> ShowS)
-> Show PaymentIntent
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntent] -> ShowS
$cshowList :: [PaymentIntent] -> ShowS
show :: PaymentIntent -> String
$cshow :: PaymentIntent -> String
showsPrec :: Int -> PaymentIntent -> ShowS
$cshowsPrec :: Int -> PaymentIntent -> ShowS
GHC.Show.Show,
      PaymentIntent -> PaymentIntent -> Bool
(PaymentIntent -> PaymentIntent -> Bool)
-> (PaymentIntent -> PaymentIntent -> Bool) -> Eq PaymentIntent
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntent -> PaymentIntent -> Bool
$c/= :: PaymentIntent -> PaymentIntent -> Bool
== :: PaymentIntent -> PaymentIntent -> Bool
$c== :: PaymentIntent -> PaymentIntent -> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntent where
  toJSON :: PaymentIntent -> Value
toJSON PaymentIntent
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"amount" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Int
paymentIntentAmount PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"amount_capturable" Text -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Int
paymentIntentAmountCapturable PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"amount_received" Text -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Int
paymentIntentAmountReceived PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"application" Text -> Maybe PaymentIntentApplication'Variants -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentApplication'Variants
paymentIntentApplication PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"application_fee_amount" Text -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Int
paymentIntentApplicationFeeAmount PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"canceled_at" Text -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Int
paymentIntentCanceledAt PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"cancellation_reason" Text -> Maybe PaymentIntentCancellationReason' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentCancellationReason'
paymentIntentCancellationReason PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"capture_method" Text -> PaymentIntentCaptureMethod' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> PaymentIntentCaptureMethod'
paymentIntentCaptureMethod PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"charges" Text -> Maybe PaymentIntentCharges' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentCharges'
paymentIntentCharges PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"client_secret" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Text
paymentIntentClientSecret PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"confirmation_method" Text -> PaymentIntentConfirmationMethod' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> PaymentIntentConfirmationMethod'
paymentIntentConfirmationMethod PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"created" Text -> Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Int
paymentIntentCreated PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"currency" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Text
paymentIntentCurrency PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"customer" Text -> Maybe PaymentIntentCustomer'Variants -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentCustomer'Variants
paymentIntentCustomer PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"description" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Text
paymentIntentDescription PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"id" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Text
paymentIntentId PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"invoice" Text -> Maybe PaymentIntentInvoice'Variants -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentInvoice'Variants
paymentIntentInvoice PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"last_payment_error" Text -> Maybe PaymentIntentLastPaymentError' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentLastPaymentError'
paymentIntentLastPaymentError PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"livemode" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Bool
paymentIntentLivemode PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"metadata" Text -> Maybe Object -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Object
paymentIntentMetadata PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"next_action" Text -> Maybe PaymentIntentNextAction' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentNextAction'
paymentIntentNextAction PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"on_behalf_of" Text -> Maybe PaymentIntentOnBehalfOf'Variants -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentOnBehalfOf'Variants
paymentIntentOnBehalfOf PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"payment_method" Text -> Maybe PaymentIntentPaymentMethod'Variants -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentPaymentMethod'Variants
paymentIntentPaymentMethod PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"payment_method_options" Text -> Maybe PaymentIntentPaymentMethodOptions' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentPaymentMethodOptions'
paymentIntentPaymentMethodOptions PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"payment_method_types" Text -> [Text] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> [Text]
paymentIntentPaymentMethodTypes PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"receipt_email" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Text
paymentIntentReceiptEmail PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"review" Text -> Maybe PaymentIntentReview'Variants -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentReview'Variants
paymentIntentReview PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"setup_future_usage" Text -> Maybe PaymentIntentSetupFutureUsage' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentSetupFutureUsage'
paymentIntentSetupFutureUsage PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"shipping" Text -> Maybe PaymentIntentShipping' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentShipping'
paymentIntentShipping PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"statement_descriptor" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Text
paymentIntentStatementDescriptor PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"statement_descriptor_suffix" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Text
paymentIntentStatementDescriptorSuffix PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"status" Text -> PaymentIntentStatus' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> PaymentIntentStatus'
paymentIntentStatus PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"transfer_data" Text -> Maybe PaymentIntentTransferData' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentTransferData'
paymentIntentTransferData PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"transfer_group" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Text
paymentIntentTransferGroup PaymentIntent
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"object" Text -> Value -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Text -> Value
Data.Aeson.Types.Internal.String Text
"payment_intent" Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: PaymentIntent -> Encoding
toEncoding PaymentIntent
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"amount" Text -> Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Int
paymentIntentAmount PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"amount_capturable" Text -> Maybe Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Int
paymentIntentAmountCapturable PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"amount_received" Text -> Maybe Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Int
paymentIntentAmountReceived PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"application" Text -> Maybe PaymentIntentApplication'Variants -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentApplication'Variants
paymentIntentApplication PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"application_fee_amount" Text -> Maybe Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Int
paymentIntentApplicationFeeAmount PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"canceled_at" Text -> Maybe Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Int
paymentIntentCanceledAt PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"cancellation_reason" Text -> Maybe PaymentIntentCancellationReason' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentCancellationReason'
paymentIntentCancellationReason PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"capture_method" Text -> PaymentIntentCaptureMethod' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> PaymentIntentCaptureMethod'
paymentIntentCaptureMethod PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"charges" Text -> Maybe PaymentIntentCharges' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentCharges'
paymentIntentCharges PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"client_secret" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Text
paymentIntentClientSecret PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"confirmation_method" Text -> PaymentIntentConfirmationMethod' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> PaymentIntentConfirmationMethod'
paymentIntentConfirmationMethod PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"created" Text -> Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Int
paymentIntentCreated PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"currency" Text -> Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Text
paymentIntentCurrency PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"customer" Text -> Maybe PaymentIntentCustomer'Variants -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentCustomer'Variants
paymentIntentCustomer PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"description" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Text
paymentIntentDescription PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"id" Text -> Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Text
paymentIntentId PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"invoice" Text -> Maybe PaymentIntentInvoice'Variants -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentInvoice'Variants
paymentIntentInvoice PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"last_payment_error" Text -> Maybe PaymentIntentLastPaymentError' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentLastPaymentError'
paymentIntentLastPaymentError PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"livemode" Text -> Bool -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Bool
paymentIntentLivemode PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"metadata" Text -> Maybe Object -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Object
paymentIntentMetadata PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"next_action" Text -> Maybe PaymentIntentNextAction' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentNextAction'
paymentIntentNextAction PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"on_behalf_of" Text -> Maybe PaymentIntentOnBehalfOf'Variants -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentOnBehalfOf'Variants
paymentIntentOnBehalfOf PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"payment_method" Text -> Maybe PaymentIntentPaymentMethod'Variants -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentPaymentMethod'Variants
paymentIntentPaymentMethod PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"payment_method_options" Text -> Maybe PaymentIntentPaymentMethodOptions' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentPaymentMethodOptions'
paymentIntentPaymentMethodOptions PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"payment_method_types" Text -> [Text] -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> [Text]
paymentIntentPaymentMethodTypes PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"receipt_email" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Text
paymentIntentReceiptEmail PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"review" Text -> Maybe PaymentIntentReview'Variants -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentReview'Variants
paymentIntentReview PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"setup_future_usage" Text -> Maybe PaymentIntentSetupFutureUsage' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentSetupFutureUsage'
paymentIntentSetupFutureUsage PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"shipping" Text -> Maybe PaymentIntentShipping' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentShipping'
paymentIntentShipping PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"statement_descriptor" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Text
paymentIntentStatementDescriptor PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"statement_descriptor_suffix" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Text
paymentIntentStatementDescriptorSuffix PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"status" Text -> PaymentIntentStatus' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> PaymentIntentStatus'
paymentIntentStatus PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"transfer_data" Text -> Maybe PaymentIntentTransferData' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe PaymentIntentTransferData'
paymentIntentTransferData PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"transfer_group" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntent -> Maybe Text
paymentIntentTransferGroup PaymentIntent
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"object" Text -> Value -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Text -> Value
Data.Aeson.Types.Internal.String Text
"payment_intent")))))))))))))))))))))))))))))))))))

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntent where
  parseJSON :: Value -> Parser PaymentIntent
parseJSON = String
-> (Object -> Parser PaymentIntent)
-> Value
-> Parser PaymentIntent
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"PaymentIntent" (\Object
obj -> ((((((((((((((((((((((((((((((((((Int
 -> Maybe Int
 -> Maybe Int
 -> Maybe PaymentIntentApplication'Variants
 -> Maybe Int
 -> Maybe Int
 -> Maybe PaymentIntentCancellationReason'
 -> PaymentIntentCaptureMethod'
 -> Maybe PaymentIntentCharges'
 -> Maybe Text
 -> PaymentIntentConfirmationMethod'
 -> Int
 -> Text
 -> Maybe PaymentIntentCustomer'Variants
 -> Maybe Text
 -> Text
 -> Maybe PaymentIntentInvoice'Variants
 -> Maybe PaymentIntentLastPaymentError'
 -> Bool
 -> Maybe Object
 -> Maybe PaymentIntentNextAction'
 -> Maybe PaymentIntentOnBehalfOf'Variants
 -> Maybe PaymentIntentPaymentMethod'Variants
 -> Maybe PaymentIntentPaymentMethodOptions'
 -> [Text]
 -> Maybe Text
 -> Maybe PaymentIntentReview'Variants
 -> Maybe PaymentIntentSetupFutureUsage'
 -> Maybe PaymentIntentShipping'
 -> Maybe Text
 -> Maybe Text
 -> PaymentIntentStatus'
 -> Maybe PaymentIntentTransferData'
 -> Maybe Text
 -> PaymentIntent)
-> Parser
     (Int
      -> Maybe Int
      -> Maybe Int
      -> Maybe PaymentIntentApplication'Variants
      -> Maybe Int
      -> Maybe Int
      -> Maybe PaymentIntentCancellationReason'
      -> PaymentIntentCaptureMethod'
      -> Maybe PaymentIntentCharges'
      -> Maybe Text
      -> PaymentIntentConfirmationMethod'
      -> Int
      -> Text
      -> Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure Int
-> Maybe Int
-> Maybe Int
-> Maybe PaymentIntentApplication'Variants
-> Maybe Int
-> Maybe Int
-> Maybe PaymentIntentCancellationReason'
-> PaymentIntentCaptureMethod'
-> Maybe PaymentIntentCharges'
-> Maybe Text
-> PaymentIntentConfirmationMethod'
-> Int
-> Text
-> Maybe PaymentIntentCustomer'Variants
-> Maybe Text
-> Text
-> Maybe PaymentIntentInvoice'Variants
-> Maybe PaymentIntentLastPaymentError'
-> Bool
-> Maybe Object
-> Maybe PaymentIntentNextAction'
-> Maybe PaymentIntentOnBehalfOf'Variants
-> Maybe PaymentIntentPaymentMethod'Variants
-> Maybe PaymentIntentPaymentMethodOptions'
-> [Text]
-> Maybe Text
-> Maybe PaymentIntentReview'Variants
-> Maybe PaymentIntentSetupFutureUsage'
-> Maybe PaymentIntentShipping'
-> Maybe Text
-> Maybe Text
-> PaymentIntentStatus'
-> Maybe PaymentIntentTransferData'
-> Maybe Text
-> PaymentIntent
PaymentIntent Parser
  (Int
   -> Maybe Int
   -> Maybe Int
   -> Maybe PaymentIntentApplication'Variants
   -> Maybe Int
   -> Maybe Int
   -> Maybe PaymentIntentCancellationReason'
   -> PaymentIntentCaptureMethod'
   -> Maybe PaymentIntentCharges'
   -> Maybe Text
   -> PaymentIntentConfirmationMethod'
   -> Int
   -> Text
   -> Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser Int
-> Parser
     (Maybe Int
      -> Maybe Int
      -> Maybe PaymentIntentApplication'Variants
      -> Maybe Int
      -> Maybe Int
      -> Maybe PaymentIntentCancellationReason'
      -> PaymentIntentCaptureMethod'
      -> Maybe PaymentIntentCharges'
      -> Maybe Text
      -> PaymentIntentConfirmationMethod'
      -> Int
      -> Text
      -> Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Int
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"amount")) Parser
  (Maybe Int
   -> Maybe Int
   -> Maybe PaymentIntentApplication'Variants
   -> Maybe Int
   -> Maybe Int
   -> Maybe PaymentIntentCancellationReason'
   -> PaymentIntentCaptureMethod'
   -> Maybe PaymentIntentCharges'
   -> Maybe Text
   -> PaymentIntentConfirmationMethod'
   -> Int
   -> Text
   -> Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe Int)
-> Parser
     (Maybe Int
      -> Maybe PaymentIntentApplication'Variants
      -> Maybe Int
      -> Maybe Int
      -> Maybe PaymentIntentCancellationReason'
      -> PaymentIntentCaptureMethod'
      -> Maybe PaymentIntentCharges'
      -> Maybe Text
      -> PaymentIntentConfirmationMethod'
      -> Int
      -> Text
      -> Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"amount_capturable")) Parser
  (Maybe Int
   -> Maybe PaymentIntentApplication'Variants
   -> Maybe Int
   -> Maybe Int
   -> Maybe PaymentIntentCancellationReason'
   -> PaymentIntentCaptureMethod'
   -> Maybe PaymentIntentCharges'
   -> Maybe Text
   -> PaymentIntentConfirmationMethod'
   -> Int
   -> Text
   -> Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe Int)
-> Parser
     (Maybe PaymentIntentApplication'Variants
      -> Maybe Int
      -> Maybe Int
      -> Maybe PaymentIntentCancellationReason'
      -> PaymentIntentCaptureMethod'
      -> Maybe PaymentIntentCharges'
      -> Maybe Text
      -> PaymentIntentConfirmationMethod'
      -> Int
      -> Text
      -> Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"amount_received")) Parser
  (Maybe PaymentIntentApplication'Variants
   -> Maybe Int
   -> Maybe Int
   -> Maybe PaymentIntentCancellationReason'
   -> PaymentIntentCaptureMethod'
   -> Maybe PaymentIntentCharges'
   -> Maybe Text
   -> PaymentIntentConfirmationMethod'
   -> Int
   -> Text
   -> Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe PaymentIntentApplication'Variants)
-> Parser
     (Maybe Int
      -> Maybe Int
      -> Maybe PaymentIntentCancellationReason'
      -> PaymentIntentCaptureMethod'
      -> Maybe PaymentIntentCharges'
      -> Maybe Text
      -> PaymentIntentConfirmationMethod'
      -> Int
      -> Text
      -> Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentApplication'Variants)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"application")) Parser
  (Maybe Int
   -> Maybe Int
   -> Maybe PaymentIntentCancellationReason'
   -> PaymentIntentCaptureMethod'
   -> Maybe PaymentIntentCharges'
   -> Maybe Text
   -> PaymentIntentConfirmationMethod'
   -> Int
   -> Text
   -> Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe Int)
-> Parser
     (Maybe Int
      -> Maybe PaymentIntentCancellationReason'
      -> PaymentIntentCaptureMethod'
      -> Maybe PaymentIntentCharges'
      -> Maybe Text
      -> PaymentIntentConfirmationMethod'
      -> Int
      -> Text
      -> Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"application_fee_amount")) Parser
  (Maybe Int
   -> Maybe PaymentIntentCancellationReason'
   -> PaymentIntentCaptureMethod'
   -> Maybe PaymentIntentCharges'
   -> Maybe Text
   -> PaymentIntentConfirmationMethod'
   -> Int
   -> Text
   -> Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe Int)
-> Parser
     (Maybe PaymentIntentCancellationReason'
      -> PaymentIntentCaptureMethod'
      -> Maybe PaymentIntentCharges'
      -> Maybe Text
      -> PaymentIntentConfirmationMethod'
      -> Int
      -> Text
      -> Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"canceled_at")) Parser
  (Maybe PaymentIntentCancellationReason'
   -> PaymentIntentCaptureMethod'
   -> Maybe PaymentIntentCharges'
   -> Maybe Text
   -> PaymentIntentConfirmationMethod'
   -> Int
   -> Text
   -> Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe PaymentIntentCancellationReason')
-> Parser
     (PaymentIntentCaptureMethod'
      -> Maybe PaymentIntentCharges'
      -> Maybe Text
      -> PaymentIntentConfirmationMethod'
      -> Int
      -> Text
      -> Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentCancellationReason')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"cancellation_reason")) Parser
  (PaymentIntentCaptureMethod'
   -> Maybe PaymentIntentCharges'
   -> Maybe Text
   -> PaymentIntentConfirmationMethod'
   -> Int
   -> Text
   -> Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser PaymentIntentCaptureMethod'
-> Parser
     (Maybe PaymentIntentCharges'
      -> Maybe Text
      -> PaymentIntentConfirmationMethod'
      -> Int
      -> Text
      -> Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser PaymentIntentCaptureMethod'
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"capture_method")) Parser
  (Maybe PaymentIntentCharges'
   -> Maybe Text
   -> PaymentIntentConfirmationMethod'
   -> Int
   -> Text
   -> Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe PaymentIntentCharges')
-> Parser
     (Maybe Text
      -> PaymentIntentConfirmationMethod'
      -> Int
      -> Text
      -> Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentCharges')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"charges")) Parser
  (Maybe Text
   -> PaymentIntentConfirmationMethod'
   -> Int
   -> Text
   -> Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe Text)
-> Parser
     (PaymentIntentConfirmationMethod'
      -> Int
      -> Text
      -> Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"client_secret")) Parser
  (PaymentIntentConfirmationMethod'
   -> Int
   -> Text
   -> Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser PaymentIntentConfirmationMethod'
-> Parser
     (Int
      -> Text
      -> Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser PaymentIntentConfirmationMethod'
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"confirmation_method")) Parser
  (Int
   -> Text
   -> Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser Int
-> Parser
     (Text
      -> Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Int
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"created")) Parser
  (Text
   -> Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser Text
-> Parser
     (Maybe PaymentIntentCustomer'Variants
      -> Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"currency")) Parser
  (Maybe PaymentIntentCustomer'Variants
   -> Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe PaymentIntentCustomer'Variants)
-> Parser
     (Maybe Text
      -> Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentCustomer'Variants)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"customer")) Parser
  (Maybe Text
   -> Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe Text)
-> Parser
     (Text
      -> Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"description")) Parser
  (Text
   -> Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser Text
-> Parser
     (Maybe PaymentIntentInvoice'Variants
      -> Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"id")) Parser
  (Maybe PaymentIntentInvoice'Variants
   -> Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe PaymentIntentInvoice'Variants)
-> Parser
     (Maybe PaymentIntentLastPaymentError'
      -> Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentInvoice'Variants)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"invoice")) Parser
  (Maybe PaymentIntentLastPaymentError'
   -> Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe PaymentIntentLastPaymentError')
-> Parser
     (Bool
      -> Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentLastPaymentError')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"last_payment_error")) Parser
  (Bool
   -> Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser Bool
-> Parser
     (Maybe Object
      -> Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Bool
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"livemode")) Parser
  (Maybe Object
   -> Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe Object)
-> Parser
     (Maybe PaymentIntentNextAction'
      -> Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Object)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"metadata")) Parser
  (Maybe PaymentIntentNextAction'
   -> Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe PaymentIntentNextAction')
-> Parser
     (Maybe PaymentIntentOnBehalfOf'Variants
      -> Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentNextAction')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"next_action")) Parser
  (Maybe PaymentIntentOnBehalfOf'Variants
   -> Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe PaymentIntentOnBehalfOf'Variants)
-> Parser
     (Maybe PaymentIntentPaymentMethod'Variants
      -> Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentOnBehalfOf'Variants)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"on_behalf_of")) Parser
  (Maybe PaymentIntentPaymentMethod'Variants
   -> Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe PaymentIntentPaymentMethod'Variants)
-> Parser
     (Maybe PaymentIntentPaymentMethodOptions'
      -> [Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text -> Parser (Maybe PaymentIntentPaymentMethod'Variants)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"payment_method")) Parser
  (Maybe PaymentIntentPaymentMethodOptions'
   -> [Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe PaymentIntentPaymentMethodOptions')
-> Parser
     ([Text]
      -> Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentPaymentMethodOptions')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"payment_method_options")) Parser
  ([Text]
   -> Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser [Text]
-> Parser
     (Maybe Text
      -> Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser [Text]
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"payment_method_types")) Parser
  (Maybe Text
   -> Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe Text)
-> Parser
     (Maybe PaymentIntentReview'Variants
      -> Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"receipt_email")) Parser
  (Maybe PaymentIntentReview'Variants
   -> Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe PaymentIntentReview'Variants)
-> Parser
     (Maybe PaymentIntentSetupFutureUsage'
      -> Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentReview'Variants)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"review")) Parser
  (Maybe PaymentIntentSetupFutureUsage'
   -> Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe PaymentIntentSetupFutureUsage')
-> Parser
     (Maybe PaymentIntentShipping'
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentSetupFutureUsage')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"setup_future_usage")) Parser
  (Maybe PaymentIntentShipping'
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe PaymentIntentShipping')
-> Parser
     (Maybe Text
      -> Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentShipping')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"shipping")) Parser
  (Maybe Text
   -> Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData'
      -> Maybe Text
      -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"statement_descriptor")) Parser
  (Maybe Text
   -> PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData'
   -> Maybe Text
   -> PaymentIntent)
-> Parser (Maybe Text)
-> Parser
     (PaymentIntentStatus'
      -> Maybe PaymentIntentTransferData' -> Maybe Text -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"statement_descriptor_suffix")) Parser
  (PaymentIntentStatus'
   -> Maybe PaymentIntentTransferData' -> Maybe Text -> PaymentIntent)
-> Parser PaymentIntentStatus'
-> Parser
     (Maybe PaymentIntentTransferData' -> Maybe Text -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser PaymentIntentStatus'
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"status")) Parser
  (Maybe PaymentIntentTransferData' -> Maybe Text -> PaymentIntent)
-> Parser (Maybe PaymentIntentTransferData')
-> Parser (Maybe Text -> PaymentIntent)
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentTransferData')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"transfer_data")) Parser (Maybe Text -> PaymentIntent)
-> Parser (Maybe Text) -> Parser PaymentIntent
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"transfer_group"))

-- | Create a new 'PaymentIntent' with all required fields.
mkPaymentIntent ::
  -- | 'paymentIntentAmount'
  GHC.Types.Int ->
  -- | 'paymentIntentCaptureMethod'
  PaymentIntentCaptureMethod' ->
  -- | 'paymentIntentConfirmationMethod'
  PaymentIntentConfirmationMethod' ->
  -- | 'paymentIntentCreated'
  GHC.Types.Int ->
  -- | 'paymentIntentCurrency'
  Data.Text.Internal.Text ->
  -- | 'paymentIntentId'
  Data.Text.Internal.Text ->
  -- | 'paymentIntentLivemode'
  GHC.Types.Bool ->
  -- | 'paymentIntentPaymentMethodTypes'
  [Data.Text.Internal.Text] ->
  -- | 'paymentIntentStatus'
  PaymentIntentStatus' ->
  PaymentIntent
mkPaymentIntent :: Int
-> PaymentIntentCaptureMethod'
-> PaymentIntentConfirmationMethod'
-> Int
-> Text
-> Text
-> Bool
-> [Text]
-> PaymentIntentStatus'
-> PaymentIntent
mkPaymentIntent Int
paymentIntentAmount PaymentIntentCaptureMethod'
paymentIntentCaptureMethod PaymentIntentConfirmationMethod'
paymentIntentConfirmationMethod Int
paymentIntentCreated Text
paymentIntentCurrency Text
paymentIntentId Bool
paymentIntentLivemode [Text]
paymentIntentPaymentMethodTypes PaymentIntentStatus'
paymentIntentStatus =
  PaymentIntent :: Int
-> Maybe Int
-> Maybe Int
-> Maybe PaymentIntentApplication'Variants
-> Maybe Int
-> Maybe Int
-> Maybe PaymentIntentCancellationReason'
-> PaymentIntentCaptureMethod'
-> Maybe PaymentIntentCharges'
-> Maybe Text
-> PaymentIntentConfirmationMethod'
-> Int
-> Text
-> Maybe PaymentIntentCustomer'Variants
-> Maybe Text
-> Text
-> Maybe PaymentIntentInvoice'Variants
-> Maybe PaymentIntentLastPaymentError'
-> Bool
-> Maybe Object
-> Maybe PaymentIntentNextAction'
-> Maybe PaymentIntentOnBehalfOf'Variants
-> Maybe PaymentIntentPaymentMethod'Variants
-> Maybe PaymentIntentPaymentMethodOptions'
-> [Text]
-> Maybe Text
-> Maybe PaymentIntentReview'Variants
-> Maybe PaymentIntentSetupFutureUsage'
-> Maybe PaymentIntentShipping'
-> Maybe Text
-> Maybe Text
-> PaymentIntentStatus'
-> Maybe PaymentIntentTransferData'
-> Maybe Text
-> PaymentIntent
PaymentIntent
    { paymentIntentAmount :: Int
paymentIntentAmount = Int
paymentIntentAmount,
      paymentIntentAmountCapturable :: Maybe Int
paymentIntentAmountCapturable = Maybe Int
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentAmountReceived :: Maybe Int
paymentIntentAmountReceived = Maybe Int
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentApplication :: Maybe PaymentIntentApplication'Variants
paymentIntentApplication = Maybe PaymentIntentApplication'Variants
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentApplicationFeeAmount :: Maybe Int
paymentIntentApplicationFeeAmount = Maybe Int
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentCanceledAt :: Maybe Int
paymentIntentCanceledAt = Maybe Int
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentCancellationReason :: Maybe PaymentIntentCancellationReason'
paymentIntentCancellationReason = Maybe PaymentIntentCancellationReason'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentCaptureMethod :: PaymentIntentCaptureMethod'
paymentIntentCaptureMethod = PaymentIntentCaptureMethod'
paymentIntentCaptureMethod,
      paymentIntentCharges :: Maybe PaymentIntentCharges'
paymentIntentCharges = Maybe PaymentIntentCharges'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentClientSecret :: Maybe Text
paymentIntentClientSecret = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentConfirmationMethod :: PaymentIntentConfirmationMethod'
paymentIntentConfirmationMethod = PaymentIntentConfirmationMethod'
paymentIntentConfirmationMethod,
      paymentIntentCreated :: Int
paymentIntentCreated = Int
paymentIntentCreated,
      paymentIntentCurrency :: Text
paymentIntentCurrency = Text
paymentIntentCurrency,
      paymentIntentCustomer :: Maybe PaymentIntentCustomer'Variants
paymentIntentCustomer = Maybe PaymentIntentCustomer'Variants
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentDescription :: Maybe Text
paymentIntentDescription = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentId :: Text
paymentIntentId = Text
paymentIntentId,
      paymentIntentInvoice :: Maybe PaymentIntentInvoice'Variants
paymentIntentInvoice = Maybe PaymentIntentInvoice'Variants
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError :: Maybe PaymentIntentLastPaymentError'
paymentIntentLastPaymentError = Maybe PaymentIntentLastPaymentError'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLivemode :: Bool
paymentIntentLivemode = Bool
paymentIntentLivemode,
      paymentIntentMetadata :: Maybe Object
paymentIntentMetadata = Maybe Object
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentNextAction :: Maybe PaymentIntentNextAction'
paymentIntentNextAction = Maybe PaymentIntentNextAction'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentOnBehalfOf :: Maybe PaymentIntentOnBehalfOf'Variants
paymentIntentOnBehalfOf = Maybe PaymentIntentOnBehalfOf'Variants
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentPaymentMethod :: Maybe PaymentIntentPaymentMethod'Variants
paymentIntentPaymentMethod = Maybe PaymentIntentPaymentMethod'Variants
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentPaymentMethodOptions :: Maybe PaymentIntentPaymentMethodOptions'
paymentIntentPaymentMethodOptions = Maybe PaymentIntentPaymentMethodOptions'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentPaymentMethodTypes :: [Text]
paymentIntentPaymentMethodTypes = [Text]
paymentIntentPaymentMethodTypes,
      paymentIntentReceiptEmail :: Maybe Text
paymentIntentReceiptEmail = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentReview :: Maybe PaymentIntentReview'Variants
paymentIntentReview = Maybe PaymentIntentReview'Variants
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentSetupFutureUsage :: Maybe PaymentIntentSetupFutureUsage'
paymentIntentSetupFutureUsage = Maybe PaymentIntentSetupFutureUsage'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentShipping :: Maybe PaymentIntentShipping'
paymentIntentShipping = Maybe PaymentIntentShipping'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentStatementDescriptor :: Maybe Text
paymentIntentStatementDescriptor = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentStatementDescriptorSuffix :: Maybe Text
paymentIntentStatementDescriptorSuffix = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentStatus :: PaymentIntentStatus'
paymentIntentStatus = PaymentIntentStatus'
paymentIntentStatus,
      paymentIntentTransferData :: Maybe PaymentIntentTransferData'
paymentIntentTransferData = Maybe PaymentIntentTransferData'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentTransferGroup :: Maybe Text
paymentIntentTransferGroup = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing
    }

-- | Defines the oneOf schema located at @components.schemas.payment_intent.properties.application.anyOf@ in the specification.
--
-- ID of the Connect application that created the PaymentIntent.
data PaymentIntentApplication'Variants
  = PaymentIntentApplication'Text Data.Text.Internal.Text
  | PaymentIntentApplication'Application Application
  deriving (Int -> PaymentIntentApplication'Variants -> ShowS
[PaymentIntentApplication'Variants] -> ShowS
PaymentIntentApplication'Variants -> String
(Int -> PaymentIntentApplication'Variants -> ShowS)
-> (PaymentIntentApplication'Variants -> String)
-> ([PaymentIntentApplication'Variants] -> ShowS)
-> Show PaymentIntentApplication'Variants
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentApplication'Variants] -> ShowS
$cshowList :: [PaymentIntentApplication'Variants] -> ShowS
show :: PaymentIntentApplication'Variants -> String
$cshow :: PaymentIntentApplication'Variants -> String
showsPrec :: Int -> PaymentIntentApplication'Variants -> ShowS
$cshowsPrec :: Int -> PaymentIntentApplication'Variants -> ShowS
GHC.Show.Show, PaymentIntentApplication'Variants
-> PaymentIntentApplication'Variants -> Bool
(PaymentIntentApplication'Variants
 -> PaymentIntentApplication'Variants -> Bool)
-> (PaymentIntentApplication'Variants
    -> PaymentIntentApplication'Variants -> Bool)
-> Eq PaymentIntentApplication'Variants
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentApplication'Variants
-> PaymentIntentApplication'Variants -> Bool
$c/= :: PaymentIntentApplication'Variants
-> PaymentIntentApplication'Variants -> Bool
== :: PaymentIntentApplication'Variants
-> PaymentIntentApplication'Variants -> Bool
$c== :: PaymentIntentApplication'Variants
-> PaymentIntentApplication'Variants -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentApplication'Variants where
  toJSON :: PaymentIntentApplication'Variants -> Value
toJSON (PaymentIntentApplication'Text Text
a) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
a
  toJSON (PaymentIntentApplication'Application Application
a) = Application -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Application
a

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentApplication'Variants where
  parseJSON :: Value -> Parser PaymentIntentApplication'Variants
parseJSON Value
val = case (Text -> PaymentIntentApplication'Variants
PaymentIntentApplication'Text (Text -> PaymentIntentApplication'Variants)
-> Result Text -> Result PaymentIntentApplication'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Text
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentApplication'Variants
-> Result PaymentIntentApplication'Variants
-> Result PaymentIntentApplication'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> ((Application -> PaymentIntentApplication'Variants
PaymentIntentApplication'Application (Application -> PaymentIntentApplication'Variants)
-> Result Application -> Result PaymentIntentApplication'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Application
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentApplication'Variants
-> Result PaymentIntentApplication'Variants
-> Result PaymentIntentApplication'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> String -> Result PaymentIntentApplication'Variants
forall a. String -> Result a
Data.Aeson.Types.Internal.Error String
"No variant matched") of
    Data.Aeson.Types.Internal.Success PaymentIntentApplication'Variants
a -> PaymentIntentApplication'Variants
-> Parser PaymentIntentApplication'Variants
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure PaymentIntentApplication'Variants
a
    Data.Aeson.Types.Internal.Error String
a -> String -> Parser PaymentIntentApplication'Variants
forall (m :: * -> *) a. MonadFail m => String -> m a
Control.Monad.Fail.fail String
a

-- | Defines the enum schema located at @components.schemas.payment_intent.properties.cancellation_reason@ in the specification.
--
-- Reason for cancellation of this PaymentIntent, either user-provided (\`duplicate\`, \`fraudulent\`, \`requested_by_customer\`, or \`abandoned\`) or generated by Stripe internally (\`failed_invoice\`, \`void_invoice\`, or \`automatic\`).
data PaymentIntentCancellationReason'
  = -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
    PaymentIntentCancellationReason'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.
    PaymentIntentCancellationReason'Typed Data.Text.Internal.Text
  | -- | Represents the JSON value @"abandoned"@
    PaymentIntentCancellationReason'EnumAbandoned
  | -- | Represents the JSON value @"automatic"@
    PaymentIntentCancellationReason'EnumAutomatic
  | -- | Represents the JSON value @"duplicate"@
    PaymentIntentCancellationReason'EnumDuplicate
  | -- | Represents the JSON value @"failed_invoice"@
    PaymentIntentCancellationReason'EnumFailedInvoice
  | -- | Represents the JSON value @"fraudulent"@
    PaymentIntentCancellationReason'EnumFraudulent
  | -- | Represents the JSON value @"requested_by_customer"@
    PaymentIntentCancellationReason'EnumRequestedByCustomer
  | -- | Represents the JSON value @"void_invoice"@
    PaymentIntentCancellationReason'EnumVoidInvoice
  deriving (Int -> PaymentIntentCancellationReason' -> ShowS
[PaymentIntentCancellationReason'] -> ShowS
PaymentIntentCancellationReason' -> String
(Int -> PaymentIntentCancellationReason' -> ShowS)
-> (PaymentIntentCancellationReason' -> String)
-> ([PaymentIntentCancellationReason'] -> ShowS)
-> Show PaymentIntentCancellationReason'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentCancellationReason'] -> ShowS
$cshowList :: [PaymentIntentCancellationReason'] -> ShowS
show :: PaymentIntentCancellationReason' -> String
$cshow :: PaymentIntentCancellationReason' -> String
showsPrec :: Int -> PaymentIntentCancellationReason' -> ShowS
$cshowsPrec :: Int -> PaymentIntentCancellationReason' -> ShowS
GHC.Show.Show, PaymentIntentCancellationReason'
-> PaymentIntentCancellationReason' -> Bool
(PaymentIntentCancellationReason'
 -> PaymentIntentCancellationReason' -> Bool)
-> (PaymentIntentCancellationReason'
    -> PaymentIntentCancellationReason' -> Bool)
-> Eq PaymentIntentCancellationReason'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentCancellationReason'
-> PaymentIntentCancellationReason' -> Bool
$c/= :: PaymentIntentCancellationReason'
-> PaymentIntentCancellationReason' -> Bool
== :: PaymentIntentCancellationReason'
-> PaymentIntentCancellationReason' -> Bool
$c== :: PaymentIntentCancellationReason'
-> PaymentIntentCancellationReason' -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentCancellationReason' where
  toJSON :: PaymentIntentCancellationReason' -> Value
toJSON (PaymentIntentCancellationReason'Other Value
val) = Value
val
  toJSON (PaymentIntentCancellationReason'Typed Text
val) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
val
  toJSON (PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumAbandoned) = Value
"abandoned"
  toJSON (PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumAutomatic) = Value
"automatic"
  toJSON (PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumDuplicate) = Value
"duplicate"
  toJSON (PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumFailedInvoice) = Value
"failed_invoice"
  toJSON (PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumFraudulent) = Value
"fraudulent"
  toJSON (PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumRequestedByCustomer) = Value
"requested_by_customer"
  toJSON (PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumVoidInvoice) = Value
"void_invoice"

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentCancellationReason' where
  parseJSON :: Value -> Parser PaymentIntentCancellationReason'
parseJSON Value
val =
    PaymentIntentCancellationReason'
-> Parser PaymentIntentCancellationReason'
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure
      ( if
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"abandoned" -> PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumAbandoned
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"automatic" -> PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumAutomatic
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"duplicate" -> PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumDuplicate
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"failed_invoice" -> PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumFailedInvoice
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"fraudulent" -> PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumFraudulent
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"requested_by_customer" -> PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumRequestedByCustomer
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"void_invoice" -> PaymentIntentCancellationReason'
PaymentIntentCancellationReason'EnumVoidInvoice
            | Bool
GHC.Base.otherwise -> Value -> PaymentIntentCancellationReason'
PaymentIntentCancellationReason'Other Value
val
      )

-- | Defines the enum schema located at @components.schemas.payment_intent.properties.capture_method@ in the specification.
--
-- Controls when the funds will be captured from the customer\'s account.
data PaymentIntentCaptureMethod'
  = -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
    PaymentIntentCaptureMethod'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.
    PaymentIntentCaptureMethod'Typed Data.Text.Internal.Text
  | -- | Represents the JSON value @"automatic"@
    PaymentIntentCaptureMethod'EnumAutomatic
  | -- | Represents the JSON value @"manual"@
    PaymentIntentCaptureMethod'EnumManual
  deriving (Int -> PaymentIntentCaptureMethod' -> ShowS
[PaymentIntentCaptureMethod'] -> ShowS
PaymentIntentCaptureMethod' -> String
(Int -> PaymentIntentCaptureMethod' -> ShowS)
-> (PaymentIntentCaptureMethod' -> String)
-> ([PaymentIntentCaptureMethod'] -> ShowS)
-> Show PaymentIntentCaptureMethod'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentCaptureMethod'] -> ShowS
$cshowList :: [PaymentIntentCaptureMethod'] -> ShowS
show :: PaymentIntentCaptureMethod' -> String
$cshow :: PaymentIntentCaptureMethod' -> String
showsPrec :: Int -> PaymentIntentCaptureMethod' -> ShowS
$cshowsPrec :: Int -> PaymentIntentCaptureMethod' -> ShowS
GHC.Show.Show, PaymentIntentCaptureMethod' -> PaymentIntentCaptureMethod' -> Bool
(PaymentIntentCaptureMethod'
 -> PaymentIntentCaptureMethod' -> Bool)
-> (PaymentIntentCaptureMethod'
    -> PaymentIntentCaptureMethod' -> Bool)
-> Eq PaymentIntentCaptureMethod'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentCaptureMethod' -> PaymentIntentCaptureMethod' -> Bool
$c/= :: PaymentIntentCaptureMethod' -> PaymentIntentCaptureMethod' -> Bool
== :: PaymentIntentCaptureMethod' -> PaymentIntentCaptureMethod' -> Bool
$c== :: PaymentIntentCaptureMethod' -> PaymentIntentCaptureMethod' -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentCaptureMethod' where
  toJSON :: PaymentIntentCaptureMethod' -> Value
toJSON (PaymentIntentCaptureMethod'Other Value
val) = Value
val
  toJSON (PaymentIntentCaptureMethod'Typed Text
val) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
val
  toJSON (PaymentIntentCaptureMethod'
PaymentIntentCaptureMethod'EnumAutomatic) = Value
"automatic"
  toJSON (PaymentIntentCaptureMethod'
PaymentIntentCaptureMethod'EnumManual) = Value
"manual"

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentCaptureMethod' where
  parseJSON :: Value -> Parser PaymentIntentCaptureMethod'
parseJSON Value
val =
    PaymentIntentCaptureMethod' -> Parser PaymentIntentCaptureMethod'
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure
      ( if
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"automatic" -> PaymentIntentCaptureMethod'
PaymentIntentCaptureMethod'EnumAutomatic
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"manual" -> PaymentIntentCaptureMethod'
PaymentIntentCaptureMethod'EnumManual
            | Bool
GHC.Base.otherwise -> Value -> PaymentIntentCaptureMethod'
PaymentIntentCaptureMethod'Other Value
val
      )

-- | Defines the object schema located at @components.schemas.payment_intent.properties.charges@ in the specification.
--
-- Charges that were created by this PaymentIntent, if any.
data PaymentIntentCharges' = PaymentIntentCharges'
  { -- | data: This list only contains the latest charge, even if there were previously multiple unsuccessful charges. To view all previous charges for a PaymentIntent, you can filter the charges list using the \`payment_intent\` [parameter](https:\/\/stripe.com\/docs\/api\/charges\/list\#list_charges-payment_intent).
    PaymentIntentCharges' -> [Charge]
paymentIntentCharges'Data :: ([Charge]),
    -- | has_more: True if this list has another page of items after this one that can be fetched.
    PaymentIntentCharges' -> Bool
paymentIntentCharges'HasMore :: GHC.Types.Bool,
    -- | url: The URL where this list can be accessed.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentCharges' -> Text
paymentIntentCharges'Url :: Data.Text.Internal.Text
  }
  deriving
    ( Int -> PaymentIntentCharges' -> ShowS
[PaymentIntentCharges'] -> ShowS
PaymentIntentCharges' -> String
(Int -> PaymentIntentCharges' -> ShowS)
-> (PaymentIntentCharges' -> String)
-> ([PaymentIntentCharges'] -> ShowS)
-> Show PaymentIntentCharges'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentCharges'] -> ShowS
$cshowList :: [PaymentIntentCharges'] -> ShowS
show :: PaymentIntentCharges' -> String
$cshow :: PaymentIntentCharges' -> String
showsPrec :: Int -> PaymentIntentCharges' -> ShowS
$cshowsPrec :: Int -> PaymentIntentCharges' -> ShowS
GHC.Show.Show,
      PaymentIntentCharges' -> PaymentIntentCharges' -> Bool
(PaymentIntentCharges' -> PaymentIntentCharges' -> Bool)
-> (PaymentIntentCharges' -> PaymentIntentCharges' -> Bool)
-> Eq PaymentIntentCharges'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentCharges' -> PaymentIntentCharges' -> Bool
$c/= :: PaymentIntentCharges' -> PaymentIntentCharges' -> Bool
== :: PaymentIntentCharges' -> PaymentIntentCharges' -> Bool
$c== :: PaymentIntentCharges' -> PaymentIntentCharges' -> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentCharges' where
  toJSON :: PaymentIntentCharges' -> Value
toJSON PaymentIntentCharges'
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"data" Text -> [Charge] -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentCharges' -> [Charge]
paymentIntentCharges'Data PaymentIntentCharges'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"has_more" Text -> Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentCharges' -> Bool
paymentIntentCharges'HasMore PaymentIntentCharges'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"url" Text -> Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentCharges' -> Text
paymentIntentCharges'Url PaymentIntentCharges'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"object" Text -> Value -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Text -> Value
Data.Aeson.Types.Internal.String Text
"list" Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: PaymentIntentCharges' -> Encoding
toEncoding PaymentIntentCharges'
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"data" Text -> [Charge] -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentCharges' -> [Charge]
paymentIntentCharges'Data PaymentIntentCharges'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"has_more" Text -> Bool -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentCharges' -> Bool
paymentIntentCharges'HasMore PaymentIntentCharges'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"url" Text -> Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentCharges' -> Text
paymentIntentCharges'Url PaymentIntentCharges'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"object" Text -> Value -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= Text -> Value
Data.Aeson.Types.Internal.String Text
"list"))))

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentCharges' where
  parseJSON :: Value -> Parser PaymentIntentCharges'
parseJSON = String
-> (Object -> Parser PaymentIntentCharges')
-> Value
-> Parser PaymentIntentCharges'
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"PaymentIntentCharges'" (\Object
obj -> ((([Charge] -> Bool -> Text -> PaymentIntentCharges')
-> Parser ([Charge] -> Bool -> Text -> PaymentIntentCharges')
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure [Charge] -> Bool -> Text -> PaymentIntentCharges'
PaymentIntentCharges' Parser ([Charge] -> Bool -> Text -> PaymentIntentCharges')
-> Parser [Charge]
-> Parser (Bool -> Text -> PaymentIntentCharges')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser [Charge]
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"data")) Parser (Bool -> Text -> PaymentIntentCharges')
-> Parser Bool -> Parser (Text -> PaymentIntentCharges')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Bool
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"has_more")) Parser (Text -> PaymentIntentCharges')
-> Parser Text -> Parser PaymentIntentCharges'
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser Text
forall a. FromJSON a => Object -> Text -> Parser a
Data.Aeson.Types.FromJSON..: Text
"url"))

-- | Create a new 'PaymentIntentCharges'' with all required fields.
mkPaymentIntentCharges' ::
  -- | 'paymentIntentCharges'Data'
  [Charge] ->
  -- | 'paymentIntentCharges'HasMore'
  GHC.Types.Bool ->
  -- | 'paymentIntentCharges'Url'
  Data.Text.Internal.Text ->
  PaymentIntentCharges'
mkPaymentIntentCharges' :: [Charge] -> Bool -> Text -> PaymentIntentCharges'
mkPaymentIntentCharges' [Charge]
paymentIntentCharges'Data Bool
paymentIntentCharges'HasMore Text
paymentIntentCharges'Url =
  PaymentIntentCharges' :: [Charge] -> Bool -> Text -> PaymentIntentCharges'
PaymentIntentCharges'
    { paymentIntentCharges'Data :: [Charge]
paymentIntentCharges'Data = [Charge]
paymentIntentCharges'Data,
      paymentIntentCharges'HasMore :: Bool
paymentIntentCharges'HasMore = Bool
paymentIntentCharges'HasMore,
      paymentIntentCharges'Url :: Text
paymentIntentCharges'Url = Text
paymentIntentCharges'Url
    }

-- | Defines the enum schema located at @components.schemas.payment_intent.properties.confirmation_method@ in the specification.
data PaymentIntentConfirmationMethod'
  = -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
    PaymentIntentConfirmationMethod'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.
    PaymentIntentConfirmationMethod'Typed Data.Text.Internal.Text
  | -- | Represents the JSON value @"automatic"@
    PaymentIntentConfirmationMethod'EnumAutomatic
  | -- | Represents the JSON value @"manual"@
    PaymentIntentConfirmationMethod'EnumManual
  deriving (Int -> PaymentIntentConfirmationMethod' -> ShowS
[PaymentIntentConfirmationMethod'] -> ShowS
PaymentIntentConfirmationMethod' -> String
(Int -> PaymentIntentConfirmationMethod' -> ShowS)
-> (PaymentIntentConfirmationMethod' -> String)
-> ([PaymentIntentConfirmationMethod'] -> ShowS)
-> Show PaymentIntentConfirmationMethod'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentConfirmationMethod'] -> ShowS
$cshowList :: [PaymentIntentConfirmationMethod'] -> ShowS
show :: PaymentIntentConfirmationMethod' -> String
$cshow :: PaymentIntentConfirmationMethod' -> String
showsPrec :: Int -> PaymentIntentConfirmationMethod' -> ShowS
$cshowsPrec :: Int -> PaymentIntentConfirmationMethod' -> ShowS
GHC.Show.Show, PaymentIntentConfirmationMethod'
-> PaymentIntentConfirmationMethod' -> Bool
(PaymentIntentConfirmationMethod'
 -> PaymentIntentConfirmationMethod' -> Bool)
-> (PaymentIntentConfirmationMethod'
    -> PaymentIntentConfirmationMethod' -> Bool)
-> Eq PaymentIntentConfirmationMethod'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentConfirmationMethod'
-> PaymentIntentConfirmationMethod' -> Bool
$c/= :: PaymentIntentConfirmationMethod'
-> PaymentIntentConfirmationMethod' -> Bool
== :: PaymentIntentConfirmationMethod'
-> PaymentIntentConfirmationMethod' -> Bool
$c== :: PaymentIntentConfirmationMethod'
-> PaymentIntentConfirmationMethod' -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentConfirmationMethod' where
  toJSON :: PaymentIntentConfirmationMethod' -> Value
toJSON (PaymentIntentConfirmationMethod'Other Value
val) = Value
val
  toJSON (PaymentIntentConfirmationMethod'Typed Text
val) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
val
  toJSON (PaymentIntentConfirmationMethod'
PaymentIntentConfirmationMethod'EnumAutomatic) = Value
"automatic"
  toJSON (PaymentIntentConfirmationMethod'
PaymentIntentConfirmationMethod'EnumManual) = Value
"manual"

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentConfirmationMethod' where
  parseJSON :: Value -> Parser PaymentIntentConfirmationMethod'
parseJSON Value
val =
    PaymentIntentConfirmationMethod'
-> Parser PaymentIntentConfirmationMethod'
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure
      ( if
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"automatic" -> PaymentIntentConfirmationMethod'
PaymentIntentConfirmationMethod'EnumAutomatic
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"manual" -> PaymentIntentConfirmationMethod'
PaymentIntentConfirmationMethod'EnumManual
            | Bool
GHC.Base.otherwise -> Value -> PaymentIntentConfirmationMethod'
PaymentIntentConfirmationMethod'Other Value
val
      )

-- | Defines the oneOf schema located at @components.schemas.payment_intent.properties.customer.anyOf@ in the specification.
--
-- ID of the Customer this PaymentIntent belongs to, if one exists.
--
-- Payment methods attached to other Customers cannot be used with this PaymentIntent.
--
-- If present in combination with [setup_future_usage](https:\/\/stripe.com\/docs\/api\#payment_intent_object-setup_future_usage), this PaymentIntent\'s payment method will be attached to the Customer after the PaymentIntent has been confirmed and any required actions from the user are complete.
data PaymentIntentCustomer'Variants
  = PaymentIntentCustomer'Text Data.Text.Internal.Text
  | PaymentIntentCustomer'Customer Customer
  | PaymentIntentCustomer'DeletedCustomer DeletedCustomer
  deriving (Int -> PaymentIntentCustomer'Variants -> ShowS
[PaymentIntentCustomer'Variants] -> ShowS
PaymentIntentCustomer'Variants -> String
(Int -> PaymentIntentCustomer'Variants -> ShowS)
-> (PaymentIntentCustomer'Variants -> String)
-> ([PaymentIntentCustomer'Variants] -> ShowS)
-> Show PaymentIntentCustomer'Variants
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentCustomer'Variants] -> ShowS
$cshowList :: [PaymentIntentCustomer'Variants] -> ShowS
show :: PaymentIntentCustomer'Variants -> String
$cshow :: PaymentIntentCustomer'Variants -> String
showsPrec :: Int -> PaymentIntentCustomer'Variants -> ShowS
$cshowsPrec :: Int -> PaymentIntentCustomer'Variants -> ShowS
GHC.Show.Show, PaymentIntentCustomer'Variants
-> PaymentIntentCustomer'Variants -> Bool
(PaymentIntentCustomer'Variants
 -> PaymentIntentCustomer'Variants -> Bool)
-> (PaymentIntentCustomer'Variants
    -> PaymentIntentCustomer'Variants -> Bool)
-> Eq PaymentIntentCustomer'Variants
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentCustomer'Variants
-> PaymentIntentCustomer'Variants -> Bool
$c/= :: PaymentIntentCustomer'Variants
-> PaymentIntentCustomer'Variants -> Bool
== :: PaymentIntentCustomer'Variants
-> PaymentIntentCustomer'Variants -> Bool
$c== :: PaymentIntentCustomer'Variants
-> PaymentIntentCustomer'Variants -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentCustomer'Variants where
  toJSON :: PaymentIntentCustomer'Variants -> Value
toJSON (PaymentIntentCustomer'Text Text
a) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
a
  toJSON (PaymentIntentCustomer'Customer Customer
a) = Customer -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Customer
a
  toJSON (PaymentIntentCustomer'DeletedCustomer DeletedCustomer
a) = DeletedCustomer -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON DeletedCustomer
a

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentCustomer'Variants where
  parseJSON :: Value -> Parser PaymentIntentCustomer'Variants
parseJSON Value
val = case (Text -> PaymentIntentCustomer'Variants
PaymentIntentCustomer'Text (Text -> PaymentIntentCustomer'Variants)
-> Result Text -> Result PaymentIntentCustomer'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Text
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentCustomer'Variants
-> Result PaymentIntentCustomer'Variants
-> Result PaymentIntentCustomer'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> ((Customer -> PaymentIntentCustomer'Variants
PaymentIntentCustomer'Customer (Customer -> PaymentIntentCustomer'Variants)
-> Result Customer -> Result PaymentIntentCustomer'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Customer
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentCustomer'Variants
-> Result PaymentIntentCustomer'Variants
-> Result PaymentIntentCustomer'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> ((DeletedCustomer -> PaymentIntentCustomer'Variants
PaymentIntentCustomer'DeletedCustomer (DeletedCustomer -> PaymentIntentCustomer'Variants)
-> Result DeletedCustomer -> Result PaymentIntentCustomer'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result DeletedCustomer
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentCustomer'Variants
-> Result PaymentIntentCustomer'Variants
-> Result PaymentIntentCustomer'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> String -> Result PaymentIntentCustomer'Variants
forall a. String -> Result a
Data.Aeson.Types.Internal.Error String
"No variant matched")) of
    Data.Aeson.Types.Internal.Success PaymentIntentCustomer'Variants
a -> PaymentIntentCustomer'Variants
-> Parser PaymentIntentCustomer'Variants
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure PaymentIntentCustomer'Variants
a
    Data.Aeson.Types.Internal.Error String
a -> String -> Parser PaymentIntentCustomer'Variants
forall (m :: * -> *) a. MonadFail m => String -> m a
Control.Monad.Fail.fail String
a

-- | Defines the oneOf schema located at @components.schemas.payment_intent.properties.invoice.anyOf@ in the specification.
--
-- ID of the invoice that created this PaymentIntent, if it exists.
data PaymentIntentInvoice'Variants
  = PaymentIntentInvoice'Text Data.Text.Internal.Text
  | PaymentIntentInvoice'Invoice Invoice
  deriving (Int -> PaymentIntentInvoice'Variants -> ShowS
[PaymentIntentInvoice'Variants] -> ShowS
PaymentIntentInvoice'Variants -> String
(Int -> PaymentIntentInvoice'Variants -> ShowS)
-> (PaymentIntentInvoice'Variants -> String)
-> ([PaymentIntentInvoice'Variants] -> ShowS)
-> Show PaymentIntentInvoice'Variants
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentInvoice'Variants] -> ShowS
$cshowList :: [PaymentIntentInvoice'Variants] -> ShowS
show :: PaymentIntentInvoice'Variants -> String
$cshow :: PaymentIntentInvoice'Variants -> String
showsPrec :: Int -> PaymentIntentInvoice'Variants -> ShowS
$cshowsPrec :: Int -> PaymentIntentInvoice'Variants -> ShowS
GHC.Show.Show, PaymentIntentInvoice'Variants
-> PaymentIntentInvoice'Variants -> Bool
(PaymentIntentInvoice'Variants
 -> PaymentIntentInvoice'Variants -> Bool)
-> (PaymentIntentInvoice'Variants
    -> PaymentIntentInvoice'Variants -> Bool)
-> Eq PaymentIntentInvoice'Variants
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentInvoice'Variants
-> PaymentIntentInvoice'Variants -> Bool
$c/= :: PaymentIntentInvoice'Variants
-> PaymentIntentInvoice'Variants -> Bool
== :: PaymentIntentInvoice'Variants
-> PaymentIntentInvoice'Variants -> Bool
$c== :: PaymentIntentInvoice'Variants
-> PaymentIntentInvoice'Variants -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentInvoice'Variants where
  toJSON :: PaymentIntentInvoice'Variants -> Value
toJSON (PaymentIntentInvoice'Text Text
a) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
a
  toJSON (PaymentIntentInvoice'Invoice Invoice
a) = Invoice -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Invoice
a

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentInvoice'Variants where
  parseJSON :: Value -> Parser PaymentIntentInvoice'Variants
parseJSON Value
val = case (Text -> PaymentIntentInvoice'Variants
PaymentIntentInvoice'Text (Text -> PaymentIntentInvoice'Variants)
-> Result Text -> Result PaymentIntentInvoice'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Text
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentInvoice'Variants
-> Result PaymentIntentInvoice'Variants
-> Result PaymentIntentInvoice'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> ((Invoice -> PaymentIntentInvoice'Variants
PaymentIntentInvoice'Invoice (Invoice -> PaymentIntentInvoice'Variants)
-> Result Invoice -> Result PaymentIntentInvoice'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Invoice
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentInvoice'Variants
-> Result PaymentIntentInvoice'Variants
-> Result PaymentIntentInvoice'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> String -> Result PaymentIntentInvoice'Variants
forall a. String -> Result a
Data.Aeson.Types.Internal.Error String
"No variant matched") of
    Data.Aeson.Types.Internal.Success PaymentIntentInvoice'Variants
a -> PaymentIntentInvoice'Variants
-> Parser PaymentIntentInvoice'Variants
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure PaymentIntentInvoice'Variants
a
    Data.Aeson.Types.Internal.Error String
a -> String -> Parser PaymentIntentInvoice'Variants
forall (m :: * -> *) a. MonadFail m => String -> m a
Control.Monad.Fail.fail String
a

-- | Defines the object schema located at @components.schemas.payment_intent.properties.last_payment_error.anyOf@ in the specification.
--
-- The payment error encountered in the previous PaymentIntent confirmation. It will be cleared if the PaymentIntent is later updated for any reason.
data PaymentIntentLastPaymentError' = PaymentIntentLastPaymentError'
  { -- | charge: For card errors, the ID of the failed charge.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'Charge :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | code: For some errors that could be handled programmatically, a short string indicating the [error code](https:\/\/stripe.com\/docs\/error-codes) reported.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'Code :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | decline_code: For card errors resulting from a card issuer decline, a short string indicating the [card issuer\'s reason for the decline](https:\/\/stripe.com\/docs\/declines\#issuer-declines) if they provide one.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'DeclineCode :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | doc_url: A URL to more information about the [error code](https:\/\/stripe.com\/docs\/error-codes) reported.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'DocUrl :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | message: A human-readable message providing more details about the error. For card errors, these messages can be shown to your users.
    --
    -- Constraints:
    --
    -- * Maximum length of 40000
    PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'Message :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | param: If the error is parameter-specific, the parameter related to the error. For example, you can use this to display a message near the correct form field.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'Param :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | payment_intent: A PaymentIntent guides you through the process of collecting a payment from your customer.
    -- We recommend that you create exactly one PaymentIntent for each order or
    -- customer session in your system. You can reference the PaymentIntent later to
    -- see the history of payment attempts for a particular session.
    --
    -- A PaymentIntent transitions through
    -- [multiple statuses](https:\/\/stripe.com\/docs\/payments\/intents\#intent-statuses)
    -- throughout its lifetime as it interfaces with Stripe.js to perform
    -- authentication flows and ultimately creates at most one successful charge.
    --
    -- Related guide: [Payment Intents API](https:\/\/stripe.com\/docs\/payments\/payment-intents).
    PaymentIntentLastPaymentError' -> Maybe PaymentIntent
paymentIntentLastPaymentError'PaymentIntent :: (GHC.Maybe.Maybe PaymentIntent),
    -- | payment_method: PaymentMethod objects represent your customer\'s payment instruments.
    -- They can be used with [PaymentIntents](https:\/\/stripe.com\/docs\/payments\/payment-intents) to collect payments or saved to
    -- Customer objects to store instrument details for future payments.
    --
    -- Related guides: [Payment Methods](https:\/\/stripe.com\/docs\/payments\/payment-methods) and [More Payment Scenarios](https:\/\/stripe.com\/docs\/payments\/more-payment-scenarios).
    PaymentIntentLastPaymentError' -> Maybe PaymentMethod
paymentIntentLastPaymentError'PaymentMethod :: (GHC.Maybe.Maybe PaymentMethod),
    -- | payment_method_type: If the error is specific to the type of payment method, the payment method type that had a problem. This field is only populated for invoice-related errors.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'PaymentMethodType :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | setup_intent: A SetupIntent guides you through the process of setting up and saving a customer\'s payment credentials for future payments.
    -- For example, you could use a SetupIntent to set up and save your customer\'s card without immediately collecting a payment.
    -- Later, you can use [PaymentIntents](https:\/\/stripe.com\/docs\/api\#payment_intents) to drive the payment flow.
    --
    -- Create a SetupIntent as soon as you\'re ready to collect your customer\'s payment credentials.
    -- Do not maintain long-lived, unconfirmed SetupIntents as they may no longer be valid.
    -- The SetupIntent then transitions through multiple [statuses](https:\/\/stripe.com\/docs\/payments\/intents\#intent-statuses) as it guides
    -- you through the setup process.
    --
    -- Successful SetupIntents result in payment credentials that are optimized for future payments.
    -- For example, cardholders in [certain regions](\/guides\/strong-customer-authentication) may need to be run through
    -- [Strong Customer Authentication](https:\/\/stripe.com\/docs\/strong-customer-authentication) at the time of payment method collection
    -- in order to streamline later [off-session payments](https:\/\/stripe.com\/docs\/payments\/setup-intents).
    -- If the SetupIntent is used with a [Customer](https:\/\/stripe.com\/docs\/api\#setup_intent_object-customer), upon success,
    -- it will automatically attach the resulting payment method to that Customer.
    -- We recommend using SetupIntents or [setup_future_usage](https:\/\/stripe.com\/docs\/api\#payment_intent_object-setup_future_usage) on
    -- PaymentIntents to save payment methods in order to prevent saving invalid or unoptimized payment methods.
    --
    -- By using SetupIntents, you ensure that your customers experience the minimum set of required friction,
    -- even as regulations change over time.
    --
    -- Related guide: [Setup Intents API](https:\/\/stripe.com\/docs\/payments\/setup-intents).
    PaymentIntentLastPaymentError' -> Maybe SetupIntent
paymentIntentLastPaymentError'SetupIntent :: (GHC.Maybe.Maybe SetupIntent),
    -- | source: The source object for errors returned on a request involving a source.
    PaymentIntentLastPaymentError'
-> Maybe PaymentIntentLastPaymentError'Source'
paymentIntentLastPaymentError'Source :: (GHC.Maybe.Maybe PaymentIntentLastPaymentError'Source'),
    -- | type: The type of error returned. One of \`api_connection_error\`, \`api_error\`, \`authentication_error\`, \`card_error\`, \`idempotency_error\`, \`invalid_request_error\`, or \`rate_limit_error\`
    PaymentIntentLastPaymentError'
-> Maybe PaymentIntentLastPaymentError'Type'
paymentIntentLastPaymentError'Type :: (GHC.Maybe.Maybe PaymentIntentLastPaymentError'Type')
  }
  deriving
    ( Int -> PaymentIntentLastPaymentError' -> ShowS
[PaymentIntentLastPaymentError'] -> ShowS
PaymentIntentLastPaymentError' -> String
(Int -> PaymentIntentLastPaymentError' -> ShowS)
-> (PaymentIntentLastPaymentError' -> String)
-> ([PaymentIntentLastPaymentError'] -> ShowS)
-> Show PaymentIntentLastPaymentError'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentLastPaymentError'] -> ShowS
$cshowList :: [PaymentIntentLastPaymentError'] -> ShowS
show :: PaymentIntentLastPaymentError' -> String
$cshow :: PaymentIntentLastPaymentError' -> String
showsPrec :: Int -> PaymentIntentLastPaymentError' -> ShowS
$cshowsPrec :: Int -> PaymentIntentLastPaymentError' -> ShowS
GHC.Show.Show,
      PaymentIntentLastPaymentError'
-> PaymentIntentLastPaymentError' -> Bool
(PaymentIntentLastPaymentError'
 -> PaymentIntentLastPaymentError' -> Bool)
-> (PaymentIntentLastPaymentError'
    -> PaymentIntentLastPaymentError' -> Bool)
-> Eq PaymentIntentLastPaymentError'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentLastPaymentError'
-> PaymentIntentLastPaymentError' -> Bool
$c/= :: PaymentIntentLastPaymentError'
-> PaymentIntentLastPaymentError' -> Bool
== :: PaymentIntentLastPaymentError'
-> PaymentIntentLastPaymentError' -> Bool
$c== :: PaymentIntentLastPaymentError'
-> PaymentIntentLastPaymentError' -> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentLastPaymentError' where
  toJSON :: PaymentIntentLastPaymentError' -> Value
toJSON PaymentIntentLastPaymentError'
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"charge" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'Charge PaymentIntentLastPaymentError'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"code" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'Code PaymentIntentLastPaymentError'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"decline_code" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'DeclineCode PaymentIntentLastPaymentError'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"doc_url" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'DocUrl PaymentIntentLastPaymentError'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"message" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'Message PaymentIntentLastPaymentError'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"param" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'Param PaymentIntentLastPaymentError'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"payment_intent" Text -> Maybe PaymentIntent -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe PaymentIntent
paymentIntentLastPaymentError'PaymentIntent PaymentIntentLastPaymentError'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"payment_method" Text -> Maybe PaymentMethod -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe PaymentMethod
paymentIntentLastPaymentError'PaymentMethod PaymentIntentLastPaymentError'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"payment_method_type" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'PaymentMethodType PaymentIntentLastPaymentError'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"setup_intent" Text -> Maybe SetupIntent -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe SetupIntent
paymentIntentLastPaymentError'SetupIntent PaymentIntentLastPaymentError'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"source" Text -> Maybe PaymentIntentLastPaymentError'Source' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'
-> Maybe PaymentIntentLastPaymentError'Source'
paymentIntentLastPaymentError'Source PaymentIntentLastPaymentError'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"type" Text -> Maybe PaymentIntentLastPaymentError'Type' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'
-> Maybe PaymentIntentLastPaymentError'Type'
paymentIntentLastPaymentError'Type PaymentIntentLastPaymentError'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: PaymentIntentLastPaymentError' -> Encoding
toEncoding PaymentIntentLastPaymentError'
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"charge" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'Charge PaymentIntentLastPaymentError'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"code" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'Code PaymentIntentLastPaymentError'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"decline_code" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'DeclineCode PaymentIntentLastPaymentError'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"doc_url" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'DocUrl PaymentIntentLastPaymentError'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"message" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'Message PaymentIntentLastPaymentError'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"param" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'Param PaymentIntentLastPaymentError'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"payment_intent" Text -> Maybe PaymentIntent -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe PaymentIntent
paymentIntentLastPaymentError'PaymentIntent PaymentIntentLastPaymentError'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"payment_method" Text -> Maybe PaymentMethod -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe PaymentMethod
paymentIntentLastPaymentError'PaymentMethod PaymentIntentLastPaymentError'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"payment_method_type" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe Text
paymentIntentLastPaymentError'PaymentMethodType PaymentIntentLastPaymentError'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"setup_intent" Text -> Maybe SetupIntent -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError' -> Maybe SetupIntent
paymentIntentLastPaymentError'SetupIntent PaymentIntentLastPaymentError'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"source" Text -> Maybe PaymentIntentLastPaymentError'Source' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'
-> Maybe PaymentIntentLastPaymentError'Source'
paymentIntentLastPaymentError'Source PaymentIntentLastPaymentError'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"type" Text -> Maybe PaymentIntentLastPaymentError'Type' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'
-> Maybe PaymentIntentLastPaymentError'Type'
paymentIntentLastPaymentError'Type PaymentIntentLastPaymentError'
obj))))))))))))

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentLastPaymentError' where
  parseJSON :: Value -> Parser PaymentIntentLastPaymentError'
parseJSON = String
-> (Object -> Parser PaymentIntentLastPaymentError')
-> Value
-> Parser PaymentIntentLastPaymentError'
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"PaymentIntentLastPaymentError'" (\Object
obj -> ((((((((((((Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe PaymentIntent
 -> Maybe PaymentMethod
 -> Maybe Text
 -> Maybe SetupIntent
 -> Maybe PaymentIntentLastPaymentError'Source'
 -> Maybe PaymentIntentLastPaymentError'Type'
 -> PaymentIntentLastPaymentError')
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe PaymentIntent
      -> Maybe PaymentMethod
      -> Maybe Text
      -> Maybe SetupIntent
      -> Maybe PaymentIntentLastPaymentError'Source'
      -> Maybe PaymentIntentLastPaymentError'Type'
      -> PaymentIntentLastPaymentError')
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe PaymentIntent
-> Maybe PaymentMethod
-> Maybe Text
-> Maybe SetupIntent
-> Maybe PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Type'
-> PaymentIntentLastPaymentError'
PaymentIntentLastPaymentError' Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe PaymentIntent
   -> Maybe PaymentMethod
   -> Maybe Text
   -> Maybe SetupIntent
   -> Maybe PaymentIntentLastPaymentError'Source'
   -> Maybe PaymentIntentLastPaymentError'Type'
   -> PaymentIntentLastPaymentError')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe PaymentIntent
      -> Maybe PaymentMethod
      -> Maybe Text
      -> Maybe SetupIntent
      -> Maybe PaymentIntentLastPaymentError'Source'
      -> Maybe PaymentIntentLastPaymentError'Type'
      -> PaymentIntentLastPaymentError')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"charge")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe PaymentIntent
   -> Maybe PaymentMethod
   -> Maybe Text
   -> Maybe SetupIntent
   -> Maybe PaymentIntentLastPaymentError'Source'
   -> Maybe PaymentIntentLastPaymentError'Type'
   -> PaymentIntentLastPaymentError')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe PaymentIntent
      -> Maybe PaymentMethod
      -> Maybe Text
      -> Maybe SetupIntent
      -> Maybe PaymentIntentLastPaymentError'Source'
      -> Maybe PaymentIntentLastPaymentError'Type'
      -> PaymentIntentLastPaymentError')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"code")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe PaymentIntent
   -> Maybe PaymentMethod
   -> Maybe Text
   -> Maybe SetupIntent
   -> Maybe PaymentIntentLastPaymentError'Source'
   -> Maybe PaymentIntentLastPaymentError'Type'
   -> PaymentIntentLastPaymentError')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe PaymentIntent
      -> Maybe PaymentMethod
      -> Maybe Text
      -> Maybe SetupIntent
      -> Maybe PaymentIntentLastPaymentError'Source'
      -> Maybe PaymentIntentLastPaymentError'Type'
      -> PaymentIntentLastPaymentError')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"decline_code")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe PaymentIntent
   -> Maybe PaymentMethod
   -> Maybe Text
   -> Maybe SetupIntent
   -> Maybe PaymentIntentLastPaymentError'Source'
   -> Maybe PaymentIntentLastPaymentError'Type'
   -> PaymentIntentLastPaymentError')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe PaymentIntent
      -> Maybe PaymentMethod
      -> Maybe Text
      -> Maybe SetupIntent
      -> Maybe PaymentIntentLastPaymentError'Source'
      -> Maybe PaymentIntentLastPaymentError'Type'
      -> PaymentIntentLastPaymentError')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"doc_url")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe PaymentIntent
   -> Maybe PaymentMethod
   -> Maybe Text
   -> Maybe SetupIntent
   -> Maybe PaymentIntentLastPaymentError'Source'
   -> Maybe PaymentIntentLastPaymentError'Type'
   -> PaymentIntentLastPaymentError')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe PaymentIntent
      -> Maybe PaymentMethod
      -> Maybe Text
      -> Maybe SetupIntent
      -> Maybe PaymentIntentLastPaymentError'Source'
      -> Maybe PaymentIntentLastPaymentError'Type'
      -> PaymentIntentLastPaymentError')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"message")) Parser
  (Maybe Text
   -> Maybe PaymentIntent
   -> Maybe PaymentMethod
   -> Maybe Text
   -> Maybe SetupIntent
   -> Maybe PaymentIntentLastPaymentError'Source'
   -> Maybe PaymentIntentLastPaymentError'Type'
   -> PaymentIntentLastPaymentError')
-> Parser (Maybe Text)
-> Parser
     (Maybe PaymentIntent
      -> Maybe PaymentMethod
      -> Maybe Text
      -> Maybe SetupIntent
      -> Maybe PaymentIntentLastPaymentError'Source'
      -> Maybe PaymentIntentLastPaymentError'Type'
      -> PaymentIntentLastPaymentError')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"param")) Parser
  (Maybe PaymentIntent
   -> Maybe PaymentMethod
   -> Maybe Text
   -> Maybe SetupIntent
   -> Maybe PaymentIntentLastPaymentError'Source'
   -> Maybe PaymentIntentLastPaymentError'Type'
   -> PaymentIntentLastPaymentError')
-> Parser (Maybe PaymentIntent)
-> Parser
     (Maybe PaymentMethod
      -> Maybe Text
      -> Maybe SetupIntent
      -> Maybe PaymentIntentLastPaymentError'Source'
      -> Maybe PaymentIntentLastPaymentError'Type'
      -> PaymentIntentLastPaymentError')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntent)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"payment_intent")) Parser
  (Maybe PaymentMethod
   -> Maybe Text
   -> Maybe SetupIntent
   -> Maybe PaymentIntentLastPaymentError'Source'
   -> Maybe PaymentIntentLastPaymentError'Type'
   -> PaymentIntentLastPaymentError')
-> Parser (Maybe PaymentMethod)
-> Parser
     (Maybe Text
      -> Maybe SetupIntent
      -> Maybe PaymentIntentLastPaymentError'Source'
      -> Maybe PaymentIntentLastPaymentError'Type'
      -> PaymentIntentLastPaymentError')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentMethod)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"payment_method")) Parser
  (Maybe Text
   -> Maybe SetupIntent
   -> Maybe PaymentIntentLastPaymentError'Source'
   -> Maybe PaymentIntentLastPaymentError'Type'
   -> PaymentIntentLastPaymentError')
-> Parser (Maybe Text)
-> Parser
     (Maybe SetupIntent
      -> Maybe PaymentIntentLastPaymentError'Source'
      -> Maybe PaymentIntentLastPaymentError'Type'
      -> PaymentIntentLastPaymentError')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"payment_method_type")) Parser
  (Maybe SetupIntent
   -> Maybe PaymentIntentLastPaymentError'Source'
   -> Maybe PaymentIntentLastPaymentError'Type'
   -> PaymentIntentLastPaymentError')
-> Parser (Maybe SetupIntent)
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'
      -> Maybe PaymentIntentLastPaymentError'Type'
      -> PaymentIntentLastPaymentError')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SetupIntent)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"setup_intent")) Parser
  (Maybe PaymentIntentLastPaymentError'Source'
   -> Maybe PaymentIntentLastPaymentError'Type'
   -> PaymentIntentLastPaymentError')
-> Parser (Maybe PaymentIntentLastPaymentError'Source')
-> Parser
     (Maybe PaymentIntentLastPaymentError'Type'
      -> PaymentIntentLastPaymentError')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text -> Parser (Maybe PaymentIntentLastPaymentError'Source')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"source")) Parser
  (Maybe PaymentIntentLastPaymentError'Type'
   -> PaymentIntentLastPaymentError')
-> Parser (Maybe PaymentIntentLastPaymentError'Type')
-> Parser PaymentIntentLastPaymentError'
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text -> Parser (Maybe PaymentIntentLastPaymentError'Type')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"type"))

-- | Create a new 'PaymentIntentLastPaymentError'' with all required fields.
mkPaymentIntentLastPaymentError' :: PaymentIntentLastPaymentError'
mkPaymentIntentLastPaymentError' :: PaymentIntentLastPaymentError'
mkPaymentIntentLastPaymentError' =
  PaymentIntentLastPaymentError' :: Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe PaymentIntent
-> Maybe PaymentMethod
-> Maybe Text
-> Maybe SetupIntent
-> Maybe PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Type'
-> PaymentIntentLastPaymentError'
PaymentIntentLastPaymentError'
    { paymentIntentLastPaymentError'Charge :: Maybe Text
paymentIntentLastPaymentError'Charge = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Code :: Maybe Text
paymentIntentLastPaymentError'Code = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'DeclineCode :: Maybe Text
paymentIntentLastPaymentError'DeclineCode = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'DocUrl :: Maybe Text
paymentIntentLastPaymentError'DocUrl = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Message :: Maybe Text
paymentIntentLastPaymentError'Message = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Param :: Maybe Text
paymentIntentLastPaymentError'Param = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'PaymentIntent :: Maybe PaymentIntent
paymentIntentLastPaymentError'PaymentIntent = Maybe PaymentIntent
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'PaymentMethod :: Maybe PaymentMethod
paymentIntentLastPaymentError'PaymentMethod = Maybe PaymentMethod
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'PaymentMethodType :: Maybe Text
paymentIntentLastPaymentError'PaymentMethodType = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'SetupIntent :: Maybe SetupIntent
paymentIntentLastPaymentError'SetupIntent = Maybe SetupIntent
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source :: Maybe PaymentIntentLastPaymentError'Source'
paymentIntentLastPaymentError'Source = Maybe PaymentIntentLastPaymentError'Source'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Type :: Maybe PaymentIntentLastPaymentError'Type'
paymentIntentLastPaymentError'Type = Maybe PaymentIntentLastPaymentError'Type'
forall a. Maybe a
GHC.Maybe.Nothing
    }

-- | Defines the object schema located at @components.schemas.payment_intent.properties.last_payment_error.anyOf.properties.source.anyOf@ in the specification.
--
-- The source object for errors returned on a request involving a source.
data PaymentIntentLastPaymentError'Source' = PaymentIntentLastPaymentError'Source'
  { -- | account: The ID of the account that the bank account is associated with.
    PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Account'Variants
paymentIntentLastPaymentError'Source'Account :: (GHC.Maybe.Maybe PaymentIntentLastPaymentError'Source'Account'Variants),
    -- | account_holder_name: The name of the person or business that owns the bank account.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AccountHolderName :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | account_holder_type: The type of entity that holds the account. This can be either \`individual\` or \`company\`.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AccountHolderType :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | ach_credit_transfer
    PaymentIntentLastPaymentError'Source'
-> Maybe SourceTypeAchCreditTransfer
paymentIntentLastPaymentError'Source'AchCreditTransfer :: (GHC.Maybe.Maybe SourceTypeAchCreditTransfer),
    -- | ach_debit
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeAchDebit
paymentIntentLastPaymentError'Source'AchDebit :: (GHC.Maybe.Maybe SourceTypeAchDebit),
    -- | acss_debit
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeAcssDebit
paymentIntentLastPaymentError'Source'AcssDebit :: (GHC.Maybe.Maybe SourceTypeAcssDebit),
    -- | address_city: City\/District\/Suburb\/Town\/Village.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressCity :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | address_country: Billing address country, if provided when creating card.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressCountry :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | address_line1: Address line 1 (Street address\/PO Box\/Company name).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressLine1 :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | address_line1_check: If \`address_line1\` was provided, results of the check: \`pass\`, \`fail\`, \`unavailable\`, or \`unchecked\`.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressLine1Check :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | address_line2: Address line 2 (Apartment\/Suite\/Unit\/Building).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressLine2 :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | address_state: State\/County\/Province\/Region.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressState :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | address_zip: ZIP or postal code.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressZip :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | address_zip_check: If \`address_zip\` was provided, results of the check: \`pass\`, \`fail\`, \`unavailable\`, or \`unchecked\`.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressZipCheck :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | alipay
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeAlipay
paymentIntentLastPaymentError'Source'Alipay :: (GHC.Maybe.Maybe SourceTypeAlipay),
    -- | amount: A positive integer in the smallest currency unit (that is, 100 cents for \$1.00, or 1 for ¥1, Japanese Yen being a zero-decimal currency) representing the total amount associated with the source. This is the amount for which the source will be chargeable once ready. Required for \`single_use\` sources.
    PaymentIntentLastPaymentError'Source' -> Maybe Int
paymentIntentLastPaymentError'Source'Amount :: (GHC.Maybe.Maybe GHC.Types.Int),
    -- | au_becs_debit
    PaymentIntentLastPaymentError'Source'
-> Maybe SourceTypeAuBecsDebit
paymentIntentLastPaymentError'Source'AuBecsDebit :: (GHC.Maybe.Maybe SourceTypeAuBecsDebit),
    -- | available_payout_methods: A set of available payout methods for this bank account. Only values from this set should be passed as the \`method\` when creating a payout.
    PaymentIntentLastPaymentError'Source'
-> Maybe
     [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
paymentIntentLastPaymentError'Source'AvailablePayoutMethods :: (GHC.Maybe.Maybe ([PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'])),
    -- | bancontact
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeBancontact
paymentIntentLastPaymentError'Source'Bancontact :: (GHC.Maybe.Maybe SourceTypeBancontact),
    -- | bank_name: Name of the bank associated with the routing number (e.g., \`WELLS FARGO\`).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'BankName :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | brand: Card brand. Can be \`American Express\`, \`Diners Club\`, \`Discover\`, \`JCB\`, \`MasterCard\`, \`UnionPay\`, \`Visa\`, or \`Unknown\`.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Brand :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | card
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeCard
paymentIntentLastPaymentError'Source'Card :: (GHC.Maybe.Maybe SourceTypeCard),
    -- | card_present
    PaymentIntentLastPaymentError'Source'
-> Maybe SourceTypeCardPresent
paymentIntentLastPaymentError'Source'CardPresent :: (GHC.Maybe.Maybe SourceTypeCardPresent),
    -- | client_secret: The client secret of the source. Used for client-side retrieval using a publishable key.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'ClientSecret :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | code_verification:
    PaymentIntentLastPaymentError'Source'
-> Maybe SourceCodeVerificationFlow
paymentIntentLastPaymentError'Source'CodeVerification :: (GHC.Maybe.Maybe SourceCodeVerificationFlow),
    -- | country: Two-letter ISO code representing the country the bank account is located in.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Country :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | created: Time at which the object was created. Measured in seconds since the Unix epoch.
    PaymentIntentLastPaymentError'Source' -> Maybe Int
paymentIntentLastPaymentError'Source'Created :: (GHC.Maybe.Maybe GHC.Types.Int),
    -- | currency: Three-letter [ISO code for the currency](https:\/\/stripe.com\/docs\/payouts) paid out to the bank account.
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Currency :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | customer: The ID of the customer that the bank account is associated with.
    PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
paymentIntentLastPaymentError'Source'Customer :: (GHC.Maybe.Maybe PaymentIntentLastPaymentError'Source'Customer'Variants),
    -- | cvc_check: If a CVC was provided, results of the check: \`pass\`, \`fail\`, \`unavailable\`, or \`unchecked\`. A result of unchecked indicates that CVC was provided but hasn\'t been checked yet. Checks are typically performed when attaching a card to a Customer object, or when creating a charge. For more details, see [Check if a card is valid without a charge](https:\/\/support.stripe.com\/questions\/check-if-a-card-is-valid-without-a-charge).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'CvcCheck :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | default_for_currency: Whether this bank account is the default external account for its currency.
    PaymentIntentLastPaymentError'Source' -> Maybe Bool
paymentIntentLastPaymentError'Source'DefaultForCurrency :: (GHC.Maybe.Maybe GHC.Types.Bool),
    -- | dynamic_last4: (For tokenized numbers only.) The last four digits of the device account number.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'DynamicLast4 :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | eps
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeEps
paymentIntentLastPaymentError'Source'Eps :: (GHC.Maybe.Maybe SourceTypeEps),
    -- | exp_month: Two-digit number representing the card\'s expiration month.
    PaymentIntentLastPaymentError'Source' -> Maybe Int
paymentIntentLastPaymentError'Source'ExpMonth :: (GHC.Maybe.Maybe GHC.Types.Int),
    -- | exp_year: Four-digit number representing the card\'s expiration year.
    PaymentIntentLastPaymentError'Source' -> Maybe Int
paymentIntentLastPaymentError'Source'ExpYear :: (GHC.Maybe.Maybe GHC.Types.Int),
    -- | fingerprint: Uniquely identifies this particular bank account. You can use this attribute to check whether two bank accounts are the same.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Fingerprint :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | flow: The authentication \`flow\` of the source. \`flow\` is one of \`redirect\`, \`receiver\`, \`code_verification\`, \`none\`.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Flow :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | funding: Card funding type. Can be \`credit\`, \`debit\`, \`prepaid\`, or \`unknown\`.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Funding :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | giropay
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeGiropay
paymentIntentLastPaymentError'Source'Giropay :: (GHC.Maybe.Maybe SourceTypeGiropay),
    -- | id: Unique identifier for the object.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Id :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | ideal
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeIdeal
paymentIntentLastPaymentError'Source'Ideal :: (GHC.Maybe.Maybe SourceTypeIdeal),
    -- | klarna
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeKlarna
paymentIntentLastPaymentError'Source'Klarna :: (GHC.Maybe.Maybe SourceTypeKlarna),
    -- | last4: The last four digits of the bank account number.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Last4 :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | livemode: Has the value \`true\` if the object exists in live mode or the value \`false\` if the object exists in test mode.
    PaymentIntentLastPaymentError'Source' -> Maybe Bool
paymentIntentLastPaymentError'Source'Livemode :: (GHC.Maybe.Maybe GHC.Types.Bool),
    -- | metadata: Set of [key-value pairs](https:\/\/stripe.com\/docs\/api\/metadata) that you can attach to an object. This can be useful for storing additional information about the object in a structured format.
    PaymentIntentLastPaymentError'Source' -> Maybe Object
paymentIntentLastPaymentError'Source'Metadata :: (GHC.Maybe.Maybe Data.Aeson.Types.Internal.Object),
    -- | multibanco
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeMultibanco
paymentIntentLastPaymentError'Source'Multibanco :: (GHC.Maybe.Maybe SourceTypeMultibanco),
    -- | name: Cardholder name.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Name :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | object: String representing the object\'s type. Objects of the same type share the same value.
    PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Object'
paymentIntentLastPaymentError'Source'Object :: (GHC.Maybe.Maybe PaymentIntentLastPaymentError'Source'Object'),
    -- | owner: Information about the owner of the payment instrument that may be used or required by particular source types.
    PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Owner'
paymentIntentLastPaymentError'Source'Owner :: (GHC.Maybe.Maybe PaymentIntentLastPaymentError'Source'Owner'),
    -- | p24
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeP24
paymentIntentLastPaymentError'Source'P24 :: (GHC.Maybe.Maybe SourceTypeP24),
    -- | receiver:
    PaymentIntentLastPaymentError'Source' -> Maybe SourceReceiverFlow
paymentIntentLastPaymentError'Source'Receiver :: (GHC.Maybe.Maybe SourceReceiverFlow),
    -- | recipient: The recipient that this card belongs to. This attribute will not be in the card object if the card belongs to a customer or account instead.
    PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
paymentIntentLastPaymentError'Source'Recipient :: (GHC.Maybe.Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants),
    -- | redirect:
    PaymentIntentLastPaymentError'Source' -> Maybe SourceRedirectFlow
paymentIntentLastPaymentError'Source'Redirect :: (GHC.Maybe.Maybe SourceRedirectFlow),
    -- | routing_number: The routing transit number for the bank account.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'RoutingNumber :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | sepa_debit
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeSepaDebit
paymentIntentLastPaymentError'Source'SepaDebit :: (GHC.Maybe.Maybe SourceTypeSepaDebit),
    -- | sofort
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeSofort
paymentIntentLastPaymentError'Source'Sofort :: (GHC.Maybe.Maybe SourceTypeSofort),
    -- | source_order:
    PaymentIntentLastPaymentError'Source' -> Maybe SourceOrder
paymentIntentLastPaymentError'Source'SourceOrder :: (GHC.Maybe.Maybe SourceOrder),
    -- | statement_descriptor: Extra information about a source. This will appear on your customer\'s statement every time you charge the source.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'StatementDescriptor :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | status: For bank accounts, possible values are \`new\`, \`validated\`, \`verified\`, \`verification_failed\`, or \`errored\`. A bank account that hasn\'t had any activity or validation performed is \`new\`. If Stripe can determine that the bank account exists, its status will be \`validated\`. Note that there often isn’t enough information to know (e.g., for smaller credit unions), and the validation is not always run. If customer bank account verification has succeeded, the bank account status will be \`verified\`. If the verification failed for any reason, such as microdeposit failure, the status will be \`verification_failed\`. If a transfer sent to this bank account fails, we\'ll set the status to \`errored\` and will not continue to send transfers until the bank details are updated.
    --
    -- For external accounts, possible values are \`new\` and \`errored\`. Validations aren\'t run against external accounts because they\'re only used for payouts. This means the other statuses don\'t apply. If a transfer fails, the status is set to \`errored\` and transfers are stopped until account details are updated.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Status :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | three_d_secure
    PaymentIntentLastPaymentError'Source'
-> Maybe SourceTypeThreeDSecure
paymentIntentLastPaymentError'Source'ThreeDSecure :: (GHC.Maybe.Maybe SourceTypeThreeDSecure),
    -- | tokenization_method: If the card number is tokenized, this is the method that was used. Can be \`android_pay\` (includes Google Pay), \`apple_pay\`, \`masterpass\`, \`visa_checkout\`, or null.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'TokenizationMethod :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | type: The \`type\` of the source. The \`type\` is a payment method, one of \`ach_credit_transfer\`, \`ach_debit\`, \`alipay\`, \`bancontact\`, \`card\`, \`card_present\`, \`eps\`, \`giropay\`, \`ideal\`, \`multibanco\`, \`klarna\`, \`p24\`, \`sepa_debit\`, \`sofort\`, \`three_d_secure\`, or \`wechat\`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https:\/\/stripe.com\/docs\/sources) used.
    PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Type'
paymentIntentLastPaymentError'Source'Type :: (GHC.Maybe.Maybe PaymentIntentLastPaymentError'Source'Type'),
    -- | usage: Either \`reusable\` or \`single_use\`. Whether this source should be reusable or not. Some source types may or may not be reusable by construction, while others may leave the option at creation. If an incompatible value is passed, an error will be returned.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Usage :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | wechat
    PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeWechat
paymentIntentLastPaymentError'Source'Wechat :: (GHC.Maybe.Maybe SourceTypeWechat)
  }
  deriving
    ( Int -> PaymentIntentLastPaymentError'Source' -> ShowS
[PaymentIntentLastPaymentError'Source'] -> ShowS
PaymentIntentLastPaymentError'Source' -> String
(Int -> PaymentIntentLastPaymentError'Source' -> ShowS)
-> (PaymentIntentLastPaymentError'Source' -> String)
-> ([PaymentIntentLastPaymentError'Source'] -> ShowS)
-> Show PaymentIntentLastPaymentError'Source'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentLastPaymentError'Source'] -> ShowS
$cshowList :: [PaymentIntentLastPaymentError'Source'] -> ShowS
show :: PaymentIntentLastPaymentError'Source' -> String
$cshow :: PaymentIntentLastPaymentError'Source' -> String
showsPrec :: Int -> PaymentIntentLastPaymentError'Source' -> ShowS
$cshowsPrec :: Int -> PaymentIntentLastPaymentError'Source' -> ShowS
GHC.Show.Show,
      PaymentIntentLastPaymentError'Source'
-> PaymentIntentLastPaymentError'Source' -> Bool
(PaymentIntentLastPaymentError'Source'
 -> PaymentIntentLastPaymentError'Source' -> Bool)
-> (PaymentIntentLastPaymentError'Source'
    -> PaymentIntentLastPaymentError'Source' -> Bool)
-> Eq PaymentIntentLastPaymentError'Source'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentLastPaymentError'Source'
-> PaymentIntentLastPaymentError'Source' -> Bool
$c/= :: PaymentIntentLastPaymentError'Source'
-> PaymentIntentLastPaymentError'Source' -> Bool
== :: PaymentIntentLastPaymentError'Source'
-> PaymentIntentLastPaymentError'Source' -> Bool
$c== :: PaymentIntentLastPaymentError'Source'
-> PaymentIntentLastPaymentError'Source' -> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentLastPaymentError'Source' where
  toJSON :: PaymentIntentLastPaymentError'Source' -> Value
toJSON PaymentIntentLastPaymentError'Source'
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"account" Text
-> Maybe PaymentIntentLastPaymentError'Source'Account'Variants
-> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Account'Variants
paymentIntentLastPaymentError'Source'Account PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"account_holder_name" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AccountHolderName PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"account_holder_type" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AccountHolderType PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"ach_credit_transfer" Text -> Maybe SourceTypeAchCreditTransfer -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe SourceTypeAchCreditTransfer
paymentIntentLastPaymentError'Source'AchCreditTransfer PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"ach_debit" Text -> Maybe SourceTypeAchDebit -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeAchDebit
paymentIntentLastPaymentError'Source'AchDebit PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"acss_debit" Text -> Maybe SourceTypeAcssDebit -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeAcssDebit
paymentIntentLastPaymentError'Source'AcssDebit PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"address_city" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressCity PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"address_country" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressCountry PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"address_line1" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressLine1 PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"address_line1_check" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressLine1Check PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"address_line2" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressLine2 PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"address_state" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressState PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"address_zip" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressZip PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"address_zip_check" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressZipCheck PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"alipay" Text -> Maybe SourceTypeAlipay -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeAlipay
paymentIntentLastPaymentError'Source'Alipay PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"amount" Text -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Int
paymentIntentLastPaymentError'Source'Amount PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"au_becs_debit" Text -> Maybe SourceTypeAuBecsDebit -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe SourceTypeAuBecsDebit
paymentIntentLastPaymentError'Source'AuBecsDebit PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"available_payout_methods" Text
-> Maybe
     [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
-> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe
     [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
paymentIntentLastPaymentError'Source'AvailablePayoutMethods PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"bancontact" Text -> Maybe SourceTypeBancontact -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeBancontact
paymentIntentLastPaymentError'Source'Bancontact PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"bank_name" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'BankName PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"brand" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Brand PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"card" Text -> Maybe SourceTypeCard -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeCard
paymentIntentLastPaymentError'Source'Card PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"card_present" Text -> Maybe SourceTypeCardPresent -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe SourceTypeCardPresent
paymentIntentLastPaymentError'Source'CardPresent PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"client_secret" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'ClientSecret PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"code_verification" Text -> Maybe SourceCodeVerificationFlow -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe SourceCodeVerificationFlow
paymentIntentLastPaymentError'Source'CodeVerification PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"country" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Country PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"created" Text -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Int
paymentIntentLastPaymentError'Source'Created PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"currency" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Currency PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"customer" Text
-> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
-> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
paymentIntentLastPaymentError'Source'Customer PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"cvc_check" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'CvcCheck PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"default_for_currency" Text -> Maybe Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Bool
paymentIntentLastPaymentError'Source'DefaultForCurrency PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"dynamic_last4" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'DynamicLast4 PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"eps" Text -> Maybe SourceTypeEps -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeEps
paymentIntentLastPaymentError'Source'Eps PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"exp_month" Text -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Int
paymentIntentLastPaymentError'Source'ExpMonth PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"exp_year" Text -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Int
paymentIntentLastPaymentError'Source'ExpYear PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"fingerprint" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Fingerprint PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"flow" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Flow PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"funding" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Funding PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"giropay" Text -> Maybe SourceTypeGiropay -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeGiropay
paymentIntentLastPaymentError'Source'Giropay PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"id" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Id PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"ideal" Text -> Maybe SourceTypeIdeal -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeIdeal
paymentIntentLastPaymentError'Source'Ideal PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"klarna" Text -> Maybe SourceTypeKlarna -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeKlarna
paymentIntentLastPaymentError'Source'Klarna PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"last4" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Last4 PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"livemode" Text -> Maybe Bool -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Bool
paymentIntentLastPaymentError'Source'Livemode PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"metadata" Text -> Maybe Object -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Object
paymentIntentLastPaymentError'Source'Metadata PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"multibanco" Text -> Maybe SourceTypeMultibanco -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeMultibanco
paymentIntentLastPaymentError'Source'Multibanco PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"name" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Name PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"object" Text -> Maybe PaymentIntentLastPaymentError'Source'Object' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Object'
paymentIntentLastPaymentError'Source'Object PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"owner" Text -> Maybe PaymentIntentLastPaymentError'Source'Owner' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Owner'
paymentIntentLastPaymentError'Source'Owner PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"p24" Text -> Maybe SourceTypeP24 -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeP24
paymentIntentLastPaymentError'Source'P24 PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"receiver" Text -> Maybe SourceReceiverFlow -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceReceiverFlow
paymentIntentLastPaymentError'Source'Receiver PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"recipient" Text
-> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
-> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
paymentIntentLastPaymentError'Source'Recipient PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"redirect" Text -> Maybe SourceRedirectFlow -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceRedirectFlow
paymentIntentLastPaymentError'Source'Redirect PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"routing_number" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'RoutingNumber PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"sepa_debit" Text -> Maybe SourceTypeSepaDebit -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeSepaDebit
paymentIntentLastPaymentError'Source'SepaDebit PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"sofort" Text -> Maybe SourceTypeSofort -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeSofort
paymentIntentLastPaymentError'Source'Sofort PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"source_order" Text -> Maybe SourceOrder -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceOrder
paymentIntentLastPaymentError'Source'SourceOrder PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"statement_descriptor" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'StatementDescriptor PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"status" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Status PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"three_d_secure" Text -> Maybe SourceTypeThreeDSecure -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe SourceTypeThreeDSecure
paymentIntentLastPaymentError'Source'ThreeDSecure PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"tokenization_method" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'TokenizationMethod PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"type" Text -> Maybe PaymentIntentLastPaymentError'Source'Type' -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Type'
paymentIntentLastPaymentError'Source'Type PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"usage" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Usage PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"wechat" Text -> Maybe SourceTypeWechat -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeWechat
paymentIntentLastPaymentError'Source'Wechat PaymentIntentLastPaymentError'Source'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: PaymentIntentLastPaymentError'Source' -> Encoding
toEncoding PaymentIntentLastPaymentError'Source'
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"account" Text
-> Maybe PaymentIntentLastPaymentError'Source'Account'Variants
-> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Account'Variants
paymentIntentLastPaymentError'Source'Account PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"account_holder_name" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AccountHolderName PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"account_holder_type" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AccountHolderType PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"ach_credit_transfer" Text -> Maybe SourceTypeAchCreditTransfer -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe SourceTypeAchCreditTransfer
paymentIntentLastPaymentError'Source'AchCreditTransfer PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"ach_debit" Text -> Maybe SourceTypeAchDebit -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeAchDebit
paymentIntentLastPaymentError'Source'AchDebit PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"acss_debit" Text -> Maybe SourceTypeAcssDebit -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeAcssDebit
paymentIntentLastPaymentError'Source'AcssDebit PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"address_city" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressCity PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"address_country" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressCountry PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"address_line1" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressLine1 PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"address_line1_check" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressLine1Check PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"address_line2" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressLine2 PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"address_state" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressState PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"address_zip" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressZip PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"address_zip_check" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'AddressZipCheck PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"alipay" Text -> Maybe SourceTypeAlipay -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeAlipay
paymentIntentLastPaymentError'Source'Alipay PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"amount" Text -> Maybe Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Int
paymentIntentLastPaymentError'Source'Amount PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"au_becs_debit" Text -> Maybe SourceTypeAuBecsDebit -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe SourceTypeAuBecsDebit
paymentIntentLastPaymentError'Source'AuBecsDebit PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"available_payout_methods" Text
-> Maybe
     [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
-> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe
     [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
paymentIntentLastPaymentError'Source'AvailablePayoutMethods PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"bancontact" Text -> Maybe SourceTypeBancontact -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeBancontact
paymentIntentLastPaymentError'Source'Bancontact PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"bank_name" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'BankName PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"brand" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Brand PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"card" Text -> Maybe SourceTypeCard -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeCard
paymentIntentLastPaymentError'Source'Card PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"card_present" Text -> Maybe SourceTypeCardPresent -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe SourceTypeCardPresent
paymentIntentLastPaymentError'Source'CardPresent PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"client_secret" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'ClientSecret PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"code_verification" Text -> Maybe SourceCodeVerificationFlow -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe SourceCodeVerificationFlow
paymentIntentLastPaymentError'Source'CodeVerification PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"country" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Country PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"created" Text -> Maybe Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Int
paymentIntentLastPaymentError'Source'Created PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"currency" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Currency PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"customer" Text
-> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
-> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
paymentIntentLastPaymentError'Source'Customer PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"cvc_check" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'CvcCheck PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"default_for_currency" Text -> Maybe Bool -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Bool
paymentIntentLastPaymentError'Source'DefaultForCurrency PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"dynamic_last4" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'DynamicLast4 PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"eps" Text -> Maybe SourceTypeEps -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeEps
paymentIntentLastPaymentError'Source'Eps PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"exp_month" Text -> Maybe Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Int
paymentIntentLastPaymentError'Source'ExpMonth PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"exp_year" Text -> Maybe Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Int
paymentIntentLastPaymentError'Source'ExpYear PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"fingerprint" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Fingerprint PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"flow" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Flow PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"funding" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Funding PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"giropay" Text -> Maybe SourceTypeGiropay -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeGiropay
paymentIntentLastPaymentError'Source'Giropay PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"id" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Id PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"ideal" Text -> Maybe SourceTypeIdeal -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeIdeal
paymentIntentLastPaymentError'Source'Ideal PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"klarna" Text -> Maybe SourceTypeKlarna -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeKlarna
paymentIntentLastPaymentError'Source'Klarna PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"last4" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Last4 PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"livemode" Text -> Maybe Bool -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Bool
paymentIntentLastPaymentError'Source'Livemode PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"metadata" Text -> Maybe Object -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Object
paymentIntentLastPaymentError'Source'Metadata PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"multibanco" Text -> Maybe SourceTypeMultibanco -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeMultibanco
paymentIntentLastPaymentError'Source'Multibanco PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"name" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Name PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"object" Text
-> Maybe PaymentIntentLastPaymentError'Source'Object' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Object'
paymentIntentLastPaymentError'Source'Object PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"owner" Text -> Maybe PaymentIntentLastPaymentError'Source'Owner' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Owner'
paymentIntentLastPaymentError'Source'Owner PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"p24" Text -> Maybe SourceTypeP24 -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeP24
paymentIntentLastPaymentError'Source'P24 PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"receiver" Text -> Maybe SourceReceiverFlow -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceReceiverFlow
paymentIntentLastPaymentError'Source'Receiver PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"recipient" Text
-> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
-> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
paymentIntentLastPaymentError'Source'Recipient PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"redirect" Text -> Maybe SourceRedirectFlow -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceRedirectFlow
paymentIntentLastPaymentError'Source'Redirect PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"routing_number" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'RoutingNumber PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"sepa_debit" Text -> Maybe SourceTypeSepaDebit -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeSepaDebit
paymentIntentLastPaymentError'Source'SepaDebit PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"sofort" Text -> Maybe SourceTypeSofort -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeSofort
paymentIntentLastPaymentError'Source'Sofort PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"source_order" Text -> Maybe SourceOrder -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceOrder
paymentIntentLastPaymentError'Source'SourceOrder PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"statement_descriptor" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'StatementDescriptor PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"status" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Status PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"three_d_secure" Text -> Maybe SourceTypeThreeDSecure -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe SourceTypeThreeDSecure
paymentIntentLastPaymentError'Source'ThreeDSecure PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"tokenization_method" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'TokenizationMethod PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"type" Text -> Maybe PaymentIntentLastPaymentError'Source'Type' -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'
-> Maybe PaymentIntentLastPaymentError'Source'Type'
paymentIntentLastPaymentError'Source'Type PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"usage" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe Text
paymentIntentLastPaymentError'Source'Usage PaymentIntentLastPaymentError'Source'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"wechat" Text -> Maybe SourceTypeWechat -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source' -> Maybe SourceTypeWechat
paymentIntentLastPaymentError'Source'Wechat PaymentIntentLastPaymentError'Source'
obj))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))))

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentLastPaymentError'Source' where
  parseJSON :: Value -> Parser PaymentIntentLastPaymentError'Source'
parseJSON = String
-> (Object -> Parser PaymentIntentLastPaymentError'Source')
-> Value
-> Parser PaymentIntentLastPaymentError'Source'
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"PaymentIntentLastPaymentError'Source'" (\Object
obj -> ((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((((Maybe PaymentIntentLastPaymentError'Source'Account'Variants
 -> Maybe Text
 -> Maybe Text
 -> Maybe SourceTypeAchCreditTransfer
 -> Maybe SourceTypeAchDebit
 -> Maybe SourceTypeAcssDebit
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe SourceTypeAlipay
 -> Maybe Int
 -> Maybe SourceTypeAuBecsDebit
 -> Maybe
      [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
 -> Maybe SourceTypeBancontact
 -> Maybe Text
 -> Maybe Text
 -> Maybe SourceTypeCard
 -> Maybe SourceTypeCardPresent
 -> Maybe Text
 -> Maybe SourceCodeVerificationFlow
 -> Maybe Text
 -> Maybe Int
 -> Maybe Text
 -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
 -> Maybe Text
 -> Maybe Bool
 -> Maybe Text
 -> Maybe SourceTypeEps
 -> Maybe Int
 -> Maybe Int
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe SourceTypeGiropay
 -> Maybe Text
 -> Maybe SourceTypeIdeal
 -> Maybe SourceTypeKlarna
 -> Maybe Text
 -> Maybe Bool
 -> Maybe Object
 -> Maybe SourceTypeMultibanco
 -> Maybe Text
 -> Maybe PaymentIntentLastPaymentError'Source'Object'
 -> Maybe PaymentIntentLastPaymentError'Source'Owner'
 -> Maybe SourceTypeP24
 -> Maybe SourceReceiverFlow
 -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
 -> Maybe SourceRedirectFlow
 -> Maybe Text
 -> Maybe SourceTypeSepaDebit
 -> Maybe SourceTypeSofort
 -> Maybe SourceOrder
 -> Maybe Text
 -> Maybe Text
 -> Maybe SourceTypeThreeDSecure
 -> Maybe Text
 -> Maybe PaymentIntentLastPaymentError'Source'Type'
 -> Maybe Text
 -> Maybe SourceTypeWechat
 -> PaymentIntentLastPaymentError'Source')
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Account'Variants
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAchCreditTransfer
      -> Maybe SourceTypeAchDebit
      -> Maybe SourceTypeAcssDebit
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure Maybe PaymentIntentLastPaymentError'Source'Account'Variants
-> Maybe Text
-> Maybe Text
-> Maybe SourceTypeAchCreditTransfer
-> Maybe SourceTypeAchDebit
-> Maybe SourceTypeAcssDebit
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe SourceTypeAlipay
-> Maybe Int
-> Maybe SourceTypeAuBecsDebit
-> Maybe
     [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
-> Maybe SourceTypeBancontact
-> Maybe Text
-> Maybe Text
-> Maybe SourceTypeCard
-> Maybe SourceTypeCardPresent
-> Maybe Text
-> Maybe SourceCodeVerificationFlow
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> Maybe SourceTypeEps
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe SourceTypeGiropay
-> Maybe Text
-> Maybe SourceTypeIdeal
-> Maybe SourceTypeKlarna
-> Maybe Text
-> Maybe Bool
-> Maybe Object
-> Maybe SourceTypeMultibanco
-> Maybe Text
-> Maybe PaymentIntentLastPaymentError'Source'Object'
-> Maybe PaymentIntentLastPaymentError'Source'Owner'
-> Maybe SourceTypeP24
-> Maybe SourceReceiverFlow
-> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
-> Maybe SourceRedirectFlow
-> Maybe Text
-> Maybe SourceTypeSepaDebit
-> Maybe SourceTypeSofort
-> Maybe SourceOrder
-> Maybe Text
-> Maybe Text
-> Maybe SourceTypeThreeDSecure
-> Maybe Text
-> Maybe PaymentIntentLastPaymentError'Source'Type'
-> Maybe Text
-> Maybe SourceTypeWechat
-> PaymentIntentLastPaymentError'Source'
PaymentIntentLastPaymentError'Source' Parser
  (Maybe PaymentIntentLastPaymentError'Source'Account'Variants
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAchCreditTransfer
   -> Maybe SourceTypeAchDebit
   -> Maybe SourceTypeAcssDebit
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Account'Variants)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAchCreditTransfer
      -> Maybe SourceTypeAchDebit
      -> Maybe SourceTypeAcssDebit
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Account'Variants)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"account")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAchCreditTransfer
   -> Maybe SourceTypeAchDebit
   -> Maybe SourceTypeAcssDebit
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe SourceTypeAchCreditTransfer
      -> Maybe SourceTypeAchDebit
      -> Maybe SourceTypeAcssDebit
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"account_holder_name")) Parser
  (Maybe Text
   -> Maybe SourceTypeAchCreditTransfer
   -> Maybe SourceTypeAchDebit
   -> Maybe SourceTypeAcssDebit
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe SourceTypeAchCreditTransfer
      -> Maybe SourceTypeAchDebit
      -> Maybe SourceTypeAcssDebit
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"account_holder_type")) Parser
  (Maybe SourceTypeAchCreditTransfer
   -> Maybe SourceTypeAchDebit
   -> Maybe SourceTypeAcssDebit
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeAchCreditTransfer)
-> Parser
     (Maybe SourceTypeAchDebit
      -> Maybe SourceTypeAcssDebit
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeAchCreditTransfer)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"ach_credit_transfer")) Parser
  (Maybe SourceTypeAchDebit
   -> Maybe SourceTypeAcssDebit
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeAchDebit)
-> Parser
     (Maybe SourceTypeAcssDebit
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeAchDebit)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"ach_debit")) Parser
  (Maybe SourceTypeAcssDebit
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeAcssDebit)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeAcssDebit)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"acss_debit")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"address_city")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"address_country")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"address_line1")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"address_line1_check")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"address_line2")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"address_state")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"address_zip")) Parser
  (Maybe Text
   -> Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe SourceTypeAlipay
      -> Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"address_zip_check")) Parser
  (Maybe SourceTypeAlipay
   -> Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeAlipay)
-> Parser
     (Maybe Int
      -> Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeAlipay)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"alipay")) Parser
  (Maybe Int
   -> Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Int)
-> Parser
     (Maybe SourceTypeAuBecsDebit
      -> Maybe
           [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"amount")) Parser
  (Maybe SourceTypeAuBecsDebit
   -> Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeAuBecsDebit)
-> Parser
     (Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
      -> Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeAuBecsDebit)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"au_becs_debit")) Parser
  (Maybe
     [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
   -> Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser
     (Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'])
-> Parser
     (Maybe SourceTypeBancontact
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser
     (Maybe
        [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'])
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"available_payout_methods")) Parser
  (Maybe SourceTypeBancontact
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeBancontact)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeBancontact)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"bancontact")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"bank_name")) Parser
  (Maybe Text
   -> Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe SourceTypeCard
      -> Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"brand")) Parser
  (Maybe SourceTypeCard
   -> Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeCard)
-> Parser
     (Maybe SourceTypeCardPresent
      -> Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeCard)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"card")) Parser
  (Maybe SourceTypeCardPresent
   -> Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeCardPresent)
-> Parser
     (Maybe Text
      -> Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeCardPresent)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"card_present")) Parser
  (Maybe Text
   -> Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe SourceCodeVerificationFlow
      -> Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"client_secret")) Parser
  (Maybe SourceCodeVerificationFlow
   -> Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceCodeVerificationFlow)
-> Parser
     (Maybe Text
      -> Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceCodeVerificationFlow)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"code_verification")) Parser
  (Maybe Text
   -> Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Int
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"country")) Parser
  (Maybe Int
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Int)
-> Parser
     (Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"created")) Parser
  (Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"currency")) Parser
  (Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Customer'Variants)
-> Parser
     (Maybe Text
      -> Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Customer'Variants)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"customer")) Parser
  (Maybe Text
   -> Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Bool
      -> Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"cvc_check")) Parser
  (Maybe Bool
   -> Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Bool)
-> Parser
     (Maybe Text
      -> Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"default_for_currency")) Parser
  (Maybe Text
   -> Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe SourceTypeEps
      -> Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"dynamic_last4")) Parser
  (Maybe SourceTypeEps
   -> Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeEps)
-> Parser
     (Maybe Int
      -> Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeEps)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"eps")) Parser
  (Maybe Int
   -> Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Int)
-> Parser
     (Maybe Int
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"exp_month")) Parser
  (Maybe Int
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Int)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"exp_year")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"fingerprint")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"flow")) Parser
  (Maybe Text
   -> Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe SourceTypeGiropay
      -> Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"funding")) Parser
  (Maybe SourceTypeGiropay
   -> Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeGiropay)
-> Parser
     (Maybe Text
      -> Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeGiropay)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"giropay")) Parser
  (Maybe Text
   -> Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe SourceTypeIdeal
      -> Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"id")) Parser
  (Maybe SourceTypeIdeal
   -> Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeIdeal)
-> Parser
     (Maybe SourceTypeKlarna
      -> Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeIdeal)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"ideal")) Parser
  (Maybe SourceTypeKlarna
   -> Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeKlarna)
-> Parser
     (Maybe Text
      -> Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeKlarna)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"klarna")) Parser
  (Maybe Text
   -> Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Bool
      -> Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"last4")) Parser
  (Maybe Bool
   -> Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Bool)
-> Parser
     (Maybe Object
      -> Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Bool)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"livemode")) Parser
  (Maybe Object
   -> Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Object)
-> Parser
     (Maybe SourceTypeMultibanco
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Object)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"metadata")) Parser
  (Maybe SourceTypeMultibanco
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeMultibanco)
-> Parser
     (Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeMultibanco)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"multibanco")) Parser
  (Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Object'
      -> Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"name")) Parser
  (Maybe PaymentIntentLastPaymentError'Source'Object'
   -> Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe PaymentIntentLastPaymentError'Source'Object')
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Owner'
      -> Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser (Maybe PaymentIntentLastPaymentError'Source'Object')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"object")) Parser
  (Maybe PaymentIntentLastPaymentError'Source'Owner'
   -> Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe PaymentIntentLastPaymentError'Source'Owner')
-> Parser
     (Maybe SourceTypeP24
      -> Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser (Maybe PaymentIntentLastPaymentError'Source'Owner')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"owner")) Parser
  (Maybe SourceTypeP24
   -> Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeP24)
-> Parser
     (Maybe SourceReceiverFlow
      -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeP24)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"p24")) Parser
  (Maybe SourceReceiverFlow
   -> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceReceiverFlow)
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
      -> Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceReceiverFlow)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"receiver")) Parser
  (Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
   -> Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants)
-> Parser
     (Maybe SourceRedirectFlow
      -> Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"recipient")) Parser
  (Maybe SourceRedirectFlow
   -> Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceRedirectFlow)
-> Parser
     (Maybe Text
      -> Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceRedirectFlow)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"redirect")) Parser
  (Maybe Text
   -> Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe SourceTypeSepaDebit
      -> Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"routing_number")) Parser
  (Maybe SourceTypeSepaDebit
   -> Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeSepaDebit)
-> Parser
     (Maybe SourceTypeSofort
      -> Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeSepaDebit)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"sepa_debit")) Parser
  (Maybe SourceTypeSofort
   -> Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeSofort)
-> Parser
     (Maybe SourceOrder
      -> Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeSofort)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"sofort")) Parser
  (Maybe SourceOrder
   -> Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceOrder)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceOrder)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"source_order")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"statement_descriptor")) Parser
  (Maybe Text
   -> Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe SourceTypeThreeDSecure
      -> Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"status")) Parser
  (Maybe SourceTypeThreeDSecure
   -> Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeThreeDSecure)
-> Parser
     (Maybe Text
      -> Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeThreeDSecure)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"three_d_secure")) Parser
  (Maybe Text
   -> Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Type'
      -> Maybe Text
      -> Maybe SourceTypeWechat
      -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"tokenization_method")) Parser
  (Maybe PaymentIntentLastPaymentError'Source'Type'
   -> Maybe Text
   -> Maybe SourceTypeWechat
   -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe PaymentIntentLastPaymentError'Source'Type')
-> Parser
     (Maybe Text
      -> Maybe SourceTypeWechat -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser (Maybe PaymentIntentLastPaymentError'Source'Type')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"type")) Parser
  (Maybe Text
   -> Maybe SourceTypeWechat -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe Text)
-> Parser
     (Maybe SourceTypeWechat -> PaymentIntentLastPaymentError'Source')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"usage")) Parser
  (Maybe SourceTypeWechat -> PaymentIntentLastPaymentError'Source')
-> Parser (Maybe SourceTypeWechat)
-> Parser PaymentIntentLastPaymentError'Source'
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe SourceTypeWechat)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"wechat"))

-- | Create a new 'PaymentIntentLastPaymentError'Source'' with all required fields.
mkPaymentIntentLastPaymentError'Source' :: PaymentIntentLastPaymentError'Source'
mkPaymentIntentLastPaymentError'Source' :: PaymentIntentLastPaymentError'Source'
mkPaymentIntentLastPaymentError'Source' =
  PaymentIntentLastPaymentError'Source' :: Maybe PaymentIntentLastPaymentError'Source'Account'Variants
-> Maybe Text
-> Maybe Text
-> Maybe SourceTypeAchCreditTransfer
-> Maybe SourceTypeAchDebit
-> Maybe SourceTypeAcssDebit
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe SourceTypeAlipay
-> Maybe Int
-> Maybe SourceTypeAuBecsDebit
-> Maybe
     [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
-> Maybe SourceTypeBancontact
-> Maybe Text
-> Maybe Text
-> Maybe SourceTypeCard
-> Maybe SourceTypeCardPresent
-> Maybe Text
-> Maybe SourceCodeVerificationFlow
-> Maybe Text
-> Maybe Int
-> Maybe Text
-> Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
-> Maybe Text
-> Maybe Bool
-> Maybe Text
-> Maybe SourceTypeEps
-> Maybe Int
-> Maybe Int
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe SourceTypeGiropay
-> Maybe Text
-> Maybe SourceTypeIdeal
-> Maybe SourceTypeKlarna
-> Maybe Text
-> Maybe Bool
-> Maybe Object
-> Maybe SourceTypeMultibanco
-> Maybe Text
-> Maybe PaymentIntentLastPaymentError'Source'Object'
-> Maybe PaymentIntentLastPaymentError'Source'Owner'
-> Maybe SourceTypeP24
-> Maybe SourceReceiverFlow
-> Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
-> Maybe SourceRedirectFlow
-> Maybe Text
-> Maybe SourceTypeSepaDebit
-> Maybe SourceTypeSofort
-> Maybe SourceOrder
-> Maybe Text
-> Maybe Text
-> Maybe SourceTypeThreeDSecure
-> Maybe Text
-> Maybe PaymentIntentLastPaymentError'Source'Type'
-> Maybe Text
-> Maybe SourceTypeWechat
-> PaymentIntentLastPaymentError'Source'
PaymentIntentLastPaymentError'Source'
    { paymentIntentLastPaymentError'Source'Account :: Maybe PaymentIntentLastPaymentError'Source'Account'Variants
paymentIntentLastPaymentError'Source'Account = Maybe PaymentIntentLastPaymentError'Source'Account'Variants
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AccountHolderName :: Maybe Text
paymentIntentLastPaymentError'Source'AccountHolderName = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AccountHolderType :: Maybe Text
paymentIntentLastPaymentError'Source'AccountHolderType = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AchCreditTransfer :: Maybe SourceTypeAchCreditTransfer
paymentIntentLastPaymentError'Source'AchCreditTransfer = Maybe SourceTypeAchCreditTransfer
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AchDebit :: Maybe SourceTypeAchDebit
paymentIntentLastPaymentError'Source'AchDebit = Maybe SourceTypeAchDebit
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AcssDebit :: Maybe SourceTypeAcssDebit
paymentIntentLastPaymentError'Source'AcssDebit = Maybe SourceTypeAcssDebit
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AddressCity :: Maybe Text
paymentIntentLastPaymentError'Source'AddressCity = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AddressCountry :: Maybe Text
paymentIntentLastPaymentError'Source'AddressCountry = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AddressLine1 :: Maybe Text
paymentIntentLastPaymentError'Source'AddressLine1 = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AddressLine1Check :: Maybe Text
paymentIntentLastPaymentError'Source'AddressLine1Check = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AddressLine2 :: Maybe Text
paymentIntentLastPaymentError'Source'AddressLine2 = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AddressState :: Maybe Text
paymentIntentLastPaymentError'Source'AddressState = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AddressZip :: Maybe Text
paymentIntentLastPaymentError'Source'AddressZip = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AddressZipCheck :: Maybe Text
paymentIntentLastPaymentError'Source'AddressZipCheck = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Alipay :: Maybe SourceTypeAlipay
paymentIntentLastPaymentError'Source'Alipay = Maybe SourceTypeAlipay
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Amount :: Maybe Int
paymentIntentLastPaymentError'Source'Amount = Maybe Int
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AuBecsDebit :: Maybe SourceTypeAuBecsDebit
paymentIntentLastPaymentError'Source'AuBecsDebit = Maybe SourceTypeAuBecsDebit
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'AvailablePayoutMethods :: Maybe
  [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
paymentIntentLastPaymentError'Source'AvailablePayoutMethods = Maybe
  [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Bancontact :: Maybe SourceTypeBancontact
paymentIntentLastPaymentError'Source'Bancontact = Maybe SourceTypeBancontact
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'BankName :: Maybe Text
paymentIntentLastPaymentError'Source'BankName = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Brand :: Maybe Text
paymentIntentLastPaymentError'Source'Brand = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Card :: Maybe SourceTypeCard
paymentIntentLastPaymentError'Source'Card = Maybe SourceTypeCard
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'CardPresent :: Maybe SourceTypeCardPresent
paymentIntentLastPaymentError'Source'CardPresent = Maybe SourceTypeCardPresent
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'ClientSecret :: Maybe Text
paymentIntentLastPaymentError'Source'ClientSecret = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'CodeVerification :: Maybe SourceCodeVerificationFlow
paymentIntentLastPaymentError'Source'CodeVerification = Maybe SourceCodeVerificationFlow
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Country :: Maybe Text
paymentIntentLastPaymentError'Source'Country = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Created :: Maybe Int
paymentIntentLastPaymentError'Source'Created = Maybe Int
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Currency :: Maybe Text
paymentIntentLastPaymentError'Source'Currency = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Customer :: Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
paymentIntentLastPaymentError'Source'Customer = Maybe PaymentIntentLastPaymentError'Source'Customer'Variants
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'CvcCheck :: Maybe Text
paymentIntentLastPaymentError'Source'CvcCheck = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'DefaultForCurrency :: Maybe Bool
paymentIntentLastPaymentError'Source'DefaultForCurrency = Maybe Bool
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'DynamicLast4 :: Maybe Text
paymentIntentLastPaymentError'Source'DynamicLast4 = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Eps :: Maybe SourceTypeEps
paymentIntentLastPaymentError'Source'Eps = Maybe SourceTypeEps
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'ExpMonth :: Maybe Int
paymentIntentLastPaymentError'Source'ExpMonth = Maybe Int
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'ExpYear :: Maybe Int
paymentIntentLastPaymentError'Source'ExpYear = Maybe Int
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Fingerprint :: Maybe Text
paymentIntentLastPaymentError'Source'Fingerprint = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Flow :: Maybe Text
paymentIntentLastPaymentError'Source'Flow = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Funding :: Maybe Text
paymentIntentLastPaymentError'Source'Funding = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Giropay :: Maybe SourceTypeGiropay
paymentIntentLastPaymentError'Source'Giropay = Maybe SourceTypeGiropay
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Id :: Maybe Text
paymentIntentLastPaymentError'Source'Id = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Ideal :: Maybe SourceTypeIdeal
paymentIntentLastPaymentError'Source'Ideal = Maybe SourceTypeIdeal
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Klarna :: Maybe SourceTypeKlarna
paymentIntentLastPaymentError'Source'Klarna = Maybe SourceTypeKlarna
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Last4 :: Maybe Text
paymentIntentLastPaymentError'Source'Last4 = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Livemode :: Maybe Bool
paymentIntentLastPaymentError'Source'Livemode = Maybe Bool
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Metadata :: Maybe Object
paymentIntentLastPaymentError'Source'Metadata = Maybe Object
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Multibanco :: Maybe SourceTypeMultibanco
paymentIntentLastPaymentError'Source'Multibanco = Maybe SourceTypeMultibanco
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Name :: Maybe Text
paymentIntentLastPaymentError'Source'Name = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Object :: Maybe PaymentIntentLastPaymentError'Source'Object'
paymentIntentLastPaymentError'Source'Object = Maybe PaymentIntentLastPaymentError'Source'Object'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner :: Maybe PaymentIntentLastPaymentError'Source'Owner'
paymentIntentLastPaymentError'Source'Owner = Maybe PaymentIntentLastPaymentError'Source'Owner'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'P24 :: Maybe SourceTypeP24
paymentIntentLastPaymentError'Source'P24 = Maybe SourceTypeP24
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Receiver :: Maybe SourceReceiverFlow
paymentIntentLastPaymentError'Source'Receiver = Maybe SourceReceiverFlow
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Recipient :: Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
paymentIntentLastPaymentError'Source'Recipient = Maybe PaymentIntentLastPaymentError'Source'Recipient'Variants
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Redirect :: Maybe SourceRedirectFlow
paymentIntentLastPaymentError'Source'Redirect = Maybe SourceRedirectFlow
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'RoutingNumber :: Maybe Text
paymentIntentLastPaymentError'Source'RoutingNumber = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'SepaDebit :: Maybe SourceTypeSepaDebit
paymentIntentLastPaymentError'Source'SepaDebit = Maybe SourceTypeSepaDebit
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Sofort :: Maybe SourceTypeSofort
paymentIntentLastPaymentError'Source'Sofort = Maybe SourceTypeSofort
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'SourceOrder :: Maybe SourceOrder
paymentIntentLastPaymentError'Source'SourceOrder = Maybe SourceOrder
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'StatementDescriptor :: Maybe Text
paymentIntentLastPaymentError'Source'StatementDescriptor = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Status :: Maybe Text
paymentIntentLastPaymentError'Source'Status = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'ThreeDSecure :: Maybe SourceTypeThreeDSecure
paymentIntentLastPaymentError'Source'ThreeDSecure = Maybe SourceTypeThreeDSecure
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'TokenizationMethod :: Maybe Text
paymentIntentLastPaymentError'Source'TokenizationMethod = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Type :: Maybe PaymentIntentLastPaymentError'Source'Type'
paymentIntentLastPaymentError'Source'Type = Maybe PaymentIntentLastPaymentError'Source'Type'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Usage :: Maybe Text
paymentIntentLastPaymentError'Source'Usage = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Wechat :: Maybe SourceTypeWechat
paymentIntentLastPaymentError'Source'Wechat = Maybe SourceTypeWechat
forall a. Maybe a
GHC.Maybe.Nothing
    }

-- | Defines the oneOf schema located at @components.schemas.payment_intent.properties.last_payment_error.anyOf.properties.source.anyOf.properties.account.anyOf@ in the specification.
--
-- The ID of the account that the bank account is associated with.
data PaymentIntentLastPaymentError'Source'Account'Variants
  = PaymentIntentLastPaymentError'Source'Account'Text Data.Text.Internal.Text
  | PaymentIntentLastPaymentError'Source'Account'Account Account
  deriving (Int
-> PaymentIntentLastPaymentError'Source'Account'Variants -> ShowS
[PaymentIntentLastPaymentError'Source'Account'Variants] -> ShowS
PaymentIntentLastPaymentError'Source'Account'Variants -> String
(Int
 -> PaymentIntentLastPaymentError'Source'Account'Variants -> ShowS)
-> (PaymentIntentLastPaymentError'Source'Account'Variants
    -> String)
-> ([PaymentIntentLastPaymentError'Source'Account'Variants]
    -> ShowS)
-> Show PaymentIntentLastPaymentError'Source'Account'Variants
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentLastPaymentError'Source'Account'Variants] -> ShowS
$cshowList :: [PaymentIntentLastPaymentError'Source'Account'Variants] -> ShowS
show :: PaymentIntentLastPaymentError'Source'Account'Variants -> String
$cshow :: PaymentIntentLastPaymentError'Source'Account'Variants -> String
showsPrec :: Int
-> PaymentIntentLastPaymentError'Source'Account'Variants -> ShowS
$cshowsPrec :: Int
-> PaymentIntentLastPaymentError'Source'Account'Variants -> ShowS
GHC.Show.Show, PaymentIntentLastPaymentError'Source'Account'Variants
-> PaymentIntentLastPaymentError'Source'Account'Variants -> Bool
(PaymentIntentLastPaymentError'Source'Account'Variants
 -> PaymentIntentLastPaymentError'Source'Account'Variants -> Bool)
-> (PaymentIntentLastPaymentError'Source'Account'Variants
    -> PaymentIntentLastPaymentError'Source'Account'Variants -> Bool)
-> Eq PaymentIntentLastPaymentError'Source'Account'Variants
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentLastPaymentError'Source'Account'Variants
-> PaymentIntentLastPaymentError'Source'Account'Variants -> Bool
$c/= :: PaymentIntentLastPaymentError'Source'Account'Variants
-> PaymentIntentLastPaymentError'Source'Account'Variants -> Bool
== :: PaymentIntentLastPaymentError'Source'Account'Variants
-> PaymentIntentLastPaymentError'Source'Account'Variants -> Bool
$c== :: PaymentIntentLastPaymentError'Source'Account'Variants
-> PaymentIntentLastPaymentError'Source'Account'Variants -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentLastPaymentError'Source'Account'Variants where
  toJSON :: PaymentIntentLastPaymentError'Source'Account'Variants -> Value
toJSON (PaymentIntentLastPaymentError'Source'Account'Text Text
a) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
a
  toJSON (PaymentIntentLastPaymentError'Source'Account'Account Account
a) = Account -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Account
a

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentLastPaymentError'Source'Account'Variants where
  parseJSON :: Value
-> Parser PaymentIntentLastPaymentError'Source'Account'Variants
parseJSON Value
val = case (Text -> PaymentIntentLastPaymentError'Source'Account'Variants
PaymentIntentLastPaymentError'Source'Account'Text (Text -> PaymentIntentLastPaymentError'Source'Account'Variants)
-> Result Text
-> Result PaymentIntentLastPaymentError'Source'Account'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Text
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentLastPaymentError'Source'Account'Variants
-> Result PaymentIntentLastPaymentError'Source'Account'Variants
-> Result PaymentIntentLastPaymentError'Source'Account'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> ((Account -> PaymentIntentLastPaymentError'Source'Account'Variants
PaymentIntentLastPaymentError'Source'Account'Account (Account -> PaymentIntentLastPaymentError'Source'Account'Variants)
-> Result Account
-> Result PaymentIntentLastPaymentError'Source'Account'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Account
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentLastPaymentError'Source'Account'Variants
-> Result PaymentIntentLastPaymentError'Source'Account'Variants
-> Result PaymentIntentLastPaymentError'Source'Account'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> String
-> Result PaymentIntentLastPaymentError'Source'Account'Variants
forall a. String -> Result a
Data.Aeson.Types.Internal.Error String
"No variant matched") of
    Data.Aeson.Types.Internal.Success PaymentIntentLastPaymentError'Source'Account'Variants
a -> PaymentIntentLastPaymentError'Source'Account'Variants
-> Parser PaymentIntentLastPaymentError'Source'Account'Variants
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure PaymentIntentLastPaymentError'Source'Account'Variants
a
    Data.Aeson.Types.Internal.Error String
a -> String
-> Parser PaymentIntentLastPaymentError'Source'Account'Variants
forall (m :: * -> *) a. MonadFail m => String -> m a
Control.Monad.Fail.fail String
a

-- | Defines the enum schema located at @components.schemas.payment_intent.properties.last_payment_error.anyOf.properties.source.anyOf.properties.available_payout_methods.items@ in the specification.
data PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
  = -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
    PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'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.
    PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'Typed Data.Text.Internal.Text
  | -- | Represents the JSON value @"instant"@
    PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'EnumInstant
  | -- | Represents the JSON value @"standard"@
    PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'EnumStandard
  deriving (Int
-> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> ShowS
[PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
-> ShowS
PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> String
(Int
 -> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
 -> ShowS)
-> (PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
    -> String)
-> ([PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
    -> ShowS)
-> Show
     PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
-> ShowS
$cshowList :: [PaymentIntentLastPaymentError'Source'AvailablePayoutMethods']
-> ShowS
show :: PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> String
$cshow :: PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> String
showsPrec :: Int
-> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> ShowS
$cshowsPrec :: Int
-> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> ShowS
GHC.Show.Show, PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> Bool
(PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
 -> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
 -> Bool)
-> (PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
    -> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
    -> Bool)
-> Eq PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> Bool
$c/= :: PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> Bool
== :: PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> Bool
$c== :: PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentLastPaymentError'Source'AvailablePayoutMethods' where
  toJSON :: PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> Value
toJSON (PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'Other Value
val) = Value
val
  toJSON (PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'Typed Text
val) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
val
  toJSON (PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'EnumInstant) = Value
"instant"
  toJSON (PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'EnumStandard) = Value
"standard"

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentLastPaymentError'Source'AvailablePayoutMethods' where
  parseJSON :: Value
-> Parser
     PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
parseJSON Value
val =
    PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
-> Parser
     PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure
      ( if
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"instant" -> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'EnumInstant
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"standard" -> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'EnumStandard
            | Bool
GHC.Base.otherwise -> Value
-> PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'
PaymentIntentLastPaymentError'Source'AvailablePayoutMethods'Other Value
val
      )

-- | Defines the oneOf schema located at @components.schemas.payment_intent.properties.last_payment_error.anyOf.properties.source.anyOf.properties.customer.anyOf@ in the specification.
--
-- The ID of the customer that the bank account is associated with.
data PaymentIntentLastPaymentError'Source'Customer'Variants
  = PaymentIntentLastPaymentError'Source'Customer'Text Data.Text.Internal.Text
  | PaymentIntentLastPaymentError'Source'Customer'Customer Customer
  | PaymentIntentLastPaymentError'Source'Customer'DeletedCustomer DeletedCustomer
  deriving (Int
-> PaymentIntentLastPaymentError'Source'Customer'Variants -> ShowS
[PaymentIntentLastPaymentError'Source'Customer'Variants] -> ShowS
PaymentIntentLastPaymentError'Source'Customer'Variants -> String
(Int
 -> PaymentIntentLastPaymentError'Source'Customer'Variants -> ShowS)
-> (PaymentIntentLastPaymentError'Source'Customer'Variants
    -> String)
-> ([PaymentIntentLastPaymentError'Source'Customer'Variants]
    -> ShowS)
-> Show PaymentIntentLastPaymentError'Source'Customer'Variants
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentLastPaymentError'Source'Customer'Variants] -> ShowS
$cshowList :: [PaymentIntentLastPaymentError'Source'Customer'Variants] -> ShowS
show :: PaymentIntentLastPaymentError'Source'Customer'Variants -> String
$cshow :: PaymentIntentLastPaymentError'Source'Customer'Variants -> String
showsPrec :: Int
-> PaymentIntentLastPaymentError'Source'Customer'Variants -> ShowS
$cshowsPrec :: Int
-> PaymentIntentLastPaymentError'Source'Customer'Variants -> ShowS
GHC.Show.Show, PaymentIntentLastPaymentError'Source'Customer'Variants
-> PaymentIntentLastPaymentError'Source'Customer'Variants -> Bool
(PaymentIntentLastPaymentError'Source'Customer'Variants
 -> PaymentIntentLastPaymentError'Source'Customer'Variants -> Bool)
-> (PaymentIntentLastPaymentError'Source'Customer'Variants
    -> PaymentIntentLastPaymentError'Source'Customer'Variants -> Bool)
-> Eq PaymentIntentLastPaymentError'Source'Customer'Variants
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentLastPaymentError'Source'Customer'Variants
-> PaymentIntentLastPaymentError'Source'Customer'Variants -> Bool
$c/= :: PaymentIntentLastPaymentError'Source'Customer'Variants
-> PaymentIntentLastPaymentError'Source'Customer'Variants -> Bool
== :: PaymentIntentLastPaymentError'Source'Customer'Variants
-> PaymentIntentLastPaymentError'Source'Customer'Variants -> Bool
$c== :: PaymentIntentLastPaymentError'Source'Customer'Variants
-> PaymentIntentLastPaymentError'Source'Customer'Variants -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentLastPaymentError'Source'Customer'Variants where
  toJSON :: PaymentIntentLastPaymentError'Source'Customer'Variants -> Value
toJSON (PaymentIntentLastPaymentError'Source'Customer'Text Text
a) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
a
  toJSON (PaymentIntentLastPaymentError'Source'Customer'Customer Customer
a) = Customer -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Customer
a
  toJSON (PaymentIntentLastPaymentError'Source'Customer'DeletedCustomer DeletedCustomer
a) = DeletedCustomer -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON DeletedCustomer
a

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentLastPaymentError'Source'Customer'Variants where
  parseJSON :: Value
-> Parser PaymentIntentLastPaymentError'Source'Customer'Variants
parseJSON Value
val = case (Text -> PaymentIntentLastPaymentError'Source'Customer'Variants
PaymentIntentLastPaymentError'Source'Customer'Text (Text -> PaymentIntentLastPaymentError'Source'Customer'Variants)
-> Result Text
-> Result PaymentIntentLastPaymentError'Source'Customer'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Text
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentLastPaymentError'Source'Customer'Variants
-> Result PaymentIntentLastPaymentError'Source'Customer'Variants
-> Result PaymentIntentLastPaymentError'Source'Customer'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> ((Customer -> PaymentIntentLastPaymentError'Source'Customer'Variants
PaymentIntentLastPaymentError'Source'Customer'Customer (Customer
 -> PaymentIntentLastPaymentError'Source'Customer'Variants)
-> Result Customer
-> Result PaymentIntentLastPaymentError'Source'Customer'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Customer
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentLastPaymentError'Source'Customer'Variants
-> Result PaymentIntentLastPaymentError'Source'Customer'Variants
-> Result PaymentIntentLastPaymentError'Source'Customer'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> ((DeletedCustomer
-> PaymentIntentLastPaymentError'Source'Customer'Variants
PaymentIntentLastPaymentError'Source'Customer'DeletedCustomer (DeletedCustomer
 -> PaymentIntentLastPaymentError'Source'Customer'Variants)
-> Result DeletedCustomer
-> Result PaymentIntentLastPaymentError'Source'Customer'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result DeletedCustomer
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentLastPaymentError'Source'Customer'Variants
-> Result PaymentIntentLastPaymentError'Source'Customer'Variants
-> Result PaymentIntentLastPaymentError'Source'Customer'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> String
-> Result PaymentIntentLastPaymentError'Source'Customer'Variants
forall a. String -> Result a
Data.Aeson.Types.Internal.Error String
"No variant matched")) of
    Data.Aeson.Types.Internal.Success PaymentIntentLastPaymentError'Source'Customer'Variants
a -> PaymentIntentLastPaymentError'Source'Customer'Variants
-> Parser PaymentIntentLastPaymentError'Source'Customer'Variants
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure PaymentIntentLastPaymentError'Source'Customer'Variants
a
    Data.Aeson.Types.Internal.Error String
a -> String
-> Parser PaymentIntentLastPaymentError'Source'Customer'Variants
forall (m :: * -> *) a. MonadFail m => String -> m a
Control.Monad.Fail.fail String
a

-- | Defines the enum schema located at @components.schemas.payment_intent.properties.last_payment_error.anyOf.properties.source.anyOf.properties.object@ in the specification.
--
-- String representing the object\'s type. Objects of the same type share the same value.
data PaymentIntentLastPaymentError'Source'Object'
  = -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
    PaymentIntentLastPaymentError'Source'Object'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.
    PaymentIntentLastPaymentError'Source'Object'Typed Data.Text.Internal.Text
  | -- | Represents the JSON value @"bank_account"@
    PaymentIntentLastPaymentError'Source'Object'EnumBankAccount
  deriving (Int -> PaymentIntentLastPaymentError'Source'Object' -> ShowS
[PaymentIntentLastPaymentError'Source'Object'] -> ShowS
PaymentIntentLastPaymentError'Source'Object' -> String
(Int -> PaymentIntentLastPaymentError'Source'Object' -> ShowS)
-> (PaymentIntentLastPaymentError'Source'Object' -> String)
-> ([PaymentIntentLastPaymentError'Source'Object'] -> ShowS)
-> Show PaymentIntentLastPaymentError'Source'Object'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentLastPaymentError'Source'Object'] -> ShowS
$cshowList :: [PaymentIntentLastPaymentError'Source'Object'] -> ShowS
show :: PaymentIntentLastPaymentError'Source'Object' -> String
$cshow :: PaymentIntentLastPaymentError'Source'Object' -> String
showsPrec :: Int -> PaymentIntentLastPaymentError'Source'Object' -> ShowS
$cshowsPrec :: Int -> PaymentIntentLastPaymentError'Source'Object' -> ShowS
GHC.Show.Show, PaymentIntentLastPaymentError'Source'Object'
-> PaymentIntentLastPaymentError'Source'Object' -> Bool
(PaymentIntentLastPaymentError'Source'Object'
 -> PaymentIntentLastPaymentError'Source'Object' -> Bool)
-> (PaymentIntentLastPaymentError'Source'Object'
    -> PaymentIntentLastPaymentError'Source'Object' -> Bool)
-> Eq PaymentIntentLastPaymentError'Source'Object'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentLastPaymentError'Source'Object'
-> PaymentIntentLastPaymentError'Source'Object' -> Bool
$c/= :: PaymentIntentLastPaymentError'Source'Object'
-> PaymentIntentLastPaymentError'Source'Object' -> Bool
== :: PaymentIntentLastPaymentError'Source'Object'
-> PaymentIntentLastPaymentError'Source'Object' -> Bool
$c== :: PaymentIntentLastPaymentError'Source'Object'
-> PaymentIntentLastPaymentError'Source'Object' -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentLastPaymentError'Source'Object' where
  toJSON :: PaymentIntentLastPaymentError'Source'Object' -> Value
toJSON (PaymentIntentLastPaymentError'Source'Object'Other Value
val) = Value
val
  toJSON (PaymentIntentLastPaymentError'Source'Object'Typed Text
val) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
val
  toJSON (PaymentIntentLastPaymentError'Source'Object'
PaymentIntentLastPaymentError'Source'Object'EnumBankAccount) = Value
"bank_account"

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentLastPaymentError'Source'Object' where
  parseJSON :: Value -> Parser PaymentIntentLastPaymentError'Source'Object'
parseJSON Value
val =
    PaymentIntentLastPaymentError'Source'Object'
-> Parser PaymentIntentLastPaymentError'Source'Object'
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure
      ( if
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"bank_account" -> PaymentIntentLastPaymentError'Source'Object'
PaymentIntentLastPaymentError'Source'Object'EnumBankAccount
            | Bool
GHC.Base.otherwise -> Value -> PaymentIntentLastPaymentError'Source'Object'
PaymentIntentLastPaymentError'Source'Object'Other Value
val
      )

-- | Defines the object schema located at @components.schemas.payment_intent.properties.last_payment_error.anyOf.properties.source.anyOf.properties.owner.anyOf@ in the specification.
--
-- Information about the owner of the payment instrument that may be used or required by particular source types.
data PaymentIntentLastPaymentError'Source'Owner' = PaymentIntentLastPaymentError'Source'Owner'
  { -- | address: Owner\'s address.
    PaymentIntentLastPaymentError'Source'Owner'
-> Maybe PaymentIntentLastPaymentError'Source'Owner'Address'
paymentIntentLastPaymentError'Source'Owner'Address :: (GHC.Maybe.Maybe PaymentIntentLastPaymentError'Source'Owner'Address'),
    -- | email: Owner\'s email address.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Email :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | name: Owner\'s full name.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Name :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | phone: Owner\'s phone number (including extension).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Phone :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | verified_address: Verified owner\'s address. Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.
    PaymentIntentLastPaymentError'Source'Owner'
-> Maybe
     PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress :: (GHC.Maybe.Maybe PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'),
    -- | verified_email: Verified owner\'s email address. Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedEmail :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | verified_name: Verified owner\'s full name. Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedName :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | verified_phone: Verified owner\'s phone number (including extension). Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedPhone :: (GHC.Maybe.Maybe Data.Text.Internal.Text)
  }
  deriving
    ( Int -> PaymentIntentLastPaymentError'Source'Owner' -> ShowS
[PaymentIntentLastPaymentError'Source'Owner'] -> ShowS
PaymentIntentLastPaymentError'Source'Owner' -> String
(Int -> PaymentIntentLastPaymentError'Source'Owner' -> ShowS)
-> (PaymentIntentLastPaymentError'Source'Owner' -> String)
-> ([PaymentIntentLastPaymentError'Source'Owner'] -> ShowS)
-> Show PaymentIntentLastPaymentError'Source'Owner'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentLastPaymentError'Source'Owner'] -> ShowS
$cshowList :: [PaymentIntentLastPaymentError'Source'Owner'] -> ShowS
show :: PaymentIntentLastPaymentError'Source'Owner' -> String
$cshow :: PaymentIntentLastPaymentError'Source'Owner' -> String
showsPrec :: Int -> PaymentIntentLastPaymentError'Source'Owner' -> ShowS
$cshowsPrec :: Int -> PaymentIntentLastPaymentError'Source'Owner' -> ShowS
GHC.Show.Show,
      PaymentIntentLastPaymentError'Source'Owner'
-> PaymentIntentLastPaymentError'Source'Owner' -> Bool
(PaymentIntentLastPaymentError'Source'Owner'
 -> PaymentIntentLastPaymentError'Source'Owner' -> Bool)
-> (PaymentIntentLastPaymentError'Source'Owner'
    -> PaymentIntentLastPaymentError'Source'Owner' -> Bool)
-> Eq PaymentIntentLastPaymentError'Source'Owner'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentLastPaymentError'Source'Owner'
-> PaymentIntentLastPaymentError'Source'Owner' -> Bool
$c/= :: PaymentIntentLastPaymentError'Source'Owner'
-> PaymentIntentLastPaymentError'Source'Owner' -> Bool
== :: PaymentIntentLastPaymentError'Source'Owner'
-> PaymentIntentLastPaymentError'Source'Owner' -> Bool
$c== :: PaymentIntentLastPaymentError'Source'Owner'
-> PaymentIntentLastPaymentError'Source'Owner' -> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentLastPaymentError'Source'Owner' where
  toJSON :: PaymentIntentLastPaymentError'Source'Owner' -> Value
toJSON PaymentIntentLastPaymentError'Source'Owner'
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"address" Text
-> Maybe PaymentIntentLastPaymentError'Source'Owner'Address'
-> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'
-> Maybe PaymentIntentLastPaymentError'Source'Owner'Address'
paymentIntentLastPaymentError'Source'Owner'Address PaymentIntentLastPaymentError'Source'Owner'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"email" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Email PaymentIntentLastPaymentError'Source'Owner'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"name" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Name PaymentIntentLastPaymentError'Source'Owner'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"phone" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Phone PaymentIntentLastPaymentError'Source'Owner'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"verified_address" Text
-> Maybe
     PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'
-> Maybe
     PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress PaymentIntentLastPaymentError'Source'Owner'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"verified_email" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedEmail PaymentIntentLastPaymentError'Source'Owner'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"verified_name" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedName PaymentIntentLastPaymentError'Source'Owner'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"verified_phone" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedPhone PaymentIntentLastPaymentError'Source'Owner'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: PaymentIntentLastPaymentError'Source'Owner' -> Encoding
toEncoding PaymentIntentLastPaymentError'Source'Owner'
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"address" Text
-> Maybe PaymentIntentLastPaymentError'Source'Owner'Address'
-> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'
-> Maybe PaymentIntentLastPaymentError'Source'Owner'Address'
paymentIntentLastPaymentError'Source'Owner'Address PaymentIntentLastPaymentError'Source'Owner'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"email" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Email PaymentIntentLastPaymentError'Source'Owner'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"name" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Name PaymentIntentLastPaymentError'Source'Owner'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"phone" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Phone PaymentIntentLastPaymentError'Source'Owner'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"verified_address" Text
-> Maybe
     PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'
-> Maybe
     PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress PaymentIntentLastPaymentError'Source'Owner'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"verified_email" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedEmail PaymentIntentLastPaymentError'Source'Owner'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"verified_name" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedName PaymentIntentLastPaymentError'Source'Owner'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"verified_phone" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedPhone PaymentIntentLastPaymentError'Source'Owner'
obj))))))))

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentLastPaymentError'Source'Owner' where
  parseJSON :: Value -> Parser PaymentIntentLastPaymentError'Source'Owner'
parseJSON = String
-> (Object -> Parser PaymentIntentLastPaymentError'Source'Owner')
-> Value
-> Parser PaymentIntentLastPaymentError'Source'Owner'
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"PaymentIntentLastPaymentError'Source'Owner'" (\Object
obj -> ((((((((Maybe PaymentIntentLastPaymentError'Source'Owner'Address'
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe
      PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> PaymentIntentLastPaymentError'Source'Owner')
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Owner'Address'
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe
           PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner')
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure Maybe PaymentIntentLastPaymentError'Source'Owner'Address'
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe
     PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> PaymentIntentLastPaymentError'Source'Owner'
PaymentIntentLastPaymentError'Source'Owner' Parser
  (Maybe PaymentIntentLastPaymentError'Source'Owner'Address'
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe
        PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner')
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Owner'Address')
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe
           PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Owner'Address')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"address")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe
        PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe
           PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"email")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe
        PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe
           PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"name")) Parser
  (Maybe Text
   -> Maybe
        PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner')
-> Parser (Maybe Text)
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"phone")) Parser
  (Maybe PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner')
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser
     (Maybe PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"verified_address")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text -> PaymentIntentLastPaymentError'Source'Owner')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"verified_email")) Parser
  (Maybe Text
   -> Maybe Text -> PaymentIntentLastPaymentError'Source'Owner')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text -> PaymentIntentLastPaymentError'Source'Owner')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"verified_name")) Parser (Maybe Text -> PaymentIntentLastPaymentError'Source'Owner')
-> Parser (Maybe Text)
-> Parser PaymentIntentLastPaymentError'Source'Owner'
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"verified_phone"))

-- | Create a new 'PaymentIntentLastPaymentError'Source'Owner'' with all required fields.
mkPaymentIntentLastPaymentError'Source'Owner' :: PaymentIntentLastPaymentError'Source'Owner'
mkPaymentIntentLastPaymentError'Source'Owner' :: PaymentIntentLastPaymentError'Source'Owner'
mkPaymentIntentLastPaymentError'Source'Owner' =
  PaymentIntentLastPaymentError'Source'Owner' :: Maybe PaymentIntentLastPaymentError'Source'Owner'Address'
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe
     PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> PaymentIntentLastPaymentError'Source'Owner'
PaymentIntentLastPaymentError'Source'Owner'
    { paymentIntentLastPaymentError'Source'Owner'Address :: Maybe PaymentIntentLastPaymentError'Source'Owner'Address'
paymentIntentLastPaymentError'Source'Owner'Address = Maybe PaymentIntentLastPaymentError'Source'Owner'Address'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'Email :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'Email = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'Name :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'Name = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'Phone :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'Phone = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'VerifiedAddress :: Maybe PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress = Maybe PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'VerifiedEmail :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedEmail = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'VerifiedName :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedName = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'VerifiedPhone :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedPhone = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing
    }

-- | Defines the object schema located at @components.schemas.payment_intent.properties.last_payment_error.anyOf.properties.source.anyOf.properties.owner.anyOf.properties.address.anyOf@ in the specification.
--
-- Owner\\\'s address.
data PaymentIntentLastPaymentError'Source'Owner'Address' = PaymentIntentLastPaymentError'Source'Owner'Address'
  { -- | city: City, district, suburb, town, or village.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'City :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | country: Two-letter country code ([ISO 3166-1 alpha-2](https:\/\/en.wikipedia.org\/wiki\/ISO_3166-1_alpha-2)).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'Country :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | line1: Address line 1 (e.g., street, PO Box, or company name).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'Line1 :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | line2: Address line 2 (e.g., apartment, suite, unit, or building).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'Line2 :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | postal_code: ZIP or postal code.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'PostalCode :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | state: State, county, province, or region.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'State :: (GHC.Maybe.Maybe Data.Text.Internal.Text)
  }
  deriving
    ( Int -> PaymentIntentLastPaymentError'Source'Owner'Address' -> ShowS
[PaymentIntentLastPaymentError'Source'Owner'Address'] -> ShowS
PaymentIntentLastPaymentError'Source'Owner'Address' -> String
(Int
 -> PaymentIntentLastPaymentError'Source'Owner'Address' -> ShowS)
-> (PaymentIntentLastPaymentError'Source'Owner'Address' -> String)
-> ([PaymentIntentLastPaymentError'Source'Owner'Address'] -> ShowS)
-> Show PaymentIntentLastPaymentError'Source'Owner'Address'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentLastPaymentError'Source'Owner'Address'] -> ShowS
$cshowList :: [PaymentIntentLastPaymentError'Source'Owner'Address'] -> ShowS
show :: PaymentIntentLastPaymentError'Source'Owner'Address' -> String
$cshow :: PaymentIntentLastPaymentError'Source'Owner'Address' -> String
showsPrec :: Int -> PaymentIntentLastPaymentError'Source'Owner'Address' -> ShowS
$cshowsPrec :: Int -> PaymentIntentLastPaymentError'Source'Owner'Address' -> ShowS
GHC.Show.Show,
      PaymentIntentLastPaymentError'Source'Owner'Address'
-> PaymentIntentLastPaymentError'Source'Owner'Address' -> Bool
(PaymentIntentLastPaymentError'Source'Owner'Address'
 -> PaymentIntentLastPaymentError'Source'Owner'Address' -> Bool)
-> (PaymentIntentLastPaymentError'Source'Owner'Address'
    -> PaymentIntentLastPaymentError'Source'Owner'Address' -> Bool)
-> Eq PaymentIntentLastPaymentError'Source'Owner'Address'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentLastPaymentError'Source'Owner'Address'
-> PaymentIntentLastPaymentError'Source'Owner'Address' -> Bool
$c/= :: PaymentIntentLastPaymentError'Source'Owner'Address'
-> PaymentIntentLastPaymentError'Source'Owner'Address' -> Bool
== :: PaymentIntentLastPaymentError'Source'Owner'Address'
-> PaymentIntentLastPaymentError'Source'Owner'Address' -> Bool
$c== :: PaymentIntentLastPaymentError'Source'Owner'Address'
-> PaymentIntentLastPaymentError'Source'Owner'Address' -> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentLastPaymentError'Source'Owner'Address' where
  toJSON :: PaymentIntentLastPaymentError'Source'Owner'Address' -> Value
toJSON PaymentIntentLastPaymentError'Source'Owner'Address'
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"city" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'City PaymentIntentLastPaymentError'Source'Owner'Address'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"country" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'Country PaymentIntentLastPaymentError'Source'Owner'Address'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"line1" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'Line1 PaymentIntentLastPaymentError'Source'Owner'Address'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"line2" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'Line2 PaymentIntentLastPaymentError'Source'Owner'Address'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"postal_code" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'PostalCode PaymentIntentLastPaymentError'Source'Owner'Address'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"state" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'State PaymentIntentLastPaymentError'Source'Owner'Address'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: PaymentIntentLastPaymentError'Source'Owner'Address' -> Encoding
toEncoding PaymentIntentLastPaymentError'Source'Owner'Address'
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"city" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'City PaymentIntentLastPaymentError'Source'Owner'Address'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"country" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'Country PaymentIntentLastPaymentError'Source'Owner'Address'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"line1" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'Line1 PaymentIntentLastPaymentError'Source'Owner'Address'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"line2" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'Line2 PaymentIntentLastPaymentError'Source'Owner'Address'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"postal_code" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'PostalCode PaymentIntentLastPaymentError'Source'Owner'Address'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"state" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'Address' -> Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'State PaymentIntentLastPaymentError'Source'Owner'Address'
obj))))))

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentLastPaymentError'Source'Owner'Address' where
  parseJSON :: Value -> Parser PaymentIntentLastPaymentError'Source'Owner'Address'
parseJSON = String
-> (Object
    -> Parser PaymentIntentLastPaymentError'Source'Owner'Address')
-> Value
-> Parser PaymentIntentLastPaymentError'Source'Owner'Address'
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"PaymentIntentLastPaymentError'Source'Owner'Address'" (\Object
obj -> ((((((Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> PaymentIntentLastPaymentError'Source'Owner'Address')
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner'Address')
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> PaymentIntentLastPaymentError'Source'Owner'Address'
PaymentIntentLastPaymentError'Source'Owner'Address' Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner'Address')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner'Address')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"city")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner'Address')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner'Address')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"country")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner'Address')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner'Address')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"line1")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner'Address')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner'Address')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"line2")) Parser
  (Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner'Address')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text -> PaymentIntentLastPaymentError'Source'Owner'Address')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"postal_code")) Parser
  (Maybe Text -> PaymentIntentLastPaymentError'Source'Owner'Address')
-> Parser (Maybe Text)
-> Parser PaymentIntentLastPaymentError'Source'Owner'Address'
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"state"))

-- | Create a new 'PaymentIntentLastPaymentError'Source'Owner'Address'' with all required fields.
mkPaymentIntentLastPaymentError'Source'Owner'Address' :: PaymentIntentLastPaymentError'Source'Owner'Address'
mkPaymentIntentLastPaymentError'Source'Owner'Address' :: PaymentIntentLastPaymentError'Source'Owner'Address'
mkPaymentIntentLastPaymentError'Source'Owner'Address' =
  PaymentIntentLastPaymentError'Source'Owner'Address' :: Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> PaymentIntentLastPaymentError'Source'Owner'Address'
PaymentIntentLastPaymentError'Source'Owner'Address'
    { paymentIntentLastPaymentError'Source'Owner'Address'City :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'City = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'Address'Country :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'Country = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'Address'Line1 :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'Line1 = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'Address'Line2 :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'Line2 = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'Address'PostalCode :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'PostalCode = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'Address'State :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'Address'State = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing
    }

-- | Defines the object schema located at @components.schemas.payment_intent.properties.last_payment_error.anyOf.properties.source.anyOf.properties.owner.anyOf.properties.verified_address.anyOf@ in the specification.
--
-- Verified owner\\\'s address. Verified values are verified or provided by the payment method directly (and if supported) at the time of authorization or settlement. They cannot be set or mutated.
data PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress' = PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
  { -- | city: City, district, suburb, town, or village.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'City :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | country: Two-letter country code ([ISO 3166-1 alpha-2](https:\/\/en.wikipedia.org\/wiki\/ISO_3166-1_alpha-2)).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Country :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | line1: Address line 1 (e.g., street, PO Box, or company name).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Line1 :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | line2: Address line 2 (e.g., apartment, suite, unit, or building).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Line2 :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | postal_code: ZIP or postal code.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'PostalCode :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | state: State, county, province, or region.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'State :: (GHC.Maybe.Maybe Data.Text.Internal.Text)
  }
  deriving
    ( Int
-> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> ShowS
[PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress']
-> ShowS
PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> String
(Int
 -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
 -> ShowS)
-> (PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
    -> String)
-> ([PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress']
    -> ShowS)
-> Show PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress']
-> ShowS
$cshowList :: [PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress']
-> ShowS
show :: PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> String
$cshow :: PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> String
showsPrec :: Int
-> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> ShowS
$cshowsPrec :: Int
-> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> ShowS
GHC.Show.Show,
      PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Bool
(PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
 -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
 -> Bool)
-> (PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
    -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
    -> Bool)
-> Eq PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Bool
$c/= :: PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Bool
== :: PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Bool
$c== :: PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress' where
  toJSON :: PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Value
toJSON PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"city" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'City PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"country" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Country PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"line1" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Line1 PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"line2" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Line2 PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"postal_code" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'PostalCode PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"state" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'State PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Encoding
toEncoding PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"city" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'City PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"country" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Country PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"line1" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Line1 PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"line2" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Line2 PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"postal_code" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'PostalCode PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"state" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
-> Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'State PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
obj))))))

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress' where
  parseJSON :: Value
-> Parser
     PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
parseJSON = String
-> (Object
    -> Parser
         PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
-> Value
-> Parser
     PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'" (\Object
obj -> ((((((Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress' Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"city")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"country")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"line1")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"line2")) Parser
  (Maybe Text
   -> Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text
      -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"postal_code")) Parser
  (Maybe Text
   -> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress')
-> Parser (Maybe Text)
-> Parser
     PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"state"))

-- | Create a new 'PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'' with all required fields.
mkPaymentIntentLastPaymentError'Source'Owner'VerifiedAddress' :: PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
mkPaymentIntentLastPaymentError'Source'Owner'VerifiedAddress' :: PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
mkPaymentIntentLastPaymentError'Source'Owner'VerifiedAddress' =
  PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress' :: Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
PaymentIntentLastPaymentError'Source'Owner'VerifiedAddress'
    { paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'City :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'City = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Country :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Country = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Line1 :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Line1 = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Line2 :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'Line2 = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'PostalCode :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'PostalCode = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'State :: Maybe Text
paymentIntentLastPaymentError'Source'Owner'VerifiedAddress'State = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing
    }

-- | Defines the oneOf schema located at @components.schemas.payment_intent.properties.last_payment_error.anyOf.properties.source.anyOf.properties.recipient.anyOf@ in the specification.
--
-- The recipient that this card belongs to. This attribute will not be in the card object if the card belongs to a customer or account instead.
data PaymentIntentLastPaymentError'Source'Recipient'Variants
  = PaymentIntentLastPaymentError'Source'Recipient'Text Data.Text.Internal.Text
  | PaymentIntentLastPaymentError'Source'Recipient'Recipient Recipient
  deriving (Int
-> PaymentIntentLastPaymentError'Source'Recipient'Variants -> ShowS
[PaymentIntentLastPaymentError'Source'Recipient'Variants] -> ShowS
PaymentIntentLastPaymentError'Source'Recipient'Variants -> String
(Int
 -> PaymentIntentLastPaymentError'Source'Recipient'Variants
 -> ShowS)
-> (PaymentIntentLastPaymentError'Source'Recipient'Variants
    -> String)
-> ([PaymentIntentLastPaymentError'Source'Recipient'Variants]
    -> ShowS)
-> Show PaymentIntentLastPaymentError'Source'Recipient'Variants
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentLastPaymentError'Source'Recipient'Variants] -> ShowS
$cshowList :: [PaymentIntentLastPaymentError'Source'Recipient'Variants] -> ShowS
show :: PaymentIntentLastPaymentError'Source'Recipient'Variants -> String
$cshow :: PaymentIntentLastPaymentError'Source'Recipient'Variants -> String
showsPrec :: Int
-> PaymentIntentLastPaymentError'Source'Recipient'Variants -> ShowS
$cshowsPrec :: Int
-> PaymentIntentLastPaymentError'Source'Recipient'Variants -> ShowS
GHC.Show.Show, PaymentIntentLastPaymentError'Source'Recipient'Variants
-> PaymentIntentLastPaymentError'Source'Recipient'Variants -> Bool
(PaymentIntentLastPaymentError'Source'Recipient'Variants
 -> PaymentIntentLastPaymentError'Source'Recipient'Variants -> Bool)
-> (PaymentIntentLastPaymentError'Source'Recipient'Variants
    -> PaymentIntentLastPaymentError'Source'Recipient'Variants -> Bool)
-> Eq PaymentIntentLastPaymentError'Source'Recipient'Variants
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentLastPaymentError'Source'Recipient'Variants
-> PaymentIntentLastPaymentError'Source'Recipient'Variants -> Bool
$c/= :: PaymentIntentLastPaymentError'Source'Recipient'Variants
-> PaymentIntentLastPaymentError'Source'Recipient'Variants -> Bool
== :: PaymentIntentLastPaymentError'Source'Recipient'Variants
-> PaymentIntentLastPaymentError'Source'Recipient'Variants -> Bool
$c== :: PaymentIntentLastPaymentError'Source'Recipient'Variants
-> PaymentIntentLastPaymentError'Source'Recipient'Variants -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentLastPaymentError'Source'Recipient'Variants where
  toJSON :: PaymentIntentLastPaymentError'Source'Recipient'Variants -> Value
toJSON (PaymentIntentLastPaymentError'Source'Recipient'Text Text
a) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
a
  toJSON (PaymentIntentLastPaymentError'Source'Recipient'Recipient Recipient
a) = Recipient -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Recipient
a

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentLastPaymentError'Source'Recipient'Variants where
  parseJSON :: Value
-> Parser PaymentIntentLastPaymentError'Source'Recipient'Variants
parseJSON Value
val = case (Text -> PaymentIntentLastPaymentError'Source'Recipient'Variants
PaymentIntentLastPaymentError'Source'Recipient'Text (Text -> PaymentIntentLastPaymentError'Source'Recipient'Variants)
-> Result Text
-> Result PaymentIntentLastPaymentError'Source'Recipient'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Text
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentLastPaymentError'Source'Recipient'Variants
-> Result PaymentIntentLastPaymentError'Source'Recipient'Variants
-> Result PaymentIntentLastPaymentError'Source'Recipient'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> ((Recipient
-> PaymentIntentLastPaymentError'Source'Recipient'Variants
PaymentIntentLastPaymentError'Source'Recipient'Recipient (Recipient
 -> PaymentIntentLastPaymentError'Source'Recipient'Variants)
-> Result Recipient
-> Result PaymentIntentLastPaymentError'Source'Recipient'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Recipient
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentLastPaymentError'Source'Recipient'Variants
-> Result PaymentIntentLastPaymentError'Source'Recipient'Variants
-> Result PaymentIntentLastPaymentError'Source'Recipient'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> String
-> Result PaymentIntentLastPaymentError'Source'Recipient'Variants
forall a. String -> Result a
Data.Aeson.Types.Internal.Error String
"No variant matched") of
    Data.Aeson.Types.Internal.Success PaymentIntentLastPaymentError'Source'Recipient'Variants
a -> PaymentIntentLastPaymentError'Source'Recipient'Variants
-> Parser PaymentIntentLastPaymentError'Source'Recipient'Variants
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure PaymentIntentLastPaymentError'Source'Recipient'Variants
a
    Data.Aeson.Types.Internal.Error String
a -> String
-> Parser PaymentIntentLastPaymentError'Source'Recipient'Variants
forall (m :: * -> *) a. MonadFail m => String -> m a
Control.Monad.Fail.fail String
a

-- | Defines the enum schema located at @components.schemas.payment_intent.properties.last_payment_error.anyOf.properties.source.anyOf.properties.type@ in the specification.
--
-- The \`type\` of the source. The \`type\` is a payment method, one of \`ach_credit_transfer\`, \`ach_debit\`, \`alipay\`, \`bancontact\`, \`card\`, \`card_present\`, \`eps\`, \`giropay\`, \`ideal\`, \`multibanco\`, \`klarna\`, \`p24\`, \`sepa_debit\`, \`sofort\`, \`three_d_secure\`, or \`wechat\`. An additional hash is included on the source with a name matching this value. It contains additional information specific to the [payment method](https:\/\/stripe.com\/docs\/sources) used.
data PaymentIntentLastPaymentError'Source'Type'
  = -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
    PaymentIntentLastPaymentError'Source'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.
    PaymentIntentLastPaymentError'Source'Type'Typed Data.Text.Internal.Text
  | -- | Represents the JSON value @"ach_credit_transfer"@
    PaymentIntentLastPaymentError'Source'Type'EnumAchCreditTransfer
  | -- | Represents the JSON value @"ach_debit"@
    PaymentIntentLastPaymentError'Source'Type'EnumAchDebit
  | -- | Represents the JSON value @"acss_debit"@
    PaymentIntentLastPaymentError'Source'Type'EnumAcssDebit
  | -- | Represents the JSON value @"alipay"@
    PaymentIntentLastPaymentError'Source'Type'EnumAlipay
  | -- | Represents the JSON value @"au_becs_debit"@
    PaymentIntentLastPaymentError'Source'Type'EnumAuBecsDebit
  | -- | Represents the JSON value @"bancontact"@
    PaymentIntentLastPaymentError'Source'Type'EnumBancontact
  | -- | Represents the JSON value @"card"@
    PaymentIntentLastPaymentError'Source'Type'EnumCard
  | -- | Represents the JSON value @"card_present"@
    PaymentIntentLastPaymentError'Source'Type'EnumCardPresent
  | -- | Represents the JSON value @"eps"@
    PaymentIntentLastPaymentError'Source'Type'EnumEps
  | -- | Represents the JSON value @"giropay"@
    PaymentIntentLastPaymentError'Source'Type'EnumGiropay
  | -- | Represents the JSON value @"ideal"@
    PaymentIntentLastPaymentError'Source'Type'EnumIdeal
  | -- | Represents the JSON value @"klarna"@
    PaymentIntentLastPaymentError'Source'Type'EnumKlarna
  | -- | Represents the JSON value @"multibanco"@
    PaymentIntentLastPaymentError'Source'Type'EnumMultibanco
  | -- | Represents the JSON value @"p24"@
    PaymentIntentLastPaymentError'Source'Type'EnumP24
  | -- | Represents the JSON value @"sepa_debit"@
    PaymentIntentLastPaymentError'Source'Type'EnumSepaDebit
  | -- | Represents the JSON value @"sofort"@
    PaymentIntentLastPaymentError'Source'Type'EnumSofort
  | -- | Represents the JSON value @"three_d_secure"@
    PaymentIntentLastPaymentError'Source'Type'EnumThreeDSecure
  | -- | Represents the JSON value @"wechat"@
    PaymentIntentLastPaymentError'Source'Type'EnumWechat
  deriving (Int -> PaymentIntentLastPaymentError'Source'Type' -> ShowS
[PaymentIntentLastPaymentError'Source'Type'] -> ShowS
PaymentIntentLastPaymentError'Source'Type' -> String
(Int -> PaymentIntentLastPaymentError'Source'Type' -> ShowS)
-> (PaymentIntentLastPaymentError'Source'Type' -> String)
-> ([PaymentIntentLastPaymentError'Source'Type'] -> ShowS)
-> Show PaymentIntentLastPaymentError'Source'Type'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentLastPaymentError'Source'Type'] -> ShowS
$cshowList :: [PaymentIntentLastPaymentError'Source'Type'] -> ShowS
show :: PaymentIntentLastPaymentError'Source'Type' -> String
$cshow :: PaymentIntentLastPaymentError'Source'Type' -> String
showsPrec :: Int -> PaymentIntentLastPaymentError'Source'Type' -> ShowS
$cshowsPrec :: Int -> PaymentIntentLastPaymentError'Source'Type' -> ShowS
GHC.Show.Show, PaymentIntentLastPaymentError'Source'Type'
-> PaymentIntentLastPaymentError'Source'Type' -> Bool
(PaymentIntentLastPaymentError'Source'Type'
 -> PaymentIntentLastPaymentError'Source'Type' -> Bool)
-> (PaymentIntentLastPaymentError'Source'Type'
    -> PaymentIntentLastPaymentError'Source'Type' -> Bool)
-> Eq PaymentIntentLastPaymentError'Source'Type'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentLastPaymentError'Source'Type'
-> PaymentIntentLastPaymentError'Source'Type' -> Bool
$c/= :: PaymentIntentLastPaymentError'Source'Type'
-> PaymentIntentLastPaymentError'Source'Type' -> Bool
== :: PaymentIntentLastPaymentError'Source'Type'
-> PaymentIntentLastPaymentError'Source'Type' -> Bool
$c== :: PaymentIntentLastPaymentError'Source'Type'
-> PaymentIntentLastPaymentError'Source'Type' -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentLastPaymentError'Source'Type' where
  toJSON :: PaymentIntentLastPaymentError'Source'Type' -> Value
toJSON (PaymentIntentLastPaymentError'Source'Type'Other Value
val) = Value
val
  toJSON (PaymentIntentLastPaymentError'Source'Type'Typed Text
val) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
val
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumAchCreditTransfer) = Value
"ach_credit_transfer"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumAchDebit) = Value
"ach_debit"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumAcssDebit) = Value
"acss_debit"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumAlipay) = Value
"alipay"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumAuBecsDebit) = Value
"au_becs_debit"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumBancontact) = Value
"bancontact"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumCard) = Value
"card"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumCardPresent) = Value
"card_present"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumEps) = Value
"eps"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumGiropay) = Value
"giropay"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumIdeal) = Value
"ideal"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumKlarna) = Value
"klarna"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumMultibanco) = Value
"multibanco"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumP24) = Value
"p24"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumSepaDebit) = Value
"sepa_debit"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumSofort) = Value
"sofort"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumThreeDSecure) = Value
"three_d_secure"
  toJSON (PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumWechat) = Value
"wechat"

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentLastPaymentError'Source'Type' where
  parseJSON :: Value -> Parser PaymentIntentLastPaymentError'Source'Type'
parseJSON Value
val =
    PaymentIntentLastPaymentError'Source'Type'
-> Parser PaymentIntentLastPaymentError'Source'Type'
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure
      ( if
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"ach_credit_transfer" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumAchCreditTransfer
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"ach_debit" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumAchDebit
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"acss_debit" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumAcssDebit
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"alipay" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumAlipay
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"au_becs_debit" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumAuBecsDebit
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"bancontact" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumBancontact
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"card" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumCard
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"card_present" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumCardPresent
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"eps" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumEps
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"giropay" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumGiropay
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"ideal" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumIdeal
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"klarna" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumKlarna
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"multibanco" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumMultibanco
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"p24" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumP24
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"sepa_debit" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumSepaDebit
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"sofort" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumSofort
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"three_d_secure" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumThreeDSecure
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"wechat" -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'EnumWechat
            | Bool
GHC.Base.otherwise -> Value -> PaymentIntentLastPaymentError'Source'Type'
PaymentIntentLastPaymentError'Source'Type'Other Value
val
      )

-- | Defines the enum schema located at @components.schemas.payment_intent.properties.last_payment_error.anyOf.properties.type@ in the specification.
--
-- The type of error returned. One of \`api_connection_error\`, \`api_error\`, \`authentication_error\`, \`card_error\`, \`idempotency_error\`, \`invalid_request_error\`, or \`rate_limit_error\`
data PaymentIntentLastPaymentError'Type'
  = -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
    PaymentIntentLastPaymentError'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.
    PaymentIntentLastPaymentError'Type'Typed Data.Text.Internal.Text
  | -- | Represents the JSON value @"api_connection_error"@
    PaymentIntentLastPaymentError'Type'EnumApiConnectionError
  | -- | Represents the JSON value @"api_error"@
    PaymentIntentLastPaymentError'Type'EnumApiError
  | -- | Represents the JSON value @"authentication_error"@
    PaymentIntentLastPaymentError'Type'EnumAuthenticationError
  | -- | Represents the JSON value @"card_error"@
    PaymentIntentLastPaymentError'Type'EnumCardError
  | -- | Represents the JSON value @"idempotency_error"@
    PaymentIntentLastPaymentError'Type'EnumIdempotencyError
  | -- | Represents the JSON value @"invalid_request_error"@
    PaymentIntentLastPaymentError'Type'EnumInvalidRequestError
  | -- | Represents the JSON value @"rate_limit_error"@
    PaymentIntentLastPaymentError'Type'EnumRateLimitError
  deriving (Int -> PaymentIntentLastPaymentError'Type' -> ShowS
[PaymentIntentLastPaymentError'Type'] -> ShowS
PaymentIntentLastPaymentError'Type' -> String
(Int -> PaymentIntentLastPaymentError'Type' -> ShowS)
-> (PaymentIntentLastPaymentError'Type' -> String)
-> ([PaymentIntentLastPaymentError'Type'] -> ShowS)
-> Show PaymentIntentLastPaymentError'Type'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentLastPaymentError'Type'] -> ShowS
$cshowList :: [PaymentIntentLastPaymentError'Type'] -> ShowS
show :: PaymentIntentLastPaymentError'Type' -> String
$cshow :: PaymentIntentLastPaymentError'Type' -> String
showsPrec :: Int -> PaymentIntentLastPaymentError'Type' -> ShowS
$cshowsPrec :: Int -> PaymentIntentLastPaymentError'Type' -> ShowS
GHC.Show.Show, PaymentIntentLastPaymentError'Type'
-> PaymentIntentLastPaymentError'Type' -> Bool
(PaymentIntentLastPaymentError'Type'
 -> PaymentIntentLastPaymentError'Type' -> Bool)
-> (PaymentIntentLastPaymentError'Type'
    -> PaymentIntentLastPaymentError'Type' -> Bool)
-> Eq PaymentIntentLastPaymentError'Type'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentLastPaymentError'Type'
-> PaymentIntentLastPaymentError'Type' -> Bool
$c/= :: PaymentIntentLastPaymentError'Type'
-> PaymentIntentLastPaymentError'Type' -> Bool
== :: PaymentIntentLastPaymentError'Type'
-> PaymentIntentLastPaymentError'Type' -> Bool
$c== :: PaymentIntentLastPaymentError'Type'
-> PaymentIntentLastPaymentError'Type' -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentLastPaymentError'Type' where
  toJSON :: PaymentIntentLastPaymentError'Type' -> Value
toJSON (PaymentIntentLastPaymentError'Type'Other Value
val) = Value
val
  toJSON (PaymentIntentLastPaymentError'Type'Typed Text
val) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
val
  toJSON (PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumApiConnectionError) = Value
"api_connection_error"
  toJSON (PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumApiError) = Value
"api_error"
  toJSON (PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumAuthenticationError) = Value
"authentication_error"
  toJSON (PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumCardError) = Value
"card_error"
  toJSON (PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumIdempotencyError) = Value
"idempotency_error"
  toJSON (PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumInvalidRequestError) = Value
"invalid_request_error"
  toJSON (PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumRateLimitError) = Value
"rate_limit_error"

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentLastPaymentError'Type' where
  parseJSON :: Value -> Parser PaymentIntentLastPaymentError'Type'
parseJSON Value
val =
    PaymentIntentLastPaymentError'Type'
-> Parser PaymentIntentLastPaymentError'Type'
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure
      ( if
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"api_connection_error" -> PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumApiConnectionError
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"api_error" -> PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumApiError
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"authentication_error" -> PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumAuthenticationError
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"card_error" -> PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumCardError
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"idempotency_error" -> PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumIdempotencyError
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"invalid_request_error" -> PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumInvalidRequestError
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"rate_limit_error" -> PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'EnumRateLimitError
            | Bool
GHC.Base.otherwise -> Value -> PaymentIntentLastPaymentError'Type'
PaymentIntentLastPaymentError'Type'Other Value
val
      )

-- | Defines the object schema located at @components.schemas.payment_intent.properties.next_action.anyOf@ in the specification.
--
-- If present, this property tells you what actions you need to take in order for your customer to fulfill a payment using the provided source.
data PaymentIntentNextAction' = PaymentIntentNextAction'
  { -- | alipay_handle_redirect:
    PaymentIntentNextAction'
-> Maybe PaymentIntentNextActionAlipayHandleRedirect
paymentIntentNextAction'AlipayHandleRedirect :: (GHC.Maybe.Maybe PaymentIntentNextActionAlipayHandleRedirect),
    -- | boleto_display_details:
    PaymentIntentNextAction' -> Maybe PaymentIntentNextActionBoleto
paymentIntentNextAction'BoletoDisplayDetails :: (GHC.Maybe.Maybe PaymentIntentNextActionBoleto),
    -- | oxxo_display_details:
    PaymentIntentNextAction'
-> Maybe PaymentIntentNextActionDisplayOxxoDetails
paymentIntentNextAction'OxxoDisplayDetails :: (GHC.Maybe.Maybe PaymentIntentNextActionDisplayOxxoDetails),
    -- | redirect_to_url:
    PaymentIntentNextAction'
-> Maybe PaymentIntentNextActionRedirectToUrl
paymentIntentNextAction'RedirectToUrl :: (GHC.Maybe.Maybe PaymentIntentNextActionRedirectToUrl),
    -- | type: Type of the next action to perform, one of \`redirect_to_url\`, \`use_stripe_sdk\`, \`alipay_handle_redirect\`, or \`oxxo_display_details\`.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentNextAction' -> Maybe Text
paymentIntentNextAction'Type :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | use_stripe_sdk: When confirming a PaymentIntent with Stripe.js, Stripe.js depends on the contents of this dictionary to invoke authentication flows. The shape of the contents is subject to change and is only intended to be used by Stripe.js.
    PaymentIntentNextAction' -> Maybe Object
paymentIntentNextAction'UseStripeSdk :: (GHC.Maybe.Maybe Data.Aeson.Types.Internal.Object),
    -- | verify_with_microdeposits:
    PaymentIntentNextAction'
-> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
paymentIntentNextAction'VerifyWithMicrodeposits :: (GHC.Maybe.Maybe PaymentIntentNextActionVerifyWithMicrodeposits)
  }
  deriving
    ( Int -> PaymentIntentNextAction' -> ShowS
[PaymentIntentNextAction'] -> ShowS
PaymentIntentNextAction' -> String
(Int -> PaymentIntentNextAction' -> ShowS)
-> (PaymentIntentNextAction' -> String)
-> ([PaymentIntentNextAction'] -> ShowS)
-> Show PaymentIntentNextAction'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentNextAction'] -> ShowS
$cshowList :: [PaymentIntentNextAction'] -> ShowS
show :: PaymentIntentNextAction' -> String
$cshow :: PaymentIntentNextAction' -> String
showsPrec :: Int -> PaymentIntentNextAction' -> ShowS
$cshowsPrec :: Int -> PaymentIntentNextAction' -> ShowS
GHC.Show.Show,
      PaymentIntentNextAction' -> PaymentIntentNextAction' -> Bool
(PaymentIntentNextAction' -> PaymentIntentNextAction' -> Bool)
-> (PaymentIntentNextAction' -> PaymentIntentNextAction' -> Bool)
-> Eq PaymentIntentNextAction'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentNextAction' -> PaymentIntentNextAction' -> Bool
$c/= :: PaymentIntentNextAction' -> PaymentIntentNextAction' -> Bool
== :: PaymentIntentNextAction' -> PaymentIntentNextAction' -> Bool
$c== :: PaymentIntentNextAction' -> PaymentIntentNextAction' -> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentNextAction' where
  toJSON :: PaymentIntentNextAction' -> Value
toJSON PaymentIntentNextAction'
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"alipay_handle_redirect" Text -> Maybe PaymentIntentNextActionAlipayHandleRedirect -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction'
-> Maybe PaymentIntentNextActionAlipayHandleRedirect
paymentIntentNextAction'AlipayHandleRedirect PaymentIntentNextAction'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"boleto_display_details" Text -> Maybe PaymentIntentNextActionBoleto -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction' -> Maybe PaymentIntentNextActionBoleto
paymentIntentNextAction'BoletoDisplayDetails PaymentIntentNextAction'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"oxxo_display_details" Text -> Maybe PaymentIntentNextActionDisplayOxxoDetails -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction'
-> Maybe PaymentIntentNextActionDisplayOxxoDetails
paymentIntentNextAction'OxxoDisplayDetails PaymentIntentNextAction'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"redirect_to_url" Text -> Maybe PaymentIntentNextActionRedirectToUrl -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction'
-> Maybe PaymentIntentNextActionRedirectToUrl
paymentIntentNextAction'RedirectToUrl PaymentIntentNextAction'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"type" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction' -> Maybe Text
paymentIntentNextAction'Type PaymentIntentNextAction'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"use_stripe_sdk" Text -> Maybe Object -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction' -> Maybe Object
paymentIntentNextAction'UseStripeSdk PaymentIntentNextAction'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"verify_with_microdeposits" Text
-> Maybe PaymentIntentNextActionVerifyWithMicrodeposits -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction'
-> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
paymentIntentNextAction'VerifyWithMicrodeposits PaymentIntentNextAction'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: PaymentIntentNextAction' -> Encoding
toEncoding PaymentIntentNextAction'
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"alipay_handle_redirect" Text -> Maybe PaymentIntentNextActionAlipayHandleRedirect -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction'
-> Maybe PaymentIntentNextActionAlipayHandleRedirect
paymentIntentNextAction'AlipayHandleRedirect PaymentIntentNextAction'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"boleto_display_details" Text -> Maybe PaymentIntentNextActionBoleto -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction' -> Maybe PaymentIntentNextActionBoleto
paymentIntentNextAction'BoletoDisplayDetails PaymentIntentNextAction'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"oxxo_display_details" Text -> Maybe PaymentIntentNextActionDisplayOxxoDetails -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction'
-> Maybe PaymentIntentNextActionDisplayOxxoDetails
paymentIntentNextAction'OxxoDisplayDetails PaymentIntentNextAction'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"redirect_to_url" Text -> Maybe PaymentIntentNextActionRedirectToUrl -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction'
-> Maybe PaymentIntentNextActionRedirectToUrl
paymentIntentNextAction'RedirectToUrl PaymentIntentNextAction'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"type" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction' -> Maybe Text
paymentIntentNextAction'Type PaymentIntentNextAction'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"use_stripe_sdk" Text -> Maybe Object -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction' -> Maybe Object
paymentIntentNextAction'UseStripeSdk PaymentIntentNextAction'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"verify_with_microdeposits" Text
-> Maybe PaymentIntentNextActionVerifyWithMicrodeposits -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentNextAction'
-> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
paymentIntentNextAction'VerifyWithMicrodeposits PaymentIntentNextAction'
obj)))))))

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentNextAction' where
  parseJSON :: Value -> Parser PaymentIntentNextAction'
parseJSON = String
-> (Object -> Parser PaymentIntentNextAction')
-> Value
-> Parser PaymentIntentNextAction'
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"PaymentIntentNextAction'" (\Object
obj -> (((((((Maybe PaymentIntentNextActionAlipayHandleRedirect
 -> Maybe PaymentIntentNextActionBoleto
 -> Maybe PaymentIntentNextActionDisplayOxxoDetails
 -> Maybe PaymentIntentNextActionRedirectToUrl
 -> Maybe Text
 -> Maybe Object
 -> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
 -> PaymentIntentNextAction')
-> Parser
     (Maybe PaymentIntentNextActionAlipayHandleRedirect
      -> Maybe PaymentIntentNextActionBoleto
      -> Maybe PaymentIntentNextActionDisplayOxxoDetails
      -> Maybe PaymentIntentNextActionRedirectToUrl
      -> Maybe Text
      -> Maybe Object
      -> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
      -> PaymentIntentNextAction')
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure Maybe PaymentIntentNextActionAlipayHandleRedirect
-> Maybe PaymentIntentNextActionBoleto
-> Maybe PaymentIntentNextActionDisplayOxxoDetails
-> Maybe PaymentIntentNextActionRedirectToUrl
-> Maybe Text
-> Maybe Object
-> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
-> PaymentIntentNextAction'
PaymentIntentNextAction' Parser
  (Maybe PaymentIntentNextActionAlipayHandleRedirect
   -> Maybe PaymentIntentNextActionBoleto
   -> Maybe PaymentIntentNextActionDisplayOxxoDetails
   -> Maybe PaymentIntentNextActionRedirectToUrl
   -> Maybe Text
   -> Maybe Object
   -> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
   -> PaymentIntentNextAction')
-> Parser (Maybe PaymentIntentNextActionAlipayHandleRedirect)
-> Parser
     (Maybe PaymentIntentNextActionBoleto
      -> Maybe PaymentIntentNextActionDisplayOxxoDetails
      -> Maybe PaymentIntentNextActionRedirectToUrl
      -> Maybe Text
      -> Maybe Object
      -> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
      -> PaymentIntentNextAction')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser (Maybe PaymentIntentNextActionAlipayHandleRedirect)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"alipay_handle_redirect")) Parser
  (Maybe PaymentIntentNextActionBoleto
   -> Maybe PaymentIntentNextActionDisplayOxxoDetails
   -> Maybe PaymentIntentNextActionRedirectToUrl
   -> Maybe Text
   -> Maybe Object
   -> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
   -> PaymentIntentNextAction')
-> Parser (Maybe PaymentIntentNextActionBoleto)
-> Parser
     (Maybe PaymentIntentNextActionDisplayOxxoDetails
      -> Maybe PaymentIntentNextActionRedirectToUrl
      -> Maybe Text
      -> Maybe Object
      -> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
      -> PaymentIntentNextAction')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentIntentNextActionBoleto)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"boleto_display_details")) Parser
  (Maybe PaymentIntentNextActionDisplayOxxoDetails
   -> Maybe PaymentIntentNextActionRedirectToUrl
   -> Maybe Text
   -> Maybe Object
   -> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
   -> PaymentIntentNextAction')
-> Parser (Maybe PaymentIntentNextActionDisplayOxxoDetails)
-> Parser
     (Maybe PaymentIntentNextActionRedirectToUrl
      -> Maybe Text
      -> Maybe Object
      -> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
      -> PaymentIntentNextAction')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text -> Parser (Maybe PaymentIntentNextActionDisplayOxxoDetails)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"oxxo_display_details")) Parser
  (Maybe PaymentIntentNextActionRedirectToUrl
   -> Maybe Text
   -> Maybe Object
   -> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
   -> PaymentIntentNextAction')
-> Parser (Maybe PaymentIntentNextActionRedirectToUrl)
-> Parser
     (Maybe Text
      -> Maybe Object
      -> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
      -> PaymentIntentNextAction')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text -> Parser (Maybe PaymentIntentNextActionRedirectToUrl)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"redirect_to_url")) Parser
  (Maybe Text
   -> Maybe Object
   -> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
   -> PaymentIntentNextAction')
-> Parser (Maybe Text)
-> Parser
     (Maybe Object
      -> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
      -> PaymentIntentNextAction')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"type")) Parser
  (Maybe Object
   -> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
   -> PaymentIntentNextAction')
-> Parser (Maybe Object)
-> Parser
     (Maybe PaymentIntentNextActionVerifyWithMicrodeposits
      -> PaymentIntentNextAction')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Object)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"use_stripe_sdk")) Parser
  (Maybe PaymentIntentNextActionVerifyWithMicrodeposits
   -> PaymentIntentNextAction')
-> Parser (Maybe PaymentIntentNextActionVerifyWithMicrodeposits)
-> Parser PaymentIntentNextAction'
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser (Maybe PaymentIntentNextActionVerifyWithMicrodeposits)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"verify_with_microdeposits"))

-- | Create a new 'PaymentIntentNextAction'' with all required fields.
mkPaymentIntentNextAction' :: PaymentIntentNextAction'
mkPaymentIntentNextAction' :: PaymentIntentNextAction'
mkPaymentIntentNextAction' =
  PaymentIntentNextAction' :: Maybe PaymentIntentNextActionAlipayHandleRedirect
-> Maybe PaymentIntentNextActionBoleto
-> Maybe PaymentIntentNextActionDisplayOxxoDetails
-> Maybe PaymentIntentNextActionRedirectToUrl
-> Maybe Text
-> Maybe Object
-> Maybe PaymentIntentNextActionVerifyWithMicrodeposits
-> PaymentIntentNextAction'
PaymentIntentNextAction'
    { paymentIntentNextAction'AlipayHandleRedirect :: Maybe PaymentIntentNextActionAlipayHandleRedirect
paymentIntentNextAction'AlipayHandleRedirect = Maybe PaymentIntentNextActionAlipayHandleRedirect
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentNextAction'BoletoDisplayDetails :: Maybe PaymentIntentNextActionBoleto
paymentIntentNextAction'BoletoDisplayDetails = Maybe PaymentIntentNextActionBoleto
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentNextAction'OxxoDisplayDetails :: Maybe PaymentIntentNextActionDisplayOxxoDetails
paymentIntentNextAction'OxxoDisplayDetails = Maybe PaymentIntentNextActionDisplayOxxoDetails
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentNextAction'RedirectToUrl :: Maybe PaymentIntentNextActionRedirectToUrl
paymentIntentNextAction'RedirectToUrl = Maybe PaymentIntentNextActionRedirectToUrl
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentNextAction'Type :: Maybe Text
paymentIntentNextAction'Type = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentNextAction'UseStripeSdk :: Maybe Object
paymentIntentNextAction'UseStripeSdk = Maybe Object
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentNextAction'VerifyWithMicrodeposits :: Maybe PaymentIntentNextActionVerifyWithMicrodeposits
paymentIntentNextAction'VerifyWithMicrodeposits = Maybe PaymentIntentNextActionVerifyWithMicrodeposits
forall a. Maybe a
GHC.Maybe.Nothing
    }

-- | Defines the oneOf schema located at @components.schemas.payment_intent.properties.on_behalf_of.anyOf@ in the specification.
--
-- The account (if any) for which the funds of the PaymentIntent are intended. See the PaymentIntents [use case for connected accounts](https:\/\/stripe.com\/docs\/payments\/connected-accounts) for details.
data PaymentIntentOnBehalfOf'Variants
  = PaymentIntentOnBehalfOf'Text Data.Text.Internal.Text
  | PaymentIntentOnBehalfOf'Account Account
  deriving (Int -> PaymentIntentOnBehalfOf'Variants -> ShowS
[PaymentIntentOnBehalfOf'Variants] -> ShowS
PaymentIntentOnBehalfOf'Variants -> String
(Int -> PaymentIntentOnBehalfOf'Variants -> ShowS)
-> (PaymentIntentOnBehalfOf'Variants -> String)
-> ([PaymentIntentOnBehalfOf'Variants] -> ShowS)
-> Show PaymentIntentOnBehalfOf'Variants
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentOnBehalfOf'Variants] -> ShowS
$cshowList :: [PaymentIntentOnBehalfOf'Variants] -> ShowS
show :: PaymentIntentOnBehalfOf'Variants -> String
$cshow :: PaymentIntentOnBehalfOf'Variants -> String
showsPrec :: Int -> PaymentIntentOnBehalfOf'Variants -> ShowS
$cshowsPrec :: Int -> PaymentIntentOnBehalfOf'Variants -> ShowS
GHC.Show.Show, PaymentIntentOnBehalfOf'Variants
-> PaymentIntentOnBehalfOf'Variants -> Bool
(PaymentIntentOnBehalfOf'Variants
 -> PaymentIntentOnBehalfOf'Variants -> Bool)
-> (PaymentIntentOnBehalfOf'Variants
    -> PaymentIntentOnBehalfOf'Variants -> Bool)
-> Eq PaymentIntentOnBehalfOf'Variants
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentOnBehalfOf'Variants
-> PaymentIntentOnBehalfOf'Variants -> Bool
$c/= :: PaymentIntentOnBehalfOf'Variants
-> PaymentIntentOnBehalfOf'Variants -> Bool
== :: PaymentIntentOnBehalfOf'Variants
-> PaymentIntentOnBehalfOf'Variants -> Bool
$c== :: PaymentIntentOnBehalfOf'Variants
-> PaymentIntentOnBehalfOf'Variants -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentOnBehalfOf'Variants where
  toJSON :: PaymentIntentOnBehalfOf'Variants -> Value
toJSON (PaymentIntentOnBehalfOf'Text Text
a) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
a
  toJSON (PaymentIntentOnBehalfOf'Account Account
a) = Account -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Account
a

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentOnBehalfOf'Variants where
  parseJSON :: Value -> Parser PaymentIntentOnBehalfOf'Variants
parseJSON Value
val = case (Text -> PaymentIntentOnBehalfOf'Variants
PaymentIntentOnBehalfOf'Text (Text -> PaymentIntentOnBehalfOf'Variants)
-> Result Text -> Result PaymentIntentOnBehalfOf'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Text
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentOnBehalfOf'Variants
-> Result PaymentIntentOnBehalfOf'Variants
-> Result PaymentIntentOnBehalfOf'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> ((Account -> PaymentIntentOnBehalfOf'Variants
PaymentIntentOnBehalfOf'Account (Account -> PaymentIntentOnBehalfOf'Variants)
-> Result Account -> Result PaymentIntentOnBehalfOf'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Account
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentOnBehalfOf'Variants
-> Result PaymentIntentOnBehalfOf'Variants
-> Result PaymentIntentOnBehalfOf'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> String -> Result PaymentIntentOnBehalfOf'Variants
forall a. String -> Result a
Data.Aeson.Types.Internal.Error String
"No variant matched") of
    Data.Aeson.Types.Internal.Success PaymentIntentOnBehalfOf'Variants
a -> PaymentIntentOnBehalfOf'Variants
-> Parser PaymentIntentOnBehalfOf'Variants
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure PaymentIntentOnBehalfOf'Variants
a
    Data.Aeson.Types.Internal.Error String
a -> String -> Parser PaymentIntentOnBehalfOf'Variants
forall (m :: * -> *) a. MonadFail m => String -> m a
Control.Monad.Fail.fail String
a

-- | Defines the oneOf schema located at @components.schemas.payment_intent.properties.payment_method.anyOf@ in the specification.
--
-- ID of the payment method used in this PaymentIntent.
data PaymentIntentPaymentMethod'Variants
  = PaymentIntentPaymentMethod'Text Data.Text.Internal.Text
  | PaymentIntentPaymentMethod'PaymentMethod PaymentMethod
  deriving (Int -> PaymentIntentPaymentMethod'Variants -> ShowS
[PaymentIntentPaymentMethod'Variants] -> ShowS
PaymentIntentPaymentMethod'Variants -> String
(Int -> PaymentIntentPaymentMethod'Variants -> ShowS)
-> (PaymentIntentPaymentMethod'Variants -> String)
-> ([PaymentIntentPaymentMethod'Variants] -> ShowS)
-> Show PaymentIntentPaymentMethod'Variants
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentPaymentMethod'Variants] -> ShowS
$cshowList :: [PaymentIntentPaymentMethod'Variants] -> ShowS
show :: PaymentIntentPaymentMethod'Variants -> String
$cshow :: PaymentIntentPaymentMethod'Variants -> String
showsPrec :: Int -> PaymentIntentPaymentMethod'Variants -> ShowS
$cshowsPrec :: Int -> PaymentIntentPaymentMethod'Variants -> ShowS
GHC.Show.Show, PaymentIntentPaymentMethod'Variants
-> PaymentIntentPaymentMethod'Variants -> Bool
(PaymentIntentPaymentMethod'Variants
 -> PaymentIntentPaymentMethod'Variants -> Bool)
-> (PaymentIntentPaymentMethod'Variants
    -> PaymentIntentPaymentMethod'Variants -> Bool)
-> Eq PaymentIntentPaymentMethod'Variants
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentPaymentMethod'Variants
-> PaymentIntentPaymentMethod'Variants -> Bool
$c/= :: PaymentIntentPaymentMethod'Variants
-> PaymentIntentPaymentMethod'Variants -> Bool
== :: PaymentIntentPaymentMethod'Variants
-> PaymentIntentPaymentMethod'Variants -> Bool
$c== :: PaymentIntentPaymentMethod'Variants
-> PaymentIntentPaymentMethod'Variants -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentPaymentMethod'Variants where
  toJSON :: PaymentIntentPaymentMethod'Variants -> Value
toJSON (PaymentIntentPaymentMethod'Text Text
a) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
a
  toJSON (PaymentIntentPaymentMethod'PaymentMethod PaymentMethod
a) = PaymentMethod -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON PaymentMethod
a

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentPaymentMethod'Variants where
  parseJSON :: Value -> Parser PaymentIntentPaymentMethod'Variants
parseJSON Value
val = case (Text -> PaymentIntentPaymentMethod'Variants
PaymentIntentPaymentMethod'Text (Text -> PaymentIntentPaymentMethod'Variants)
-> Result Text -> Result PaymentIntentPaymentMethod'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Text
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentPaymentMethod'Variants
-> Result PaymentIntentPaymentMethod'Variants
-> Result PaymentIntentPaymentMethod'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> ((PaymentMethod -> PaymentIntentPaymentMethod'Variants
PaymentIntentPaymentMethod'PaymentMethod (PaymentMethod -> PaymentIntentPaymentMethod'Variants)
-> Result PaymentMethod
-> Result PaymentIntentPaymentMethod'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result PaymentMethod
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentPaymentMethod'Variants
-> Result PaymentIntentPaymentMethod'Variants
-> Result PaymentIntentPaymentMethod'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> String -> Result PaymentIntentPaymentMethod'Variants
forall a. String -> Result a
Data.Aeson.Types.Internal.Error String
"No variant matched") of
    Data.Aeson.Types.Internal.Success PaymentIntentPaymentMethod'Variants
a -> PaymentIntentPaymentMethod'Variants
-> Parser PaymentIntentPaymentMethod'Variants
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure PaymentIntentPaymentMethod'Variants
a
    Data.Aeson.Types.Internal.Error String
a -> String -> Parser PaymentIntentPaymentMethod'Variants
forall (m :: * -> *) a. MonadFail m => String -> m a
Control.Monad.Fail.fail String
a

-- | Defines the object schema located at @components.schemas.payment_intent.properties.payment_method_options.anyOf@ in the specification.
--
-- Payment-method-specific configuration for this PaymentIntent.
data PaymentIntentPaymentMethodOptions' = PaymentIntentPaymentMethodOptions'
  { -- | acss_debit:
    PaymentIntentPaymentMethodOptions'
-> Maybe PaymentIntentPaymentMethodOptionsAcssDebit
paymentIntentPaymentMethodOptions'AcssDebit :: (GHC.Maybe.Maybe PaymentIntentPaymentMethodOptionsAcssDebit),
    -- | afterpay_clearpay:
    PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsAfterpayClearpay
paymentIntentPaymentMethodOptions'AfterpayClearpay :: (GHC.Maybe.Maybe PaymentMethodOptionsAfterpayClearpay),
    -- | alipay:
    PaymentIntentPaymentMethodOptions' -> Maybe Object
paymentIntentPaymentMethodOptions'Alipay :: (GHC.Maybe.Maybe PaymentMethodOptionsAlipay),
    -- | bancontact:
    PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsBancontact
paymentIntentPaymentMethodOptions'Bancontact :: (GHC.Maybe.Maybe PaymentMethodOptionsBancontact),
    -- | boleto:
    PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsBoleto
paymentIntentPaymentMethodOptions'Boleto :: (GHC.Maybe.Maybe PaymentMethodOptionsBoleto),
    -- | card:
    PaymentIntentPaymentMethodOptions'
-> Maybe PaymentIntentPaymentMethodOptionsCard
paymentIntentPaymentMethodOptions'Card :: (GHC.Maybe.Maybe PaymentIntentPaymentMethodOptionsCard),
    -- | card_present:
    PaymentIntentPaymentMethodOptions' -> Maybe Object
paymentIntentPaymentMethodOptions'CardPresent :: (GHC.Maybe.Maybe PaymentMethodOptionsCardPresent),
    -- | oxxo:
    PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsOxxo
paymentIntentPaymentMethodOptions'Oxxo :: (GHC.Maybe.Maybe PaymentMethodOptionsOxxo),
    -- | p24:
    PaymentIntentPaymentMethodOptions' -> Maybe Object
paymentIntentPaymentMethodOptions'P24 :: (GHC.Maybe.Maybe PaymentMethodOptionsP24),
    -- | sepa_debit:
    PaymentIntentPaymentMethodOptions'
-> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
paymentIntentPaymentMethodOptions'SepaDebit :: (GHC.Maybe.Maybe PaymentIntentPaymentMethodOptionsSepaDebit),
    -- | sofort:
    PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsSofort
paymentIntentPaymentMethodOptions'Sofort :: (GHC.Maybe.Maybe PaymentMethodOptionsSofort)
  }
  deriving
    ( Int -> PaymentIntentPaymentMethodOptions' -> ShowS
[PaymentIntentPaymentMethodOptions'] -> ShowS
PaymentIntentPaymentMethodOptions' -> String
(Int -> PaymentIntentPaymentMethodOptions' -> ShowS)
-> (PaymentIntentPaymentMethodOptions' -> String)
-> ([PaymentIntentPaymentMethodOptions'] -> ShowS)
-> Show PaymentIntentPaymentMethodOptions'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentPaymentMethodOptions'] -> ShowS
$cshowList :: [PaymentIntentPaymentMethodOptions'] -> ShowS
show :: PaymentIntentPaymentMethodOptions' -> String
$cshow :: PaymentIntentPaymentMethodOptions' -> String
showsPrec :: Int -> PaymentIntentPaymentMethodOptions' -> ShowS
$cshowsPrec :: Int -> PaymentIntentPaymentMethodOptions' -> ShowS
GHC.Show.Show,
      PaymentIntentPaymentMethodOptions'
-> PaymentIntentPaymentMethodOptions' -> Bool
(PaymentIntentPaymentMethodOptions'
 -> PaymentIntentPaymentMethodOptions' -> Bool)
-> (PaymentIntentPaymentMethodOptions'
    -> PaymentIntentPaymentMethodOptions' -> Bool)
-> Eq PaymentIntentPaymentMethodOptions'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentPaymentMethodOptions'
-> PaymentIntentPaymentMethodOptions' -> Bool
$c/= :: PaymentIntentPaymentMethodOptions'
-> PaymentIntentPaymentMethodOptions' -> Bool
== :: PaymentIntentPaymentMethodOptions'
-> PaymentIntentPaymentMethodOptions' -> Bool
$c== :: PaymentIntentPaymentMethodOptions'
-> PaymentIntentPaymentMethodOptions' -> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentPaymentMethodOptions' where
  toJSON :: PaymentIntentPaymentMethodOptions' -> Value
toJSON PaymentIntentPaymentMethodOptions'
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"acss_debit" Text -> Maybe PaymentIntentPaymentMethodOptionsAcssDebit -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentIntentPaymentMethodOptionsAcssDebit
paymentIntentPaymentMethodOptions'AcssDebit PaymentIntentPaymentMethodOptions'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"afterpay_clearpay" Text -> Maybe PaymentMethodOptionsAfterpayClearpay -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsAfterpayClearpay
paymentIntentPaymentMethodOptions'AfterpayClearpay PaymentIntentPaymentMethodOptions'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"alipay" Text -> Maybe Object -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions' -> Maybe Object
paymentIntentPaymentMethodOptions'Alipay PaymentIntentPaymentMethodOptions'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"bancontact" Text -> Maybe PaymentMethodOptionsBancontact -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsBancontact
paymentIntentPaymentMethodOptions'Bancontact PaymentIntentPaymentMethodOptions'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"boleto" Text -> Maybe PaymentMethodOptionsBoleto -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsBoleto
paymentIntentPaymentMethodOptions'Boleto PaymentIntentPaymentMethodOptions'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"card" Text -> Maybe PaymentIntentPaymentMethodOptionsCard -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentIntentPaymentMethodOptionsCard
paymentIntentPaymentMethodOptions'Card PaymentIntentPaymentMethodOptions'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"card_present" Text -> Maybe Object -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions' -> Maybe Object
paymentIntentPaymentMethodOptions'CardPresent PaymentIntentPaymentMethodOptions'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"oxxo" Text -> Maybe PaymentMethodOptionsOxxo -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsOxxo
paymentIntentPaymentMethodOptions'Oxxo PaymentIntentPaymentMethodOptions'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"p24" Text -> Maybe Object -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions' -> Maybe Object
paymentIntentPaymentMethodOptions'P24 PaymentIntentPaymentMethodOptions'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"sepa_debit" Text -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
paymentIntentPaymentMethodOptions'SepaDebit PaymentIntentPaymentMethodOptions'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"sofort" Text -> Maybe PaymentMethodOptionsSofort -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsSofort
paymentIntentPaymentMethodOptions'Sofort PaymentIntentPaymentMethodOptions'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: PaymentIntentPaymentMethodOptions' -> Encoding
toEncoding PaymentIntentPaymentMethodOptions'
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"acss_debit" Text -> Maybe PaymentIntentPaymentMethodOptionsAcssDebit -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentIntentPaymentMethodOptionsAcssDebit
paymentIntentPaymentMethodOptions'AcssDebit PaymentIntentPaymentMethodOptions'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"afterpay_clearpay" Text -> Maybe PaymentMethodOptionsAfterpayClearpay -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsAfterpayClearpay
paymentIntentPaymentMethodOptions'AfterpayClearpay PaymentIntentPaymentMethodOptions'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"alipay" Text -> Maybe Object -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions' -> Maybe Object
paymentIntentPaymentMethodOptions'Alipay PaymentIntentPaymentMethodOptions'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"bancontact" Text -> Maybe PaymentMethodOptionsBancontact -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsBancontact
paymentIntentPaymentMethodOptions'Bancontact PaymentIntentPaymentMethodOptions'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"boleto" Text -> Maybe PaymentMethodOptionsBoleto -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsBoleto
paymentIntentPaymentMethodOptions'Boleto PaymentIntentPaymentMethodOptions'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"card" Text -> Maybe PaymentIntentPaymentMethodOptionsCard -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentIntentPaymentMethodOptionsCard
paymentIntentPaymentMethodOptions'Card PaymentIntentPaymentMethodOptions'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"card_present" Text -> Maybe Object -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions' -> Maybe Object
paymentIntentPaymentMethodOptions'CardPresent PaymentIntentPaymentMethodOptions'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"oxxo" Text -> Maybe PaymentMethodOptionsOxxo -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsOxxo
paymentIntentPaymentMethodOptions'Oxxo PaymentIntentPaymentMethodOptions'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"p24" Text -> Maybe Object -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions' -> Maybe Object
paymentIntentPaymentMethodOptions'P24 PaymentIntentPaymentMethodOptions'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"sepa_debit" Text -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
paymentIntentPaymentMethodOptions'SepaDebit PaymentIntentPaymentMethodOptions'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"sofort" Text -> Maybe PaymentMethodOptionsSofort -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentPaymentMethodOptions'
-> Maybe PaymentMethodOptionsSofort
paymentIntentPaymentMethodOptions'Sofort PaymentIntentPaymentMethodOptions'
obj)))))))))))

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentPaymentMethodOptions' where
  parseJSON :: Value -> Parser PaymentIntentPaymentMethodOptions'
parseJSON = String
-> (Object -> Parser PaymentIntentPaymentMethodOptions')
-> Value
-> Parser PaymentIntentPaymentMethodOptions'
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"PaymentIntentPaymentMethodOptions'" (\Object
obj -> (((((((((((Maybe PaymentIntentPaymentMethodOptionsAcssDebit
 -> Maybe PaymentMethodOptionsAfterpayClearpay
 -> Maybe Object
 -> Maybe PaymentMethodOptionsBancontact
 -> Maybe PaymentMethodOptionsBoleto
 -> Maybe PaymentIntentPaymentMethodOptionsCard
 -> Maybe Object
 -> Maybe PaymentMethodOptionsOxxo
 -> Maybe Object
 -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
 -> Maybe PaymentMethodOptionsSofort
 -> PaymentIntentPaymentMethodOptions')
-> Parser
     (Maybe PaymentIntentPaymentMethodOptionsAcssDebit
      -> Maybe PaymentMethodOptionsAfterpayClearpay
      -> Maybe Object
      -> Maybe PaymentMethodOptionsBancontact
      -> Maybe PaymentMethodOptionsBoleto
      -> Maybe PaymentIntentPaymentMethodOptionsCard
      -> Maybe Object
      -> Maybe PaymentMethodOptionsOxxo
      -> Maybe Object
      -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
      -> Maybe PaymentMethodOptionsSofort
      -> PaymentIntentPaymentMethodOptions')
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure Maybe PaymentIntentPaymentMethodOptionsAcssDebit
-> Maybe PaymentMethodOptionsAfterpayClearpay
-> Maybe Object
-> Maybe PaymentMethodOptionsBancontact
-> Maybe PaymentMethodOptionsBoleto
-> Maybe PaymentIntentPaymentMethodOptionsCard
-> Maybe Object
-> Maybe PaymentMethodOptionsOxxo
-> Maybe Object
-> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
-> Maybe PaymentMethodOptionsSofort
-> PaymentIntentPaymentMethodOptions'
PaymentIntentPaymentMethodOptions' Parser
  (Maybe PaymentIntentPaymentMethodOptionsAcssDebit
   -> Maybe PaymentMethodOptionsAfterpayClearpay
   -> Maybe Object
   -> Maybe PaymentMethodOptionsBancontact
   -> Maybe PaymentMethodOptionsBoleto
   -> Maybe PaymentIntentPaymentMethodOptionsCard
   -> Maybe Object
   -> Maybe PaymentMethodOptionsOxxo
   -> Maybe Object
   -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
   -> Maybe PaymentMethodOptionsSofort
   -> PaymentIntentPaymentMethodOptions')
-> Parser (Maybe PaymentIntentPaymentMethodOptionsAcssDebit)
-> Parser
     (Maybe PaymentMethodOptionsAfterpayClearpay
      -> Maybe Object
      -> Maybe PaymentMethodOptionsBancontact
      -> Maybe PaymentMethodOptionsBoleto
      -> Maybe PaymentIntentPaymentMethodOptionsCard
      -> Maybe Object
      -> Maybe PaymentMethodOptionsOxxo
      -> Maybe Object
      -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
      -> Maybe PaymentMethodOptionsSofort
      -> PaymentIntentPaymentMethodOptions')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser (Maybe PaymentIntentPaymentMethodOptionsAcssDebit)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"acss_debit")) Parser
  (Maybe PaymentMethodOptionsAfterpayClearpay
   -> Maybe Object
   -> Maybe PaymentMethodOptionsBancontact
   -> Maybe PaymentMethodOptionsBoleto
   -> Maybe PaymentIntentPaymentMethodOptionsCard
   -> Maybe Object
   -> Maybe PaymentMethodOptionsOxxo
   -> Maybe Object
   -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
   -> Maybe PaymentMethodOptionsSofort
   -> PaymentIntentPaymentMethodOptions')
-> Parser (Maybe PaymentMethodOptionsAfterpayClearpay)
-> Parser
     (Maybe Object
      -> Maybe PaymentMethodOptionsBancontact
      -> Maybe PaymentMethodOptionsBoleto
      -> Maybe PaymentIntentPaymentMethodOptionsCard
      -> Maybe Object
      -> Maybe PaymentMethodOptionsOxxo
      -> Maybe Object
      -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
      -> Maybe PaymentMethodOptionsSofort
      -> PaymentIntentPaymentMethodOptions')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text -> Parser (Maybe PaymentMethodOptionsAfterpayClearpay)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"afterpay_clearpay")) Parser
  (Maybe Object
   -> Maybe PaymentMethodOptionsBancontact
   -> Maybe PaymentMethodOptionsBoleto
   -> Maybe PaymentIntentPaymentMethodOptionsCard
   -> Maybe Object
   -> Maybe PaymentMethodOptionsOxxo
   -> Maybe Object
   -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
   -> Maybe PaymentMethodOptionsSofort
   -> PaymentIntentPaymentMethodOptions')
-> Parser (Maybe Object)
-> Parser
     (Maybe PaymentMethodOptionsBancontact
      -> Maybe PaymentMethodOptionsBoleto
      -> Maybe PaymentIntentPaymentMethodOptionsCard
      -> Maybe Object
      -> Maybe PaymentMethodOptionsOxxo
      -> Maybe Object
      -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
      -> Maybe PaymentMethodOptionsSofort
      -> PaymentIntentPaymentMethodOptions')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Object)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"alipay")) Parser
  (Maybe PaymentMethodOptionsBancontact
   -> Maybe PaymentMethodOptionsBoleto
   -> Maybe PaymentIntentPaymentMethodOptionsCard
   -> Maybe Object
   -> Maybe PaymentMethodOptionsOxxo
   -> Maybe Object
   -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
   -> Maybe PaymentMethodOptionsSofort
   -> PaymentIntentPaymentMethodOptions')
-> Parser (Maybe PaymentMethodOptionsBancontact)
-> Parser
     (Maybe PaymentMethodOptionsBoleto
      -> Maybe PaymentIntentPaymentMethodOptionsCard
      -> Maybe Object
      -> Maybe PaymentMethodOptionsOxxo
      -> Maybe Object
      -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
      -> Maybe PaymentMethodOptionsSofort
      -> PaymentIntentPaymentMethodOptions')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentMethodOptionsBancontact)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"bancontact")) Parser
  (Maybe PaymentMethodOptionsBoleto
   -> Maybe PaymentIntentPaymentMethodOptionsCard
   -> Maybe Object
   -> Maybe PaymentMethodOptionsOxxo
   -> Maybe Object
   -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
   -> Maybe PaymentMethodOptionsSofort
   -> PaymentIntentPaymentMethodOptions')
-> Parser (Maybe PaymentMethodOptionsBoleto)
-> Parser
     (Maybe PaymentIntentPaymentMethodOptionsCard
      -> Maybe Object
      -> Maybe PaymentMethodOptionsOxxo
      -> Maybe Object
      -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
      -> Maybe PaymentMethodOptionsSofort
      -> PaymentIntentPaymentMethodOptions')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentMethodOptionsBoleto)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"boleto")) Parser
  (Maybe PaymentIntentPaymentMethodOptionsCard
   -> Maybe Object
   -> Maybe PaymentMethodOptionsOxxo
   -> Maybe Object
   -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
   -> Maybe PaymentMethodOptionsSofort
   -> PaymentIntentPaymentMethodOptions')
-> Parser (Maybe PaymentIntentPaymentMethodOptionsCard)
-> Parser
     (Maybe Object
      -> Maybe PaymentMethodOptionsOxxo
      -> Maybe Object
      -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
      -> Maybe PaymentMethodOptionsSofort
      -> PaymentIntentPaymentMethodOptions')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text -> Parser (Maybe PaymentIntentPaymentMethodOptionsCard)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"card")) Parser
  (Maybe Object
   -> Maybe PaymentMethodOptionsOxxo
   -> Maybe Object
   -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
   -> Maybe PaymentMethodOptionsSofort
   -> PaymentIntentPaymentMethodOptions')
-> Parser (Maybe Object)
-> Parser
     (Maybe PaymentMethodOptionsOxxo
      -> Maybe Object
      -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
      -> Maybe PaymentMethodOptionsSofort
      -> PaymentIntentPaymentMethodOptions')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Object)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"card_present")) Parser
  (Maybe PaymentMethodOptionsOxxo
   -> Maybe Object
   -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
   -> Maybe PaymentMethodOptionsSofort
   -> PaymentIntentPaymentMethodOptions')
-> Parser (Maybe PaymentMethodOptionsOxxo)
-> Parser
     (Maybe Object
      -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
      -> Maybe PaymentMethodOptionsSofort
      -> PaymentIntentPaymentMethodOptions')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentMethodOptionsOxxo)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"oxxo")) Parser
  (Maybe Object
   -> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
   -> Maybe PaymentMethodOptionsSofort
   -> PaymentIntentPaymentMethodOptions')
-> Parser (Maybe Object)
-> Parser
     (Maybe PaymentIntentPaymentMethodOptionsSepaDebit
      -> Maybe PaymentMethodOptionsSofort
      -> PaymentIntentPaymentMethodOptions')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Object)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"p24")) Parser
  (Maybe PaymentIntentPaymentMethodOptionsSepaDebit
   -> Maybe PaymentMethodOptionsSofort
   -> PaymentIntentPaymentMethodOptions')
-> Parser (Maybe PaymentIntentPaymentMethodOptionsSepaDebit)
-> Parser
     (Maybe PaymentMethodOptionsSofort
      -> PaymentIntentPaymentMethodOptions')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser (Maybe PaymentIntentPaymentMethodOptionsSepaDebit)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"sepa_debit")) Parser
  (Maybe PaymentMethodOptionsSofort
   -> PaymentIntentPaymentMethodOptions')
-> Parser (Maybe PaymentMethodOptionsSofort)
-> Parser PaymentIntentPaymentMethodOptions'
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe PaymentMethodOptionsSofort)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"sofort"))

-- | Create a new 'PaymentIntentPaymentMethodOptions'' with all required fields.
mkPaymentIntentPaymentMethodOptions' :: PaymentIntentPaymentMethodOptions'
mkPaymentIntentPaymentMethodOptions' :: PaymentIntentPaymentMethodOptions'
mkPaymentIntentPaymentMethodOptions' =
  PaymentIntentPaymentMethodOptions' :: Maybe PaymentIntentPaymentMethodOptionsAcssDebit
-> Maybe PaymentMethodOptionsAfterpayClearpay
-> Maybe Object
-> Maybe PaymentMethodOptionsBancontact
-> Maybe PaymentMethodOptionsBoleto
-> Maybe PaymentIntentPaymentMethodOptionsCard
-> Maybe Object
-> Maybe PaymentMethodOptionsOxxo
-> Maybe Object
-> Maybe PaymentIntentPaymentMethodOptionsSepaDebit
-> Maybe PaymentMethodOptionsSofort
-> PaymentIntentPaymentMethodOptions'
PaymentIntentPaymentMethodOptions'
    { paymentIntentPaymentMethodOptions'AcssDebit :: Maybe PaymentIntentPaymentMethodOptionsAcssDebit
paymentIntentPaymentMethodOptions'AcssDebit = Maybe PaymentIntentPaymentMethodOptionsAcssDebit
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentPaymentMethodOptions'AfterpayClearpay :: Maybe PaymentMethodOptionsAfterpayClearpay
paymentIntentPaymentMethodOptions'AfterpayClearpay = Maybe PaymentMethodOptionsAfterpayClearpay
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentPaymentMethodOptions'Alipay :: Maybe Object
paymentIntentPaymentMethodOptions'Alipay = Maybe Object
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentPaymentMethodOptions'Bancontact :: Maybe PaymentMethodOptionsBancontact
paymentIntentPaymentMethodOptions'Bancontact = Maybe PaymentMethodOptionsBancontact
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentPaymentMethodOptions'Boleto :: Maybe PaymentMethodOptionsBoleto
paymentIntentPaymentMethodOptions'Boleto = Maybe PaymentMethodOptionsBoleto
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentPaymentMethodOptions'Card :: Maybe PaymentIntentPaymentMethodOptionsCard
paymentIntentPaymentMethodOptions'Card = Maybe PaymentIntentPaymentMethodOptionsCard
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentPaymentMethodOptions'CardPresent :: Maybe Object
paymentIntentPaymentMethodOptions'CardPresent = Maybe Object
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentPaymentMethodOptions'Oxxo :: Maybe PaymentMethodOptionsOxxo
paymentIntentPaymentMethodOptions'Oxxo = Maybe PaymentMethodOptionsOxxo
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentPaymentMethodOptions'P24 :: Maybe Object
paymentIntentPaymentMethodOptions'P24 = Maybe Object
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentPaymentMethodOptions'SepaDebit :: Maybe PaymentIntentPaymentMethodOptionsSepaDebit
paymentIntentPaymentMethodOptions'SepaDebit = Maybe PaymentIntentPaymentMethodOptionsSepaDebit
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentPaymentMethodOptions'Sofort :: Maybe PaymentMethodOptionsSofort
paymentIntentPaymentMethodOptions'Sofort = Maybe PaymentMethodOptionsSofort
forall a. Maybe a
GHC.Maybe.Nothing
    }

-- | Defines the oneOf schema located at @components.schemas.payment_intent.properties.review.anyOf@ in the specification.
--
-- ID of the review associated with this PaymentIntent, if any.
data PaymentIntentReview'Variants
  = PaymentIntentReview'Text Data.Text.Internal.Text
  | PaymentIntentReview'Review Review
  deriving (Int -> PaymentIntentReview'Variants -> ShowS
[PaymentIntentReview'Variants] -> ShowS
PaymentIntentReview'Variants -> String
(Int -> PaymentIntentReview'Variants -> ShowS)
-> (PaymentIntentReview'Variants -> String)
-> ([PaymentIntentReview'Variants] -> ShowS)
-> Show PaymentIntentReview'Variants
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentReview'Variants] -> ShowS
$cshowList :: [PaymentIntentReview'Variants] -> ShowS
show :: PaymentIntentReview'Variants -> String
$cshow :: PaymentIntentReview'Variants -> String
showsPrec :: Int -> PaymentIntentReview'Variants -> ShowS
$cshowsPrec :: Int -> PaymentIntentReview'Variants -> ShowS
GHC.Show.Show, PaymentIntentReview'Variants
-> PaymentIntentReview'Variants -> Bool
(PaymentIntentReview'Variants
 -> PaymentIntentReview'Variants -> Bool)
-> (PaymentIntentReview'Variants
    -> PaymentIntentReview'Variants -> Bool)
-> Eq PaymentIntentReview'Variants
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentReview'Variants
-> PaymentIntentReview'Variants -> Bool
$c/= :: PaymentIntentReview'Variants
-> PaymentIntentReview'Variants -> Bool
== :: PaymentIntentReview'Variants
-> PaymentIntentReview'Variants -> Bool
$c== :: PaymentIntentReview'Variants
-> PaymentIntentReview'Variants -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentReview'Variants where
  toJSON :: PaymentIntentReview'Variants -> Value
toJSON (PaymentIntentReview'Text Text
a) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
a
  toJSON (PaymentIntentReview'Review Review
a) = Review -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Review
a

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentReview'Variants where
  parseJSON :: Value -> Parser PaymentIntentReview'Variants
parseJSON Value
val = case (Text -> PaymentIntentReview'Variants
PaymentIntentReview'Text (Text -> PaymentIntentReview'Variants)
-> Result Text -> Result PaymentIntentReview'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Text
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentReview'Variants
-> Result PaymentIntentReview'Variants
-> Result PaymentIntentReview'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> ((Review -> PaymentIntentReview'Variants
PaymentIntentReview'Review (Review -> PaymentIntentReview'Variants)
-> Result Review -> Result PaymentIntentReview'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Review
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentReview'Variants
-> Result PaymentIntentReview'Variants
-> Result PaymentIntentReview'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> String -> Result PaymentIntentReview'Variants
forall a. String -> Result a
Data.Aeson.Types.Internal.Error String
"No variant matched") of
    Data.Aeson.Types.Internal.Success PaymentIntentReview'Variants
a -> PaymentIntentReview'Variants -> Parser PaymentIntentReview'Variants
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure PaymentIntentReview'Variants
a
    Data.Aeson.Types.Internal.Error String
a -> String -> Parser PaymentIntentReview'Variants
forall (m :: * -> *) a. MonadFail m => String -> m a
Control.Monad.Fail.fail String
a

-- | Defines the enum schema located at @components.schemas.payment_intent.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).
data PaymentIntentSetupFutureUsage'
  = -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
    PaymentIntentSetupFutureUsage'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.
    PaymentIntentSetupFutureUsage'Typed Data.Text.Internal.Text
  | -- | Represents the JSON value @"off_session"@
    PaymentIntentSetupFutureUsage'EnumOffSession
  | -- | Represents the JSON value @"on_session"@
    PaymentIntentSetupFutureUsage'EnumOnSession
  deriving (Int -> PaymentIntentSetupFutureUsage' -> ShowS
[PaymentIntentSetupFutureUsage'] -> ShowS
PaymentIntentSetupFutureUsage' -> String
(Int -> PaymentIntentSetupFutureUsage' -> ShowS)
-> (PaymentIntentSetupFutureUsage' -> String)
-> ([PaymentIntentSetupFutureUsage'] -> ShowS)
-> Show PaymentIntentSetupFutureUsage'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentSetupFutureUsage'] -> ShowS
$cshowList :: [PaymentIntentSetupFutureUsage'] -> ShowS
show :: PaymentIntentSetupFutureUsage' -> String
$cshow :: PaymentIntentSetupFutureUsage' -> String
showsPrec :: Int -> PaymentIntentSetupFutureUsage' -> ShowS
$cshowsPrec :: Int -> PaymentIntentSetupFutureUsage' -> ShowS
GHC.Show.Show, PaymentIntentSetupFutureUsage'
-> PaymentIntentSetupFutureUsage' -> Bool
(PaymentIntentSetupFutureUsage'
 -> PaymentIntentSetupFutureUsage' -> Bool)
-> (PaymentIntentSetupFutureUsage'
    -> PaymentIntentSetupFutureUsage' -> Bool)
-> Eq PaymentIntentSetupFutureUsage'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentSetupFutureUsage'
-> PaymentIntentSetupFutureUsage' -> Bool
$c/= :: PaymentIntentSetupFutureUsage'
-> PaymentIntentSetupFutureUsage' -> Bool
== :: PaymentIntentSetupFutureUsage'
-> PaymentIntentSetupFutureUsage' -> Bool
$c== :: PaymentIntentSetupFutureUsage'
-> PaymentIntentSetupFutureUsage' -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentSetupFutureUsage' where
  toJSON :: PaymentIntentSetupFutureUsage' -> Value
toJSON (PaymentIntentSetupFutureUsage'Other Value
val) = Value
val
  toJSON (PaymentIntentSetupFutureUsage'Typed Text
val) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
val
  toJSON (PaymentIntentSetupFutureUsage'
PaymentIntentSetupFutureUsage'EnumOffSession) = Value
"off_session"
  toJSON (PaymentIntentSetupFutureUsage'
PaymentIntentSetupFutureUsage'EnumOnSession) = Value
"on_session"

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentSetupFutureUsage' where
  parseJSON :: Value -> Parser PaymentIntentSetupFutureUsage'
parseJSON Value
val =
    PaymentIntentSetupFutureUsage'
-> Parser PaymentIntentSetupFutureUsage'
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure
      ( if
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"off_session" -> PaymentIntentSetupFutureUsage'
PaymentIntentSetupFutureUsage'EnumOffSession
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"on_session" -> PaymentIntentSetupFutureUsage'
PaymentIntentSetupFutureUsage'EnumOnSession
            | Bool
GHC.Base.otherwise -> Value -> PaymentIntentSetupFutureUsage'
PaymentIntentSetupFutureUsage'Other Value
val
      )

-- | Defines the object schema located at @components.schemas.payment_intent.properties.shipping.anyOf@ in the specification.
--
-- Shipping information for this PaymentIntent.
data PaymentIntentShipping' = PaymentIntentShipping'
  { -- | address:
    PaymentIntentShipping' -> Maybe Address
paymentIntentShipping'Address :: (GHC.Maybe.Maybe Address),
    -- | carrier: The delivery service that shipped a physical product, such as Fedex, UPS, USPS, etc.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentShipping' -> Maybe Text
paymentIntentShipping'Carrier :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | name: Recipient name.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentShipping' -> Maybe Text
paymentIntentShipping'Name :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | phone: Recipient phone (including extension).
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentShipping' -> Maybe Text
paymentIntentShipping'Phone :: (GHC.Maybe.Maybe Data.Text.Internal.Text),
    -- | tracking_number: The tracking number for a physical product, obtained from the delivery service. If multiple tracking numbers were generated for this purchase, please separate them with commas.
    --
    -- Constraints:
    --
    -- * Maximum length of 5000
    PaymentIntentShipping' -> Maybe Text
paymentIntentShipping'TrackingNumber :: (GHC.Maybe.Maybe Data.Text.Internal.Text)
  }
  deriving
    ( Int -> PaymentIntentShipping' -> ShowS
[PaymentIntentShipping'] -> ShowS
PaymentIntentShipping' -> String
(Int -> PaymentIntentShipping' -> ShowS)
-> (PaymentIntentShipping' -> String)
-> ([PaymentIntentShipping'] -> ShowS)
-> Show PaymentIntentShipping'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentShipping'] -> ShowS
$cshowList :: [PaymentIntentShipping'] -> ShowS
show :: PaymentIntentShipping' -> String
$cshow :: PaymentIntentShipping' -> String
showsPrec :: Int -> PaymentIntentShipping' -> ShowS
$cshowsPrec :: Int -> PaymentIntentShipping' -> ShowS
GHC.Show.Show,
      PaymentIntentShipping' -> PaymentIntentShipping' -> Bool
(PaymentIntentShipping' -> PaymentIntentShipping' -> Bool)
-> (PaymentIntentShipping' -> PaymentIntentShipping' -> Bool)
-> Eq PaymentIntentShipping'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentShipping' -> PaymentIntentShipping' -> Bool
$c/= :: PaymentIntentShipping' -> PaymentIntentShipping' -> Bool
== :: PaymentIntentShipping' -> PaymentIntentShipping' -> Bool
$c== :: PaymentIntentShipping' -> PaymentIntentShipping' -> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentShipping' where
  toJSON :: PaymentIntentShipping' -> Value
toJSON PaymentIntentShipping'
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"address" Text -> Maybe Address -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentShipping' -> Maybe Address
paymentIntentShipping'Address PaymentIntentShipping'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"carrier" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentShipping' -> Maybe Text
paymentIntentShipping'Carrier PaymentIntentShipping'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"name" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentShipping' -> Maybe Text
paymentIntentShipping'Name PaymentIntentShipping'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"phone" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentShipping' -> Maybe Text
paymentIntentShipping'Phone PaymentIntentShipping'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"tracking_number" Text -> Maybe Text -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentShipping' -> Maybe Text
paymentIntentShipping'TrackingNumber PaymentIntentShipping'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: PaymentIntentShipping' -> Encoding
toEncoding PaymentIntentShipping'
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"address" Text -> Maybe Address -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentShipping' -> Maybe Address
paymentIntentShipping'Address PaymentIntentShipping'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"carrier" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentShipping' -> Maybe Text
paymentIntentShipping'Carrier PaymentIntentShipping'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"name" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentShipping' -> Maybe Text
paymentIntentShipping'Name PaymentIntentShipping'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> ((Text
"phone" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentShipping' -> Maybe Text
paymentIntentShipping'Phone PaymentIntentShipping'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"tracking_number" Text -> Maybe Text -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentShipping' -> Maybe Text
paymentIntentShipping'TrackingNumber PaymentIntentShipping'
obj)))))

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentShipping' where
  parseJSON :: Value -> Parser PaymentIntentShipping'
parseJSON = String
-> (Object -> Parser PaymentIntentShipping')
-> Value
-> Parser PaymentIntentShipping'
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"PaymentIntentShipping'" (\Object
obj -> (((((Maybe Address
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> Maybe Text
 -> PaymentIntentShipping')
-> Parser
     (Maybe Address
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentShipping')
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> PaymentIntentShipping'
PaymentIntentShipping' Parser
  (Maybe Address
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentShipping')
-> Parser (Maybe Address)
-> Parser
     (Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> Maybe Text
      -> PaymentIntentShipping')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Address)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"address")) Parser
  (Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> Maybe Text
   -> PaymentIntentShipping')
-> Parser (Maybe Text)
-> Parser
     (Maybe Text -> Maybe Text -> Maybe Text -> PaymentIntentShipping')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"carrier")) Parser
  (Maybe Text -> Maybe Text -> Maybe Text -> PaymentIntentShipping')
-> Parser (Maybe Text)
-> Parser (Maybe Text -> Maybe Text -> PaymentIntentShipping')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"name")) Parser (Maybe Text -> Maybe Text -> PaymentIntentShipping')
-> Parser (Maybe Text)
-> Parser (Maybe Text -> PaymentIntentShipping')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"phone")) Parser (Maybe Text -> PaymentIntentShipping')
-> Parser (Maybe Text) -> Parser PaymentIntentShipping'
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Text)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"tracking_number"))

-- | Create a new 'PaymentIntentShipping'' with all required fields.
mkPaymentIntentShipping' :: PaymentIntentShipping'
mkPaymentIntentShipping' :: PaymentIntentShipping'
mkPaymentIntentShipping' =
  PaymentIntentShipping' :: Maybe Address
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> Maybe Text
-> PaymentIntentShipping'
PaymentIntentShipping'
    { paymentIntentShipping'Address :: Maybe Address
paymentIntentShipping'Address = Maybe Address
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentShipping'Carrier :: Maybe Text
paymentIntentShipping'Carrier = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentShipping'Name :: Maybe Text
paymentIntentShipping'Name = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentShipping'Phone :: Maybe Text
paymentIntentShipping'Phone = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentShipping'TrackingNumber :: Maybe Text
paymentIntentShipping'TrackingNumber = Maybe Text
forall a. Maybe a
GHC.Maybe.Nothing
    }

-- | Defines the enum schema located at @components.schemas.payment_intent.properties.status@ in the specification.
--
-- Status of this PaymentIntent, one of \`requires_payment_method\`, \`requires_confirmation\`, \`requires_action\`, \`processing\`, \`requires_capture\`, \`canceled\`, or \`succeeded\`. Read more about each PaymentIntent [status](https:\/\/stripe.com\/docs\/payments\/intents\#intent-statuses).
data PaymentIntentStatus'
  = -- | This case is used if the value encountered during decoding does not match any of the provided cases in the specification.
    PaymentIntentStatus'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.
    PaymentIntentStatus'Typed Data.Text.Internal.Text
  | -- | Represents the JSON value @"canceled"@
    PaymentIntentStatus'EnumCanceled
  | -- | Represents the JSON value @"processing"@
    PaymentIntentStatus'EnumProcessing
  | -- | Represents the JSON value @"requires_action"@
    PaymentIntentStatus'EnumRequiresAction
  | -- | Represents the JSON value @"requires_capture"@
    PaymentIntentStatus'EnumRequiresCapture
  | -- | Represents the JSON value @"requires_confirmation"@
    PaymentIntentStatus'EnumRequiresConfirmation
  | -- | Represents the JSON value @"requires_payment_method"@
    PaymentIntentStatus'EnumRequiresPaymentMethod
  | -- | Represents the JSON value @"succeeded"@
    PaymentIntentStatus'EnumSucceeded
  deriving (Int -> PaymentIntentStatus' -> ShowS
[PaymentIntentStatus'] -> ShowS
PaymentIntentStatus' -> String
(Int -> PaymentIntentStatus' -> ShowS)
-> (PaymentIntentStatus' -> String)
-> ([PaymentIntentStatus'] -> ShowS)
-> Show PaymentIntentStatus'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentStatus'] -> ShowS
$cshowList :: [PaymentIntentStatus'] -> ShowS
show :: PaymentIntentStatus' -> String
$cshow :: PaymentIntentStatus' -> String
showsPrec :: Int -> PaymentIntentStatus' -> ShowS
$cshowsPrec :: Int -> PaymentIntentStatus' -> ShowS
GHC.Show.Show, PaymentIntentStatus' -> PaymentIntentStatus' -> Bool
(PaymentIntentStatus' -> PaymentIntentStatus' -> Bool)
-> (PaymentIntentStatus' -> PaymentIntentStatus' -> Bool)
-> Eq PaymentIntentStatus'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentStatus' -> PaymentIntentStatus' -> Bool
$c/= :: PaymentIntentStatus' -> PaymentIntentStatus' -> Bool
== :: PaymentIntentStatus' -> PaymentIntentStatus' -> Bool
$c== :: PaymentIntentStatus' -> PaymentIntentStatus' -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentStatus' where
  toJSON :: PaymentIntentStatus' -> Value
toJSON (PaymentIntentStatus'Other Value
val) = Value
val
  toJSON (PaymentIntentStatus'Typed Text
val) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
val
  toJSON (PaymentIntentStatus'
PaymentIntentStatus'EnumCanceled) = Value
"canceled"
  toJSON (PaymentIntentStatus'
PaymentIntentStatus'EnumProcessing) = Value
"processing"
  toJSON (PaymentIntentStatus'
PaymentIntentStatus'EnumRequiresAction) = Value
"requires_action"
  toJSON (PaymentIntentStatus'
PaymentIntentStatus'EnumRequiresCapture) = Value
"requires_capture"
  toJSON (PaymentIntentStatus'
PaymentIntentStatus'EnumRequiresConfirmation) = Value
"requires_confirmation"
  toJSON (PaymentIntentStatus'
PaymentIntentStatus'EnumRequiresPaymentMethod) = Value
"requires_payment_method"
  toJSON (PaymentIntentStatus'
PaymentIntentStatus'EnumSucceeded) = Value
"succeeded"

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentStatus' where
  parseJSON :: Value -> Parser PaymentIntentStatus'
parseJSON Value
val =
    PaymentIntentStatus' -> Parser PaymentIntentStatus'
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure
      ( if
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"canceled" -> PaymentIntentStatus'
PaymentIntentStatus'EnumCanceled
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"processing" -> PaymentIntentStatus'
PaymentIntentStatus'EnumProcessing
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"requires_action" -> PaymentIntentStatus'
PaymentIntentStatus'EnumRequiresAction
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"requires_capture" -> PaymentIntentStatus'
PaymentIntentStatus'EnumRequiresCapture
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"requires_confirmation" -> PaymentIntentStatus'
PaymentIntentStatus'EnumRequiresConfirmation
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"requires_payment_method" -> PaymentIntentStatus'
PaymentIntentStatus'EnumRequiresPaymentMethod
            | Value
val Value -> Value -> Bool
forall a. Eq a => a -> a -> Bool
GHC.Classes.== Value
"succeeded" -> PaymentIntentStatus'
PaymentIntentStatus'EnumSucceeded
            | Bool
GHC.Base.otherwise -> Value -> PaymentIntentStatus'
PaymentIntentStatus'Other Value
val
      )

-- | Defines the object schema located at @components.schemas.payment_intent.properties.transfer_data.anyOf@ in the specification.
--
-- The data with which to automatically create a Transfer when the payment is finalized. See the PaymentIntents [use case for connected accounts](https:\\\/\\\/stripe.com\\\/docs\\\/payments\\\/connected-accounts) for details.
data PaymentIntentTransferData' = PaymentIntentTransferData'
  { -- | amount: Amount intended to be collected by this PaymentIntent. A positive integer representing how much to charge in the [smallest currency unit](https:\/\/stripe.com\/docs\/currencies\#zero-decimal) (e.g., 100 cents to charge \$1.00 or 100 to charge ¥100, a zero-decimal currency). The minimum amount is \$0.50 US or [equivalent in charge currency](https:\/\/stripe.com\/docs\/currencies\#minimum-and-maximum-charge-amounts). The amount value supports up to eight digits (e.g., a value of 99999999 for a USD charge of \$999,999.99).
    PaymentIntentTransferData' -> Maybe Int
paymentIntentTransferData'Amount :: (GHC.Maybe.Maybe GHC.Types.Int),
    -- | destination: The account (if any) the payment will be attributed to for tax
    -- reporting, and where funds from the payment will be transferred to upon
    -- payment success.
    PaymentIntentTransferData'
-> Maybe PaymentIntentTransferData'Destination'Variants
paymentIntentTransferData'Destination :: (GHC.Maybe.Maybe PaymentIntentTransferData'Destination'Variants)
  }
  deriving
    ( Int -> PaymentIntentTransferData' -> ShowS
[PaymentIntentTransferData'] -> ShowS
PaymentIntentTransferData' -> String
(Int -> PaymentIntentTransferData' -> ShowS)
-> (PaymentIntentTransferData' -> String)
-> ([PaymentIntentTransferData'] -> ShowS)
-> Show PaymentIntentTransferData'
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentTransferData'] -> ShowS
$cshowList :: [PaymentIntentTransferData'] -> ShowS
show :: PaymentIntentTransferData' -> String
$cshow :: PaymentIntentTransferData' -> String
showsPrec :: Int -> PaymentIntentTransferData' -> ShowS
$cshowsPrec :: Int -> PaymentIntentTransferData' -> ShowS
GHC.Show.Show,
      PaymentIntentTransferData' -> PaymentIntentTransferData' -> Bool
(PaymentIntentTransferData' -> PaymentIntentTransferData' -> Bool)
-> (PaymentIntentTransferData'
    -> PaymentIntentTransferData' -> Bool)
-> Eq PaymentIntentTransferData'
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentTransferData' -> PaymentIntentTransferData' -> Bool
$c/= :: PaymentIntentTransferData' -> PaymentIntentTransferData' -> Bool
== :: PaymentIntentTransferData' -> PaymentIntentTransferData' -> Bool
$c== :: PaymentIntentTransferData' -> PaymentIntentTransferData' -> Bool
GHC.Classes.Eq
    )

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentTransferData' where
  toJSON :: PaymentIntentTransferData' -> Value
toJSON PaymentIntentTransferData'
obj = [Pair] -> Value
Data.Aeson.Types.Internal.object (Text
"amount" Text -> Maybe Int -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentTransferData' -> Maybe Int
paymentIntentTransferData'Amount PaymentIntentTransferData'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: Text
"destination" Text
-> Maybe PaymentIntentTransferData'Destination'Variants -> Pair
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentTransferData'
-> Maybe PaymentIntentTransferData'Destination'Variants
paymentIntentTransferData'Destination PaymentIntentTransferData'
obj Pair -> [Pair] -> [Pair]
forall a. a -> [a] -> [a]
: [Pair]
forall a. Monoid a => a
GHC.Base.mempty)
  toEncoding :: PaymentIntentTransferData' -> Encoding
toEncoding PaymentIntentTransferData'
obj = Series -> Encoding
Data.Aeson.Encoding.Internal.pairs ((Text
"amount" Text -> Maybe Int -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentTransferData' -> Maybe Int
paymentIntentTransferData'Amount PaymentIntentTransferData'
obj) Series -> Series -> Series
forall a. Semigroup a => a -> a -> a
GHC.Base.<> (Text
"destination" Text
-> Maybe PaymentIntentTransferData'Destination'Variants -> Series
forall kv v. (KeyValue kv, ToJSON v) => Text -> v -> kv
Data.Aeson.Types.ToJSON..= PaymentIntentTransferData'
-> Maybe PaymentIntentTransferData'Destination'Variants
paymentIntentTransferData'Destination PaymentIntentTransferData'
obj))

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentTransferData' where
  parseJSON :: Value -> Parser PaymentIntentTransferData'
parseJSON = String
-> (Object -> Parser PaymentIntentTransferData')
-> Value
-> Parser PaymentIntentTransferData'
forall a. String -> (Object -> Parser a) -> Value -> Parser a
Data.Aeson.Types.FromJSON.withObject String
"PaymentIntentTransferData'" (\Object
obj -> ((Maybe Int
 -> Maybe PaymentIntentTransferData'Destination'Variants
 -> PaymentIntentTransferData')
-> Parser
     (Maybe Int
      -> Maybe PaymentIntentTransferData'Destination'Variants
      -> PaymentIntentTransferData')
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure Maybe Int
-> Maybe PaymentIntentTransferData'Destination'Variants
-> PaymentIntentTransferData'
PaymentIntentTransferData' Parser
  (Maybe Int
   -> Maybe PaymentIntentTransferData'Destination'Variants
   -> PaymentIntentTransferData')
-> Parser (Maybe Int)
-> Parser
     (Maybe PaymentIntentTransferData'Destination'Variants
      -> PaymentIntentTransferData')
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object -> Text -> Parser (Maybe Int)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"amount")) Parser
  (Maybe PaymentIntentTransferData'Destination'Variants
   -> PaymentIntentTransferData')
-> Parser (Maybe PaymentIntentTransferData'Destination'Variants)
-> Parser PaymentIntentTransferData'
forall (f :: * -> *) a b. Applicative f => f (a -> b) -> f a -> f b
GHC.Base.<*> (Object
obj Object
-> Text
-> Parser (Maybe PaymentIntentTransferData'Destination'Variants)
forall a. FromJSON a => Object -> Text -> Parser (Maybe a)
Data.Aeson.Types.FromJSON..:? Text
"destination"))

-- | Create a new 'PaymentIntentTransferData'' with all required fields.
mkPaymentIntentTransferData' :: PaymentIntentTransferData'
mkPaymentIntentTransferData' :: PaymentIntentTransferData'
mkPaymentIntentTransferData' =
  PaymentIntentTransferData' :: Maybe Int
-> Maybe PaymentIntentTransferData'Destination'Variants
-> PaymentIntentTransferData'
PaymentIntentTransferData'
    { paymentIntentTransferData'Amount :: Maybe Int
paymentIntentTransferData'Amount = Maybe Int
forall a. Maybe a
GHC.Maybe.Nothing,
      paymentIntentTransferData'Destination :: Maybe PaymentIntentTransferData'Destination'Variants
paymentIntentTransferData'Destination = Maybe PaymentIntentTransferData'Destination'Variants
forall a. Maybe a
GHC.Maybe.Nothing
    }

-- | Defines the oneOf schema located at @components.schemas.payment_intent.properties.transfer_data.anyOf.properties.destination.anyOf@ in the specification.
--
-- The account (if any) the payment will be attributed to for tax
-- reporting, and where funds from the payment will be transferred to upon
-- payment success.
data PaymentIntentTransferData'Destination'Variants
  = PaymentIntentTransferData'Destination'Text Data.Text.Internal.Text
  | PaymentIntentTransferData'Destination'Account Account
  deriving (Int -> PaymentIntentTransferData'Destination'Variants -> ShowS
[PaymentIntentTransferData'Destination'Variants] -> ShowS
PaymentIntentTransferData'Destination'Variants -> String
(Int -> PaymentIntentTransferData'Destination'Variants -> ShowS)
-> (PaymentIntentTransferData'Destination'Variants -> String)
-> ([PaymentIntentTransferData'Destination'Variants] -> ShowS)
-> Show PaymentIntentTransferData'Destination'Variants
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [PaymentIntentTransferData'Destination'Variants] -> ShowS
$cshowList :: [PaymentIntentTransferData'Destination'Variants] -> ShowS
show :: PaymentIntentTransferData'Destination'Variants -> String
$cshow :: PaymentIntentTransferData'Destination'Variants -> String
showsPrec :: Int -> PaymentIntentTransferData'Destination'Variants -> ShowS
$cshowsPrec :: Int -> PaymentIntentTransferData'Destination'Variants -> ShowS
GHC.Show.Show, PaymentIntentTransferData'Destination'Variants
-> PaymentIntentTransferData'Destination'Variants -> Bool
(PaymentIntentTransferData'Destination'Variants
 -> PaymentIntentTransferData'Destination'Variants -> Bool)
-> (PaymentIntentTransferData'Destination'Variants
    -> PaymentIntentTransferData'Destination'Variants -> Bool)
-> Eq PaymentIntentTransferData'Destination'Variants
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PaymentIntentTransferData'Destination'Variants
-> PaymentIntentTransferData'Destination'Variants -> Bool
$c/= :: PaymentIntentTransferData'Destination'Variants
-> PaymentIntentTransferData'Destination'Variants -> Bool
== :: PaymentIntentTransferData'Destination'Variants
-> PaymentIntentTransferData'Destination'Variants -> Bool
$c== :: PaymentIntentTransferData'Destination'Variants
-> PaymentIntentTransferData'Destination'Variants -> Bool
GHC.Classes.Eq)

instance Data.Aeson.Types.ToJSON.ToJSON PaymentIntentTransferData'Destination'Variants where
  toJSON :: PaymentIntentTransferData'Destination'Variants -> Value
toJSON (PaymentIntentTransferData'Destination'Text Text
a) = Text -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Text
a
  toJSON (PaymentIntentTransferData'Destination'Account Account
a) = Account -> Value
forall a. ToJSON a => a -> Value
Data.Aeson.Types.ToJSON.toJSON Account
a

instance Data.Aeson.Types.FromJSON.FromJSON PaymentIntentTransferData'Destination'Variants where
  parseJSON :: Value -> Parser PaymentIntentTransferData'Destination'Variants
parseJSON Value
val = case (Text -> PaymentIntentTransferData'Destination'Variants
PaymentIntentTransferData'Destination'Text (Text -> PaymentIntentTransferData'Destination'Variants)
-> Result Text
-> Result PaymentIntentTransferData'Destination'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Text
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentTransferData'Destination'Variants
-> Result PaymentIntentTransferData'Destination'Variants
-> Result PaymentIntentTransferData'Destination'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> ((Account -> PaymentIntentTransferData'Destination'Variants
PaymentIntentTransferData'Destination'Account (Account -> PaymentIntentTransferData'Destination'Variants)
-> Result Account
-> Result PaymentIntentTransferData'Destination'Variants
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
Data.Functor.<$> Value -> Result Account
forall a. FromJSON a => Value -> Result a
Data.Aeson.Types.FromJSON.fromJSON Value
val) Result PaymentIntentTransferData'Destination'Variants
-> Result PaymentIntentTransferData'Destination'Variants
-> Result PaymentIntentTransferData'Destination'Variants
forall (f :: * -> *) a. Alternative f => f a -> f a -> f a
GHC.Base.<|> String -> Result PaymentIntentTransferData'Destination'Variants
forall a. String -> Result a
Data.Aeson.Types.Internal.Error String
"No variant matched") of
    Data.Aeson.Types.Internal.Success PaymentIntentTransferData'Destination'Variants
a -> PaymentIntentTransferData'Destination'Variants
-> Parser PaymentIntentTransferData'Destination'Variants
forall (f :: * -> *) a. Applicative f => a -> f a
GHC.Base.pure PaymentIntentTransferData'Destination'Variants
a
    Data.Aeson.Types.Internal.Error String
a -> String -> Parser PaymentIntentTransferData'Destination'Variants
forall (m :: * -> *) a. MonadFail m => String -> m a
Control.Monad.Fail.fail String
a