#sov-paymentelement-pmts

1 messages · Page 1 of 1 (latest)

plain estuaryBOT
#

Hello! We'll be with you shortly. Below are links to other discussions we've had with you in the past week in case you want to review that information. If your question is related to one of these previous discussions, please provide a comprehensive summary of the current state and what you need help with now. We help many users simultaneously, so a summary allows us to resolve your issue as soon as possible.

gloomy vigil
silk tapir
#

Yes, one moment!

#

I'm using the ruby SDK and this is what I am doing to create the intent

Stripe::PaymentIntent.create({
  amount: 50000,
  currency: "usd",
  customer: @user.stripe_customer_id,
  payment_method_types: %w[affirm]
})

Here's the corresponding request id req_JI6Mwd2K6Jc4ip

plain estuaryBOT
silk tapir
#

Here's the payment element when supplying the client secret of that PI

glossy pumice
#

sov-paymentelement-pmts

#

@silk tapir Can you share the client-side code?

silk tapir
#

Ah, I found the issue! The customer I was testing with did not have an associated card method yet. After adding one, the PaymentElement is doing what I expect and only showing the affirm option

glossy pumice
#

that doesn't really make sense to me

#

having "an associated card" is irrelevant

silk tapir
#

Happy to continue working through this if you think there's an issue here. But I manually added a card method to that customer from the dashboard. After reloading the page on my checkout, this is what I see now.

glossy pumice
#

yeah my point is that doesn't make sense really. PaymentElement renders a list of payment methods as configured on the PaymentIntent. The example you gave earlier only has Affirm and should only show Affirm.
So there's a bug somewhere in your code where you likely are not showing the right information/using the right client_secret

silk tapir
#

Let me run through it again with a fresh customer and see if I can reproduce

#

Unable to reproduce. You're probably right that it was a client side issue and a cache was using a previous client secret. Sorry for the trouble and thanks for your help!