From e03204a7106e24f2c2ae825baef7e4697b528823 Mon Sep 17 00:00:00 2001 From: oslynn Date: Wed, 8 Jan 2025 09:20:41 -0600 Subject: [PATCH] Carbob Health Onboarding Test with NJ --- prime-router/settings/STLTs/NJ/nj-doh.yml | 110 ---------------- prime-router/settings/STLTs/NJ/nj-dph.yml | 122 ++++++++++++++++++ .../STLTs/NJ/NJ-receiver-transform.yml | 34 ++++- 3 files changed, 155 insertions(+), 111 deletions(-) delete mode 100644 prime-router/settings/STLTs/NJ/nj-doh.yml create mode 100644 prime-router/settings/STLTs/NJ/nj-dph.yml diff --git a/prime-router/settings/STLTs/NJ/nj-doh.yml b/prime-router/settings/STLTs/NJ/nj-doh.yml deleted file mode 100644 index bbd289a2f63..00000000000 --- a/prime-router/settings/STLTs/NJ/nj-doh.yml +++ /dev/null @@ -1,110 +0,0 @@ -- name: "nj-doh" - description: "New Jersey Department of Health" - jurisdiction: "STATE" - stateCode: "NJ" - countyName: null - filters: null - featureFlags: null - keys: null - senders: [] - receivers: - - name: "full-elr" - organizationName: "nj-doh" - topic: "full-elr" - customerStatus: "active" - translation: ! - schemaName: "azure:/hl7_mapping/receivers/STLTs/NJ/NJ-receiver-transform.yml" - useTestProcessingMode: false - useBatchHeaders: true - receivingApplicationName: "ELRS" - receivingApplicationOID: "2.16.840.1.113883.3.1299.5.1.6.1" - receivingFacilityName: "NJDOH" - receivingFacilityOID: "2.16.840.1.113883.3.1299" - messageProfileId: null - replaceValue: { } - replaceValueAwithB: { } - reportingFacilityName: null - reportingFacilityId: null - reportingFacilityIdType: null - suppressQstForAoe: false - suppressHl7Fields: null - suppressAoe: false - defaultAoeToUnknown: false - replaceUnicodeWithAscii: false - useBlankInsteadOfUnknown: null - truncateHDNamespaceIds: true - truncateHl7Fields: "OBX-23-1,ORC-12-3,OBR-16-3,OBX-17-1,ORC-12-1,OBR-16-1" - usePid14ForPatientEmail: false - convertTimestampToDateTime: null - cliaForOutOfStateTesting: null - cliaForSender: { } - phoneNumberFormatting: "STANDARD" - suppressNonNPI: false - processingModeCode: null - replaceDiiWithOid: null - applyOTCDefault: false - useOrderingFacilityName: "STANDARD" - valueSetOverrides: { } - nameFormat: "STANDARD" - receivingOrganization: null - convertPositiveDateTimeOffsetToNegative: false - stripInvalidCharsRegex: null - convertDateTimesToReceiverLocalTime: false - useHighPrecisionHeaderDateTimeFormat: false - type: "HL7" - truncationConfig: - truncateHDNamespaceIds: true - truncateHl7Fields: - - "OBX-23-1" - - "ORC-12-3" - - "OBR-16-3" - - "OBX-17-1" - - "ORC-12-1" - - "OBR-16-1" - customLengthHl7Fields: { } - jurisdictionalFilter: - - "(Bundle.entry.resource.ofType(ServiceRequest)[0].requester.resolve().organization.resolve().address.state.exists() and Bundle.entry.resource.ofType(ServiceRequest)[0].requester.resolve().organization.resolve().address.state = 'NJ') or (Bundle.entry.resource.ofType(Patient).address.state.exists() and Bundle.entry.resource.ofType(Patient).address.state = 'NJ')" - qualityFilter: - # hasOneOf(patient_street, patient_zip_code, patient_phone_number, patient_email) - - "Bundle.entry.resource.ofType(Patient).where(address.line[0].empty() and address.postalCode.empty() and telecom.where(system = 'phone').value.empty() and telecom.where(system = 'email').value.empty()).count() = 0" - # hasOneOf(order_test_date, specimen_collection_date_time, test_result_date) - - "Bundle.entry.resource.ofType(DiagnosticReport).where(basedOn.resolve().extension('https://reportstream.cdc.gov/fhir/StructureDefinition/effective-date').empty() and specimen.resolve().collection.collected.empty() and effective.empty() and issued.empty() and result.resolve().effective.empty()).count() = 0" - # isValidClia(testing_lab_clia) - - "Bundle.entry.resource.ofType(ServiceRequest).performer.resolve().identifier.where(type.coding.code = 'CLIA').value.getIdType() = 'CLIA'" - # hasValidData(patient_last_name, patient_first_name, patient_dob) - - "Bundle.entry.resource.ofType(Patient).where(name.family.empty() or name.given.empty() or birthDate.empty()).count() = 0" - # hasValidData(specimen_type) - - "Bundle.entry.resource.ofType(Specimen).where(type.empty()).count() = 0" - # hasValidData(message_id) - - "Bundle.identifier.value.empty().not()" - # hasValidData(equipment_model_name, test_result) - - "Bundle.entry.resource.ofType(DiagnosticReport).result.resolve().where(method.empty() or value.coding.code.empty()).count() = 0" - routingFilter: [ ] - processingModeFilter: - # matches(processing_mode_code, P) - - "Bundle.entry.resource.ofType(MessageHeader).meta.tag.where(system = 'http://terminology.hl7.org/CodeSystem/v2-0103').code = 'P'" - reverseTheQualityFilter: false - deidentify: false - deidentifiedValue: "" - timing: - operation: "MERGE" - numberPerDay: 1440 - initialTime: "09:40" - timeZone: "EASTERN" - maxReportCount: 100 - whenEmpty: - action: "NONE" - onlyOncePerDay: false - description: "" - transport: ! - type: SFTP - host: sftp - port: 22 - filePath: ./upload - credentialName: DEFAULT-SFTP - conditionFilter: [ ] - mappedConditionFilter: [ ] - externalName: null - enrichmentSchemaNames: ["classpath:/metadata/fhir_transforms/common/suppress-device-information.yml" ] - timeZone: null - dateTimeFormat: "OFFSET" diff --git a/prime-router/settings/STLTs/NJ/nj-dph.yml b/prime-router/settings/STLTs/NJ/nj-dph.yml new file mode 100644 index 00000000000..5a7845a0f9a --- /dev/null +++ b/prime-router/settings/STLTs/NJ/nj-dph.yml @@ -0,0 +1,122 @@ +--- +- name: "nj-doh" + description: "New Jersey Department of Health" + jurisdiction: "STATE" + stateCode: "NJ" + countyName: null + filters: null + featureFlags: null + keys: null + senders: [] + receivers: + - name: "full-elr" + organizationName: "nj-doh" + topic: "full-elr" + customerStatus: "active" + translation: + schemaName: "azure:/hl7_mapping/receivers/STLTs/NJ/NJ-receiver-transform.yml" + useTestProcessingMode: false + useBatchHeaders: true + receivingApplicationName: "ELRS^2.16.840.1.113883.3.1299.5.1.6.1^ISO" + receivingApplicationOID: "2.16.840.1.113883.3.1299.5.1.6.1" + receivingFacilityName: "NJDOH^2.16.840.1.113883.3.1299^ISO" + receivingFacilityOID: "2.16.840.1.113883.3.1299" + messageProfileId: null + replaceValue: {} + replaceValueAwithB: {} + reportingFacilityName: null + reportingFacilityId: null + reportingFacilityIdType: null + suppressQstForAoe: false + suppressHl7Fields: null + suppressAoe: false + defaultAoeToUnknown: false + replaceUnicodeWithAscii: false + useBlankInsteadOfUnknown: null + truncateHDNamespaceIds: true + truncateHl7Fields: "OBX-23-1,ORC-12-3,OBR-16-3,OBX-17-1,ORC-12-1,OBR-16-1" + usePid14ForPatientEmail: false + convertTimestampToDateTime: null + cliaForOutOfStateTesting: null + cliaForSender: {} + phoneNumberFormatting: "STANDARD" + suppressNonNPI: false + processingModeCode: null + replaceDiiWithOid: null + applyOTCDefault: false + useOrderingFacilityName: "STANDARD" + valueSetOverrides: {} + nameFormat: "STANDARD" + receivingOrganization: null + convertPositiveDateTimeOffsetToNegative: false + stripInvalidCharsRegex: null + convertDateTimesToReceiverLocalTime: false + useHighPrecisionHeaderDateTimeFormat: false + type: "HL7" + truncationConfig: + truncateHDNamespaceIds: true + truncateHl7Fields: + - "OBR-16-1" + - "OBR-16-3" + - "OBX-17-1" + - "OBX-23-1" + - "ORC-12-1" + - "ORC-12-3" + customLengthHl7Fields: {} + jurisdictionalFilter: + - "(Bundle.entry.resource.ofType(ServiceRequest)[0].requester.resolve().organization.resolve().address.state.exists()\ + \ and Bundle.entry.resource.ofType(ServiceRequest)[0].requester.resolve().organization.resolve().address.state\ + \ = 'NJ') or (Bundle.entry.resource.ofType(Patient).address.state.exists() and\ + \ Bundle.entry.resource.ofType(Patient).address.state = 'NJ')" + qualityFilter: + - "Bundle.entry.resource.ofType(DiagnosticReport).result.resolve().where(method.empty()\ + \ or value.coding.code.empty()).count() = 0" + - "Bundle.entry.resource.ofType(DiagnosticReport).where(basedOn.resolve().extension('https://reportstream.cdc.gov/fhir/StructureDefinition/effective-date').empty()\ + \ and specimen.resolve().collection.collected.empty() and effective.empty()\ + \ and issued.empty() and result.resolve().effective.empty()).count() = 0" + - "Bundle.entry.resource.ofType(Organization).identifier.where(type.coding.code\ + \ = 'CLIA' or system = 'CLIA').where(value.getIdType() != 'CLIA').count() =\ + \ 0" + - "Bundle.entry.resource.ofType(Patient).where(address.line[0].empty() and address.postalCode.empty()\ + \ and telecom.where(system = 'phone').value.empty() and telecom.where(system\ + \ = 'email').value.empty()).count() = 0" + - "Bundle.entry.resource.ofType(Patient).where(name.family.empty() or name.given.empty()\ + \ or birthDate.empty()).count() = 0" + - "Bundle.entry.resource.ofType(Specimen).where(type.empty()).count() = 0" + - "Bundle.identifier.value.empty().not()" + routingFilter: + - "Bundle.entry.resource.ofType(MessageHeader).extension('https://reportstream.cdc.gov/fhir/StructureDefinition/sender-id').where(value\ + \ = 'carbon-health').exists()" + processingModeFilter: + - "Bundle.entry.resource.ofType(MessageHeader).meta.tag.where(system = 'http://terminology.hl7.org/CodeSystem/v2-0103').code\ + \ = 'P'" + reverseTheQualityFilter: false + conditionFilter: + - "(%resource.code.coding.extension('https://reportstream.cdc.gov/fhir/StructureDefinition/condition-code').value.where(code\ + \ in ('840539006'|'895448002'|'6142004'|'541131000124102')).exists())" + mappedConditionFilter: [] + deidentify: false + deidentifiedValue: "" + timing: + operation: "MERGE" + numberPerDay: 1440 + initialTime: "09:40" + timeZone: "EASTERN" + maxReportCount: 100 + whenEmpty: + action: "NONE" + onlyOncePerDay: false + description: "" + transport: + host: "njgov.moveitcloud.com" + port: "22" + filePath: "./TEST" + credentialName: null + type: "SFTP" + externalName: null + enrichmentSchemaNames: + - "azure:/fhir_transforms/common/handle-aoe-unknown-value/handle-aoe-unknown-value.yml" + - "classpath:/metadata/fhir_transforms/common/suppress-device-information.yml" + timeZone: null + dateTimeFormat: "OFFSET" + diff --git a/prime-router/src/main/resources/metadata/hl7_mapping/receivers/STLTs/NJ/NJ-receiver-transform.yml b/prime-router/src/main/resources/metadata/hl7_mapping/receivers/STLTs/NJ/NJ-receiver-transform.yml index 197d135adfb..a00b099ab06 100644 --- a/prime-router/src/main/resources/metadata/hl7_mapping/receivers/STLTs/NJ/NJ-receiver-transform.yml +++ b/prime-router/src/main/resources/metadata/hl7_mapping/receivers/STLTs/NJ/NJ-receiver-transform.yml @@ -56,4 +56,36 @@ elements: - name: nj-receiving-facility-universal-id-type value: [ '"ISO"' ] - hl7Spec: [ MSH-6-3 ] \ No newline at end of file + hl7Spec: [ MSH-6-3 ] + + # If the Ordering Provider information is unknown, + # complete with the Ordering Facility Information + # ORC 24.1 + - name: nj-ordering-provider-street1 + condition: 'Bundle.entry.resource.ofType(Practitioner).address.line.exists().not()' + value: ['Bundle.entry.resource.ofType(Organization).address.line[0]'] + hl7Spec: [/PATIENT_RESULT/ORDER_OBSERVATION/ORC-24-1] + + # ORC 24.2 + - name: nj-ordering-provider-street2 + condition: 'Bundle.entry.resource.ofType(Practitioner).address.line.exists().not() and Bundle.entry.resource.ofType(Organization).address.line[1].exists()' + value: ['Bundle.entry.resource.ofType(Organization).address.line[1]'] + hl7Spec: [/PATIENT_RESULT/ORDER_OBSERVATION/ORC-24-2] + + # ORC 24.3 + - name: nj-ordering-provider-city + condition: 'Bundle.entry.resource.ofType(Practitioner).address.city.exists().not()' + value: ['Bundle.entry.resource.ofType(Organization).address.city'] + hl7Spec: [/PATIENT_RESULT/ORDER_OBSERVATION/ORC-24-3] + + # ORC 24.4 + - name: nj-ordering-provider-state + condition: 'Bundle.entry.resource.ofType(Practitioner).address.state.exists().not()' + value: ['Bundle.entry.resource.ofType(Organization).address.state'] + hl7Spec: [/PATIENT_RESULT/ORDER_OBSERVATION/ORC-24-4] + + # ORC 24.5 + - name: nj-ordering-provider-zip + condition: 'Bundle.entry.resource.ofType(Practitioner).address.postalCode.exists().not()' + value: ['Bundle.entry.resource.ofType(Organization).address.postalCode'] + hl7Spec: [/PATIENT_RESULT/ORDER_OBSERVATION/ORC-24-5] \ No newline at end of file