#tarantino-47_api

1 messages ¡ Page 1 of 1 (latest)

simple voidBOT
#

👋 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.

⏱️ We close idle threads, which makes them read-only. Once a thread is closed it won't be reopened, but you can always start a new thread if you have another question.

🔗 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/1222253391212843118

📝 Have more to share? Add more details, code, screenshots, videos, etc. below.

upbeat cloudBOT
cobalt lance
mental osprey
#

yes, I've already added apple pay and google pay using those guides

#

the problem is I need to know the billing address attached to the users apple pay or google pay card

cobalt lance
#

It should be on the associated Payment Method.

mental osprey
#

I want to simplify the form for a user

upbeat cloudBOT
cobalt lance
#

Can you be more specific about what you're having trouble with? Is the billing info not on the Payment Method? Are you not sure where to find that info? Something else?

mental osprey
#

just a minute

#

in my react-native app I use stripe's PlatformPayButton component. I want to remove the address form from my UI and retrieve user's billing address from his apple or google pay card instead.
can I retrieve a billing address from payment intent or setup intent on the react native client?

junior delta
#

When you create a payment method using the wallets, the billing address gets associated to the payment method object too.

Are you not seeing it when you retrieve the payment method using the API?

#

If so, can you share the code you're using for this? Additionally, an example payment method object you've created pm_xxx would help

mental osprey
#

When you create a payment method using the wallets
what do you mean by wallets?
should I use createPlatformPayPaymentMethod from react native sdk for creating payment methods?

junior delta
mental osprey
#

ok, let me check once again

mental osprey
#

can you help me?
our current implementation is the following, BE creates a payment intent or setup intent associated with a customer and sends it to the FE. On the FE I confirm setup intent and then use that pm token for payments.

how it shoud look like for the case where I create payment method. how to assotiate it with a given customer?

#

I think I can create payment method first, than pass it to the BE, then BE create a setup intent..

junior delta
#

I think I can create payment method first, than pass it to the BE
Correct

our current implementation is the following, BE creates a payment intent or setup intent associated with a customer and sends it to the FE. On the FE I confirm setup intent and then use that pm token for payments.
Typically you'd use this flow with SetupIntents when using PaymentSheet (Mobile Payment Element)
https://docs.stripe.com/payments/save-and-reuse?platform=react-native&mobile-ui=payment-element

Since you're trying to store this using native API Apple Pay and Google Pay APIs (using PlatformPay button), You don't need to create the SetupIntent first