#MiaAPancake - Invoice Authentication

1 messages ยท Page 1 of 1 (latest)

pine hazel
#

When you say "customer authentication" are you referring to a process where the ownership of the Invoice is verified or are you talking about something like 3D Secure?

#

Also, what do you mean by "re-attaching"?

#

It sounds like you're asking about 3D Secure-type authentication, but the terms you're using are ones I'm not familiar with, so wanted to confirm.

spiral raft
#

I think what it's referring to is 3D Secure? it's when I create a subscription via an attached payment_method, the invoice is unpaid and "requires authentication" so I assume 3DS?

pine hazel
#

Ah, gotcha. So what do you mean by re-attaching to the Customer? A payment requiring authentication does not detach the Payment Method from the Customer.

#

Are you talking about the Payment Method being removed from the Payment Intent associated with the Invoice?

spiral raft
#

well so what I currently do is fetch the payment intent client secret attached to the invoice to the client if this happens and go through the normal flow of creating a payment element from the elements api, but this requires the user to re-enter the payment information, and it attaches the card to the customer again. But what I would like to do is just confirm the payment with the already attached payment_method instead of pretty much creating a new one.

pine hazel
spiral raft
#

would confirmPayment work too?

#

or does it have to be confirmCardPayment?

pine hazel
#

stripe.confirmPayment only works with the Payment Element and requires the customer to enter new payment information, which is what you specifically want to avoid. It must be the stripe.confirm*Payment method, where * is the method of payment being used.

spiral raft
#

but from what I gather in step 1 I just have to create my own paymentintent instead of using the one provided by the invoice?

#

or do I have to update the one provided by the invoice?

pine hazel
#

No, you use the existing Payment Intent in step 1.

spiral raft
#

Ah I see

#

my bad

spiral raft
pine hazel
#

No problem! ๐Ÿ™‚

spiral raft
#

Then I know enough for now, I'll try it out :)

#

Thanks again for the help!

pine hazel
#

Always happy to help!

spiral raft
#

alright I managed to do one without the card being re-created.. but the customer still has to enter the cc number etc. when I create the element, am I forgetting something?

pine hazel
#

There is no Element involved here.

spiral raft
#

oh

#

that might be it lmao

pine hazel
#

๐Ÿ˜„

spiral raft
#

I just realized the confirmCardPayment takes a secret, I suppose that opens it on it's own

pine hazel
#

Yep, it uses the Payment Intent's client secret to confirm the Payment Intent client-side using the already-associated Payment Method.

spiral raft
#

ahhhh

#

alright I see the full picture now

pine hazel
#

No Element is involved since no new payment info is involved, it's already on there.

spiral raft
#

Yeah I get it so to do the same with iDeal would be the same but just the stripe.confirmIDealPayment method

#

That's actually a lot more simple than I was thinking

pine hazel
#

Yep!

spiral raft
#

Thanks again, I tend to over complicate things in my head hehe