Build an n8n Watchdog That Alerts When a Workflow Never Runs
n8n's Error Trigger only catches failed runs, so a workflow that never starts, due to a dead cron, changed webhook URL, or deactivation after an edit, goes unnoticed. The article proposes a dead-man's switch: a separate watchdog workflow that runs hourly and checks the monitored workflow's execution history via the n8n Public API. It classifies the workflow as overdue if no runs exist or the latest run is older than a configurable threshold, and sends a Gmail alert only in that case. Setup requires an n8n API key, the target workflow ID, a threshold set to roughly twice its expected interval, and Gmail OAuth2 credentials. The author reports testing the detection logic on a local n8n instance but says email delivery still needs to be confirmed by running a test alert.
This is an AI-generated summary. ShortSingh links to the original source for the complete article.


Discussion (0)
Log in to join the discussion and vote.
Log in