OHN-03 Master Patient Index (MPI)
- Version
- 1.0.0
- OpenAPI
- 3.1.0
- Source dans le dépôt
modules/OHN-03/api/openapi.yaml- Serveurs
https://opeshealthnetwork.com/api/ohn/v1- Authentification
gatewayToken: http bearer (JWT)
Les contrats sont rédigés en anglais.
Written from the observed behaviour of the TypeScript reference (backend/modules/ohn-03, 2026-11-17). Every route requires a token scoped to ONE jurisdiction (UUID claim); the wildcard is refused (403 forbidden). A different x-ohn-purpose header than the token purpose is refused (403 purpose_mismatch). A record of another jurisdiction is reported as not found.
Opérations
- mpi (5)
- governance (12)
mpi
POST/mpi/match
Identifiant d’opération: matchPatient
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
Idempotency-Key | header | string | oui |
Corps de la requête (obligatoire)
application/json:PatientIdentityCommand
Réponses
| Code | Description | Type de média |
|---|---|---|
201 | Identity stored and candidates evaluated | application/json: MatchResult |
403 | application/problem+json with the legacy error code | application/problem+json: Problem |
422 | application/problem+json with the legacy error code | application/problem+json: Problem |
GET/mpi/candidates
Identifiant d’opération: listCandidates
Authentification: gatewayToken
Réponses
| Code | Description | Type de média |
|---|---|---|
200 | Latest 50 pairs of the jurisdiction | application/json: CandidateList |
POST/mpi/cases/{id}/decisions
Identifiant d’opération: decideCase
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
id | path | string | oui | |
Idempotency-Key | header | string | oui |
Corps de la requête (obligatoire)
application/json:MatchDecisionCommand
Réponses
| Code | Description | Type de média |
|---|---|---|
201 | Decision recorded | application/json: MatchDecision |
404 | application/problem+json with the legacy error code | application/problem+json: Problem |
422 | application/problem+json with the legacy error code | application/problem+json: Problem |
GET/mpi/patients
Identifiant d’opération: searchPatients
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
family_name | query | string | non | |
given_name | query | string | non | |
birth_date | query | string | non |
Réponses
| Code | Description | Type de média |
|---|---|---|
200 | At most 25 identities | application/json: PatientList |
422 | application/problem+json with the legacy error code | application/problem+json: Problem |
GET/mpi/patients/{id}
Identifiant d’opération: getPatient
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
id | path | string | oui |
Réponses
| Code | Description | Type de média |
|---|---|---|
200 | Identity | application/json: PatientIdentity |
404 | application/problem+json with the legacy error code | application/problem+json: Problem |
governance
GET/mpi/candidates/{id}
Identifiant d’opération: getCandidate
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
id | path | string | oui |
Réponses
| Code | Description | Type de média |
|---|---|---|
200 | Pair with decision history | application/json: CandidateDetail |
404 | application/problem+json with the legacy error code | application/problem+json: Problem |
GET/mpi/rule-sets
Identifiant d’opération: listRuleSets
Authentification: gatewayToken
Réponses
| Code | Description | Type de média |
|---|---|---|
200 | Rule sets and the active rule | application/json: RuleSetList |
POST/mpi/rule-sets
Identifiant d’opération: submitRuleSet
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
Idempotency-Key | header | string | oui |
Corps de la requête (obligatoire)
application/json:RuleSetDraft
Réponses
GET/mpi/rule-sets/{id}
POST/mpi/rule-sets/{id}/approve
A different person than the submitter must approve (403 second_approver_required). The previous active rule becomes superseded.
Identifiant d’opération: approveRuleSet
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
id | path | string | oui | |
Idempotency-Key | header | string | oui |
Corps de la requête (obligatoire)
application/json:ReasonCommand
Réponses
POST/mpi/rule-sets/{id}/reject
Identifiant d’opération: rejectRuleSet
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
id | path | string | oui | |
Idempotency-Key | header | string | oui |
Corps de la requête (obligatoire)
application/json:ReasonCommand
Réponses
POST/mpi/rule-sets/{id}/retire
Identifiant d’opération: retireRuleSet
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
id | path | string | oui | |
Idempotency-Key | header | string | oui |
Corps de la requête (obligatoire)
application/json:ReasonCommand
Réponses
GET/mpi/investigations
Identifiant d’opération: listInvestigations
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
status | query | "open" | "closed" | non |
Réponses
| Code | Description | Type de média |
|---|---|---|
200 | Up to 200 newest first | application/json: InvestigationList |
POST/mpi/investigations
Identifiant d’opération: openInvestigation
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
Idempotency-Key | header | string | oui |
Corps de la requête (obligatoire)
application/json:InvestigationCommand
Réponses
| Code | Description | Type de média |
|---|---|---|
201 | Opened | application/json: Investigation |
404 | application/problem+json with the legacy error code | application/problem+json: Problem |
422 | application/problem+json with the legacy error code | application/problem+json: Problem |
GET/mpi/investigations/{id}
Identifiant d’opération: getInvestigation
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
id | path | string | oui |
Réponses
| Code | Description | Type de média |
|---|---|---|
200 | Investigation | application/json: Investigation |
404 | application/problem+json with the legacy error code | application/problem+json: Problem |
POST/mpi/investigations/{id}/close
Identifiant d’opération: closeInvestigation
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
id | path | string | oui | |
Idempotency-Key | header | string | oui |
Corps de la requête (obligatoire)
application/json:CloseCommand
Réponses
| Code | Description | Type de média |
|---|---|---|
200 | Closed | application/json: Investigation |
404 | application/problem+json with the legacy error code | application/problem+json: Problem |
409 | application/problem+json with the legacy error code | application/problem+json: Problem |
GET/mpi/reports/{reportId}
OHN-03-R001..R003. format=csv downloads and records an export event.
Identifiant d’opération: runMpiReport
Authentification: gatewayToken
Paramètres
| Nom | Emplacement | Type | Obligatoire | Description |
|---|---|---|---|---|
reportId | path | string | oui | |
from | query | string | non | |
to | query | string | non | |
format | query | string | non |
Réponses
Schémas
Problem
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
error | string | oui | |
message | string | non | |
id | string | non | |
details | object | non | |
trace_id | string | non |
ReasonCommand
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
reason | string | oui |
PatientIdentityCommand
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
jurisdiction_id | string (uuid) | oui | |
given_name | string | non | |
family_name | string | non | |
birth_date | string (date) | non | |
sex_at_birth | "male" | "female" | "unknown" | "other" | non | |
local_identifier | string | non | |
source_facility | string (uuid) | oui | |
purpose | string | oui |
PatientIdentity
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
id | string (uuid) | non | |
jurisdiction_id | string (uuid) | non | |
given_name | string | null | non | |
family_name | string | null | non | |
birth_date | string | null | non | |
sex_at_birth | string | null | non | |
local_identifier | string | null | non | |
source_facility | string (uuid) | non | |
purpose | string | non | |
match_status | "unresolved" | "review_required" | "resolved" | non | |
version | integer | non | |
created_at | string (date-time) | non | |
updated_at | string (date-time) | non |
PatientList
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
items | array of PatientIdentity | non |
MatchCandidate
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
id | string (uuid) | non | |
left_patient_id | string (uuid) | non | |
right_patient_id | string (uuid) | non | |
score | number (double) | non | |
rule_set_id | string (uuid) | non | |
status | string | non | |
reviewer_id | string | null | non | |
created_at | string (date-time) | non | |
updated_at | string (date-time) | non |
CandidateList
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
items | array of MatchCandidate | non | |
total | integer | non |
MatchResult
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
patient | PatientIdentity | non | |
candidates | array of MatchCandidate | non |
DecisionEntry
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
id | string (uuid) | non | |
decision | string | non | |
match_explanation | string | non | |
reason | string | non | |
reviewer_id | string | non | |
created_at | string (date-time) | non |
CandidateDetail
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
id | string (uuid) | non | |
left_patient_id | string (uuid) | non | |
right_patient_id | string (uuid) | non | |
score | number (double) | non | |
rule_set_id | string (uuid) | non | |
status | string | non | |
reviewer_id | string | null | non | |
created_at | string (date-time) | non | |
updated_at | string (date-time) | non | |
rule_version | string | non | |
decisions | array of DecisionEntry | non |
MatchDecisionCommand
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
candidate_pair_id | string (uuid) | non | |
decision | "link" | "non_link" | "needs_review" | oui | |
evidence_refs | array of string (uuid) | non | |
match_explanation | string | oui | |
reason | string | oui | |
reviewer_id | string (uuid) | oui |
MatchDecision
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
id | string (uuid) | non | |
candidate_pair_id | string (uuid) | non | |
decision | string | non | |
match_explanation | string | non | |
reason | string | non | |
reviewer_id | string | non | |
created_at | string (date-time) | non |
RuleSetDraft
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
rule_version | string | oui | |
feature_weights | string | non | |
auto_link_threshold | number (double) | oui | |
manual_review_threshold | number (double) | oui | |
effective_from | string (date) | oui | |
reason | string | oui |
RuleSet
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
id | string (uuid) | non | |
rule_version | string | non | |
feature_weights | string | non | |
auto_link_threshold | number (double) | non | |
manual_review_threshold | number (double) | non | |
effective_from | string | non | |
status | "submitted" | "active" | "rejected" | "retired" | "superseded" | non | |
submitted_by | string | null | non | |
approved_by | string | null | non | |
reason | string | null | non | |
decided_at | string | null | non | |
created_at | string (date-time) | non | |
updated_at | string (date-time) | non |
ActiveRule
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
id | string | null | non | |
rule_version | string | non | |
auto_link_threshold | number (double) | non | |
manual_review_threshold | number (double) | non |
RuleSetList
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
items | array of RuleSet | non | |
active | ActiveRule | non |
InvestigationCommand
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
patient_ref | string (uuid) | oui | |
suspected_duplicate_ref | string (uuid) | oui | |
investigation_reason | string | oui | |
source_evidence | string (uuid) | non |
CloseCommand
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
outcome | "duplicate_confirmed" | "not_duplicate" | "inconclusive" | oui | |
reason | string | oui |
Investigation
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
id | string (uuid) | non | |
patient_ref | string (uuid) | non | |
suspected_duplicate_ref | string (uuid) | non | |
investigation_reason | string | non | |
source_evidence | string | null | non | |
status | "open" | "closed" | non | |
outcome | string | null | non | |
opened_by | string | null | non | |
closed_by | string | null | non | |
created_at | string (date-time) | non | |
updated_at | string (date-time) | non |
InvestigationList
| Nom | Type | Obligatoire | Description |
|---|---|---|---|
items | array of Investigation | non |