Query an Unraid server via GraphQL for system, array, and Docker status in read-only mode.
Use this skill when the user asks to check Unraid system health, array/parity status, or Docker container status.
Located at: https://github.com/Yoshiofthewire/unraid-claw
Before running any script, ensure the Unraid server is configured:
UNRAID_API_KEY uses that generated key.Read these environment variables at runtime:
UNRAID_BASE_URL (example: https://tower.local)UNRAID_API_KEYOptional:
UNRAID_TIMEOUT_SECONDS (default: 10)UNRAID_STATE_DIR (default: repo-local ).stateUNRAID_NOTIFY_HOST_LABEL (default: host name)UNRAID_CPU_WARN_PERCENT (default: 85)UNRAID_CPU_CRIT_PERCENT (default: 95)UNRAID_MEM_WARN_PERCENT (default: 85)UNRAID_MEM_CRIT_PERCENT (default: 95)UNRAID_STOPPED_WARN_COUNT (default: 1)UNRAID_STOPPED_CRIT_COUNT (default: 3)Template .envexample (copy to .env and fill in real values):
# Required: Base URL for your Unraid server (include protocol).
UNRAID_BASE_URL=https://tower.local
# Required: API key from Unraid API settings.
# Keep this secret. Do not commit real keys.
UNRAID_API_KEY=replace_with_your_unraid_api_key
# Optional: request timeout in seconds.
UNRAID_TIMEOUT_SECONDS=10
# Optional: state directory for snapshot and log artifacts.
# Default is repository-local .state directory.
# UNRAID_STATE_DIR=/path/to/state
UNRAID_NOTIFY_HOST_LABEL=tower
# Optional: alert thresholds.
UNRAID_STOPPED_WARN_COUNT=1
UNRAID_STOPPED_CRIT_COUNT=3
If a required variable is missing, stop and return:
Unraid API key is not configured. Set UNRAID_API_KEY and retry.Unraid base URL is not configured. Set UNRAID_BASE_URL and retry.x-api-key: <UNRAID_API_KEY>.If API auth fails (401 or 403), return:
Authentication to Unraid API failed. Verify UNRAID_API_KEY permissions/validity.Use the repository scripts as the primary execution path. Do not handcraft ad-hoc GraphQL calls unless explicitly asked.
Primary scripts:
./scripts/unraid_connection_test.sh./scripts/unraid_preflight.sh./scripts/unraid_snapshot.sh./scripts/unraid_health_summary.sh./scripts/unraid_docker_report.sh./scripts/unraid_array_parity_report.sh./scripts/unraid_alerts.sh./scripts/unraid_notify.sh./scripts/unraid_cron_runner.sh./scripts/unraid_connection_test.sh./scripts/unraid_preflight.sh./scripts/unraid_snapshot.sh./scripts/unraid_health_summary.sh./scripts/unraid_snapshot.sh (if no recent snapshot)./scripts/unraid_docker_report.sh./scripts/unraid_snapshot.sh (if no recent snapshot)./scripts/unraid_array_parity_report.sh./scripts/unraid_alerts.sh./scripts/unraid_cron_runner.shUnraid GraphQL fields can vary by version. If some fields are unavailable:
Some API fields were unavailable for this Unraid version; output is partial.Return results in this order:
healthy | warning | criticalSet overall status using these rules:
healthy: no array/parity errors, no critical SMART issues, API reachable.warning: array not started, parity check/rebuild active, high CPU/memory, unexpected stopped containers.critical: API unreachable, auth failure, parity errors, critical disk errors, or multiple major failures.Script exit mapping for automation:
./scripts/unraid_alerts.sh exit 0: healthy./scripts/unraid_alerts.sh exit 10: warning./scripts/unraid_alerts.sh exit 20: criticalUse these notes when the user asks to schedule recurring health checks.
.env before running scripts../scripts/unraid_cron_runner.sh as the single cron entrypoint..state/logs/ (or UNRAID_STATE_DIR/logs/ if overridden)../scripts/unraid_monitor.cron.template.Use the template file as the source of truth:
./scripts/unraid_monitor.cron.templateSetup flow:
/path/to/Unraid_Claw in the template.crontab.Example: run every 15 minutes.
*/15 * * * * cd /path/to/Unraid_Claw && set -a && . ./.env && set +a && ./scripts/unraid_cron_runner.sh >> ./.state/logs/cron.log 2>&1
Example: run every 5 minutes for tighter monitoring.
*/5 * * * * cd /path/to/Unraid_Claw && set -a && . ./.env && set +a && ./scripts/unraid_cron_runner.sh >> ./.state/logs/cron.log 2>&1
scripts/unraid_monitor.cron.template.unraid_cron_runner.sh as the command target..env loading is included..state/logs/cron.log and runner logs.Never place secrets directly in crontab lines. Always source .env.
Keep responses concise and operator-friendly.
Example shape:
Overall: warning
Time: 2026-03-20T14:22:00Z
System:
- Uptime: 12d 4h
- CPU: 68% (72 C)
- Memory: 81%
Array:
- State: started
- Sync: parity-check 43%
- Disk alerts: disk3 SMART warning
Docker:
- Total: 14
- Running: 12
- Stopped: 2 (plex, immich_ml)
Alerts:
- Parity check in progress
- 1 disk SMART warning