Audit date: 2026-04-11
The current Strata runtime API surface is intentionally small. The product contract currently consists of document retrieval, search, index-job workflow, and a basic health endpoint. The only extra HTTP surface exposed by the API runtime today is the development-only OpenAPI document when the app runs in the Development environment.
This audit is a planning artifact, not an API redesign. It inventories the current surface, identifies which endpoints belong to the intended Strata contract, and records the remaining cleanup work to make that contract more explicit.
| Endpoint | Source | Current role | Contract status | Notes |
|---|---|---|---|---|
GET /health |
HealthController |
basic readiness check | intended product-facing operational endpoint | Used for platform verification and local readiness checks. |
POST /api/search |
SearchController |
search indexed documents | intended product-facing endpoint | Core retrieval API for the current Strata slice. |
GET /api/documents/{id} |
DocumentsController |
fetch a known document | intended product-facing endpoint | Supports document viewing after search or direct lookup. |
POST /api/index-jobs |
IndexJobsController |
create indexing work | intended product-facing endpoint | Current request shape is intentionally minimal for the early product slice. |
GET /api/index-jobs/{id} |
IndexJobsController |
read indexing job status | intended product-facing endpoint | Supports current operational verification of indexing flow, including retry accounting. |
GET /openapi/v1.json |
MapOpenApi() in Program.cs |
development-time API description | development-only support endpoint | Present only in Development; useful for inspection, not part of the stable product contract. |
GET /openapi/v1.jsonexists only when the API runs in Development- it is useful for local inspection, CI sanity checks, and future contract work
- it should not be treated as a stable product endpoint on its own
POST /api/index-jobscurrently accepts an effectively empty request because source-scoped indexing has not landed yetGET /healthis intentionally minimal and should remain an operational readiness check rather than expanding into a broad status dumpPOST /api/searchstill deserves tighter written contract language around validation and result semantics
For the current Milestone 1 and early Milestone 2 boundary, the intended Strata API contract is:
GET /healthPOST /api/searchGET /api/documents/{id}POST /api/index-jobsGET /api/index-jobs/{id}
Everything else should be treated as development support behavior or future work until explicitly documented otherwise.
- Keep
docs/api.mdaligned to only the intended product-facing endpoints and operationally relevant behavior. - Continue treating
GET /openapi/v1.jsonas development support behavior, not as a public product promise. - Tighten the written contract for
POST /api/search, especially around input validation and the current limit-handling behavior. - Revisit the index-job endpoints once source-aware ingestion lands so the request and status model match the future source-scoped workflow.
- Add richer API contract documentation later if the repo introduces new public endpoints or external integrator expectations.