Use casesWeb apps

JSON API backends

std.web routes returning http.json, capability-granted packages per domain, and mock-mode tests for every endpoint shape.

The problem

SPAs and mobile clients want JSON APIs. The backend team picks Go or FastAPI; the ML team picks Python notebooks; the gateway proxies between them. Every API change is two PRs and an integration test suite that only runs in staging.

Why Ecko

JSON first
http.json and json_decode are stdlib. Handlers stay small; validation uses the validate package or typed structs.
Modular grants
Auth middleware gets no network; enrichment imports get grant [net]. The API surface makes the trust boundary obvious.
Test without HTTP
Call handler functions directly in tests with mock-mode AI. You do not need to spin up a port to verify response shapes.

In practice

api.ecko
fn create(req) {
  body = json_decode(req.body)
  item = ai "Normalise this listing" from body
  http.json(item, status=201)
}

Further reading

Try it on your workload.