Skip to content

Health & monitoring

FlowRunner exposes one endpoint for liveness and readiness — GET /api/health. Point your load balancer and uptime monitor at it to know, at a glance, whether the app is up and reaching its database.

The endpoint

GET /api/health is unauthenticated but leaks nothing sensitive — it reports only ok/error and which optional features are configured, never any secret values. It responds to a plain GET:

bash
curl -isS https://<your-host>/api/health

Status codes

The status code is what your monitor should react to:

CodeMeaningReact by
200The database responded to a ping — the app is healthy.Nothing; all good.
503The database is unreachable (ping failed or the connection threw).Alerting; check MONGODB_URI, network, and the Mongo host.

Because a database outage flips the code to 503, an orchestrator (Kubernetes, a load balancer, Vercel's health checks) can pull the instance out of rotation automatically.

What the checks report

The response body carries a small checks object built by checkHealth:

json
{
  "ok": true,
  "checks": {
    "db": "ok",
    "secretsVault": "configured",
    "scheduler": "configured"
  }
}
FieldValuesWhat it means
dbok / errorResult of a live ping against MongoDB. This alone drives ok and the status code.
secretsVaultconfigured / disabledWhether SECRETS_KEY is set — reported by presence only, the value is never exposed.
schedulerconfigured / disabledWhether CRON_SECRET is set — again, presence only.

NOTE

Only the database check affects ok and the HTTP status. secretsVault and scheduler are informational — a deploy with both features off is still perfectly healthy and returns 200. Use those two fields as a quick configuration audit, not as an alerting signal.

Monitoring in practice

  • Uptime monitor — poll /api/health on your usual interval and alert on any non-200.
  • Load balancer / orchestrator — use it as the readiness probe so unhealthy instances leave rotation.
  • Post-deploy smoke check — the first thing to curl after a release. If db is error, the app started but can't reach Mongo; if a feature reads disabled unexpectedly, its environment variable didn't reach the runtime. See Environment variables.

INFO

📸 Screenshot — an uptime monitor configured with /api/health as the check URL, showing a green/200 status

See also

FlowRunner — the no-code platform for small businesses.