The API is versioned in the path: /api/v1/.... Breaking changes go to a new version
(/api/v2), never breaking v1 in production.
The contract is additive: new response fields may be added at any time — handle unknown
fields tolerantly. Internal engine/rule versions are in analysis_metadata.source_versions.
schema_version identifies the response contract (v2).
2026-09 — Self-feeding per organization (v1.32.20)
Informative decisions now automatically feed the organization's own knowledge base
(tenant RAG, no patient data) and an aggregated conduct profile enters the context of
every chat of the organization.
Versioned training snapshots per organization (anonymized JSONL + SHA-256), generated on
demand or weekly, behind a flag and consent. Nothing reaches the deterministic engine. See
Alert governance.
2026-09 — Decision memory and faster evidence (v1.32.19)
decision_history on each clinical_alert: per-organization memory of decisions already
recorded on the same alert (counts, override rate, last justification). Presentation/context
only — never changes severity or risk. Also enters the chat/MCP context.
Governance suggestions (admin): suppression-by-signature candidates derived from
decisions, always with human approval; CONTRAINDICADO is never a candidate.
Anonymized decision export (admin, disabled by default + per-organization consent) for
offline tuning of the text models.
Evidence speed: per-pair RAG lookups in parallel with caching (9.5 s → 12 ms on seen
pairs); openFDA and DailyMed with 6-hour caches and parallel pair lookups.
2026-09 — End-to-end code review (v1.32.18): robustness and security
Critical fix:POST /pharmacy/check answered 409 to every call (a constant internal
idempotency key). Fixed; Idempotency-Key behaves exactly like /interactions/check.
Webhooks: delivery no longer blocks the server while retrying slow endpoints;
chat.message now uses the same path as analysis.completed (retries, delivery log, replay).
Real client IP: the API now sees the caller's IP behind the proxy. The allowed_ips
allowlist works and GET /health returns client_ip so you can check the IP we see.
Validated pagination:limit (1–200 on client routes) and offset (≥ 0) → 422 instead of 500.
Batch (/interactions/batch): items run in parallel under a global deadline (100 s);
unfinished items come back as an explicit error instead of the proxy dropping the connection.
Monthly quota: requests rejected by the per-minute limit no longer consume the monthly
quota (distinct 429: Cota mensal excedida).
Right to erasure (LGPD):DELETE .../patients/{ref}?purge=true now deletes the profile
and pseudonymizes the reference / strips clinical data from analyses, usage logs and
snapshots (snapshots under legal_hold are preserved and reported). The response carries erased counts.
Headers: new X-SauBit-Cache, X-SauBit-Agent-Run, X-SauBit-Processing-Time-Ms
(X-SafeMed-* kept for one release). Security headers (HSTS, nosniff, frame-options) on every response.
MCP: malformed JSON → -32700 Parse error (400) instead of 500; internal errors no longer
expose details (only request_id).
2026-06 — Hospital integration, structured contract and dev experience