#meger-reactnative-googlepay

1 messages · Page 1 of 1 (latest)

foggy remnantBOT
candid ivy
#

@vapid shard let's chat here!

vapid shard
#

Ok

candid ivy
#

Can you share more details? Which documentation are you referencing and how are you trying to accept GooglePay payments?

vapid shard
#

I am using this doc

#

React native tab

#

I have GooglePayButton active on my emulator

#

On click I get back the successful alert message

#

With no googlepay pop up sheet

candid ivy
#

And you're calling presentGooglePay? Can you share some of your code?

vapid shard
#

Yes I did call it

#

I am using the exact code on the doc, the only changes is the function that get clientSecret

#

Which is for the intent

#

Also I wrap my GooglePayButton with stripe provider probably it will work

#

Nothing comes up only the alert message

candid ivy
#

Got it, thanks for the context. I'm not too familiar with React Native so I'm getting some help from a teammate

vapid shard
#

here are some screen shot, may be you should send it along

deft wraith
#

Hi 👋

As a place to start can you try logging the clientSecret value before you call presentGooglePay?

vapid shard
#

i did before it working

#

i will do it now

#

take a look at the log below

deft wraith
#

Please don't send screenshots, they aren't very useful to me.

#

If you could copy the log message and paste here that will help

vapid shard
#

what do you need

#

the intent?

deft wraith
#

SO you are getting the client secret immediately prior to calling presentGooglePay?

vapid shard
#

yes that is correct

deft wraith
#

Wait wait wait. Where are you returning the Google Pay Button view?

#

This

 return (
    <View >
      <GooglePayButton
        type="standard"
        onPress={pay}
        style={{
          width: '100%',
          height: 50,
        }}
      />
    </View>
  );
vapid shard
#

yes no error, the catch will will display the error message instead

#

the same page i made the call

#

<StripeProvider
publishableKey={key}
urlScheme="your-url-scheme" // required for 3D Secure and bank redirects
merchantIdentifier="merchant.com.{{NafoloPay}}" // required for Apple Pay
>
<GooglePayButton
type="standard"
onPress={()=> pay()}
style={{
width: '100%',
height: 50,
marginTop: 50,
justifyContent: "flex-end",
borderRadius: 25,
}}
/>
</StripeProvider>

#

i did this hopefully it work

#

i did wrap it with a provider

#

i also encounter some issue with the card payment, not until i watch one of your video on Youtube, before i discovered, there is a different import made from a hook. As for this i could not find any related video.

deft wraith
#

AFAIK the merchant identifier shouldn't include the curly braces { but I don't think that's the specific problem here

#

Can you share the Payment Intent ID so I can check that?

vapid shard
#

pi_3MbB4FHKujt7W19a1FdVac6Z_secret_NkEQ4rcVnsWdWuveTflHKmL4E here it is

deft wraith
#

Okay everything looks fine there.

vapid shard
#

i just did this

#

const data = await presentGooglePay({
clientSecret: paymentIntent,
forSetupIntent: false,
});

#

may be there is a key identifier

#

also the presentGoogle function is it suppose to return something?

#

because on click i tried consoling data, i got nothing

deft wraith
vapid shard
#

ok on it

#

let me take my time to check it out, i will come back if i still need help. Thank you

nova terrace
#

meger-reactnative-googlepay