fhir-data-utils-ts 0.6.13 → 0.6.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -2,6 +2,27 @@
2
2
 
3
3
  ## Unreleased
4
4
 
5
+ ## 0.6.17 - 2026-10-08
6
+
7
+ - Add the preferred HL7 Observation category catalogue for shared clinical
8
+ editors. English and Spanish labels retain a compact `HL7|code` suffix while
9
+ the stored option remains the complete canonical `system|code` token.
10
+
11
+ ## 0.6.16 - 2026-10-07
12
+
13
+ - Export the required FHIR R4 code bindings used by reusable IPS authoring
14
+ forms, keyed by their exact flat claim. The canonical code is stable while
15
+ English and Spanish presentation labels follow the user's locale. Fields
16
+ with extensible or example bindings remain terminology searches instead of
17
+ being incorrectly constrained to a closed dropdown.
18
+
19
+ ## 0.6.14 - 2026-10-06
20
+
21
+ - Own the product-neutral HL7 v2-0203 person and healthcare identifier-type
22
+ catalog used by FHIR adapters, including national, passport, driving licence,
23
+ health, insurance-member/subscriber, donor and patient identifiers. Contact
24
+ points and veterinary evidence remain in their respective standards.
25
+
5
26
  - Add a reusable, data-only `CommunicationRequest` form schema backed by
6
27
  canonical flat claims, including exact Patient, RelatedPerson or Group
7
28
  recipients, information providers, Encounter context and referenced or
@@ -0,0 +1,26 @@
1
+ export type FhirClinicalCodedOption = Readonly<{
2
+ code: string;
3
+ labels: Readonly<{
4
+ en: string;
5
+ es: string;
6
+ }>;
7
+ }>;
8
+ export type FhirClinicalCodedOptionSet = Readonly<{
9
+ fhirVersion: 'R4';
10
+ binding: 'required' | 'preferred';
11
+ system: string;
12
+ options: readonly FhirClinicalCodedOption[];
13
+ }>;
14
+ /**
15
+ * Required FHIR R4 code bindings used by the reusable IPS artifact editor.
16
+ *
17
+ * Extensible and example bindings deliberately stay out of this catalog: they
18
+ * require terminology search or free entry and must not be rendered as closed
19
+ * dropdowns.
20
+ */
21
+ export declare const FHIR_IPS_CLINICAL_CODED_OPTION_SETS: Readonly<Record<string, FhirClinicalCodedOptionSet>>;
22
+ /** Returns localized labels while preserving the exact canonical code value. */
23
+ export declare function clinicalArtifactCodedOptionsForClaim(claim: string, locale: string): readonly Readonly<{
24
+ code: string;
25
+ label: string;
26
+ }>[];
@@ -0,0 +1,50 @@
1
+ // Copyright 2026 Connecting Solution & Applications Ltd under the Apache License, Version 2.0.
2
+ import { AllergyIntoleranceClaim } from './claims/allergy-intolerance-claims.js';
3
+ import { ConditionClaim } from './claims/condition-claims.js';
4
+ import { ImmunizationClaim } from './claims/immunization-claims.js';
5
+ import { MedicationStatementClaim } from './claims/medication-statement-claims.js';
6
+ import { ProcedureClaim } from './claims/procedure-claims.js';
7
+ import { ObservationCategoryCodes, ObservationClaim } from './observation-claims.js';
8
+ const option = (code, en, es) => Object.freeze({ code, labels: Object.freeze({ en, es }) });
9
+ const requiredSet = (system, options) => Object.freeze({ fhirVersion: 'R4', binding: 'required', system, options: Object.freeze(options) });
10
+ const preferredSet = (system, options) => Object.freeze({ fhirVersion: 'R4', binding: 'preferred', system, options: Object.freeze(options) });
11
+ const enteredInError = option('entered-in-error', 'Entered in error', 'Introducido por error');
12
+ const unknown = option('unknown', 'Unknown', 'Desconocido');
13
+ /**
14
+ * Required FHIR R4 code bindings used by the reusable IPS artifact editor.
15
+ *
16
+ * Extensible and example bindings deliberately stay out of this catalog: they
17
+ * require terminology search or free entry and must not be rendered as closed
18
+ * dropdowns.
19
+ */
20
+ export const FHIR_IPS_CLINICAL_CODED_OPTION_SETS = Object.freeze({
21
+ [AllergyIntoleranceClaim.ClinicalStatus]: requiredSet('http://terminology.hl7.org/CodeSystem/allergyintolerance-clinical', [option('active', 'Active', 'Activo'), option('inactive', 'Inactive', 'Inactivo'), option('resolved', 'Resolved', 'Resuelto')]),
22
+ [AllergyIntoleranceClaim.VerificationStatus]: requiredSet('http://terminology.hl7.org/CodeSystem/allergyintolerance-verification', [option('unconfirmed', 'Unconfirmed', 'No confirmado'), option('confirmed', 'Confirmed', 'Confirmado'), option('refuted', 'Refuted', 'Refutado'), enteredInError]),
23
+ [AllergyIntoleranceClaim.Category]: requiredSet('http://hl7.org/fhir/allergy-intolerance-category', [option('food', 'Food', 'Alimento'), option('medication', 'Medication', 'Medicamento'), option('environment', 'Environment', 'Entorno'), option('biologic', 'Biologic', 'Biológico')]),
24
+ [AllergyIntoleranceClaim.Criticality]: requiredSet('http://hl7.org/fhir/allergy-intolerance-criticality', [option('low', 'Low risk', 'Riesgo bajo'), option('high', 'High risk', 'Riesgo alto'), option('unable-to-assess', 'Unable to assess', 'No se puede evaluar')]),
25
+ [MedicationStatementClaim.Status]: requiredSet('http://hl7.org/fhir/CodeSystem/medication-statement-status', [option('active', 'Active', 'Activo'), option('completed', 'Completed', 'Completado'), enteredInError, option('intended', 'Intended', 'Previsto'), option('stopped', 'Stopped', 'Interrumpido'), option('on-hold', 'On hold', 'En espera'), unknown, option('not-taken', 'Not taken', 'No tomado')]),
26
+ [ImmunizationClaim.Status]: requiredSet('http://hl7.org/fhir/event-status', [option('completed', 'Completed', 'Completado'), enteredInError, option('not-done', 'Not done', 'No realizado')]),
27
+ [ConditionClaim.ClinicalStatus]: requiredSet('http://terminology.hl7.org/CodeSystem/condition-clinical', [option('active', 'Active', 'Activo'), option('recurrence', 'Recurrence', 'Recurrencia'), option('relapse', 'Relapse', 'Recaída'), option('inactive', 'Inactive', 'Inactivo'), option('remission', 'Remission', 'Remisión'), option('resolved', 'Resolved', 'Resuelto')]),
28
+ [ConditionClaim.VerificationStatus]: requiredSet('http://terminology.hl7.org/CodeSystem/condition-ver-status', [option('unconfirmed', 'Unconfirmed', 'No confirmado'), option('provisional', 'Provisional', 'Provisional'), option('differential', 'Differential', 'Diferencial'), option('confirmed', 'Confirmed', 'Confirmado'), option('refuted', 'Refuted', 'Refutado'), enteredInError]),
29
+ [ProcedureClaim.Status]: requiredSet('http://hl7.org/fhir/event-status', [option('preparation', 'Preparation', 'Preparación'), option('in-progress', 'In progress', 'En curso'), option('not-done', 'Not done', 'No realizado'), option('on-hold', 'On hold', 'En espera'), option('stopped', 'Stopped', 'Detenido'), option('completed', 'Completed', 'Completado'), enteredInError, unknown]),
30
+ [ObservationClaim.Status]: requiredSet('http://hl7.org/fhir/observation-status', [option('registered', 'Registered', 'Registrado'), option('preliminary', 'Preliminary', 'Preliminar'), option('final', 'Final', 'Final'), option('amended', 'Amended', 'Modificado'), option('corrected', 'Corrected', 'Corregido'), option('cancelled', 'Cancelled', 'Cancelado'), enteredInError, unknown]),
31
+ [ObservationClaim.Category]: preferredSet(ObservationCategoryCodes.VitalSigns.system, [
32
+ option(ObservationCategoryCodes.SocialHistory.claim, 'Social history (HL7|social-history)', 'Historia social (HL7|social-history)'),
33
+ option(ObservationCategoryCodes.VitalSigns.claim, 'Vital signs (HL7|vital-signs)', 'Signos vitales (HL7|vital-signs)'),
34
+ option(ObservationCategoryCodes.Imaging.claim, 'Imaging (HL7|imaging)', 'Diagnóstico por imagen (HL7|imaging)'),
35
+ option(ObservationCategoryCodes.Laboratory.claim, 'Laboratory (HL7|laboratory)', 'Laboratorio (HL7|laboratory)'),
36
+ option(ObservationCategoryCodes.Procedure.claim, 'Procedure (HL7|procedure)', 'Procedimiento (HL7|procedure)'),
37
+ option(ObservationCategoryCodes.Survey.claim, 'Survey (HL7|survey)', 'Cuestionario (HL7|survey)'),
38
+ option(ObservationCategoryCodes.Exam.claim, 'Exam (HL7|exam)', 'Exploración (HL7|exam)'),
39
+ option(ObservationCategoryCodes.Therapy.claim, 'Therapy (HL7|therapy)', 'Terapia (HL7|therapy)'),
40
+ option(ObservationCategoryCodes.Activity.claim, 'Activity (HL7|activity)', 'Actividad (HL7|activity)'),
41
+ ]),
42
+ });
43
+ /** Returns localized labels while preserving the exact canonical code value. */
44
+ export function clinicalArtifactCodedOptionsForClaim(claim, locale) {
45
+ const set = FHIR_IPS_CLINICAL_CODED_OPTION_SETS[claim];
46
+ if (!set)
47
+ return Object.freeze([]);
48
+ const language = locale.trim().toLowerCase().split('-')[0] === 'es' ? 'es' : 'en';
49
+ return Object.freeze(set.options.map(entry => Object.freeze({ code: entry.code, label: entry.labels[language] })));
50
+ }
@@ -67,7 +67,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
67
67
  display: string;
68
68
  }[];
69
69
  };
70
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
70
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
71
71
  id: string;
72
72
  status: string;
73
73
  subject: {
@@ -84,7 +84,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
84
84
  }[];
85
85
  };
86
86
  effectiveDateTime: string;
87
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
87
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
88
88
  id: string;
89
89
  subject: {
90
90
  reference: string;
@@ -103,7 +103,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
103
103
  }[];
104
104
  };
105
105
  occurrenceDateTime: string;
106
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
106
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
107
107
  id: string;
108
108
  subject: {
109
109
  reference: string;
@@ -119,7 +119,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
119
119
  }[];
120
120
  };
121
121
  effectiveDateTime: string;
122
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
122
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
123
123
  id: string;
124
124
  subject: {
125
125
  reference: string;
@@ -135,7 +135,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
135
135
  }[];
136
136
  };
137
137
  performedDateTime: string;
138
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
138
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
139
139
  id: string;
140
140
  subject: {
141
141
  reference: string;
@@ -145,7 +145,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
145
145
  device: {
146
146
  display: "Corrective lens use";
147
147
  };
148
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
148
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
149
149
  id: string;
150
150
  subject: {
151
151
  reference: string;
@@ -166,7 +166,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
166
166
  system: string;
167
167
  code: string;
168
168
  };
169
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
169
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
170
170
  id: string;
171
171
  status: string;
172
172
  subject: {
@@ -190,7 +190,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
190
190
  display: string;
191
191
  }[];
192
192
  };
193
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
193
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
194
194
  id: string;
195
195
  status: string;
196
196
  subject: {
@@ -206,7 +206,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
206
206
  display: string;
207
207
  }[];
208
208
  };
209
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
209
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
210
210
  id: string;
211
211
  subject: {
212
212
  reference: string;
@@ -221,7 +221,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
221
221
  display: string;
222
222
  }[];
223
223
  };
224
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
224
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
225
225
  id: string;
226
226
  status: string;
227
227
  subject: {
@@ -248,7 +248,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
248
248
  patient: {
249
249
  reference: string;
250
250
  };
251
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
251
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
252
252
  id: string;
253
253
  subject: {
254
254
  reference: string;
@@ -257,7 +257,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
257
257
  status: string;
258
258
  description: "Independent daily activities";
259
259
  summary: "Independent daily activities";
260
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
260
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
261
261
  id: string;
262
262
  subject: {
263
263
  reference: string;
@@ -274,7 +274,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
274
274
  display: string;
275
275
  }[];
276
276
  }[];
277
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
277
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
278
278
  id: string;
279
279
  subject: {
280
280
  reference: string;
@@ -291,7 +291,7 @@ export declare const FHIR_IPS_ALL_SECTIONS_DEMO_DATA: Readonly<{
291
291
  display: string;
292
292
  }[];
293
293
  };
294
- resourceType: "Condition" | "Goal" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation" | "Procedure";
294
+ resourceType: "Condition" | "Goal" | "Procedure" | "AllergyIntolerance" | "CarePlan" | "ClinicalImpression" | "Consent" | "DeviceUseStatement" | "DiagnosticReport" | "Flag" | "Immunization" | "MedicationStatement" | "Observation";
295
295
  id: string;
296
296
  status: string;
297
297
  subject: {
@@ -0,0 +1,40 @@
1
+ /** Canonical HL7 v2-0203 CodeSystem used by FHIR Identifier.type coding. */
2
+ export declare const HL7_V2_0203_IDENTIFIER_TYPE_SYSTEM: "http://terminology.hl7.org/CodeSystem/v2-0203";
3
+ /** Published FHIR value set that selects commonly used Identifier.type codes. */
4
+ export declare const FHIR_IDENTIFIER_TYPE_VALUE_SET_URL: "https://hl7.org/fhir/valueset-identifier-type.html";
5
+ /** Normative registries used to validate the shared catalog. */
6
+ export declare const HL7_IDENTIFIER_REGISTRY_SOURCES: Readonly<{
7
+ CodeSystem: "http://terminology.hl7.org/CodeSystem/v2-0203";
8
+ FhirIdentifierTypeValueSet: "https://hl7.org/fhir/valueset-identifier-type.html";
9
+ Hl7TerminologySource: "https://terminology.hl7.org/6.5.0/CodeSystem-v2-0203.html";
10
+ }>;
11
+ /**
12
+ * Product-neutral person and healthcare identifier codes used by the shared
13
+ * FHIR adapters. Contact points and veterinary identifiers belong to their
14
+ * own standards and are deliberately absent.
15
+ */
16
+ export declare const HL7_V2_0203_IDENTIFIER_CODES: Readonly<{
17
+ readonly DriverLicense: "DL";
18
+ readonly CitizenshipCard: "CZ";
19
+ readonly NationalNumber: "NN";
20
+ readonly PassportNumber: "PPN";
21
+ readonly JurisdictionalHealthNumber: "JHN";
22
+ readonly PermanentResidentCard: "PRC";
23
+ readonly WorkPermit: "WP";
24
+ readonly StudyPermit: "SP";
25
+ readonly Visa: "VS";
26
+ readonly VisitorPermit: "VP";
27
+ readonly TemporaryPermanentResident: "TPR";
28
+ readonly HealthCard: "HC";
29
+ readonly MemberNumber: "MB";
30
+ readonly SubscriberNumber: "SN";
31
+ readonly DonorRecord: "DR";
32
+ readonly PatientIdentifier: "PI";
33
+ }>;
34
+ export type Hl7V20203IdentifierCode = typeof HL7_V2_0203_IDENTIFIER_CODES[keyof typeof HL7_V2_0203_IDENTIFIER_CODES];
35
+ /** Product-neutral organization identifier codes from the same CodeSystem. */
36
+ export declare const HL7_V2_0203_ORGANIZATION_IDENTIFIER_CODES: Readonly<{
37
+ readonly TaxIdentifier: "TAX";
38
+ readonly EmployerNumber: "EN";
39
+ }>;
40
+ export type Hl7V20203OrganizationIdentifierCode = typeof HL7_V2_0203_ORGANIZATION_IDENTIFIER_CODES[keyof typeof HL7_V2_0203_ORGANIZATION_IDENTIFIER_CODES];
@@ -0,0 +1,38 @@
1
+ /** Canonical HL7 v2-0203 CodeSystem used by FHIR Identifier.type coding. */
2
+ export const HL7_V2_0203_IDENTIFIER_TYPE_SYSTEM = 'http://terminology.hl7.org/CodeSystem/v2-0203';
3
+ /** Published FHIR value set that selects commonly used Identifier.type codes. */
4
+ export const FHIR_IDENTIFIER_TYPE_VALUE_SET_URL = 'https://hl7.org/fhir/valueset-identifier-type.html';
5
+ /** Normative registries used to validate the shared catalog. */
6
+ export const HL7_IDENTIFIER_REGISTRY_SOURCES = Object.freeze({
7
+ CodeSystem: HL7_V2_0203_IDENTIFIER_TYPE_SYSTEM,
8
+ FhirIdentifierTypeValueSet: FHIR_IDENTIFIER_TYPE_VALUE_SET_URL,
9
+ Hl7TerminologySource: 'https://terminology.hl7.org/6.5.0/CodeSystem-v2-0203.html',
10
+ });
11
+ /**
12
+ * Product-neutral person and healthcare identifier codes used by the shared
13
+ * FHIR adapters. Contact points and veterinary identifiers belong to their
14
+ * own standards and are deliberately absent.
15
+ */
16
+ export const HL7_V2_0203_IDENTIFIER_CODES = Object.freeze({
17
+ DriverLicense: 'DL',
18
+ CitizenshipCard: 'CZ',
19
+ NationalNumber: 'NN',
20
+ PassportNumber: 'PPN',
21
+ JurisdictionalHealthNumber: 'JHN',
22
+ PermanentResidentCard: 'PRC',
23
+ WorkPermit: 'WP',
24
+ StudyPermit: 'SP',
25
+ Visa: 'VS',
26
+ VisitorPermit: 'VP',
27
+ TemporaryPermanentResident: 'TPR',
28
+ HealthCard: 'HC',
29
+ MemberNumber: 'MB',
30
+ SubscriberNumber: 'SN',
31
+ DonorRecord: 'DR',
32
+ PatientIdentifier: 'PI',
33
+ });
34
+ /** Product-neutral organization identifier codes from the same CodeSystem. */
35
+ export const HL7_V2_0203_ORGANIZATION_IDENTIFIER_CODES = Object.freeze({
36
+ TaxIdentifier: 'TAX',
37
+ EmployerNumber: 'EN',
38
+ });
package/dist/index.d.ts CHANGED
@@ -29,3 +29,5 @@ export * from './fhir-instant.js';
29
29
  export * from './health-credential-qr.js';
30
30
  export * from './fhir-temporal-presentation.js';
31
31
  export * from './clinical-artifact-editor.js';
32
+ export * from './clinical-artifact-coded-options.js';
33
+ export * from './hl7-v2-0203-identifier-types.js';
package/dist/index.js CHANGED
@@ -29,3 +29,5 @@ export * from './fhir-instant.js';
29
29
  export * from './health-credential-qr.js';
30
30
  export * from './fhir-temporal-presentation.js';
31
31
  export * from './clinical-artifact-editor.js';
32
+ export * from './clinical-artifact-coded-options.js';
33
+ export * from './hl7-v2-0203-identifier-types.js';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "fhir-data-utils-ts",
3
- "version": "0.6.13",
3
+ "version": "0.6.17",
4
4
  "description": "FHIR-version-neutral flat-claim and SearchParameter data utilities",
5
5
  "license": "Apache-2.0",
6
6
  "type": "module",
@@ -55,6 +55,10 @@
55
55
  "types": "./dist/fhir-values.d.ts",
56
56
  "default": "./dist/fhir-values.js"
57
57
  },
58
+ "./hl7-v2-0203-identifier-types": {
59
+ "types": "./dist/hl7-v2-0203-identifier-types.d.ts",
60
+ "default": "./dist/hl7-v2-0203-identifier-types.js"
61
+ },
58
62
  "./fhir-search-parameters": {
59
63
  "types": "./dist/fhir-search-parameters.d.ts",
60
64
  "default": "./dist/fhir-search-parameters.js"
@@ -83,6 +87,10 @@
83
87
  "types": "./dist/clinical-terminology.d.ts",
84
88
  "default": "./dist/clinical-terminology.js"
85
89
  },
90
+ "./clinical-artifact-coded-options": {
91
+ "types": "./dist/clinical-artifact-coded-options.d.ts",
92
+ "default": "./dist/clinical-artifact-coded-options.js"
93
+ },
86
94
  "./immunization-flat-claims": {
87
95
  "types": "./dist/immunization-flat-claims.d.ts",
88
96
  "default": "./dist/immunization-flat-claims.js"