#henrique_code

1 messages ¡ Page 1 of 1 (latest)

edgy craneBOT
#

👋 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/1341421449696772129

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

ionic jay
#

Hey,

To be able to pay with Link payment method, I need to update the PaymentElement options, and due to the update the PE is refreshed which loses the Link payment authentication, therefore the PE looks like it is trying to process a card instead.

errant gale
#

What did you have to update the options to for Link to work?

ionic jay
#

We have to do this because it breaks our integration. Let me fetch the errors.

#

If I don't update the stripe elements, I got this error here

#

I would like to re-use the payment methdo

#

I can't use or attach the payment method created during the BNPL for future payments.

errant gale
#

Ah ok I understand

#

Yeah there's not really a way to preserve the link auth

#

I think if you need to accept bnpl, then it may make more sense for you to present the option for that payment method ahead of time to the customer before rending the Payment Element

#

That way you can know what options to pass on render

ionic jay
#

As far as I remember, I can't create invoices with those payment methods

#

For BNPL I'm creating the payment intent direclty, the other payments I'm using invoices.

errant gale
#

Yeah that's correct

ionic jay
#

Is there any alternatives to it?

errant gale
#

Not really. If a customer selects link like that and then you change the element options, you cannot preserve the auth

#

That's why I suggest you have some page/step first for the customer to indicate whether they want a bnpl payment ahead of time

#

And then maybe only render the bnpl payment method if they opt for that (ie hide link, card, etc)

ionic jay
#

Then, I can't really use the BNPL selector in PE, right?

errant gale
#

Correct

#

There's not a way to preserve the link auth

ionic jay
#

The correct fix would using the Payment Intent instead, right? At leastt, we would be able to select both payment methods.

errant gale
#

You still wouldn't be able to use setup future usage for bnpl

#

So if you went that route, you'd have to not use setup_future_usage for any payment method

ionic jay
#

Got it.

#

Do you know if every time I update the PE it would be re-rendered?

errant gale
#

Yes I believe all option updates trigger a re-render

ionic jay
#

Okidoki

#

Yeah, unfortunately it is not the news I'd like to receive. But thanks for all the explanations and clarifications @errant gale