#DramaLLama-invoice

1 messages ยท Page 1 of 1 (latest)

shrewd arch
upper maple
#

in_1JhA1yAGARJ0eCQvB2P1Jolz Yes I don't seem to get a payment intent anymore so probably detached like you say

#

hmmm no, looking it up it still has a payment intent

shrewd arch
#

yep it will always have a PaymentIntent!

#

but the Payment_Method_ gets detached from the PaymentIntent when there's a failure(the idea being that it makes it easier to have the user just enter and use a new one)

upper maple
#

ahh, so close terms!

#

When one doesn't work with this daily

shrewd arch
#

so yeah I think if you want to retry with the same card you'd call confirmCardPayment with the clientsecret + payment method ID as above(you could have a UI for this with "try existing card again" or "enter a new card")

upper maple
#

Is there anyway of reattaching this in the dashboard

#

this will be very rare right now

#

so manual step would be fine

#

ahh, I see it also shifted from action required to "requires_payment_method" on status

shrewd arch
#

yep when there' a failure it goes back to requires_payment_method to make it easier to attach a new one basically

upper maple
#

problem is, we don't work like that at all.

We only allow one card on our end and wipe other payment methods upon setting up new one

#

So for us this makes no sense

#

Can I in dashboard re-attach the card to the invoice so it goes back to action_required

shrewd arch
#

I don't think that's something that can be done in the dashboard .

upper maple
#

Can it be done by an api call?

#

Basically I don't have time to write this into proper code. Honestly I don't expect this to happen for months if not years.

So I just need a workaround I can do if/when that happens

shrewd arch
#

Thee API call is to confirm the PaymentIntent with confirmCardPayment as described above.

#

handing off to @autumn warren

autumn warren
#

๐Ÿ‘‹

upper maple
#

Ah okay, so with post to paymentintent I can reattach an existing payment method?

#

so to bring you up to date I have this scenario

  1. customer gets billed offline
  2. Requires sca auth
  3. customer goes to page but declines
  4. now payment method is detached from payment intent and status of payment intent is require card and not requrie action.

when this happens I just need a manual workaround for now to bring it back to requires_action so the user can try authing again.

#

We don't allow multiple payment methods so thats a non issue

autumn warren
#

yep, you can provide the same customer PM to a PI again if you want -- it's not detached from the customer, so you can use it again if you expect it to work

#

YOu could use it to update a PI, confirm a PI, pay and Invoice etc

upper maple
#

So if I have an invoice that in turn has pi that used to have a pm.

This pi had "requires_action" on status (sca auth).

When they manually declined it they detached the pm from the pi. then the status of pi was also require_pm instead of require_action

now of I manually reattach the pm will pi automatically go back to status action_required?

#

I tested, and it did ๐Ÿ™‚

autumn warren
#

No, you'd need to confirm the payment intent again, preferably with the customer on session to handle 3d secure and using confirmCardPayment in the client app

upper maple
#

what I did was call confirm on payment intent with card

#

Then it went back to action_required

#

so then my customer could again go to page and retry their card

autumn warren
#

yep, that should do it

#

(you confirmed it, as i noted was necessary)

#

if you just updated the PI to provide the PM, it wouldnt advance automatically

upper maple
#

ah right, great, then this is my workaround for now!

#

Thank you for the help!

autumn warren
#

quite welcome ๐Ÿ™‚