TypeScriptNext.jsMonitoringDevOps

Network Health Monitor

A real-time endpoint health monitor. Add up to 5 public URLs, hit start, and watch status indicators, response times, and latency sparklines update every 15 seconds. Built with a batch health-check API that runs all checks in parallel, with per-endpoint SSRF validation.

Try it live →

Max endpoints

5

Poll interval

15s

History depth

40 checks

Chart

SVG sparkline

How it works

1Add Endpoints
2Start Monitor
3Batch POST
4Parallel HEAD Requests
5Collect Status + Timing
6Update Sparklines
7Repeat (15s)

Architecture

Client component manages endpoint list in React state with a ref-synchronised polling loop (setInterval). Each tick sends a single POST with all URLs to the batch health-check API. The API runs Promise.all across all endpoints — each gets an independent HEAD request with its own 10-second timeout. Results update component state, which appends to per-endpoint history arrays (capped at 40 entries).

Sparkline Visualisation

Pure SVG polyline renders response time history as a sparkline. No chart library. X-axis maps to check index, Y-axis scales to max recorded response time. Failed checks render as red dots on the line. Viewbox-based rendering means the chart scales to any container width.

API Design

Single POST endpoint accepts an array of 1–5 URLs. Each URL is independently validated (format, SSRF, protocol). Requests run in parallel via Promise.all — one slow endpoint doesn't block others. Returns an array of results with status code, status text, response time in ms, and up/down boolean.

Security

  • SSRF prevention: same private IP / hostname blocking as security scanner
  • Batch size capped at 5 to prevent abuse
  • Per-URL validation — one bad URL doesn't skip checks for others
  • 10-second timeout per endpoint prevents resource exhaustion
  • HEAD requests only — minimal bandwidth to monitored targets
  • No server-side state — all history lives in the client

Want something like this built for your business?

I'll look at your problem, figure out the right approach, and ship working software. No slideshows.

Book a free consultation