Skip to content

Update Resource ID generation logic for HL7 files #3124

@ratheesh-kr

Description

@ratheesh-kr

The Resource IDs for all resources change when the same HL7 file is resubmitted. Update the ID generation logic to ensure consistent and deterministic Resource IDs across repeated submissions.

  1. Patient Resource: Hash value generated from Patient MRN, Patient CIN, PID segment content
  2. Consent Resource: Hash value generated from Patient MRN, Patient CIN, Consent OBX segment (OBX.3.1 = "105511-0" OR OBX.3.2 = "ahc-hrsn patient consent") content, currentTimestamp
  3. Organization Resource: Hash value generated from Patient MRN, Patient CIN, Organization Name, NPI, TIN, Organization Address (ORC.22), Organization Telecom (ORC.23)
  4. Encounter Resource: Hash value generated from Patient MRN, Patient CIN, PV1 segment content, encounterEffectiveTime (PV1.44.1 and PV1.45.1)
  5. Sexual Orientation Resource: Facility ID + '-' + position of the section + '-' + Hash value generated from Patient MRN, Patient CIN, Content of the OBX segment where OBX.3.1 = "76690-7"
  6. Observation Resource: Facility ID + '-' + Question Code + '-' + Hash value generated from Patient MRN, Patient CIN, Content of first OBX segment
  7. Grouper Observation Resource: Facility ID + '-' + Screening Question Code + '-' + Hash value generated from Patient MRN, Patient CIN, Content of the first OBX segment where the code is one of ("96777-8", "97023-6", "NYSAHCHRSN", "NYS-AHC-HRSN")

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions