Reputation: 5547
Is it possible to disable retries on Stripe webhooks? I'm reading this documentation but can't find anything on the topic: https://stripe.com/docs/webhooks/best-practices
I don't want them to ping my endpoint if they already did so previously and failed as the transaction is only valid at the time it was made, not 3 hours later.
Upvotes: 6
Views: 4629
Reputation: 7419
No, that's not possible, but you can respond with a 200 success message to acknowledge receipt upon the retry. For example, you could look at the created
timestamp of the event (https://stripe.com/docs/api/events/object#event_object-created) or use some information about the actual payload object to decide if you consider it important.
What events are you considering in particular, and don't you still want to know about them even if delivery failed previously?
Upvotes: 2