Polling With a Webhook Fallback: The Reliability Pattern for Production Automation
Webhooks are fast but fragile. Polling is reliable but wasteful. The pattern that production automation actually uses combines both, with webhooks as an accelerator and polling as the source of truth.
Webhooks are fast. They deliver an event within seconds of it happening. That is their entire value proposition. But they are also fragile, and when they fail, the automation that depended on them fails with them.
Polling is reliable. It does not care whether an upstream API is having an incident. It checks, it finds the state, it acts. But it is wasteful, and it is slow, and for event-driven workflows it introduces an unacceptable delay between event and action.
The pattern that production automation builders are converging on is neither. It is polling with a webhook fallback, and it is the difference between an automation that survives a provider incident and one that does not.
Why Webhook-Only Architectures Break
A webhook is a promise that someone will POST something to your endpoint. That promise has conditions, and those conditions are outside your control. The upstream API can go down. Your endpoint can be unreachable. A transient network error can occur between the two. A payload can arrive malformed, or not at all, and the upstream API can decide it delivered the event successfully even though your application never processed it.
Every one of these failure modes is a silent gap in your automation. The event happened. Your workflow did not run. Nothing told you that it had not run, because the webhook provider considered the delivery complete. You discover the gap days later when a customer complains, or when a monthly reconciliation does not balance.
The GitHub incident from May 2026 is a textbook example. Issues with GitHub's webhook delivery system meant that events which had already occurred were not being pushed to integrations. For any automation that triggered on GitHub webhooks, the gap was invisible until someone noticed the missing data. There was no error to catch, no failure to retry. The webhook system had simply stopped delivering.
Why Pure Polling Is Not the Answer Either
Polling solves the reliability problem completely, at the cost of efficiency and latency. If you poll every minute, you can miss an event by up to sixty seconds. If you poll every ten seconds, you burn API quota and risk hitting rate limits on the very APIs you are depending on. If the upstream API enforces a rate limit of, say, 60 requests per minute, you cannot poll more often than once per second without triggering throttling, and throttling means your polling also fails.
For batch jobs, polling at a generous interval is fine. For customer-facing or time-sensitive automation, the delay is unacceptable. A lead that arrives in your CRM via a webhook should trigger a follow-up sequence within seconds, not within the interval between two poll cycles.
The Polling-with-Fallback Pattern
The pattern is simple to describe and takes real engineering effort to implement correctly. You build your automation on polling as the authoritative mechanism. Every state change is confirmed by a poll cycle, never by a webhook alone. Then you layer webhooks on top as an accelerator: when a webhook arrives, you trigger an immediate poll cycle rather than waiting for the next scheduled one.
ComponentRoleFailure modeScheduled pollerSource of truth. Confirms state independently of any push mechanism.Latency between cycles. Rate-limit risk if interval is too short.Webhook receiverAccelerator. Triggers an out-of-cycle poll when an event arrives.Missed delivery, duplicate delivery, malformed payload.Deduplication layerPrevents the same event from being processed twice, whether it arrived via poll or webhook.None, if implemented correctly. This is the safety net.
The result is an architecture where webhooks can fail completely and the automation keeps running, at the cost of a small delay. The webhook is an optimisation, not a dependency. The moment it recovers, the automation returns to near-real-time without any manual intervention.
How to Implement the Deduplication Layer
The deduplication layer is what makes the pattern safe. Without it, a webhook that arrives and triggers a poll, followed by the scheduled poll that runs on time, processes the same event twice. Duplicate processing is the second most common failure in webhook-dependent automation, after missed delivery.
The standard approach is to give every upstream event a unique identifier and to store the identifiers of events you have already processed. When a poll or a webhook delivers an event, you check the store first. If the identifier is present, you skip it. If it is not, you process it and record the identifier.
The store needs to be fast and it needs to survive your own infrastructure going down. A Redis set with a TTL works for most use cases. For cross-process or cross-service deduplication, a database table with a unique constraint on the event identifier is the simplest robust option. The unique constraint means that even if your application code tries to insert a duplicate, the database rejects it, and you handle the exception gracefully.
Three Polling Strategies Worth Knowing
Not all polling is equal. The interval you choose and how you vary it matters more than the polling itself.
Fixed interval. Simple to implement and easy to reason about. Use it when the upstream API has generous rate limits and the latency cost of a fixed interval is acceptable. Most automation that runs on a five-minute cron is effectively using this strategy, with or without a webhook accelerator on top.
Exponential backoff. When the upstream API is returning errors or rate-limit responses, you increase the polling interval gradually. This reduces pressure on a struggling API and gives it time to recover. It is a small change to a poller and it has an outsized impact on stability during provider incidents.
Event-driven polling. The webhook triggers an immediate poll, and the poll result determines the next interval. If the poll finds new data, you poll again sooner. If it finds nothing, you return to the scheduled interval. This adapts the polling rate to actual activity rather than to a fixed clock.
When to Use Webhooks at All
The polling-with-fallback pattern does not mean you should never use a webhook. It means you should use webhooks only where the latency benefit justifies the reliability cost, and you should always pair them with a polling safety net.
Use the pattern when the cost of a missed event is high and the cost of a small delay is low. A lead entering your CRM is a good candidate: missing a lead is catastrophic, a thirty-second delay in starting the follow-up sequence is not. A nightly reconciliation job is not a good candidate: the webhook adds complexity without meaningful benefit, and plain polling is simpler and just as reliable.
The pattern is also worth considering when your upstream API has unreliable webhook delivery but a usable REST or GraphQL endpoint for polling. Many APIs fall into this category. Their webhook infrastructure is maintained by a different team than their REST API, and the REST API is generally the more mature and more reliable interface. Polling it directly removes an entire class of failure from your stack.
The Zero-Webhook Alternative
Some builders are going further and removing webhooks entirely. The Flowglad payment processor, for example, is built on a zero-webhook architecture. It uses a reactive programming model where the application state is the source of truth and user-facing behaviour updates in real time without any push mechanism from an external provider. This is a more radical redesign than polling-with-fallback, and it works best when you control more of the stack or when the upstream API does not offer reliable webhooks at all.
For most automation builders, polling-with-fallback is the pragmatic middle ground. It does not require redesigning your integration. It requires adding a poller and a deduplication layer, and it gives you back the confidence that your automation will still be running tomorrow even if the API you depend on has a bad day.
That confidence is worth more than the few seconds of latency a webhook saves you on a good day. On a bad day, it is the difference between an automation that works and one that silently fails.