#sweetpotato

1 messages ยท Page 1 of 1 (latest)

limpid kiteBOT
coarse heart
pliant rapids
#

thank you.

#

i have one more question..

#

this error has occurred.

#

Payment was successful, then Payment method can use next time by Customer

#

What should I do?

coarse heart
#

can you paste the PaymentMethod id here for me to take a look?

pliant rapids
#

pm_1NINjZEBFG6Yi3HCQrENQ6yE

#

here..

coarse heart
limpid kiteBOT
pliant rapids
#

but i create the PaymentIntent with setup_future_usage=off_session , i can use only card..

#

i think Customers shold be free to choose payment methods. (alipay,klarna...)

#

so, i want that customer choose payment method(card,klarna,alipay...etc) , and if they select the card and pay successfully , next their card saved

coarse heart
pliant rapids
#

i mean that way only use card.

#

I want to use Klara and Alipay as well as cards

pliant rapids
#

I have never confused.

#

you mean like this picture??

#

This will only return card.

keen moss
#

๐Ÿ‘‹ Taking over this thread, catching up now

pliant rapids
#

hi

keen moss
#

Can you share the payment intent ID (pi_xxx) created from your code above?

pliant rapids
#

pi_3NIPSUEBFG6Yi3HC0opBAbhX : 3 paymentmethod return
pi_3NIPU6EBFG6Yi3HC13cahKE1 :1 paymentMethod return

keen moss
#

Klarna and Alipay don't support saving a payment method. When you set setup_future_usage, both Klarna and Alipay aren't applicable, so they will not be shown. That's why pi_3NIPU6EBFG6Yi3HC13cahKE1 only has one payment method returned.

In pi_3NIPSUEBFG6Yi3HC0opBAbhX that doesn't have setup_future_usage set, it will return the payment methods that support one-time payment.

If you wish to have card with setup_future_usage and Klarna/Alipay for one-time payment shown, that's also possible. You don't set setup_future_usage on the parent request, but on the payment_method_options.card.setup_future_usage (card only) as suggested by alex earlier: https://stripe.com/docs/api/payment_intents/create#create_payment_intent-payment_method_options-card-setup_future_usage

pliant rapids
#

oh i understand..

#

thank you!!

#

Can the paymentmethod id be exposed?

keen moss
#

Payment method is public, but why do you want to expose the customer? It just a random ID that customer probably won't understand

pliant rapids
#

Maybe the member won't see the IDs, but I want to show the last 4 digits and allow the customer to select a card.

#

I want to enable payment with the selected card.

keen moss
#

I see! As long as you can map the selected card with the corresponding payment method ID (pm_xxx), then it should just work

pliant rapids
#

I have one more question..

#

Is there a function to specify a default among the Payment Methods with one time payment?

keen moss
#

There is no default payment method for one-time payment

pliant rapids
#

thank you!