#troyahunt
1 messages · Page 1 of 1 (latest)
hello! there are retries : https://stripe.com/docs/webhooks#retries
you can also list all events : https://stripe.com/docs/api/events/list
Retries don't address this; what if every retry fails? The goal is to identify ongoing failures.
AFAIK, events only list these types: https://stripe.com/docs/api/events/types
What I'm looking for is an API that exposes an event such as "Webhook call failed". Does this exist?
What I'm trying to do is raise an alert when something like you see in the attached image happens. I screwed up some code on my side that killed a bunch of webhook calls, I need to know when this happens short of manually browsing over the dashboard and taking a look.
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
you can't filter by unsent or failed webhook events
so you're going to need to list the events, and then loop through them
there's actually this parameter which might help : https://stripe.com/docs/api/events/object#event_object-pending_webhooks
Complete reference documentation for the Stripe API. Includes code snippets and examples for our Python, Java, PHP, Node.js, Go, Ruby, and .NET libraries.
Given that's on the event object, I assume you'd need to enumerate through events and then look for the number of pending webhooks on each, right?
sorry about the delay, yep, but you might want to double check for events that have no more retries to ensure the pending_webhooks still have a value > 0
otherwise, you may not have a choice other than to retrieve, loop through all the events and validate if they've each been processed in your DB