API reference

CRIE exposes a single REST/JSON API at /v1/.... All endpoints require a valid session cookie unless explicitly marked public. State-changing requests require a CSRF double-submit token.

Conventions

  • Content typeapplication/json for all read/write endpoints; multipart for uploads.
  • Errors — RFC 7807 Problem Details JSON with stable machine-readable code values.
  • Pagination — cursor-based, ?cursor=…&limit=….
  • Idempotency — POST creates accept an Idempotency-Key header.

Endpoints

AreaMethodPathDescription
AuthPOST/v1/auth/loginExchange credentials for a session cookie
AuthPOST/v1/auth/logoutInvalidate the current session
AuthGET/v1/auth/meCurrent user + role
PatientsGET/v1/patientsList patients (RBAC + RLS scoped)
PatientsPOST/v1/patientsCreate a patient (PHI encrypted at rest)
PatientsGET/v1/patients/:idFetch a single patient
NotesGET/v1/notesList notes for a patient
NotesPOST/v1/notesCreate a clinical note
AnalysesPOST/v1/analysesRun AI analysis over a note
AnalysesGET/v1/analyses/:idFetch an analysis
AnalysesGET/v1/analyses/:id/streamSSE stream of pipeline step events (new in v0.4)
AlertsGET/v1/alertsList clinical alerts
AlertsPOST/v1/alerts/:id/acknowledgeAcknowledge an alert
HealthGET/v1/health/liveLiveness
HealthGET/v1/health/readyReadiness — DB + migrations
HealthGET/v1/health/modulesPer-module enablement flags
ChatbotPOST/v1/chatbot/askAsk CRIE — RAG over docs (new in v0.4)

Full module-by-module endpoint listings live on each module page.