Field Notes/Automation & Daily Briefs
💡 Solution

CI/CD Monitoring via Telegram

2 min read

I fixed a production bug from my phone while in line for coffee. No laptop. No terminal. Just Telegram and my agent.

The Problem with Default CI Alerts

GitHub Actions notifications are useless — they just say "build failed" with a link. You still have to open it, scroll logs, and diagnose it yourself.

My agent does that automatically. When a workflow fails, it:

  • Fetches error logs from GitHub's API
  • Analyzes the actual failure — not just grepping for "error"
  • Diagnoses the root cause — dependency issue, test failure, syntax error
  • Sends a Telegram message with the diagnosis and suggested fix

Instead of "workflow failed," I get: "Jest found 2 failing tests in auth.test.ts. Login handler doesn't handle null email. Fix: add null check on line 47."

The Flow

1. GitHub webhook fires on workflow failure
2. Agent fetches job logs via GitHub API
3. Parses logs and diagnoses root cause
4. Sends diagnosis + suggested fix to Telegram

The agent understands context — it knows ENOSPC means disk space, ModuleNotFoundError means a missing dependency. It connects the dots.

Why Telegram?

It's where I already am. Instant, works everywhere, rich formatting. You could swap it for Slack, Discord, or any channel your agent supports — same pattern.

Real Example

Client deploy failed while I was getting coffee. Phone buzzes:

"Deploy failed on client-dashboard. TypeScript error: Property 'userId' doesn't exist on type 'Session'. One-line fix in types/session.d.ts."

I replied: "Push a fix."

Two minutes later: "Fix pushed. Build passing. Deployed to production." Client never knew there was a problem.

What You Need

  • GitHub webhook — standard setup, fires on workflow completion
  • Agent skill — parses CI logs (LLMs are surprisingly good at this out of the box)
  • Message channel — Telegram bot connected via OpenClaw's built-in channels

The goal isn't zero failures — it's faster recovery. When your agent diagnoses and fixes issues while you're in line for coffee, that's a different kind of responsiveness.