diff --git a/packages/esm-patient-registration-app/src/client-registry/hie-client-registry/hie-resource.ts b/packages/esm-patient-registration-app/src/client-registry/hie-client-registry/hie-resource.ts index 7246dee19..9f6bd6a31 100644 --- a/packages/esm-patient-registration-app/src/client-registry/hie-client-registry/hie-resource.ts +++ b/packages/esm-patient-registration-app/src/client-registry/hie-client-registry/hie-resource.ts @@ -83,9 +83,10 @@ class PatientMapper extends Mapper { ): Record { const updatedIdentifiers: Record = { ...currentFormValues.identifiers }; - // Map healthId to hiePatient.id - updatedIdentifiers.healthId = { - ...currentFormValues.identifiers['healthId'], + // Map Social Health Authority Unique Identification Number to HIE Patient ID + // See https://github.com/palladiumkenya/openmrs-module-kenyaemr/blob/1e1d281eaba8041c45318e60ca0730449b8e4197/api/src/main/distro/metadata/identifierTypes.xml#L33 + updatedIdentifiers.socialHealthAuthorityIdentificationNumber = { + ...currentFormValues.identifiers['socialHealthAuthorityIdentificationNumber'], identifierValue: hiePatient.id, };