#tomgullen_api

1 messages ¡ Page 1 of 1 (latest)

compact sparrowBOT
#

👋 Welcome to your new thread!

⏲️ We'll be here soon! Typically we respond in a few minutes, but sometimes we might take a bit longer if the server is busy or if you have a particularly tricky question. Thank you for your patience!

⏱️ We automatically close idle threads, which makes them read-only. Make sure you stick around to chat in realtime! If this thread is closed and you have another question you'll need to start a new thread.

🔗 This thread will always be available, even after it's closed. You can find it again using Discord's search, or you can save this link: https://discord.com/channels/841573134531821608/1214232055534190675

📝 Have more to share? You can add more detail below, including code, screenshots, videos, etc.

naive dove
#

The payment intent charge.billingaddress has the buyers country in it, but we're hoping this is somehow possible to discover before the payment is taken

worldly pelicanBOT
naive dove
#

EG: If Google Pay country != USA, do something

final holly
#

Hello there

naive dove
#

Howdy!

final holly
#

When you say "Payment Requests", do you mean Payment Request Button?

naive dove
#

yes

final holly
naive dove
#

One moment

#

Hurm must of not seen that, am using the guide here:

final holly
#

Gotcha, have you already integrated?

naive dove
#

I've just about finished it yes, is it better to use Express Checkout Element?

#

We have no need to accept Paypal for now as we have our own custom integration for that

final holly
#

I'd recommend using Express Checkout Element, yes. It has better/more functionality. But up to you as Payment Request Button is also still supported. In both cases, what you want to do is actually inspect the PaymentMethod for the country before you actually confirm the PaymentIntent.

#

So with Payment Request Button you want to take the ev.paymentMethod.id and pass it to your backend

#

That will show you the full details of the card, and you can then dictate what you set on your PaymentIntent (either via creating it at that point, or updating it) before confirming it.

naive dove
#

That's awesome thank you!

#

Exactly what I was looking for

#

This will work great thank you for the help and advice

final holly
#

Sure thing