#kanwardanial_invoice-webhooks
1 messages ¡ Page 1 of 1 (latest)
đ 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.
Hello! The Invoice finalization event is evt_1Otq5k4V4UG4b3QnmfXSRHar and it was definitely sent to one of your webhook endpoints
We facing this issue that event not fired after invoice.payment_succeeded event
My webhook Call set on invoice.finalized event
If you've specifically written your webhook logic to always expect invoice.finalized after invoice.payment_succeeded that won't work - we don't guarntee webhook order (https://docs.stripe.com/webhooks#event-ordering)
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.
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
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.
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
Got It
kanwardanial_invoice-webhooks
So in the case why charge Id is different ?
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
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?
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
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?
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
Thanks man for your kind support with full of knowledge.