#lennartzellmer-android-payment-sheet
1 messages ยท Page 1 of 1 (latest)
Hey! Have you added a payment method to your Google Pay wallet? https://developers.google.com/pay/api/android/guides/setup
This needs to be a real card (not a Stripe test card). We'll swap it out for a fake token in test mode
Yes! That is set up and we used a real credit card
Can you share your Stripe account ID? acct_xxx
Can you share the code where you're configuring/initialising the PaymentSheet UI
internal object StripeConfig {
private const val publishableKey = "XXXXXXXXXXXXX"
private val googlePayConfiguration = PaymentSheet.GooglePayConfiguration(
environment = PaymentSheet.GooglePayConfiguration.Environment.Test, // TODO: check env
countryCode = "DE"
)
fun getSheetConfiguration(
context: Context,
): PaymentSheet.Configuration {
PaymentConfiguration.init(
context,
publishableKey,
)
return PaymentSheet.Configuration(
merchantDisplayName = "elvah", // TODO: get from strings
allowsDelayedPaymentMethods = true,
googlePay = googlePayConfiguration,
)
}
}
cc @zealous vortex
Hello @tardy obsidian we are working currently to enable google pay.
just to clarify, a common problem I see here is you have the "wrong" version of Google Pay installed on the phone (https://play.google.com/store/apps/details?id=com.google.android.apps.nbu.paisa.user is a version specific to the Indian market and is not supported by our SDK, it's https://play.google.com/store/apps/details?id=com.google.android.apps.walletnfcrel that is the one that has to be installed, with active cards of brands we accept(e.g. Visa/Mastercard)) added to it.
also it only works on a physical device in case that's not clear, the adb simulators don't have any GPay functionality
We are using a Google Pixel 3 and i just verified that we have the correct Google Pay app installed and a visa card added to Google Pay
(I am a colleague of @quasi stream )
maybe try running the app on other colleague's phones and see if it works on any of them
FWIW I'm just spinning up my own test app to verify something, though it might take a while
Thanks for taking over @zealous vortex
@fluid linden we currently don't have other phones available, sorry
credit card works fine but Google Pay is not shown
Do you have a test app that we could try to verify if its an issue with my phone or with our setup?
do we have to enable something on the setupintent that is used here?
we are currently setting it up like this.
Its also strange that we dont see sepa as an option on the payment sheet
SetupIntent.create( SetupIntentCreateParams.builder() .setCustomer(user.payment.customerId) .addAllPaymentMethodType(listOf("card", "sepa_debit")) .setUsage(SetupIntentCreateParams.Usage.OFF_SESSION) .build(), requestFactory.requestOptions() )
can we keep it to one issue at a time?
I added some money to my Revolut account via Google Pay. This should confirm that Google Pay is working fine.
Lets stick to Google Pay for now ๐
yes sorry i thoght it might be related to the config
anyway you don't see SEPA because we don't support that for Setup right now
okay understood
as for Google Pay, I'm thinking/confirming something on my own app(and helping other users, so it might be a while)
Thank you for the details ๐
Take your time, we are not in a rush
thank you!
it's working for me at least(though this is with a saved customer so the UI is a little different).
Do you have android:name="com.google.android.gms.wallet.api.enabled" set to true in your manifest by the way?
I can't no
you are using SetupIntents anyway, right? I'm using a PaymentIntent so maybe it's different
correct
I'll test that too so give me a while
Thank you very much!
yeah I don't get Google Pay when using presentWithSetupIntent
I suppose it's intentional then(there's some uncertainty over whether it makes sense to use Google Pay in use cases where the card is not immediately saved which is probably involved)
it does seems to contradict the documentation for the SDK though so I'm not sure if I'm missing something, it does feel like it should just work
From the documentation it should clearly be possible to use google pay with SetupIntents... thats why we are so confused
@quasi stream found the issue!
we need to pass currencyCode to GooglePayConfiguration in order to make the googlePay option appear
maybe thats something for the SDK documentation ๐
oh, hmm.
Thank You very much! perfect!
Thank you @fluid linden
๐