---
title: "Get alerted when a webhook fails — How-to Guide"
description: "Five minutes from a silent failure to a Slack card or an email the moment a delivery gives up — with a quiet time so a bad hour is one message, not a hundred."
url: "https://wpwebhooks.org/docs/alert-on-failed-webhooks/"
---

[WP Webhooks](https://wpwebhooks.org/) / [Docs](https://wpwebhooks.org/docs/) / Get alerted when a webhook fails

How to since v3.3.0

# Get alerted when a webhook fails

Five minutes from a silent failure to a Slack card or an email the moment a delivery gives up — with a quiet time so a bad hour is one message, not a hundred.

Retries handle the flaky minute; this guide handles the endpoint that stays down. You add one channel (where the message goes), one rule (when it goes), send a test, and then decide per webhook whether it inherits that rule. Everything here is free. Slack is used for the channel because it is the most common ask — every other channel type works the same way, only the fields on the form differ.

## Which event should I use?

**Permanently failed** is the one that means "act now" — the plugin has stopped trying. **Attempt failed** fires on every failed try, so pair it with filters or a quiet time. **Retry scheduled** is the same moment as a failed attempt but tells you when the next try is. **Recovered** is the all-clear after a failure — point it at the same PagerDuty channel as your permanently-failed rule and the incident resolves itself. **Delivered** fires on every success; use it with a daily digest for a morning summary, never raw on a busy site. **Skipped** means the webhook's conditions did not pass, which is usually expected and rarely worth a message.

## Paging instead of chatting

For PagerDuty create an Events API v2 integration on a service and paste its routing key into a PagerDuty channel. A permanently-failed rule opens an incident keyed on the webhook, so repeated failures of the same webhook update one incident instead of opening ten; a recovered rule on the same channel resolves it. For SMS, a Twilio channel needs your Account SID, Auth Token and a sending number; the message uses the one-liner template, which is kept short for that reason.

## Let the AI write the message

In the rule editor, Draft with AI asks the site's AI provider to write the subject, title, body and one-liner from the captured payload — "mention the order number and the customer email, keep it under two lines". The linter checks the draft the same way it checks yours. In Build with AI you can simply add "…and post to #ops-alerts if it fails" to a build prompt; the agent adds a create\_notification\_rule step to the plan.

/ Setup

1.  1
    
    **Get a Slack incoming webhook URL**
    
    Open api.slack.com/apps, click Create New App → From scratch, name it "Webhook Actions" and pick your workspace. In the app's menu open Incoming Webhooks, switch Activate Incoming Webhooks on, scroll down and click Add New Webhook to Workspace, choose the channel it should post to and click Allow. Copy the URL that appears (it starts with hooks.slack.com/services/). For email you skip this step entirely — the plugin sends through wp\_mail(), so whatever SMTP plugin your site already uses applies.
    
2.  2
    
    **Add the channel**
    
    In WordPress go to Webhook Actions → Notifications → Channels and click New channel. Name it after the Slack channel (e.g. #ops-alerts), set Type to Slack, paste the URL into Incoming webhook URL and save. The URL is a secret: it is encrypted at rest and never shown again — the card shows only its last four characters.
    
3.  3
    
    **Send a test**
    
    Click the paper-plane icon on the new card. A card titled “\[Test\] Sample webhook failed” should land in Slack within a second or two, with the facts grid and an Open delivery log button. If it does not, the card shows the exact HTTP error Slack returned (a 404 with no\_service means the URL is wrong or the app was removed from the channel).
    
4.  4
    
    **Create a site-wide rule**
    
    Switch to the Rules tab and click New rule. Leave When on Permanently failed — the delivery gave up, either out of attempts or because the endpoint answered with a 4xx that will never succeed on retry. Under Send to pick #ops-alerts. Leave the message on the default for this event (it already names the webhook, the error, the attempt count and links to the log) and click Create rule. This rule now applies to every webhook that inherits site-wide rules, which is every webhook by default.
    
5.  5
    
    **Add an early warning that cannot spam you**
    
    A second rule on Attempt failed with the 5xx and “no response” chips selected and Attempt number set to 1 tells you the moment an endpoint starts erroring, while the retries are still running. Set Quiet time per webhook to 30 minutes so a bad half hour is one message per webhook, not one per order. If you would rather read one summary than a stream, pick Bundle into an hourly digest instead.
    
6.  6
    
    **Decide per webhook**
    
    Open any webhook and scroll to Notifications on its form. Inherit site-wide rules is the default; click the bell next to a rule to mute it for this webhook only — useful for a noisy test endpoint. Only this webhook's rules ignores the site-wide set; Off silences the webhook entirely. Below that you can add rules that apply to this webhook alone, and their preview renders from the webhook's captured payload, so {{ payload.order.id }} shows a real order number while you type.
    
7.  7
    
    **Watch it work**
    
    The Sent tab lists every notification with its status: sent, failed with the error and a resend button, throttled, or waiting for a digest. On the Logs tab a bell badge on a delivery shows how many notifications it produced. If a channel keeps failing — a rotated Slack URL, a revoked bot token — the health bar at the top of the plugin says so and links straight to the channel.
    

/ Related

[Notifications](https://wpwebhooks.org/docs/notifications/)[fswa\_delivery\_event](https://wpwebhooks.org/docs/fswa-delivery-event/)[Delivery Logs](https://wpwebhooks.org/docs/delivery-logs/)[Smart Retry with Exponential Backoff](https://wpwebhooks.org/docs/smart-retry/)[create\_notification\_rule](https://wpwebhooks.org/docs/ability-create-notification-rule/)[Feature page: Notifications](https://wpwebhooks.org/features/notifications/)

/Ready

## Your next automation is  
one sentence away.

[Install Plugin→](https://downloads.wordpress.org/plugin/flowsystems-webhook-actions.zip) [Try the Live Preview](https://playground.wordpress.net/?blueprint-url=https://wpwebhooks.org/blueprint.json) [See the Plugin →](https://wpwebhooks.org/wordpress-webhook-plugin/)

$ wp plugin install flowsystems-webhook-actions --activate

## Structured data

```json
{"@context":"https://schema.org","@type":"TechArticle","name":"Get alerted when a webhook fails — How-to Guide — Webhook Actions Docs","description":"Five minutes from a silent failure to a Slack card or an email the moment a delivery gives up — with a quiet time so a bad hour is one message, not a hundred.","url":"https://wpwebhooks.org/docs/alert-on-failed-webhooks/","isPartOf":{"@type":"WebSite","name":"WP Webhooks","url":"https://wpwebhooks.org"},"about":{"@type":"SoftwareApplication","name":"Webhook Actions","applicationCategory":"WordPress Plugin"}}
```
