GooglePayClient

open class GooglePayClient

Used to create and tokenize Google Pay payment methods. For more information see the documentation

Constructors

Link copied to clipboard
constructor(@NonNull activity: FragmentActivity, @NonNull braintreeClient: BraintreeClient)
Create a new instance of GooglePayClient from within an Activity using a BraintreeClient.
constructor(@NonNull fragment: Fragment, @NonNull braintreeClient: BraintreeClient)
Create a new instance of GooglePayClient from within a Fragment using a BraintreeClient.
constructor(@NonNull braintreeClient: BraintreeClient)
Create a new instance of GooglePayClient using a BraintreeClient.

Functions

Link copied to clipboard
Get Braintree specific tokenization parameters for a Google Pay.
Link copied to clipboard
Before starting the Google Pay flow, use this method to check whether the Google Pay API is supported and set up on the device.
Link copied to clipboard
open fun onActivityResult(resultCode: Int, @Nullable data: Intent, @NonNull callback: GooglePayOnActivityResultCallback)
Deprecated.
Link copied to clipboard
Launch a Google Pay request.
Link copied to clipboard
open fun setListener(listener: GooglePayListener)
Add a GooglePayListener to your client to receive results or errors from the Google Pay flow.
Link copied to clipboard
open fun tokenize(paymentData: PaymentData, callback: GooglePayOnActivityResultCallback)
Call this method when you've received a successful PaymentData response from a direct Google Play Services integration to get a GooglePayCardNonce or PayPalAccountNonce.