Skip to content

docs(api): document exact /status schema separating process vs data health (#273) - #533

Open
sparkysolutions10-pixel wants to merge 1 commit into
Divinity-Labs:mainfrom
sparkysolutions10-pixel:feat/status-schema-docs-273
Open

sparkysolutions10-pixel wants to merge 1 commit into
Divinity-Labs:mainfrom
sparkysolutions10-pixel:feat/status-schema-docs-273

Conversation

@sparkysolutions10-pixel

Copy link
Copy Markdown
Contributor

Closes #273

Summary of Changes

  • Documents the exact JSON response shape for /status in openapi.yaml, openapi.json, and README.md.
  • Explicitly separates process health (uptimeSeconds, memoryUsageMb, status) from data health (lastIndexedLedger, lastProcessedAt, ingestLagSeconds, isStale).
  • Formulates deterministic status degradation (status: "degraded" when ingestLagSeconds > 300 but server process is healthy) without false alarm paging.
  • Returns 503 Service Unavailable with pagingCondition: "DATABASE_DOWN" only when critical infrastructure failures occur (e.g. Postgres disconnect), providing a clear paging threshold for uptime monitors.
  • Adds concrete Datadog / Prometheus / BetterStack monitoring configuration examples to README.md.
  • Added unit tests in src/__tests__/statusContract.test.ts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

/status has no documented shape

1 participant