Introducing a new way to review your PRs.

Read the announcement

rajnandan1 / kener

Stunning status pages, batteries included!

View on GitHub

19 documents · Updated Nov 23, 2026

docs / public-status-pages

Public status pages

Public status pages give people a stable view of service health. Each page maps a public URL to an ordered set of monitors, then combines current status, recent history, operational events, navigation, feeds, and site branding into one shareable surface. This page is a child of Status publishing; see also Incidents and maintenance events and Embeds, badges, and capture snippets.

Public page model

A public page is a named view of selected monitors. The root page is the default view, while other pages use a custom path so one site can publish several audiences or service areas.

Page identity

The page record supplies the public path and the text and image content shown at the top of the page. The empty stored path identifies the home page and cannot be removed or changed; a custom path is normalized into a lower-case URL segment and must be unique. Public API responses represent the empty home path with the ~home token so clients can read and write page records without confusing the API value with the public / URL.

Page valuePublic role
page_pathSelects the root URL or a custom page URL.
page_titleNames the page in page lists and navigation.
page_headerProvides the main heading on the page.
page_subheaderProvides supporting text, rendered as formatted content.
page_logoProvides an optional page-specific logo.

Page administration keeps these values and the monitor list together. The management view lets an operator create or edit page text, upload a logo, and open the public page; the page API exposes the same page resource for list, create, update, and delete actions. The API is an authenticated management interface, while the resulting status page remains public. The home page is protected from path changes and deletion, while custom pages can be removed after their path is confirmed.

References: src/…/db.ts• L450-470 src/…/pagesController.ts• L9-28 src/…/+server.ts• L16-33 src/…/+server.ts• L24-41 src/…/+server.ts• L91-144 src/…/+page.svelte• L178-226 src/…/+page.svelte• L532-691 src/…/authentication.md• L6-29

Monitor membership

The page-to-monitor relationship defines both audience and order. A monitor can appear on several pages, but the public view keeps only monitors that are active and not hidden; the stored position controls their order.

This boundary prevents a page from exposing a monitor that is not meant for public use. It also means that a page can remain valid when one of its assigned monitors becomes hidden or inactive, although that monitor no longer contributes to the page view. Operators can add, remove, and reorder page monitors, while API updates replace the page's complete monitor list after checking that each tag exists and appears only once.

References: src/…/pages.ts• L61-90 src/…/pagesController.ts• L101-137 src/…/pagesController.ts• L217-230 src/…/+server.ts• L113-136 src/…/+server.ts• L172-195 src/…/+server.ts• L243-251 src/…/+page.svelte• L228-353

Public routing

The public route turns a URL path into a page lookup and then into page dashboard data. Both the root and custom-path routes use the same page assembly rules, so a custom page is not a separate product mode.

Root and custom paths

The root URL / loads the page whose stored path is empty. A custom page loads from /<page_path>, and an unknown path returns a 404 response instead of showing an unrelated page.

The route also keeps the page path when it builds related URLs. This preserves the page scope for event calendars and RSS feeds. Page management applies the same URL-friendly path rules before it sends a create or update request, so the path used by an operator matches the path checked by the API. When Kener runs below a reverse-proxy base path, the public URLs keep that deployment prefix as well.

flowchart LR
    A[Public URL] --> B{Path}
    B -->|root| C[Empty page path]
    B -->|custom segment| D[Custom page path]
    C --> E[Page and visible monitors]
    D --> E
    E --> F[Dashboard data]
    F --> G[Rendered status page]
    E --> H[404 when page is missing]

References: src/…/+page.server.ts• L1-13 src/…/+page.server.ts• L1-15 src/…/dashboardController.ts• L296-312 src/…/+page.svelte• L178-226 src/…/+server.ts• L63-110 src/…/+server.ts• L97-144 src/…/environment-variables.md• L99-120

Page route relationships

Each page has matching event and feed paths. The root page uses /events/<MMMM>-<YYYY> and /rss.xml; a custom page uses /<page_path>/events/<MMMM>-<YYYY> and /<page_path>/rss.xml.

The public monitor route is separate from page routing. A page links to each visible monitor's detail view, while the monitor detail view has its own visibility check and history view.

References: src/…/+page.server.ts• L8-45 src/…/+page.server.ts• L8-45 src/…/+page.server.ts• L18-34

Page settings

Page settings control how a page presents its monitor history and its page-level metadata. Shared event display settings control whether operational events appear on the page and where the notification list appears. Missing or invalid values fall back to safe defaults, so a partial settings change does not need to repeat the full settings object.

Display settings

The page settings contract covers the following display choices:

Setting groupPublic effect
Monitor history daysSets the desktop and mobile history window requested for monitor bars.
Monitor layout styleSelects the list, compact list, default grid, or compact grid presentation for page monitors.
Incident and maintenance optionsControls whether current events appear on the page and whether notifications use a button or side placement.
Page metadataOverrides the title, description, and social preview image for this page.

The page view uses the device class to choose its history window. The monitor bar request limits the returned history to 90 days. The public page also uses site-level event display settings to decide whether ongoing incidents and maintenance appear inline and whether notifications appear in a button or an aside; the page settings contract and the site event controls must therefore be understood as separate scopes. The management view groups history and layout controls as display preferences and checks both history values before saving them.

References: src/…/pageSettings.ts• L22-42 src/…/pageSettings.ts• L72-129 src/…/+page.svelte• L21-36 src/…/+page.svelte• L175-239 src/…/get.ts• L9-28 src/…/dashboardController.ts• L372-391 src/…/+page.svelte• L784-873 src/…/+server.ts• L197-207

Metadata fallbacks

Page metadata takes precedence over site metadata. If a page does not define an override, the rendered head uses the site title, description, and social preview image; if neither exists, the page uses a general status-page fallback.

The page settings editor exposes the social preview image, meta title, and meta description as optional page overrides. Leaving these values empty keeps the site-level metadata in control.

References: src/…/dashboardController.ts• L342-355 src/…/+page.svelte• L118-144 src/…/layoutController.ts• L184-189 src/…/+page.svelte• L875-969

Monitor status presentation

The page presents one status summary for the selected monitor set and one history bar for each visible monitor. The server supplies the page identity and current event context first; the browser then fills each monitor bar with its history and latency data.

Page status summary

The page status is an aggregate of the latest known result for every monitor on the page. It counts the current up, down, degraded, and maintenance states and derives a summary and color for the page-level event card.

This summary answers whether the page's published services are broadly healthy. A monitor can still show its own state and history below the aggregate summary.

References: src/…/dashboardController.ts• L164-209 src/…/dashboardController.ts• L311-327 src/…/+page.svelte• L181-183

Monitor history bars

Each visible monitor is rendered as a status bar with its name, current state, uptime, latency, and a time series of status counts. The selected page layout changes how these bars are arranged, while compact layouts reduce their presentation without changing the page's monitor scope.

The browser requests history for each visible monitor in parallel using the selected desktop or mobile day count. A request error stays with that monitor, and a newer page request prevents older results from replacing current data. A group monitor can also expose the monitors that it includes, which lets readers move from a grouped result to its members.

The bar supports a day-level detail view when the reader inspects a history segment. Monitor names link to their public detail pages, where the same public visibility rules protect the individual view.

References: src/…/+page.svelte• L78-114 src/…/+page.svelte• L210-229 src/…/MonitorBar.svelte• L99-158 src/…/StatusBarCalendar.svelte• L57-65 src/…/+page.svelte• L96-167

Events and calendars

Public pages connect current service status with the operational events that explain it. Incidents and maintenance can appear inline on the page, and a month-based calendar provides a broader record for the page's monitor set.

Inline event display

When site event display is enabled, the page can show ongoing incidents, ongoing maintenance, and upcoming maintenance beside or below the monitor list. The page dashboard fetches only event data that matches the page's visible monitor tags.

The notification list can use a button or a side panel according to the event display setting. This changes how readers open or view notifications, while the event scope remains limited to the page's visible monitors. The event entries link to their public detail pages. Their creation, updates, comments, and monitor impact are covered in Incidents and maintenance events.

References: src/…/dashboardController.ts• L211-294 src/…/dashboardController.ts• L372-391 src/…/+page.svelte• L175-209 src/…/+page.svelte• L236-239

Monthly event calendar

The calendar route accepts a month name and year. The page checks that the month is within the supported history range and no more than 12 months ahead, then requests incidents and maintenance for that page's monitor set.

The response is grouped by day and shown newest first. Root and custom pages share this behavior, but each custom page sends its own path so events from other pages are not mixed into the calendar.

sequenceDiagram
    participant R as Reader
    participant P as Calendar page
    participant E as Events query
    participant D as Event store

    R->>P: Open page and month
    P->>P: Validate month range
    P->>E: Request date range and page path
    E->>D: Select page-visible monitor events
    D-->>E: Incidents and maintenance
    E-->>P: Event data
    P-->>R: Events grouped by day

References: src/…/+page.server.ts• L11-41 src/…/+page.svelte• L77-153 src/…/post.ts• L17-64

Feeds and discovery

Public pages provide machine-readable feeds and human-facing navigation. These surfaces use the same page and monitor visibility rules as the page itself, which keeps a feed or link from exposing a wider set of services than the page.

RSS feeds

The root feed is available at /rss.xml. A custom page has a page-scoped feed at /<page_path>/rss.xml. Each feed publishes recent incidents and maintenance events for the page's visible monitors, with a 90-day event window and a maximum of 50 items.

Maintenance may include scheduled events in the next 90 days. Events that affect only hidden monitors are excluded, while a global maintenance event remains publishable because it applies to all monitors. The response is cacheable for five minutes.

The public layout adds the feed link to the document head and chooses the most specific matching feed: a monitor feed takes priority on a monitor route, then a custom page feed, then the root feed. A separate monitor feed exists at monitors/…/rss.xml for an individual visible active monitor.

References: src/…/+server.ts• L1-5 src/…/+server.ts• L1-8 src/…/rss.ts• L111-169 src/…/rss.ts• L182-207 src/…/+layout.svelte• L15-33

The page switcher loads the available pages from the dashboard page list. By default, pages follow their stored order; when page ordering is enabled, the configured page ID order moves listed pages first and leaves other pages in their normal order.

The site can show or hide the page switcher. It can also enable exclusive page mode, which makes the current page the navigation context instead of treating the root page as a universal home. In exclusive mode, the brand link stays within the current page and unscoped event or root-feed requests resolve to the home page's monitor set.

References: src/…/PageSelector.svelte• L12-35 src/…/get.ts• L8-39 src/…/site.ts• L131-139 src/…/KenerNav.svelte• L12-22 src/…/rss.ts• L146-157 src/…/post.ts• L35-52

Site navigation provides links that are independent of the page switcher. The same configured links appear in the desktop navigation and the mobile menu, with optional icons and external links opened in a new window.

The site brand normally links to the root page. Exclusive page mode changes that link to the current page so readers do not leave the selected page context by clicking the brand.

References: src/…/layoutController.ts• L38-43 src/…/KenerNav.svelte• L33-80 src/…/KenerNav.svelte• L83-118

Sitemap discovery

The sitemap can be off, manually defined, or generated from public resources. In automatic mode it includes all pages, active visible monitor detail pages, the current and previous month event pages, and any extra configured URLs.

References: src/…/+server.ts• L8-45 src/…/+server.ts• L47-79 src/…/site.ts• L147-152

Rendering data flow

Public rendering joins request scope, site presentation data, page data, and monitor history. This split lets the server establish what the page is and which monitors are allowed, while the browser requests the time-series data needed for each bar.

flowchart TD
    A[Request root or custom page URL] --> B[Shared site layout data]
    B --> C[Page lookup and visible monitor selection]
    C --> D[Page status and event data]
    D --> E[Rendered page shell]
    E --> F[Monitor bar requests]
    F --> G[Uptime, latency, and status history]
    G --> H[Interactive monitor bars]

The shared layout supplies branding, colors, navigation, language, time settings, feature switches, analytics settings, and global metadata. The validated site settings catalog also covers page visibility and ordering, event display, metadata, sitemap, and analytics controls that affect shared public surfaces. It resolves the configured favicon for the deployment base path before the browser reads the server-rendered document head. The page dashboard adds page text, page settings, visible monitor tags, the aggregate status, and any inline events. The page component then chooses the history window and layout, renders the page-level events and notification placement, and requests one monitor history response per visible tag. The monitor bar response adds the current monitor view and its selected history window.

References: src/…/layoutController.ts• L16-78 src/…/layoutController.ts• L117-190 src/…/+layout.svelte• L27-55 src/…/+page.svelte• L21-36 src/…/+page.svelte• L78-114 src/…/get.ts• L31-53 src/…/siteDataKeys.ts• L113-117 src/…/siteDataKeys.ts• L275-317 src/…/environment-variables.md• L49-79

Analytics capture script

The /capture.js resource supplies the optional analytics behavior used by the public page shell. It reads saved provider settings, emits code only for enabled providers, and returns an empty script when no provider is enabled. The response is not cached so a settings change can reach public pages without a stale provider configuration.

Provider values are escaped before they enter the generated script. This keeps saved quotes, backslashes, and line breaks from changing the script or preventing it from loading.

References: src/…/+server.ts• L14-26 src/…/+server.ts• L35-43 src/…/+server.ts• L116-121 src/…/server.test.ts• L16-66

Change checklist

When these files or sections are changed, remember to consider these:

  • A change to the stored home-page path, the ~home API token, or the home-page guard must stay aligned with root routing, API read-modify-write behavior, page lookup, and page deletion rules.
  • A change to page monitor filtering must stay aligned across dashboard rendering, event queries, RSS scope, sitemap entries, and individual monitor visibility.
  • A change to page history settings must stay aligned with desktop/mobile selection and the monitor-bar day limit.
  • A change to forceExclusivity must be checked against the page switcher, brand link, event calendar query, RSS scope, and page-scoped navigation.
  • A change to page ordering must preserve the page list shape used by the switcher and the URL construction for the empty home path.
  • A change to metadata names must preserve the mapping between page settings, API fields, stored settings, and rendered social tags.
  • A change to deployment-base-path handling must keep favicon URLs and page-scoped feed links valid in server-rendered HTML.
  • A change to shared site setting keys must preserve validation and the controls that consume page visibility, ordering, event display, metadata, sitemap, and analytics values.
  • A change to analytics provider requirements or capture-script assembly must preserve enabled-provider filtering, JavaScript string escaping, and the no-cache response contract.
  • A change to the page API's monitor update contract must stay aligned with the management view's add, remove, and reorder actions so the stored order and public order do not diverge.
  • A change to page settings validation or merge behavior must stay aligned with the management editor's defaults and its separate display and SEO save actions.
  • A change to monitor layout or event-list placement must stay aligned with the page component's desktop/mobile history selection, inline event visibility, notification placement, and monitor-bar request scope.
  • A change to the API authentication contract or KENER_SECRET_KEY setup must preserve protected page administration without changing the public read path.

Important failure modes

TriggerConsequenceGuard
A custom page path collides with an existing path after normalizationThe page cannot be created or renamed safelyNormalize the path and reject duplicates before the write.
A page lookup receives an unknown root or custom pathThe public route returns a 404 instead of page dataResolve the request path to a page before building dashboard data.
A monitor assigned to a page becomes hidden or inactiveIt disappears from the page, event scope, feed, and public discovery resultsUse the active and visible monitor filter when building public scopes.
Exclusive mode is applied to only one unscoped event surfaceA calendar or feed can show the wrong monitor setApply the setting to both event queries and RSS page scope.
A page settings payload has an invalid type or out-of-range history valueA public response can lose its expected settings shape or request an invalid windowValidate writes and overlay only valid stored values on defaults.
The site URL is missing when a feed or automatic sitemap is requestedThe endpoint returns 404 because it cannot build public absolute URLsTreat the site URL as required for those generated resources.
A deployment base path is omitted from a server-rendered asset URLThe browser requests the asset from the wrong host path and the public shell loses that assetResolve asset URLs in server layout data before rendering the document head.
A shared site setting is stored under an unknown or invalid keyThe related public control is ignored or receives an unsafe valueKeep the site setting key catalog and its validators aligned with the settings consumers.
An analytics requirement is inserted into the capture script without string escapingA quote, backslash, or line break can make /capture.js invalid and stop public-page analyticsEscape every saved requirement before provider snippets are assembled.
A client sends ~home as a path change for the home pageA normal read-modify-write request can be rejected or try to alter the protected home pathTranslate the API home token back to no path change before validation.
A page update lists a missing or repeated monitor tagThe update is rejected instead of creating a partial monitor assignmentValidate every tag and reject duplicates before replacing the monitor list.
An operator attempts to delete or rename the home pageThe default public entry point could disappear or become unreachableKeep the home path fixed and reject home-page deletion.
A monitor-bar request returns after the page scope or history window changedOld history can replace the data for the current page viewDiscard results from an older request version before updating monitor bars.
Event placement is changed without matching the page shell controlsNotifications can appear in the wrong region or the popover can remain visible when a side list is usedKeep event placement, inline-event rendering, and notification-list visibility under the same display setting.
An API key is missing, inactive, or invalid when an operator changes a pagePage administration returns unauthorized and the public page is not updatedUse a valid Bearer API key and keep KENER_SECRET_KEY set to a private random value.

Key files

FileWhy to read it
src/…/+page.server.tsShows root-page entry and 404 behavior.
src/…/+page.server.tsShows custom-path entry and shared dashboard loading.
src/…/+page.svelteShows the shared public page rendering, event placement, layout selection, metadata, and monitor history requests.
src/…/+page.svelteShows the custom-path page rendering with the same public surface as the root page.
src/…/+server.tsShows page listing and creation contracts, including the API home token and input checks.
src/…/+server.tsShows page read, update, deletion, path protection, settings validation, and full monitor-list replacement.
src/…/+page.svelteShows the operator flow for page identity, monitor membership, display settings, metadata, and deletion.
src/…/dashboardController.tsExplains how page scope becomes status, event, monitor, and metadata data.
src/…/pageSettings.tsDefines page defaults, validation, and API/storage settings behavior.
src/…/PageSelector.svelteShows how readers switch between public pages.
src/…/KenerNav.svelteShows site navigation and exclusive page brand behavior.
src/…/rss.tsDefines page-scoped feed content and visibility rules.
src/…/+page.svelteShows the monthly event calendar and its page-aware navigation.
src/…/MonitorBar.svelteShows the public monitor summary and history-bar data used by pages.
src/…/+server.tsShows how public pages and resources enter automatic discovery.
src/…/siteDataKeys.tsDefines the validated site settings that can affect shared public rendering, including page scope, discovery, metadata, and analytics controls.
src/…/+server.tsShows how enabled analytics settings become the public capture script and how the response avoids stale configuration.
src/…/server.test.tsStates the capture-script contract for provider values, escaping, and disabled analytics.