Skip to content

Architecture / Decision records / ADR-HIS-118

ADR-HIS-118 The contracts of slice RC-4: emergency arrival as one orchestrated step in the flow unit, unidentified persons without a duplicate check, the admission request from emergency through the flow unit, placeholder names, and the emergency access review events

Status Accepted
Decided 2026-12-01 by session RC-4-S01
Record Drafted 2026-12-01; approved 2026-12-02 by the Enterprise Architecture Board
Where the rule lives contracts/adm/api/flow.v1 1.1, registration.v1 1.2, patient-identity.v1 1.3, schemas/adm-types.v1.json, QueueStateChanged 1.1; contracts/ess/api/emergency-access.v1 1.1, EmergencyAccessReviewed and ReviewOverdue in contracts/ess/contract.yaml; contracts/adm/README.md and contracts/ess/CONTRACT-POINTS.md (contract points of slice RC-4); e2e/scenarios/RC-4/

Context

Slice RC-4 brings three requirements: - FR-ADM-REG-004, unidentified patients, aliases, newborns, name changes and identity reconciliation (MOD-ADM-002, unit adm-patient-administration); - FR-ADM-FLW-003, emergency arrival, rapid registration, triage routing and disposition (MOD-ADM-008, unit adm-scheduling-flow); - FR-ESS-AUZ-002, Break-the-Glass emergency access (MOD-ESS-002, unit ess-runtime-decision), whose API IF-ESS-004 RC-1-S01 fixed at version 1.0 (ADR-HIS-048).

The specification leaves these questions of build open:

  1. FR-ADM-FLW-003 part 6.1 asks for the person, the emergency encounter and the queue item "in a single step". They belong to three units: the person to adm-identity, the registration and the encounter to adm-patient-administration, the queue item to adm-scheduling-flow. Which unit offers the step, and what "single" means across them.
  2. An unidentified person must be created "without a duplicate-check block" (AC-01). createPerson of patient-identity.v1 requires the duplicate check the clerk answered.
  3. D01-ADM 4.3 puts the emergency flow state in "Awaiting bed" "from the admission request". Domain 1 publishes no event for an admission request (D01-ADM 8.5), and the request is made in adm-patient-administration while the flow state is adm-scheduling-flow's.
  4. The form of the placeholder name of an unidentified patient (PR-REG-004-1: unique, clearly distinguishable from real names, no clinical information) and of the name of a newborn before the legal name is known. The specification gives neither.
  5. EVT-ESS-005 is catalogued as one row, "EmergencyAccessReviewed / ReviewOverdue", with two triggers.

Decision

  1. Emergency arrival is one operation of adm-scheduling-flow, orchestrated and idempotent as a whole. flow.v1 registerEmergencyArrival takes the rapid data set of CFG-ADM-027 with one of an existing person, a new person or an unidentified observation. It calls registration.v1 (registerPatient or registerUnidentifiedPatient) and encounters.v1 createEncounter, then creates the queue item. Each call carries a key derived from the request's Idempotency-Key and the step, so a retry after a partial failure completes the missing parts and never makes a second person, encounter or item. Until all three exist, the arrival answers 503 and is not on the board. The step belongs to MOD-ADM-008, the module of FR-ADM-FLW-003, and its build session; the downtime back-entry check (unique form number per facility) belongs there too. Only Domain 1 Tier 1 services are called (part 6.6). A distributed transaction was rejected: the units have their own databases (ADR-HIS-039), and idempotent steps give the same outcome for the user.
  2. An unidentified person is created without a duplicate check, by an explicit status. createPerson takes identityStatus: unidentified, for which duplicateCheck is not required, and the person carries the exclusion flag unidentified, so every later candidate pair goes to a steward. A newborn (newborn: true) may also come without an answered check: adm-identity runs the check itself and turns every candidate into a review item, never a prompt. recordDemographicChange takes identified: true to move an unidentified person to active when the real demographics are completed. Reconciliation to an existing person is a merge request to the steward (reportIdentityWorkItem), never automatic, and the merge is that of RC-3 (ADR-HIS-083). Inferring the status from a name of use temp was rejected as implicit. These are three compatible additions to adm-identity, which no RC-4 card builds: they are a follow-up for an adm-identity session before RC-4-S06.
  3. The admission request from emergency goes through adm-scheduling-flow. flow.v1 requestAdmissionFromEmergency forwards the request to adt.v1 createAdmissionRequest with fromEmergency and, when it is accepted, sets the flow state to Awaiting bed in the same user step. The item closes with the disposition Admitted from PatientDischarged with disposition admitted, as admitFromEmergency already publishes (ADR-HIS-083). A new event was rejected, because a contract session does not add to the event catalogue; a call from adm-patient-administration to adm-scheduling-flow was rejected, because it would change a RC-3 operation outside the cards of RC-4.
  4. Placeholder names are system-generated, by a fixed pattern. An unidentified patient is named TANPA NAMA <facility>-<yymmdd>-<nnn> ("no name", the facility code, the registration date and a sequence per facility and day), for example TANPA NAMA RSU-01-261201-003. No real name has the prefix; the facility and the sequence make it unique across concurrent arrivals and across facilities; it carries nothing observed or clinical. A newborn without a given name is By. Ny. <mother's official name>, followed by the birth order for a multiple birth, as Indonesian hospitals name babies before the birth certificate; By. TANPA NAMA … when the mother is unknown. Both are names with use temp, never replaced: they stay as former names, searchable, when the identity is established or the legal name recorded (PR-REG-004-3). Registration governance may change the pattern; the contract fixes only that it is generated and unique.
  5. EVT-ESS-005 is two events, named as the catalogue names them. EmergencyAccessReviewed (outcome recorded) and ReviewOverdue (due time passed and the review escalated, once per session), both on his.ess.emergencyaccesssession.v1, aggregate EmergencyAccessSession, ordered per session after EmergencyAccessInvoked. The contract tooling reads the catalogue row's two names this way. Neither carries the justification or the review comment.
  6. The review workspace reads the session, not a list of its own. emergency-access.v1 1.1 adds to the session its role, unit, review task, escalation time, follow-up task and security incident, a reviewOverdue filter, and the pattern report of part 6.10 (readEmergencyAccessPatterns). The review queue of UI-ESS-005 stays the workflow.v1 work list of the review tasks (OV-01), and the activity list stays the audit query by emergencySessionId. "Extend emergency access" while a session is Active (Q4 on issue #15) stays open; version 1's behaviour (a repeat answers the Active session) is kept.

Consequences

  • RC-4-S04 builds the orchestration of point 1 and the admission request of point 3 in adm-scheduling-flow, with the contract points of contracts/adm/README.md, slice RC-4. RC-4-S03 builds registration.v1 1.2 in adm-patient-administration. RC-4-S02 builds emergency-access.v1 in ess-runtime-decision, beside the decision service.
  • adm-identity must serve patient-identity.v1 1.3 before RC-4-S06 can pass RC-4-E2E-001, 003 and 004. No card of RC-4 does it: it needs a card or a fix session of its own (handover RC-4-S01).
  • The emergency queue definitions gain triageRouting and emergency (CFG-ADM-019). The emergency flow state Pending discharge "from the discharge decision" has the same gap as point 3 and is left to FR-ADM-FLW-002's owner (a follow-up).
  • The placeholder patterns of point 4 are listed for registration governance; changing them changes no contract.
  • Every change is a compatible minor version: his-contract check passes against main.