Skip to main content
All status page endpoints (except publicByHost) require authentication.

create

Create a new status page to display monitor statuses publicly.

Input Parameters

name
string
required
Display name for the status page (1-120 characters)
slug
string
required
URL-friendly slug (2-63 characters). Must contain only lowercase letters, numbers, and hyphens. Cannot start or end with a hyphen.
monitorIds
array
required
Array of website IDs to include on the status page (1-100 monitors). All monitors must belong to the authenticated user.
isPublished
boolean
default:true
Whether the status page is publicly accessible

Response

id
string
Unique identifier for the status page
name
string
Display name
slug
string
URL slug
isPublished
boolean
Publication status
userId
string
Owner’s user ID
monitorCount
number
Number of monitors included
domain
object | null
Custom domain configuration (null if not configured)
createdAt
date
When the status page was created
updatedAt
date
Last update timestamp
const statusPage = await trpc.statusPage.create.mutate({
  name: "My Services Status",
  slug: "my-services",
  monitorIds: ["clx123", "clx456"],
  isPublished: true
});

console.log(`Status page ID: ${statusPage.id}`);

Error Codes

  • BAD_REQUEST - One or more monitor IDs are invalid or don’t belong to the user
  • CONFLICT - Slug already exists

update

Update an existing status page.

Input Parameters

id
string
required
Status page ID to update
name
string
New display name (1-120 characters)
slug
string
New URL slug (2-63 characters)
monitorIds
array
New array of website IDs (1-100 monitors). Replaces existing monitors.
isPublished
boolean
Update publication status

Response

Returns the updated status page object (same structure as create).
const statusPage = await trpc.statusPage.update.mutate({
  id: "clx1234567890",
  name: "Updated Status Page",
  isPublished: false
});

Error Codes

  • NOT_FOUND - Status page not found or doesn’t belong to user
  • BAD_REQUEST - One or more monitor IDs are invalid
  • CONFLICT - New slug already exists

list

Get all status pages for the authenticated user.

Response

statusPages
array
Array of status page objects (same structure as create)
const result = await trpc.statusPage.list.query();

console.log(`Total status pages: ${result.statusPages.length}`);
result.statusPages.forEach(page => {
  console.log(`${page.name} (${page.monitorCount} monitors)`);
});

delete

Permanently delete a status page.

Input Parameters

id
string
required
Status page ID to delete

Response

success
boolean
Always returns true on success
const result = await trpc.statusPage.delete.mutate({
  id: "clx1234567890"
});

console.log(result.success); // true

Error Codes

  • NOT_FOUND - Status page not found or doesn’t belong to user

publicByHost

Get public status page data by custom domain hostname. This is a public endpoint used to display status pages on custom domains.
This endpoint does not require authentication and is intended for public access.

Input Parameters

hostname
string
required
Custom domain hostname (must start with status. and be verified)
viewMode
enum
default:"per-check"
View mode for status data:
  • per-check - Returns up to 90 most recent individual checks
  • per-day - Returns aggregated daily data for last 31 days

Response

statusPage
object
Public status page data
const result = await trpc.statusPage.publicByHost.query({
  hostname: "status.example.com",
  viewMode: "per-check"
});

console.log(result.statusPage.name);
result.statusPage.websites.forEach(site => {
  console.log(`${site.websiteName}: ${site.currentStatus?.status}`);
});

Error Codes

  • NOT_FOUND - Status page not found for the given hostname, domain not verified, or status page not published

Build docs developers (and LLMs) love