#typek3
1 messages · Page 1 of 1 (latest)
Hello! When you say it won't work what does that mean? Are you seeing an error?
Yes
give me a sec, I will paste it
stripe.error.InvalidRequestError: Request req_VX0YpXArDbltIU: setup_future_usage cannot be used with one or more of the values you specified in payment_method_types. Please remove setup_future_usage or remove these types from payment_method_types: ["klarna"].
Ah, gotcha, so you're trying to create a Payment Intent. The error message is correct, Klarna can't be set up for future use, it doesn't support recurring payments.
Well, I don't want to have recurring payment but on_session
and I don't want it for Klarna but for cards
That's not how Klarna works.
I know
Let's back up. What are you trying to build?
We want to provide users with option of chosing multiple payment methods like cards, sepa, klarna etc.
On the frontend we use elements
However, the requirement is that if user pays with the card, we should save this card for further usage.
And accordingly to docs, to attach payment method to user, the recommended way is to do this with setup_future_usage="on_session"
You need to set setup_future_usage for just card in that case, not at the top-level of the Payment Intent: https://stripe.com/docs/api/payment_intents/create#create_payment_intent-payment_method_options-card-setup_future_usage
Ah!
Thanks!
So one more questions about Klarna
Can I specify country also using options or if our business is located in US we can use Klarna only for US customers?
If your Stripe account is in the US you can only accept Klarna from customers in the US. See the table here for details: https://stripe.com/docs/payments/klarna