You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
- Phase 8.9 — CLI ergonomics (`fhir-gen mcp` to launch a configured server)
580
-
- Phase 6 follow-up — wire compiled invariants into emitted Standard Schema validators
580
+
- Phase 6 follow-up — wire compiled invariants into emitted Standard Schema validators (extract `ElementDefinition.constraint[*]` at generate time, run `compileInvariant`, thread into the zod/native validator output)
581
+
- Phase 8 — Streamable HTTP transport (the package ships only stdio today; the spec also defines an HTTP transport, useful for hosted deployments)
| MCP server generation — generator + CLI integration | ✅ |`fhir-gen generate --mcp <out>` emits a server scaffold; `fhir-gen mcp <baseUrl>` launches one inline (Phases 8.8+8.9, v0.46.0+v0.47.0). |
226
+
| Phase 6 follow-up — invariants in emitted validators | ❌ | Compile generator-time invariants into the emitted Standard Schema validators. |
224
227
225
228
Drift between this table and the code is caught by `pnpm audit:export-surface` — every PR that changes the public surface must refresh `.surface-snapshot.json`.
226
229
@@ -308,14 +311,32 @@ const server = createServer({
-**Read-only by default**; writes opt in via `writes`, with optional per-resource-type allowlist (`writeResourceTypes`), `confirmWrites` (require `{confirm: true}` per call), and `dryRun` (short-circuit to a synthetic OperationOutcome)
318
+
-**Three auth strategies, all wired**: `bearer`, `backend-services` (SMART v2 signed JWT — RS384 / ES384, lazy-loaded via `@fhir-dsl/smart` + `jose`), `patient-launch` (refresh-token flow with auto-rotation)
319
+
-**Pluggable `AuditSink`** — `JsonLogAuditSink`, `MemoryAuditSink`, `NullAuditSink` ship by default
320
+
-**Token economy guards** — `defaultSearchCount` (default 20), `defaultReadSummary`, and a `maxResponseBytes` cap (default 64KB) that swaps oversize bodies for a `too-costly` OperationOutcome (the audit retains the original)
321
+
-**MCP resources** — `fhir://<ResourceType>/{id}` URIs read via `resources/read` (and `_history/<versionId>` for vread)
322
+
-**Stdio transport today**; Streamable HTTP is planned
`./mcp-server/` gets a `server.ts` shim, `mcp.config.json` seeded with the IG's resource types, and a README. Launch it with `FHIR_BASE_URL=… node server.ts`.
0 commit comments