createWithPaymentMethodId

fun createWithPaymentMethodId(paymentMethodId: String, clientSecret: String, savePaymentMethod: Boolean? = null, paymentMethodOptions: PaymentMethodOptionsParams? = null, mandateId: String? = null, mandateData: MandateDataParams? = null, setupFutureUsage: ConfirmPaymentIntentParams.SetupFutureUsage? = null, shipping: ConfirmPaymentIntentParams.Shipping? = null): ConfirmPaymentIntentParams

Create the parameters necessary for confirming a PaymentIntent while attaching a PaymentMethod that already exists.

Parameters

paymentMethodId

the ID of the PaymentMethod that is being attached to the PaymentIntent being confirmed

clientSecret

client secret from the PaymentIntent being confirmed

savePaymentMethod

Set to true to save this PaymentIntent’s payment method to the associated Customer, if the payment method is not already attached. This parameter only applies to the payment method passed in the same request or the current payment method attached to the PaymentIntent and must be specified again if a new payment method is added.

paymentMethodOptions
mandateId

Optional ID of the Mandate to be used for this payment.

mandateData

Optional details about the Mandate to create.

setupFutureUsage

Optional. See SetupFutureUsage.

shipping

Optional. See Shipping.