#BRData

1 messages · Page 1 of 1 (latest)

old schoonerBOT
mint marlin
#

Hi again!

waxen reef
#

hello, please ask

#

hello again!

mint marlin
#

I am currently getting this eventType (i am using payment holds and captures)

#

I basically am trying to create a webhook event for only when the payment was successfully held (not captured)

#

I just did a test and I got this event on my webhook:

#

"payment_intent.amount_capturable_updated"

#

Is what I am looking for is called charge.succeeded?

waxen reef
#

no, the event you had before is what you want

#

that explains this also

mint marlin
#

Well I also got a charge.succeeded

#

what is the difference between the both

waxen reef
#

yes you'll get both because a charge is created but ignore the charge ones

#

you're working with PaymentIntents and events pertaining to them give you what you need

mint marlin
#

Im just a bit confused on which one I am looking for as charge.succeeded sounds like the one I want because basically after they hit the "Pay Now" button (after entering in all their CC info) I want to get the name of the event if their CC info was valid and it successfully charged their card with a hold.

waxen reef
#

Im just a bit confused on which one I am looking for as charge.succeeded sounds like the one I want
Charges are legacy objects still used in the API but you don't need to use them in your integration

what you want is payment_intent.amount_capturable_updated to capture a PaymentIntent

I want to get the name of the event if their CC info was valid
yep what I explained above applies here

#

does that help?

mint marlin
#

Yes thank you.

#

What event would I get if the payment hold didnt go through?

mint marlin
#

payment_intent.payment_failed So this one will get called? It has no different name since its a payment capture and not just a regular payment intent

old schoonerBOT
waxen reef
#

@mint marlin sorry but I want to make some things clear here -

payment_intent.payment_failed So this one will get called?
you're asking me but I linked you to a doc that gives you a clear answer so I don't understand the need for the question

It has no different name since its a payment capture and not just a regular payment intent
you find that on the webhook response, capture_method: manual is what tells you if a PaymentIntent is capturable or not. Also the status of the PaymentIntent as requires_capture .

this is all explained in the two docs I linked you