Documentation

How-to guides

Most of Xpiry watches your domains from the outside, no setup required. These guides cover the features where you wire something in: the ping URLs, DSN, and public pages Xpiry generates for you. Looking for endpoints and payloads? See the REST API reference.

Heartbeat monitors

Pro & Agency

Confirm a job that Xpiry can't see actually ran: a nightly backup, a cron task, a queue worker. The job pings a tokenized URL when it finishes; if a ping doesn't arrive on schedule, the monitor flips to down and you're alerted.

  1. On a domain, open the Monitors tab and add a heartbeat monitor with the interval you expect (e.g. every 24h).
  2. Copy its ping URL — it's shown right on the monitor row, and in the editor.
  3. Have your job curl that URL when it succeeds.

Report a run

# success — ping the bare URL at the end of the job
curl -fsS https://xpiry.com/ping/xpm_YOUR_TOKEN
# failure, with an optional reason (job exits non-zero)
curl -fsS "https://xpiry.com/ping/xpm_YOUR_TOKEN/fail?error=OOMKilled"
# in crontab — only pings on success, so a crash or skipped run alerts
0 3 * * * /opt/backup.sh && curl -fsS https://xpiry.com/ping/xpm_YOUR_TOKEN

Time the run automatically

Set a max_duration_seconds on the monitor to flag slow runs as degraded. Either report the duration yourself with ?duration= (seconds), or ping /start when the job begins and success when it ends — Xpiry measures the elapsed time for you.

# let Xpiry time it: /start at the beginning, success at the end
curl -fsS https://xpiry.com/ping/xpm_YOUR_TOKEN/start
./run-import.sh
curl -fsS https://xpiry.com/ping/xpm_YOUR_TOKEN

A /start on its own isn't a check-in, so a job that starts but never finishes still trips the missed-heartbeat alert. Failures and orphaned starts never invent a duration. Both GET and POST work, and the URL is tokenized (no auth header) — keep it secret. Full parameters and responses are in the API reference.

Metric monitors

Pro & Agency

Watch a number you push: queue depth, disk usage, records processed, a custom SLA. Add a metric monitor with warn and critical thresholds (and which direction is bad), then push values to the same kind of ping URL.

# push a value — compared against the monitor's thresholds
curl -fsS "https://xpiry.com/ping/xpm_YOUR_TOKEN?value=42"
# e.g. report queue depth every minute from a worker
* * * * * curl -fsS "https://xpiry.com/ping/xpm_YOUR_TOKEN?value=$(qlen)"

Show the latest value on your status page, or keep it private. Thresholds and status values are documented in the API reference.

Exception tracking

All plans

Capture errors from your application with the Sentry SDK you already use. Xpiry gives each domain a Sentry-compatible DSN; point any official Sentry SDK at it and exceptions are grouped into issues, alerted, and collapsed into hourly digests when they repeat.

  1. On a domain, open the Errors tab and turn on exception tracking.
  2. Copy the DSN shown there (use “Send test exception” to confirm the wiring).
  3. Pass it to Sentry.init in your app — no other Xpiry-specific code.

DSN format

https://<KEY>@xpiry.com/<PROJECT_ID>

Point your SDK at it

# Ruby
Sentry.init { |c| c.dsn = "https://<KEY>@xpiry.com/<PROJECT_ID>" }
// JavaScript / Node
Sentry.init({ dsn: "https://<KEY>@xpiry.com/<PROJECT_ID>" })
# Python
sentry_sdk.init(dsn="https://<KEY>@xpiry.com/<PROJECT_ID>")

SDKs send events to /api/<PROJECT_ID>/envelope automatically (the legacy /store endpoint is also accepted), so any language with an official Sentry SDK works.

Every plan includes exception tracking with a per-plan daily event budget and retention window (shown on the Errors tab). Over-budget events are rejected with a 429 so your SDK backs off. The DSN is a credential — anyone with it can post events, so keep it in your app config, not client-side source you can't trust.

Public status pages

Pro & Agency

Turn a domain's checks, monitors, and incidents into a public page. Enable it on the Incidents tab and Xpiry generates a hosted URL:

https://xpiry.com/status/your-slug

Point a custom domain (e.g. status.yourcompany.com) at it with a CNAME, choose which monitors appear, post incident updates, and combine several domains onto one unified page. It all lives in the dashboard — there's nothing to deploy.

REST API

Pro & Agency

Manage everything above programmatically: add domains, create monitors (the response hands back the ping URL), record events, and read status. Authenticate with a Bearer API key from your Account settings. See the REST API reference for endpoints and payloads.