#ss2021-refunds

1 messages ยท Page 1 of 1 (latest)

acoustic yarrow
#

๐Ÿ‘‹ howdy

verbal stone
#

๐Ÿ‘‹

acoustic yarrow
#

so the follow up would get an event, yes, when the state changed

#

i don't think the initial request would get one as you would know this in the API response, its not updated per se, but trying to see if i can test

verbal stone
acoustic yarrow
#

The one you said, yea: charge.refund.updated

verbal stone
#

oh okay

#

so if the refund goes straight to a successful state (skips pending state) then the charge.refunded event will fire but if goes to pending state then successful state then charge.refund.updated will fire instead correct?

acoustic yarrow
#

Oh sorry, i've got this mixed up. Disregard and let me review.

verbal stone
#

ok

acoustic yarrow
#

Going back, yes what i said before is true for eg card refunds that go pending because of an insufficient balance

verbal stone
#

okay..

grave bronze
#

Hello! @acoustic yarrow had to step away, let me get caught up...

#

Are you asking specifically about ACH payments or other methods of payment as well?

#

Going back to your original questions:

When the status of a refund on a charge goes into the pending state does the charge.refund.updated web hook event get fired?

It will fire if the refund fails. See here for details: https://stripe.com/docs/refunds#failed-refunds

And once that pending refund succeeds (going from pending state to successful state), what web hook event is fired? charge.refund.updated? charge.refunded? some other event?

If the refund succeeds charge.refunded will fire.

#

so if the refund goes straight to a successful state (skips pending state) then the charge.refunded event will fire but if goes to pending state then successful state then charge.refund.updated will fire instead correct?

This is correct, yep.

grave bronze
#

Actually, wait, I think I misread...

verbal stone
grave bronze
#

so if the refund goes straight to a successful state (skips pending state) then the charge.refunded event will fire

This is correct.

but if goes to pending state then successful state then charge.refund.updated will fire instead correct?

If the refund succeeds you'll get charge.refunded: https://stripe.com/docs/api/events/types#event_types-charge.refunded

#

Not sure what you mean about it staying pending? Can you give me an example scenario?

verbal stone
#

e.g.
https://support.stripe.com/questions/pending-refunds-due-to-insufficient-funds-or-stripe-balance

In the event you issue a refund to a customer that results in a negative Stripe balance, the refund will show as โ€œpending.โ€

grave bronze
#

Right, but I don't understand your question about that?

verbal stone
#

so would the charge.refunded event fire if a refund with status of pending then succeeds

#

or would charge.refund.updated run since the status value is being updated from pending to successful

#

or perhaps both?

solemn meteor
#

๐Ÿ‘‹ Hi @verbal stone I'm just hopping in since @grave bronze has to step away, give me a minute to find the answer

#

From my understanding the charge.refunded event will be fired when the refund is created (even if it's pending). When it transitions to successful we do not send an additional event.

#

If it transitions to failed, then we do send a charge.refund.updated event

verbal stone
#

ah okay makes sense

#

Thank you!