# Check Database Health

> PostgreSQL database health via omninode-runtime HTTP health endpoint

- Skill: `omninode-ai/check-database-health` (Agent Skill, multi-file: 4 files)
- Install (CLI): `npx skillmds@latest add omninode-ai/check-database-health`
- Raw SKILL.md: https://api.skillmd.com/api/skills/omninode-ai/check-database-health/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Coding & Dev Tools
- Author: OmniNode-ai (https://skillmd.com/u/omninode-ai)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/omninode-ai/check-database-health

---


# Check Database Health

Monitor PostgreSQL database health through the omninode-runtime health endpoint.

The Mac must never connect directly to Postgres via raw psql. The correct
data access path is: Mac → runtime health endpoint → Postgres.

## What It Checks

- Runtime health endpoint reachability (`/health`)
- HTTP response status and latency
- Response body from the runtime service

## How to Use

```bash
python3 ${CLAUDE_PLUGIN_ROOT}/skills/system_status/check_database_health/_lib/execute.py
```

Override the endpoint via env var:

```bash
OMNINODE_RUNTIME_HEALTH_URL=http://${ONEX_HOST}:8085/health \
  python3 ${CLAUDE_PLUGIN_ROOT}/skills/system_status/check_database_health/_lib/execute.py
```

## Example Output

```json
{
  "timestamp": "2025-11-12T14:30:00Z",
  "status": "healthy",
  "probe_method": "runtime_health_endpoint",
  "database": {
    "status": "healthy",
    "response_time_ms": 12.4,
    "status_code": 200,
    "details": {"status": "ok"},
    "endpoint": "http://<onex-host>:8085/health"
  }
}
```

## Exit Codes

- `0` - Runtime health endpoint returned HTTP 200
- `1` - Endpoint unreachable, timed out, or returned non-200

