PaymentSheet

constructor(activity: ComponentActivity, callback: PaymentSheetResultCallback)

Constructor to be used when launching PaymentSheet from a ComponentActivity.

Parameters

activity

The Activity that is presenting PaymentSheet.

callback

Called with the result of the payment after PaymentSheet is dismissed.


constructor(activity: ComponentActivity, externalPaymentMethodConfirmHandler: ExternalPaymentMethodConfirmHandler, callback: PaymentSheetResultCallback)

Constructor to be used when launching PaymentSheet from a ComponentActivity and external payment methods are specified in your Configuration.

Parameters

activity

The Activity that is presenting PaymentSheet.

externalPaymentMethodConfirmHandler

Called when a user confirms payment with an external payment method.

callback

Called with the result of the payment after PaymentSheet is dismissed.


constructor(activity: ComponentActivity, createIntentCallback: CreateIntentCallback, paymentResultCallback: PaymentSheetResultCallback)

Constructor to be used when launching PaymentSheet from a ComponentActivity and intending to create and optionally confirm the PaymentIntent or SetupIntent on your server.

Parameters

activity

The Activity that is presenting PaymentSheet.

createIntentCallback

Called when the customer confirms the payment or setup.

paymentResultCallback

Called with the result of the payment or setup after PaymentSheet is dismissed.


constructor(activity: ComponentActivity, createIntentCallback: CreateIntentCallback, externalPaymentMethodConfirmHandler: ExternalPaymentMethodConfirmHandler, paymentResultCallback: PaymentSheetResultCallback)

Constructor to be used when launching PaymentSheet from a ComponentActivity and intending to create and optionally confirm the PaymentIntent or SetupIntent on your server and external payment methods are specified in your Configuration.

Parameters

activity

The Activity that is presenting PaymentSheet.

createIntentCallback

Called when the customer confirms the payment or setup.

externalPaymentMethodConfirmHandler

Called when a user confirms payment with an external payment method.

paymentResultCallback

Called with the result of the payment or setup after PaymentSheet is dismissed.


constructor(fragment: Fragment, callback: PaymentSheetResultCallback)

Constructor to be used when launching the payment sheet from a Fragment.

Parameters

fragment

the Fragment that is presenting the payment sheet.

callback

called with the result of the payment after the payment sheet is dismissed.


constructor(fragment: Fragment, externalPaymentMethodConfirmHandler: ExternalPaymentMethodConfirmHandler, callback: PaymentSheetResultCallback)

Constructor to be used when launching the payment sheet from a Fragment and external payment methods are specified in your Configuration.

Parameters

fragment

the Fragment that is presenting the payment sheet.

externalPaymentMethodConfirmHandler

Called when a user confirms payment with an external payment method.

callback

called with the result of the payment after the payment sheet is dismissed.


constructor(fragment: Fragment, createIntentCallback: CreateIntentCallback, paymentResultCallback: PaymentSheetResultCallback)

Constructor to be used when launching PaymentSheet from a Fragment and intending to create and optionally confirm the PaymentIntent or SetupIntent on your server.

Parameters

fragment

The Fragment that is presenting PaymentSheet.

createIntentCallback

Called when the customer confirms the payment or setup.

paymentResultCallback

Called with the result of the payment or setup after PaymentSheet is dismissed.


constructor(fragment: Fragment, createIntentCallback: CreateIntentCallback, externalPaymentMethodConfirmHandler: ExternalPaymentMethodConfirmHandler, paymentResultCallback: PaymentSheetResultCallback)

Constructor to be used when launching PaymentSheet from a Fragment and intending to create and optionally confirm the PaymentIntent or SetupIntent on your server and external payment methods are specified in your Configuration.

Parameters

fragment

The Fragment that is presenting PaymentSheet.

createIntentCallback

Called when the customer confirms the payment or setup.

externalPaymentMethodConfirmHandler

Called when a user confirms payment with an external payment method.

paymentResultCallback

Called with the result of the payment or setup after PaymentSheet is dismissed.