Skip to content
ujjwaluzuPublic

About

A simple status page for monitoring the availability and uptime of my websites and services, with a clean overview of their current operational status.

Topics

Resources

Stars

4 stars

Watchers

0 watching

Forks

Repository files navigation

Ujjwaluzu Status

Live status for the websites and tools in the Ujjwaluzu network. The dashboard shows current service health, recent check history, uptime, response time, and reported incidents.

Live page: status.ujjwaluzu.in

Monitored services

The service list is maintained in lib/services.ts. It currently includes ujjwaluzu.in, the Ujjwaluzu blog, Uzzutv, Auction, Wiki, CrewLab, appCrewlab, and Tools. Add or update entries there to change what appears on the dashboard.

Each service is matched to an UptimeRobot monitor by an explicit monitor ID when configured, then by exact URL, then by hostname. Set uptimeRobotMonitorId on a service when automatic matching is ambiguous.

How it works

UptimeRobot checks the configured monitors. This Next.js application provides the status dashboard and a server-side adapter for the UptimeRobot API:

Browser → status.ujjwaluzu.in → /api/status → UptimeRobot API

The browser only calls this app's /api/status endpoint. The UptimeRobot API key stays on the server. The dashboard refreshes automatically every 30 seconds and also has a manual refresh control.

The API response includes each service's current state, 30-day uptime, 24-hour average response time, and recent check history. It also includes up to 20 incidents from the last 30 days. Monitoring data is cached server-side (monitor list: 60 seconds; uptime and response-time statistics: 10 minutes; incidents: 5 minutes) to limit upstream requests.

Requirements

  • Node.js compatible with the installed Next.js 16 release
  • npm
  • A read-only UptimeRobot API key

Run locally

Install dependencies and create a local environment file:

npm install
cp .env.example .env.local

On Windows PowerShell, use Copy-Item .env.example .env.local instead of cp if needed. Add the API key to .env.local:

UPTIMEROBOT_API_KEY=your_read_only_api_key

Keep this key server-only. Do not rename it with a NEXT_PUBLIC_ prefix, and do not commit .env.local. The real environment files are ignored by Git; .env.example is safe to commit.

Start the development server:

npm run dev

Open http://localhost:3000.

Available commands

  • npm run dev — start the local development server
  • npm run build — create a production build
  • npm run start — serve the production build
  • npm run lint — run ESLint

API endpoint

GET /api/status returns the normalized status payload as JSON. Responses are not cached by browsers. If monitoring is not configured or UptimeRobot cannot provide data, the endpoint responds with HTTP 503; the dashboard displays an error or the last known data when available.

The implementation is organized as follows:

  • app/api/status/route.ts — status endpoint and safe error responses
  • lib/uptimerobot.ts — server-only UptimeRobot v3 client, pagination, timeouts, retries, and request rate limiting
  • lib/monitoring.ts — monitor matching, caching, status normalization, and incident mapping
  • lib/services.ts — services displayed on the status page
  • components/status-dashboard.tsx — client-side dashboard and polling behavior

Deployment

Deploy as a Next.js application and configure UPTIMEROBOT_API_KEY as a server-side environment variable in the hosting environment. Do not expose the key in client-side settings or include it in the repository. The canonical site URL and metadata are defined in lib/site.ts.

About

A simple status page for monitoring the availability and uptime of my websites and services, with a clean overview of their current operational status.

Topics

Resources

Stars

4 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages