Search code examples
androidbraintreebraintree-sandboxgoogle-pay

Google Pay integration using Braintree Drop-In UI


I have completed integrating the Braintree gateway as my payments processor in my Android app. I use the Drop-In UI to complete the payments with the Google Pay option enabled. Everything is working as expected in the Sandbox environment and now I have created a producrtion account and got approved by Braintree.

In order to enable the Google Pay option I have to get my app reviewed by Google as well, following the process listed in the link below: Google Pay integration checklist

Among other things, the docs state that I have to use the WalletConstants.ENVIRONMENT_TEST when I submit my app.

I don't think the Google Pay initilization is editable by the drop in sdk, so there is nowhere in the Braintree Google Pay setup a way to set the WalletOptions environment to WalletConstants.ENVIRONMENT_TEST. So should I send a Sandbox build/account of my app for review? Does Braintree's Sandbox corresponds to setting the environment parameter from WalletOptionsWalletConstants.ENVIRONMENT_TEST?

It's a simple question, but Braintree support did not have an answer.


Solution

  • Full disclosure: I work at Braintree. If you have any further questions, feel free to contact support.

    The android Drop-in UI has a dependency on Braintree's Android SDK. In the Android SDK, the WalletOptions environment is determined based on whether you are initializing the Braintree environment with sandbox or production credentials.

    So if you create an app using Braintree sandbox credentials, WalletConstants.ENVIRONMENT_TEST should be set for you.