Skip to content
NEWMarketplace and your team: sell what you build, and get plans and changes that are tested before you see them. See what is new

Library / Monitoring, Ops & Incidents

Monitoring, Ops & Incidents

Monitor n8n workflow errors and LLM spend with Slack, Gmail, OpenAI and Sheets

Runs hourly to read n8n execution history, calculate error rates and estimated LLM spend, disable runaway workflows, and post incidents with the failing node to Slack.

What it does

## 🩺 n8n Instance Health & Cost Monitor For anyone running a self-hosted or cloud n8n instance with dozens of active workflows, where a broken credential or a looping AI agent can fail hundreds of times or burn through an OpenAI budget overnight before anyone looks. ### How it works Every hour, the workflow reads recent executions for every active workflow through the n8n API, then works out error rates, run volume and estimated LLM spend. Runaway workflows are switched off automatically (tag one no-auto-disable to protect it), and every incident is posted to Slack with the failing node and error message. Repeat warnings are held back by a cooldown. Every Monday it looks at the whole week instead. It compares it with the week before, groups similar errors into clusters, and has GPT-4o-mini write a short health report. That report is emailed with a Slack TL;DR, and the week's numbers are saved so the trend builds up over time. ### Setup steps 1. Create an n8n API key (Settings → n8n API) and add it as Header Auth with the X-N8N-API-KEY header. 2. Create a Google Sheet with Guard_Log and Metrics_History tabs. 3. Connect Google Sheets, Slack, Gmail and OpenAI. 4. In Set Monitor Config, set your instance URL, thresholds, token budget and digest email. 5. Run the hourly guard once manually, then activate.

The steps

  1. Every Hour (Guard)
  2. Every Monday 9 AM (Digest)
  3. Set Guard Mode (1h Window)
  4. Set Digest Mode (7-Day Window)
  5. Set Monitor Config
  6. Fetch Active Workflows
  7. Build Workflow Index
  8. Fetch Executions per Workflow
  9. Compute Health & Cost Metrics
  10. Route by Mode
  11. Read Guard Log Sheet
  12. Read Metrics History Sheet
  13. Classify & Dedupe Incidents
  14. Build Failure Sample List

28 steps in total.

Similar automations