Skip to main content

Status Pages

Status pages let you communicate service health to your users. Beacon generates beautiful, customizable status pages that update automatically.

Creating a Status Page

BrainzLab::Beacon.create_status_page(
  name: "Acme Status",
  subdomain: "status", # status.acme.com
  custom_domain: "status.acme.com",
  monitors: ["production-api", "web-app", "cdn"]
)

Page Components

Monitor Groups

Organize monitors into logical groups:
status_page.add_group(
  name: "Core Services",
  monitors: ["api", "web", "auth"]
)

status_page.add_group(
  name: "Infrastructure",
  monitors: ["database", "cache", "cdn"]
)

Current Status

Shows real-time status of all monitors:
StatusDisplay
All OperationalGreen banner
Partial OutageYellow banner
Major OutageRed banner
MaintenanceBlue banner

Incident History

Displays recent and ongoing incidents with updates.

Uptime Graph

90-day uptime visualization for each monitor.

Customization

Branding

status_page.customize(
  logo_url: "https://acme.com/logo.png",
  favicon_url: "https://acme.com/favicon.ico",
  primary_color: "#FF6B00",
  header_text: "Acme System Status"
)

Custom CSS

status_page.custom_css = <<~CSS
  .status-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  }
CSS

Subscriptions

Users can subscribe to status updates:
  • Email - Incident notifications
  • Webhook - Programmatic updates
  • RSS - Feed reader compatible
  • Slack - Direct channel updates
# Enable subscription options
status_page.subscriptions(
  email: true,
  webhook: true,
  rss: true,
  slack: true
)

Maintenance Windows

Schedule maintenance and notify subscribers:
BrainzLab::Beacon.schedule_maintenance(
  status_page: "acme-status",
  monitors: ["database"],
  starts_at: 2.days.from_now,
  ends_at: 2.days.from_now + 2.hours,
  title: "Database Maintenance",
  description: "Upgrading PostgreSQL to version 16"
)
Subscribers receive notifications before, during, and after maintenance.

API Access

Status pages expose a JSON API for programmatic access:
curl https://status.acme.com/api/v1/status
{
  "status": "operational",
  "monitors": [
    { "name": "API", "status": "up", "uptime": 99.99 },
    { "name": "Web", "status": "up", "uptime": 99.95 }
  ],
  "incidents": []
}