Files
worldmonitor/.gitignore
Elie Habib dff14ed344 feat(agent-readiness): RFC 9727 API catalog + native openapi.yaml serve (#3343)
* feat(agent-readiness): RFC 9727 API catalog + native openapi.yaml serve

Closes #3309, part of epic #3306.

- Serves the sebuf-bundled OpenAPI spec natively at
  https://www.worldmonitor.app/openapi.yaml with correct
  application/yaml content-type (no Mintlify proxy hop).
  Build-time copy from docs/api/worldmonitor.openapi.yaml.
- Publishes RFC 9727 API catalog at /.well-known/api-catalog
  with service-desc pointing at the native URL, status rel
  pointing at /api/health, and a separate anchor for the MCP
  endpoint referencing its SEP-1649 card (#3311).

Refs PR #3341 (sebuf v0.11.1 bundle landed).

* test(deploy-config): update SPA catch-all regex assertion

The deploy-config guardrail hard-codes the SPA catch-all regex string
and asserts its Cache-Control is no-cache. The prior commit added
openapi.yaml to the exclusion list; this updates the test to match so
the guardrail continues to protect HTML entry caching.

* fix(agent-readiness): address Greptile review on PR #3343

- Extract openapi.yaml copy into named script `build:openapi` and
  prefix every web-variant build (build:full/tech/finance/happy/
  commodity). prebuild delegates to the same script so the default
  `npm run build` path is unchanged. Swap shell `cp` for Node's
  cpSync for cross-platform safety.
- Bump service-desc MIME type in /.well-known/api-catalog from
  application/yaml to application/vnd.oai.openapi (IANA-registered
  OpenAPI media type). Endpoint Content-Type stays application/yaml
  for browser/tool compatibility.

* fix(agent-readiness): P1 health href + guardrail tests on PR #3343

- status.href in /.well-known/api-catalog was pointing at
  https://api.worldmonitor.app/health (which serves the SPA HTML,
  not a health response). Corrected to /api/health, which returns
  the real {"status":"HEALTHY",...} JSON from api/health.js.
- Extend tests/deploy-config.test.mjs with assertions that would
  have caught this regression: linkset structure, status/service-
  desc href shapes, and presence of build:openapi across every
  web-variant build script.
2026-04-23 18:46:35 +04:00

85 lines
2.0 KiB
Plaintext

node_modules/
.idea/
dist/
public/blog/
.DS_Store
*.log
.env
.env.local
.playwright-mcp/
*-network.txt
.vercel
api/\[domain\]/v1/\[rpc\].js
api/\[\[...path\]\].js
.claude/
.cursor/
CLAUDE.md
.env.vercel-backup
.env.vercel-export
.agent/
.factory/
.windsurf/
skills/
!api/skills/
ideas/
docs/internal/
docs/ideation/
internal/
# Exception: api/internal/ hosts Vercel edge endpoints that must be tracked
# (e.g. api/internal/brief-why-matters.ts — RELAY_SHARED_SECRET-auth'd
# endpoints for internal callers like the Railway digest cron).
# Scoped to SOURCE FILE TYPES ONLY so the parent `.env` / secrets ignore
# rules stay in effect inside this directory. Do NOT widen to `**`.
!api/internal/
!api/internal/*.ts
!api/internal/*.js
!api/internal/*.mjs
test-results/
src-tauri/sidecar/node/*
!src-tauri/sidecar/node/.gitkeep
# AI planning session state
.planning/
# Compiled sebuf gateway bundle (built by scripts/build-sidecar-sebuf.mjs)
api/[[][[].*.js
# Compiled sidecar domain handler bundles (built by scripts/build-sidecar-handlers.mjs)
api/*/v1/\[rpc\].js
.claudedocs/
# Large generated data files (reproduced by scripts/)
scripts/data/pizzint-processed.json
scripts/data/osm-military-processed.json
scripts/data/military-bases-final.json
scripts/data/dedup-dropped-pairs.json
scripts/data/pizzint-partial.json
scripts/data/gpsjam-latest.json
scripts/data/mirta-raw.geojson
scripts/data/osm-military-raw.json
scripts/data/forecast-replays/
# Iran events data (sensitive, not for public repo)
scripts/data/iran-events-latest.json
# Military bases rebuild script (references external Supabase URLs)
scripts/rebuild-military-bases.mjs
.wrangler
# Build artifacts (generated by esbuild/tsc, not source code)
api/data/city-coords.js
# OpenAPI bundle copied at build time from docs/api/ for native Vercel serve
/public/openapi.yaml
# Runtime artifacts (generated by sidecar/tools, not source code)
api-cache.json
verbose-mode.json
skills-lock.json
tmp/
# Local planning documents (not for public repo)
docs/plans/
docs/brainstorms/
playground-pricing.html