#kanwardanial_invoice-webhooks

1 messages ¡ Page 1 of 1 (latest)

cloud sedgeBOT
#

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

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

untold swanBOT
deep prairie
#

Hello! The Invoice finalization event is evt_1Otq5k4V4UG4b3QnmfXSRHar and it was definitely sent to one of your webhook endpoints

opaque cairn
#

We facing this issue that event not fired after invoice.payment_succeeded event

#

My webhook Call set on invoice.finalized event

deep prairie
opaque cairn
#

Is this happened in any specific case like if sometime payment get failed by any reson?

#

Also irder is not my concern, I am looking for event "invoice.finalized" that is not fired to write the object in db, any solution for this.

deep prairie
#

Is there a specific webhook endpoint you're expecting the invoice.finalized event to go to? The event is definitely being created and sent to some of your webhook endpoints (you can see it at https://dashboard.stripe.com/events/evt_1Otq5k4V4UG4b3QnmfXSRHar) so if it's not being saved to your DB something must be wrong in the logic on your end

opaque cairn
#

Ok i will check that logic, but still i am confused if event "invoice.finalized" created and then getting failed, it means every events must be created again and all are created in same sequence only invoice.finalized not created.

deep prairie
#

No, Invoice finalization is something that only happens once - if payment fails you won't get another finalization event because the invoice is already finalized.

#

You an attempt payment on an already finalized Invoice multiple times

opaque cairn
#

Got It

cloud sedgeBOT
#

kanwardanial_invoice-webhooks

opaque cairn
#

So in the case why charge Id is different ?

deep prairie
#

Charge ID is completely unrelated to the invoice being finalized

#

We'd create a new charge when you re-attempt payment, but the invoice has already been finalized and we don't need to finalize it again

opaque cairn
#

Ok

#

so how we identified that is unique, and not reverting our webhook response, because currently we identifying the charge_id as unique identifier and now its in our system as failed event so in this case what other event we use for our webhook response?

deep prairie
#

I'm not fully sure how your logic works, but if you need a unique identifier for the Invoice you'd want the Invoice ID

opaque cairn
#

so in case can we use invoice.paid instead of invoice.finalized?

#

is invoice.paid is final event that have all properties that finalized event have? and a payment confirmation?

deep prairie
#

If you want an event that notifies you when the event is fully paid then yes, invoice.paid would be what you want and it would include the charge

opaque cairn
#

Thanks man for your kind support with full of knowledge.