presentForPaymentIntent

fun presentForPaymentIntent(clientSecret: String, label: String? = null)

Present Google Pay to collect customer payment details and use it to confirm the PaymentIntent represented by clientSecret.

PaymentIntent.currency and PaymentIntent.amount will be used to populate the Google Pay TransactionInfo object.

Parameters

clientSecret

the PaymentIntent's client secret

label

An optional label to display with the amount. Google Pay may or may not display this label depending on its own internal logic. Defaults to a generic label if none is provided.