---
title: "Build a Website & API Uptime Monitor That DMs You on Failure"
description: "Build a 24/7 AI uptime agent that polls your endpoints on a schedule and DMs you a plain-language diagnosis on Telegram. No servers, no API keys needed."
canonical: https://agentroost.app/en/blog/ai-uptime-monitor-agent-telegram-alerts
date: 2026-05-30T04:00:00Z
---

[Canonical URL](https://agentroost.app/en/blog/ai-uptime-monitor-agent-telegram-alerts)

## The Problem With Most Uptime Monitors

Pingdom, UptimeRobot, Better Uptime — they all do the same thing: fire an HTTP GET, check the status code, and send you "Your site is DOWN" if they get anything other than a 200.

That's useful. It's also where they stop.

What you actually want to know is: *why* is it down? Is the server unreachable, or is it returning 200 with an empty JSON body? Is it a timeout on `/api/orders` specifically, or everything? Is the response claiming success while the payload signals an internal error? Is the slowdown 400 ms or 14 seconds?

A status code can't answer those questions. An AI monitoring agent can.

This post walks you through building a 24/7 monitoring agent that polls your endpoints on a schedule, reads the actual response, and sends you a plain-language diagnosis on Telegram when something looks wrong — not just when it's technically "down."

---

## What We're Building

A monitoring agent that:

1. Runs on a schedule (every 1–5 minutes, your choice)
2. Hits one or more HTTP endpoints — your app, your API, a competitor's status page, anything
3. Checks not just the status code but the response body and latency
4. Passes the result to an LLM that decides if something is *actually* wrong and writes a brief explanation
5. Sends a Telegram message to you only when there's a real problem — no alert noise from transient blips

---

## Option A: Build It in n8n (Visual Workflow, No Code)

If you want full control over the logic and you're comfortable with a node canvas, your own n8n instance is the fastest path.

### The Node Layout

```
Schedule Trigger → HTTP Request → IF (status / latency check) → AI/LLM Node → Telegram node
                                       ↓ (no problem)
                                      (Stop — no alert)
```

### Step 1 — Schedule Trigger

Add a **Schedule Trigger** node. Set it to run every **5 minutes**:

```
Trigger Interval: Minutes
Every: 5
```

For critical payment endpoints, drop this to 1 minute. For informational pages, 15 minutes is fine.

### Step 2 — HTTP Request

Add an **HTTP Request** node. Configure:

- **Method**: GET (or POST if your endpoint expects a payload)
- **URL**: `https://your-app.com/api/health` (or whatever endpoint matters)
- **Response Format**: JSON
- **Timeout**: 10000 ms (10 seconds — if it doesn't respond by then, that's the problem)

Enable **"Include Response Headers"** so you can inspect `content-type` and any custom status headers.

For APIs that require auth, add an `Authorization` header and store the token as an **n8n Credential** — it won't appear in the workflow export and won't be exposed if you share the workflow JSON.

### Step 3 — IF Node (First-Pass Filter)

Add an **IF** node to catch obvious failures before burning LLM credits:

| Condition | Operator | Value |
|---|---|---|
| `{{ $json.statusCode }}` | Is not | `200` |

Add a second branch: **OR** `{{ $json.responseTime }}` greater than `8000` (8 seconds).

The **true** branch (something suspicious) goes to the AI node. The **false** branch (looks fine) ends here — no message, no noise.

### Step 4 — AI / LLM Node

This is where the diagnosis happens. Add the **AI/LLM** node (under the "AI" section in n8n's node palette). On AgentRoost, **this node is already connected to included credits** — you don't configure a credential or pick a provider. Just write the prompt.

**System prompt:**
```
You are a site reliability assistant. You receive HTTP response data from a monitoring check.
Analyze it and decide if there is a real problem. If yes, write a concise 2-3 sentence
diagnosis that a developer would find useful — include the status code, response time,
and any relevant snippet from the body. If no real problem, reply only with: OK
```

**User message (with expression):**
```
Endpoint: {{ $node["HTTP Request"].json.url }}
Status: {{ $node["HTTP Request"].json.statusCode }}
Response time: {{ $node["HTTP Request"].json.responseTime }}ms
Body (first 500 chars): {{ $node["HTTP Request"].json.body.toString().slice(0, 500) }}
```

Set **Max Tokens** to 200. You need a paragraph, not an essay.

### Step 5 — Second IF (Skip "OK" Responses)

Add another **IF** node:

- `{{ $json.text }}` **does not contain** `OK`

True branch → Telegram. False branch → end. This prevents the LLM from sending you a message when everything is fine but the first-pass filter caught a brief anomaly.

### Step 6 — Telegram Node

Add the **Telegram** node. You'll need a bot token (create one via BotFather — takes 2 minutes) and your own chat ID. Then:

- **Operation**: Send Message
- **Chat ID**: your personal Telegram chat ID
- **Text**:
```
🔴 Monitor Alert — {{ $node["HTTP Request"].json.url }}

{{ $node["AI/LLM"].json.text }}

Checked at: {{ $now.toISO() }}
```

Save and activate the workflow. Done.

> **Note:** The BotFather step only applies to this n8n path, where you're wiring your own Telegram node. If you use Hermes (Option B below), AgentRoost auto-provisions the Telegram bot for you — no BotFather required.

---

## Option B: Hermes (If You Want It to Just Run Forever, No Canvas)

If you'd rather not manage a workflow canvas, Hermes is AgentRoost's always-on agent framework. You describe the monitoring task in plain language, connect your Telegram bot in one click, and Hermes handles the scheduling, the HTTP calls, and the LLM reasoning natively.

Hermes is particularly good for:

- **Multi-endpoint monitoring** where you want the agent to correlate failures across endpoints before alerting (is just `/api/auth` slow, or is the whole service degraded?)
- **Stateful awareness** — Hermes remembers the last N check results, so it can tell you "this has been slow for 20 minutes" rather than alerting on every single check
- **Plain-language configuration** — no node canvas required, which is useful if the person maintaining the monitor isn't a developer

---

## Run It on AgentRoost

Here's how to get either version live in about 2 minutes:

**For n8n:**

1. Sign up at [agentroost.app](https://agentroost.app)
2. Pick the **n8n** framework, give your instance a name
3. Your private n8n editor opens at `https://<your-id>.agentroost.app` — this is your instance, your data, your workflows
4. Build the workflow above — the AI/LLM node already has credits, no API key needed
5. Activate the workflow; it starts polling on schedule immediately

**For Hermes:**

1. Sign up, pick the **Hermes** framework
2. Open the AgentRoost manager bot on Telegram, `/start` your new agent
3. Configure your endpoints and check interval in plain language
4. Hermes starts running and will DM you directly when it finds something wrong — no BotFather, no YAML, no server

Both paths cost **$19.99/mo all-in** — that's the server, the scheduling infrastructure, and the LLM credits for the AI reasoning, bundled together. No separate OpenAI bill. No "we don't host the LLM, BYOK" footnote.

[Compare plans and get started →](/en/pricing)

---

## Tips and Common Pitfalls

**Don't alert on every anomaly.** The double-IF pattern above (first pass on status/latency, second pass on LLM output) filters out transient blips. A single slow response isn't an incident.

**Include the response body, not just the status.** Many APIs return `200 OK` with `{"success": false, "error": "payment_gateway_timeout"}` in the body. A status-only check would call this healthy.

**Limit the body slice.** Passing 10 KB of HTML to the LLM on every check wastes credits and slows the alert. 500–1000 characters is enough for the model to understand what's happening.

**Check your own downstream dependencies, not just your frontend.** Set up separate monitors for `/api/health`, `/api/auth/verify`, `/api/checkout`, and your payment webhook endpoint. They fail independently.

**Test the alert path before you rely on it.** Manually trigger your workflow (or tell Hermes to run a check now) against a URL that returns 503. Confirm the Telegram message arrives before you go live.

---

## What You End Up With

A monitoring agent that wakes up every few minutes, checks whether your endpoints are not just reachable but *actually working*, and sends you a human-readable explanation if something's wrong — all without managing a server, configuring an LLM API key, or babysitting a cron job.

For a solo developer or a small team, this replaces a dedicated uptime tool plus a separate AI API bill, for a single $19.99/mo subscription. And because you own your n8n instance (or your Hermes agent runs under your account), your monitoring logic and alert history are yours — not locked in a SaaS dashboard you can't export.

[See the n8n agent page →](/en/agents/n8n) · [See the Hermes agent page →](/en/agents/hermes)
