@metriport/shared 0.33.7 → 0.34.1-alpha.0

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.
Files changed (95) hide show
  1. package/dist/common/__tests__/object.test.d.ts +2 -0
  2. package/dist/common/__tests__/object.test.d.ts.map +1 -0
  3. package/dist/common/__tests__/object.test.js +55 -0
  4. package/dist/common/__tests__/object.test.js.map +1 -0
  5. package/dist/common/__tests__/purpose-of-use.test.d.ts +2 -0
  6. package/dist/common/__tests__/purpose-of-use.test.d.ts.map +1 -0
  7. package/dist/common/__tests__/purpose-of-use.test.js +24 -0
  8. package/dist/common/__tests__/purpose-of-use.test.js.map +1 -0
  9. package/dist/common/__tests__/string.test.js +71 -0
  10. package/dist/common/__tests__/string.test.js.map +1 -1
  11. package/dist/common/object.d.ts +15 -0
  12. package/dist/common/object.d.ts.map +1 -0
  13. package/dist/common/object.js +50 -0
  14. package/dist/common/object.js.map +1 -0
  15. package/dist/common/purpose-of-use.d.ts +16 -1
  16. package/dist/common/purpose-of-use.d.ts.map +1 -1
  17. package/dist/common/purpose-of-use.js +25 -2
  18. package/dist/common/purpose-of-use.js.map +1 -1
  19. package/dist/common/string.d.ts +26 -0
  20. package/dist/common/string.d.ts.map +1 -1
  21. package/dist/common/string.js +39 -0
  22. package/dist/common/string.js.map +1 -1
  23. package/dist/domain/cohort.d.ts +9 -1
  24. package/dist/domain/cohort.d.ts.map +1 -1
  25. package/dist/domain/cohort.js +16 -2
  26. package/dist/domain/cohort.js.map +1 -1
  27. package/dist/domain/patient/patient-settings.d.ts +19 -120
  28. package/dist/domain/patient/patient-settings.d.ts.map +1 -1
  29. package/dist/domain/patient/patient-settings.js +7 -24
  30. package/dist/domain/patient/patient-settings.js.map +1 -1
  31. package/dist/domain/patient/patient-status.d.ts +4 -12
  32. package/dist/domain/patient/patient-status.d.ts.map +1 -1
  33. package/dist/domain/patient/patient-status.js +0 -6
  34. package/dist/domain/patient/patient-status.js.map +1 -1
  35. package/dist/external/hl7v2/constants.d.ts +2 -0
  36. package/dist/external/hl7v2/constants.d.ts.map +1 -1
  37. package/dist/external/hl7v2/constants.js +15 -2
  38. package/dist/external/hl7v2/constants.js.map +1 -1
  39. package/dist/index.d.ts +2 -1
  40. package/dist/index.d.ts.map +1 -1
  41. package/dist/index.js +4 -1
  42. package/dist/index.js.map +1 -1
  43. package/dist/interface/internal/cohort.d.ts +16 -0
  44. package/dist/interface/internal/cohort.d.ts.map +1 -1
  45. package/dist/interface/internal/cohort.js +1 -0
  46. package/dist/interface/internal/cohort.js.map +1 -1
  47. package/dist/interface/internal/consolidated.d.ts +37 -0
  48. package/dist/interface/internal/consolidated.d.ts.map +1 -1
  49. package/dist/interface/internal/consolidated.js +7 -1
  50. package/dist/interface/internal/consolidated.js.map +1 -1
  51. package/dist/interface/internal/index.d.ts +2 -0
  52. package/dist/interface/internal/index.d.ts.map +1 -1
  53. package/dist/interface/internal/index.js +2 -0
  54. package/dist/interface/internal/index.js.map +1 -1
  55. package/dist/interface/internal/patient-settings.d.ts +108 -0
  56. package/dist/interface/internal/patient-settings.d.ts.map +1 -0
  57. package/dist/interface/internal/patient-settings.js +19 -0
  58. package/dist/interface/internal/patient-settings.js.map +1 -0
  59. package/dist/interface/internal/patient-status.d.ts +12 -0
  60. package/dist/interface/internal/patient-status.d.ts.map +1 -0
  61. package/dist/interface/internal/patient-status.js +9 -0
  62. package/dist/interface/internal/patient-status.js.map +1 -0
  63. package/dist/medical/fhir/__tests__/primitive-types.test.d.ts +2 -0
  64. package/dist/medical/fhir/__tests__/primitive-types.test.d.ts.map +1 -0
  65. package/dist/medical/fhir/__tests__/primitive-types.test.js +56 -0
  66. package/dist/medical/fhir/__tests__/primitive-types.test.js.map +1 -0
  67. package/dist/medical/fhir/coding.d.ts +1 -0
  68. package/dist/medical/fhir/coding.d.ts.map +1 -1
  69. package/dist/medical/fhir/coding.js +8 -0
  70. package/dist/medical/fhir/coding.js.map +1 -1
  71. package/dist/medical/fhir/primitive-types.d.ts +18 -0
  72. package/dist/medical/fhir/primitive-types.d.ts.map +1 -0
  73. package/dist/medical/fhir/primitive-types.js +31 -0
  74. package/dist/medical/fhir/primitive-types.js.map +1 -0
  75. package/dist/medical/index.d.ts +1 -0
  76. package/dist/medical/index.d.ts.map +1 -1
  77. package/dist/medical/index.js +1 -0
  78. package/dist/medical/index.js.map +1 -1
  79. package/dist/util/sqs-delay-from-uuid.d.ts +11 -0
  80. package/dist/util/sqs-delay-from-uuid.d.ts.map +1 -0
  81. package/dist/util/sqs-delay-from-uuid.js +21 -0
  82. package/dist/util/sqs-delay-from-uuid.js.map +1 -0
  83. package/package.json +3 -5
  84. package/dist/domain/__tests__/cohort-purpose-of-use-hies.test.d.ts +0 -2
  85. package/dist/domain/__tests__/cohort-purpose-of-use-hies.test.d.ts.map +0 -1
  86. package/dist/domain/__tests__/cohort-purpose-of-use-hies.test.js +0 -10
  87. package/dist/domain/__tests__/cohort-purpose-of-use-hies.test.js.map +0 -1
  88. package/dist/domain/__tests__/cohort-response-dto.test.d.ts +0 -2
  89. package/dist/domain/__tests__/cohort-response-dto.test.d.ts.map +0 -1
  90. package/dist/domain/__tests__/cohort-response-dto.test.js +0 -59
  91. package/dist/domain/__tests__/cohort-response-dto.test.js.map +0 -1
  92. package/dist/domain/cohort-purpose-of-use-hies.d.ts +0 -3
  93. package/dist/domain/cohort-purpose-of-use-hies.d.ts.map +0 -1
  94. package/dist/domain/cohort-purpose-of-use-hies.js +0 -11
  95. package/dist/domain/cohort-purpose-of-use-hies.js.map +0 -1
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.internalSendConsolidatedSchema = exports.documentQueryProgressInternalSnapshotSchema = void 0;
3
+ exports.internalSendConsolidatedSchema = exports.consolidatedS3KeysSchema = exports.documentQueryProgressInternalSnapshotSchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const medical_1 = require("../../medical");
6
6
  const documentQueryStatusSchema = zod_1.z.enum(["processing", "completed", "failed"]);
@@ -20,6 +20,11 @@ exports.documentQueryProgressInternalSnapshotSchema = zod_1.z
20
20
  forceDownload: zod_1.z.boolean().optional(),
21
21
  })
22
22
  .passthrough();
23
+ exports.consolidatedS3KeysSchema = zod_1.z.object({
24
+ jsonKey: zod_1.z.string(),
25
+ gzipKey: zod_1.z.string(),
26
+ resourceCount: zod_1.z.number().nonnegative(),
27
+ });
23
28
  exports.internalSendConsolidatedSchema = zod_1.z.object({
24
29
  bundleLocation: zod_1.z.string().optional(),
25
30
  bundleFilename: zod_1.z.string().optional(),
@@ -33,5 +38,6 @@ exports.internalSendConsolidatedSchema = zod_1.z.object({
33
38
  isConsolidatedQuery: zod_1.z.boolean().optional(),
34
39
  truncatedGzipKey: zod_1.z.string().optional(),
35
40
  fastLoadGzipKey: zod_1.z.string().optional(),
41
+ s3Keys: exports.consolidatedS3KeysSchema.optional(),
36
42
  });
37
43
  //# sourceMappingURL=consolidated.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"consolidated.js","sourceRoot":"","sources":["../../../src/interface/internal/consolidated.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AACxB,2CAA0F;AAE1F,MAAM,yBAAyB,GAAG,OAAC,CAAC,IAAI,CAAC,CAAC,YAAY,EAAE,WAAW,EAAE,QAAQ,CAAC,CAAC,CAAC;AAEhF,MAAM,mBAAmB,GAAG,OAAC,CAAC,MAAM,CAAC;IACnC,MAAM,EAAE,yBAAyB;IACjC,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC5B,UAAU,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACjC,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC7B,WAAW,EAAE,OAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;CACpC,CAAC,CAAC;AAEU,QAAA,2CAA2C,GAAG,OAAC;KACzD,MAAM,C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;IACrC,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE;IACrB,cAAc,EAAE,OAAC,CAAC,IAAI,CAAC,qCAA2B,CAAC;IACnD,SAAS,EAAE,OAAC,CAAC,KAAK,CAAC,OAAC,CAAC,IAAI,CAAC,sCAA4B,CAAC,CAAC,CAAC,QAAQ,EAAE;IACnE,QAAQ,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC/B,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC7B,aAAa,EAAE,OAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;IACrC,qBAAqB,EAAE,QAAA,2CAA2C,CAAC,QAAQ,EAAE;IAC7E,mBAAmB,EAAE,OAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;IAC3C,gBAAgB,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACvC,eAAe,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACtC,MAAM,EAAE,QAAA,wBAAwB,CAAC,QAAQ,EAAE;CAC5C,CAAC,CAAC"}
@@ -2,4 +2,6 @@ export * from "./consolidated";
2
2
  export * from "./cohort";
3
3
  export * from "./customer";
4
4
  export * from "./document-query";
5
+ export * from "./patient-settings";
6
+ export * from "./patient-status";
5
7
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/interface/internal/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/interface/internal/index.ts"],"names":[],"mappings":"AAAA,cAAc,gBAAgB,CAAC;AAC/B,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,cAAc,kBAAkB,CAAC;AACjC,cAAc,oBAAoB,CAAC;AACnC,cAAc,kBAAkB,CAAC"}
@@ -18,4 +18,6 @@ __exportStar(require("./consolidated"), exports);
18
18
  __exportStar(require("./cohort"), exports);
19
19
  __exportStar(require("./customer"), exports);
20
20
  __exportStar(require("./document-query"), exports);
21
+ __exportStar(require("./patient-settings"), exports);
22
+ __exportStar(require("./patient-status"), exports);
21
23
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/interface/internal/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,iDAA+B;AAC/B,2CAAyB;AACzB,6CAA2B;AAC3B,mDAAiC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/interface/internal/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,iDAA+B;AAC/B,2CAAyB;AACzB,6CAA2B;AAC3B,mDAAiC;AACjC,qDAAmC;AACnC,mDAAiC"}
@@ -0,0 +1,108 @@
1
+ import { z } from "zod";
2
+ declare const subscriptionsSchema: z.ZodObject<{
3
+ adt: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
4
+ }, "strip", z.ZodTypeAny, {
5
+ adt?: string[] | undefined;
6
+ }, {
7
+ adt?: string[] | undefined;
8
+ }>;
9
+ export type PatientSubscriptions = z.infer<typeof subscriptionsSchema>;
10
+ export declare const patientSettingsSchema: z.ZodObject<{
11
+ subscriptions: z.ZodOptional<z.ZodObject<{
12
+ adt: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
13
+ }, "strip", z.ZodTypeAny, {
14
+ adt?: string[] | undefined;
15
+ }, {
16
+ adt?: string[] | undefined;
17
+ }>>;
18
+ treatmentRelationship: z.ZodOptional<z.ZodBoolean>;
19
+ }, "strip", z.ZodTypeAny, {
20
+ subscriptions?: {
21
+ adt?: string[] | undefined;
22
+ } | undefined;
23
+ treatmentRelationship?: boolean | undefined;
24
+ }, {
25
+ subscriptions?: {
26
+ adt?: string[] | undefined;
27
+ } | undefined;
28
+ treatmentRelationship?: boolean | undefined;
29
+ }>;
30
+ export declare const bulkPatientSettingsRequestSchema: z.ZodObject<{
31
+ settings: z.ZodObject<{
32
+ subscriptions: z.ZodOptional<z.ZodObject<{
33
+ adt: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
34
+ }, "strip", z.ZodTypeAny, {
35
+ adt?: string[] | undefined;
36
+ }, {
37
+ adt?: string[] | undefined;
38
+ }>>;
39
+ treatmentRelationship: z.ZodOptional<z.ZodBoolean>;
40
+ }, "strip", z.ZodTypeAny, {
41
+ subscriptions?: {
42
+ adt?: string[] | undefined;
43
+ } | undefined;
44
+ treatmentRelationship?: boolean | undefined;
45
+ }, {
46
+ subscriptions?: {
47
+ adt?: string[] | undefined;
48
+ } | undefined;
49
+ treatmentRelationship?: boolean | undefined;
50
+ }>;
51
+ }, "strip", z.ZodTypeAny, {
52
+ settings: {
53
+ subscriptions?: {
54
+ adt?: string[] | undefined;
55
+ } | undefined;
56
+ treatmentRelationship?: boolean | undefined;
57
+ };
58
+ }, {
59
+ settings: {
60
+ subscriptions?: {
61
+ adt?: string[] | undefined;
62
+ } | undefined;
63
+ treatmentRelationship?: boolean | undefined;
64
+ };
65
+ }>;
66
+ export type BulkPatientSettingsRequest = z.infer<typeof bulkPatientSettingsRequestSchema>;
67
+ export declare const patientSettingsRequestSchema: z.ZodObject<{
68
+ patientIds: z.ZodArray<z.ZodString, "many">;
69
+ settings: z.ZodObject<{
70
+ subscriptions: z.ZodOptional<z.ZodObject<{
71
+ adt: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
72
+ }, "strip", z.ZodTypeAny, {
73
+ adt?: string[] | undefined;
74
+ }, {
75
+ adt?: string[] | undefined;
76
+ }>>;
77
+ treatmentRelationship: z.ZodOptional<z.ZodBoolean>;
78
+ }, "strip", z.ZodTypeAny, {
79
+ subscriptions?: {
80
+ adt?: string[] | undefined;
81
+ } | undefined;
82
+ treatmentRelationship?: boolean | undefined;
83
+ }, {
84
+ subscriptions?: {
85
+ adt?: string[] | undefined;
86
+ } | undefined;
87
+ treatmentRelationship?: boolean | undefined;
88
+ }>;
89
+ }, "strip", z.ZodTypeAny, {
90
+ patientIds: string[];
91
+ settings: {
92
+ subscriptions?: {
93
+ adt?: string[] | undefined;
94
+ } | undefined;
95
+ treatmentRelationship?: boolean | undefined;
96
+ };
97
+ }, {
98
+ patientIds: string[];
99
+ settings: {
100
+ subscriptions?: {
101
+ adt?: string[] | undefined;
102
+ } | undefined;
103
+ treatmentRelationship?: boolean | undefined;
104
+ };
105
+ }>;
106
+ export type PatientSettingsRequest = z.infer<typeof patientSettingsRequestSchema>;
107
+ export {};
108
+ //# sourceMappingURL=patient-settings.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"patient-settings.d.ts","sourceRoot":"","sources":["../../../src/interface/internal/patient-settings.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,QAAA,MAAM,mBAAmB;;;;;;EAEvB,CAAC;AAEH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEvE,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;;;;;EAGhC,CAAC;AAEH,eAAO,MAAM,gCAAgC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAE3C,CAAC;AACH,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gCAAgC,CAAC,CAAC;AAE1F,eAAO,MAAM,4BAA4B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAGvC,CAAC;AACH,MAAM,MAAM,sBAAsB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,4BAA4B,CAAC,CAAC"}
@@ -0,0 +1,19 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.patientSettingsRequestSchema = exports.bulkPatientSettingsRequestSchema = exports.patientSettingsSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ const subscriptionsSchema = zod_1.z.object({
6
+ adt: zod_1.z.array(zod_1.z.string()).optional(),
7
+ });
8
+ exports.patientSettingsSchema = zod_1.z.object({
9
+ subscriptions: subscriptionsSchema.optional(),
10
+ treatmentRelationship: zod_1.z.boolean().optional(),
11
+ });
12
+ exports.bulkPatientSettingsRequestSchema = zod_1.z.object({
13
+ settings: exports.patientSettingsSchema,
14
+ });
15
+ exports.patientSettingsRequestSchema = zod_1.z.object({
16
+ patientIds: zod_1.z.array(zod_1.z.string()),
17
+ settings: exports.patientSettingsSchema,
18
+ });
19
+ //# sourceMappingURL=patient-settings.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"patient-settings.js","sourceRoot":"","sources":["../../../src/interface/internal/patient-settings.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAExB,MAAM,mBAAmB,GAAG,OAAC,CAAC,MAAM,CAAC;IACnC,GAAG,EAAE,OAAC,CAAC,KAAK,CAAC,OAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;CACpC,CAAC,CAAC;AAIU,QAAA,qBAAqB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC5C,aAAa,EAAE,mBAAmB,CAAC,QAAQ,EAAE;IAC7C,qBAAqB,EAAE,OAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;CAC9C,CAAC,CAAC;AAEU,QAAA,gCAAgC,GAAG,OAAC,CAAC,MAAM,CAAC;IACvD,QAAQ,EAAE,QAAA,qBAAqB;CAChC,CAAC,CAAC;AAGU,QAAA,4BAA4B,GAAG,OAAC,CAAC,MAAM,CAAC;IACnD,UAAU,EAAE,OAAC,CAAC,KAAK,CAAC,OAAC,CAAC,MAAM,EAAE,CAAC;IAC/B,QAAQ,EAAE,QAAA,qBAAqB;CAChC,CAAC,CAAC"}
@@ -0,0 +1,12 @@
1
+ import { z } from "zod";
2
+ export declare const patientStatusSchema: z.ZodObject<{
3
+ hieOptOut: z.ZodOptional<z.ZodBoolean>;
4
+ treatmentRelationship: z.ZodOptional<z.ZodBoolean>;
5
+ }, "strip", z.ZodTypeAny, {
6
+ hieOptOut?: boolean | undefined;
7
+ treatmentRelationship?: boolean | undefined;
8
+ }, {
9
+ hieOptOut?: boolean | undefined;
10
+ treatmentRelationship?: boolean | undefined;
11
+ }>;
12
+ //# sourceMappingURL=patient-status.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"patient-status.d.ts","sourceRoot":"","sources":["../../../src/interface/internal/patient-status.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,mBAAmB;;;;;;;;;EAG9B,CAAC"}
@@ -0,0 +1,9 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.patientStatusSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ exports.patientStatusSchema = zod_1.z.object({
6
+ hieOptOut: zod_1.z.boolean().optional(),
7
+ treatmentRelationship: zod_1.z.boolean().optional(),
8
+ });
9
+ //# sourceMappingURL=patient-status.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"patient-status.js","sourceRoot":"","sources":["../../../src/interface/internal/patient-status.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAEX,QAAA,mBAAmB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC1C,SAAS,EAAE,OAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;IACjC,qBAAqB,EAAE,OAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;CAC9C,CAAC,CAAC"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=primitive-types.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"primitive-types.test.d.ts","sourceRoot":"","sources":["../../../../src/medical/fhir/__tests__/primitive-types.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,56 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ const primitive_types_1 = require("../primitive-types");
4
+ describe("isValidFhirDateTime", () => {
5
+ it("returns false for undefined and empty", () => {
6
+ expect((0, primitive_types_1.isValidFhirDateTime)(undefined)).toEqual(false);
7
+ expect((0, primitive_types_1.isValidFhirDateTime)("")).toEqual(false);
8
+ });
9
+ it("returns true for conformant values", () => {
10
+ expect((0, primitive_types_1.isValidFhirDateTime)("2018")).toEqual(true);
11
+ expect((0, primitive_types_1.isValidFhirDateTime)("1973-06")).toEqual(true);
12
+ expect((0, primitive_types_1.isValidFhirDateTime)("1905-08-23")).toEqual(true);
13
+ expect((0, primitive_types_1.isValidFhirDateTime)("2015-02-07T13:28:17-05:00")).toEqual(true);
14
+ expect((0, primitive_types_1.isValidFhirDateTime)("2017-01-01T00:00:00.000Z")).toEqual(true);
15
+ });
16
+ it("returns false for non-conformant values dayjs would otherwise accept", () => {
17
+ expect((0, primitive_types_1.isValidFhirDateTime)("01/01/2023")).toEqual(false);
18
+ expect((0, primitive_types_1.isValidFhirDateTime)("2020/01/01")).toEqual(false);
19
+ expect((0, primitive_types_1.isValidFhirDateTime)("Jan 1 2020")).toEqual(false);
20
+ expect((0, primitive_types_1.isValidFhirDateTime)("2020-13")).toEqual(false);
21
+ expect((0, primitive_types_1.isValidFhirDateTime)("2020-2-7")).toEqual(false);
22
+ });
23
+ it("requires a timezone when a time is present", () => {
24
+ expect((0, primitive_types_1.isValidFhirDateTime)("2024-12-18T04:18:01")).toEqual(false);
25
+ expect((0, primitive_types_1.isValidFhirDateTime)("2024-12-18T04:18:01.263")).toEqual(false);
26
+ expect((0, primitive_types_1.isValidFhirDateTime)("2024-12-18T04:18:01Z")).toEqual(true);
27
+ expect((0, primitive_types_1.isValidFhirDateTime)("2024-12-18T04:18:01.263Z")).toEqual(true);
28
+ expect((0, primitive_types_1.isValidFhirDateTime)("2024-12-18T04:18:01-05:00")).toEqual(true);
29
+ });
30
+ it("does not require a timezone for date-only and partial dates", () => {
31
+ expect((0, primitive_types_1.isValidFhirDateTime)("2024-12-18")).toEqual(true);
32
+ expect((0, primitive_types_1.isValidFhirDateTime)("1973-06")).toEqual(true);
33
+ expect((0, primitive_types_1.isValidFhirDateTime)("2018")).toEqual(true);
34
+ });
35
+ it("accepts leap seconds and the full timezone range", () => {
36
+ expect((0, primitive_types_1.isValidFhirDateTime)("2020-01-31T23:59:60Z")).toEqual(true);
37
+ expect((0, primitive_types_1.isValidFhirDateTime)("2020-01-31T13:30:00+14:00")).toEqual(true);
38
+ });
39
+ it("rejects malformed years", () => {
40
+ expect((0, primitive_types_1.isValidFhirDateTime)("0000")).toEqual(false);
41
+ expect((0, primitive_types_1.isValidFhirDateTime)("22025-11-11")).toEqual(false);
42
+ expect((0, primitive_types_1.isValidFhirDateTime)("202202-12-23")).toEqual(false);
43
+ });
44
+ it("rejects out-of-range or unpadded month/day", () => {
45
+ expect((0, primitive_types_1.isValidFhirDateTime)("2020-00")).toEqual(false);
46
+ expect((0, primitive_types_1.isValidFhirDateTime)("2020-01-00")).toEqual(false);
47
+ expect((0, primitive_types_1.isValidFhirDateTime)("2020-01-32")).toEqual(false);
48
+ expect((0, primitive_types_1.isValidFhirDateTime)("2020-1-1")).toEqual(false);
49
+ });
50
+ it("rejects malformed time components", () => {
51
+ expect((0, primitive_types_1.isValidFhirDateTime)("2020-01-31T13:30Z")).toEqual(false);
52
+ expect((0, primitive_types_1.isValidFhirDateTime)("2020-01-31 13:30:00Z")).toEqual(false);
53
+ expect((0, primitive_types_1.isValidFhirDateTime)("2020-01-31T24:00:00Z")).toEqual(false);
54
+ });
55
+ });
56
+ //# sourceMappingURL=primitive-types.test.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"primitive-types.test.js","sourceRoot":"","sources":["../../../../src/medical/fhir/__tests__/primitive-types.test.ts"],"names":[],"mappings":";;AAAA,wDAAyD;AAEzD,QAAQ,CAAC,qBAAqB,EAAE,GAAG,EAAE;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type LoincClass = keyof LoincClassDisplayLookup;
8
8
  export declare function isLoinc(system: string | undefined): boolean;
9
9
  export declare function isLoincCoding(coding: Coding | undefined): boolean;
10
+ export declare function isSnomed(system: string | undefined): boolean;
10
11
  export declare function isActCoding(coding: Coding | undefined): boolean;
11
12
  export declare function getLoincCodeClass(loincCode: string): {
12
13
  abbreviation: string;
@@ -1 +1 @@
1
- {"version":3,"file":"coding.d.ts","sourceRoot":"","sources":["../../../src/medical/fhir/coding.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAK5C,MAAM,MAAM,cAAc,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,CAAC;AAInD,KAAK,uBAAuB,GAAG,MAAM,CAAC,MAAM,EAAE;IAAE,YAAY,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AAY1F,MAAM,MAAM,UAAU,GAAG,MAAM,uBAAuB,CAAC;AAEvD,wBAAgB,OAAO,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,CAQ3D;AAED,wBAAgB,aAAa,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,CAKjE;AAED,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,CAE/D;AAED,wBAAgB,iBAAiB,CAC/B,SAAS,EAAE,MAAM,GAChB;IAAE,YAAY,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAE,GAAG,SAAS,CAevD"}
1
+ {"version":3,"file":"coding.d.ts","sourceRoot":"","sources":["../../../src/medical/fhir/coding.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,oBAAoB,CAAC;AAK5C,MAAM,MAAM,cAAc,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,GAAG,CAAC;AAInD,KAAK,uBAAuB,GAAG,MAAM,CAAC,MAAM,EAAE;IAAE,YAAY,EAAE,MAAM,CAAC;IAAC,QAAQ,EAAE,MAAM,CAAA;CAAE,CAAC,CAAC;AAY1F,MAAM,MAAM,UAAU,GAAG,MAAM,uBAAuB,CAAC;AAEvD,wBAAgB,OAAO,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,CAQ3D;AAED,wBAAgB,aAAa,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,CAKjE;AAED,wBAAgB,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,CAQ5D;AAED,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,CAE/D;AAED,wBAAgB,iBAAiB,CAC/B,SAAS,EAAE,MAAM,GAChB;IAAE,YAAY,EAAE,MAAM,CAAC;IAAC,OAAO,EAAE,MAAM,CAAA;CAAE,GAAG,SAAS,CAevD"}
@@ -5,6 +5,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
6
  exports.isLoinc = isLoinc;
7
7
  exports.isLoincCoding = isLoincCoding;
8
+ exports.isSnomed = isSnomed;
8
9
  exports.isActCoding = isActCoding;
9
10
  exports.getLoincCodeClass = getLoincCodeClass;
10
11
  const constants_1 = require("./constants");
@@ -28,6 +29,13 @@ function isLoincCoding(coding) {
28
29
  }
29
30
  return false;
30
31
  }
32
+ function isSnomed(system) {
33
+ if (system?.toLowerCase().trim().includes(constants_1.SNOMED_CODE) ||
34
+ system?.toLowerCase().trim().includes(constants_1.SNOMED_OID)) {
35
+ return true;
36
+ }
37
+ return false;
38
+ }
31
39
  function isActCoding(coding) {
32
40
  return coding?.system?.toLowerCase().trim().includes(constants_1.HL7_ACT_URL.toLowerCase()) ?? false;
33
41
  }
@@ -1 +1 @@
1
- {"version":3,"file":"coding.js","sourceRoot":"","sources":["../../../src/medical/fhir/coding.ts"],"names":[],"mappings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F,CAAC;AAED,2BACE,SAAiB;IAEjB,MAAM,EAAE,SAAS,EAAE,YAAY,EAAE,GAAG,eAAe,EAAE,CAAC;IACtD,MAAM,WAAW,GAAG,SAAS,CAAC,SAAS,CAAC,CAAC;IACzC,IAAI,CAAC,WAAW,EAAE,CAAC;QACjB,OAAO,SAAS,CAAC;IACnB,CAAC;IACD,MAAM,kBAAkB,GAAG,YAAY,CAAC,WAAW,CAAC,KAAK,CAAC,CAAC;IAC3D,IAAI,CAAC,kBAAkB,EAAE,CAAC;QACxB,OAAO,SAAS,CAAC;IACnB,CAAC;IAED,OAAO;QACL,YAAY,EAAE,WAAW,CAAC,KAAK;QAC/B,OAAO,EAAE,kBAAkB,CAAC,YAAY;KACzC,CAAC;AACJ,CAAC"}
@@ -0,0 +1,18 @@
1
+ /**
2
+ * FHIR primitive type formats and validators.
3
+ * @see https://hl7.org/fhir/R4/datatypes.html#primitive
4
+ */
5
+ /**
6
+ * Exact FHIR R4 dateTime format regex (anchored for full-string matching).
7
+ * Format: YYYY, YYYY-MM, YYYY-MM-DD or YYYY-MM-DDThh:mm:ss(.sss)?(±zz:zz|Z).
8
+ * @see https://hl7.org/fhir/R4/datatypes.html#dateTime
9
+ */
10
+ export declare const fhirDateTimeRegex: RegExp;
11
+ /**
12
+ * Returns true when the value is a non-nullish string that is a valid FHIR R4 dateTime.
13
+ *
14
+ * Beyond matching fhirDateTimeRegex (format only), this enforces the spec's prose rule that a
15
+ * timezone offset SHALL be present when a time is present
16
+ */
17
+ export declare function isValidFhirDateTime(value: string | undefined): boolean;
18
+ //# sourceMappingURL=primitive-types.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"primitive-types.d.ts","sourceRoot":"","sources":["../../../src/medical/fhir/primitive-types.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH;;;;GAIG;AACH,eAAO,MAAM,iBAAiB,QACyL,CAAC;AAIxN;;;;;GAKG;AACH,wBAAgB,mBAAmB,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,CAKtE"}
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ /**
3
+ * FHIR primitive type formats and validators.
4
+ * @see https://hl7.org/fhir/R4/datatypes.html#primitive
5
+ */
6
+ Object.defineProperty(exports, "__esModule", { value: true });
7
+ exports.fhirDateTimeRegex = void 0;
8
+ exports.isValidFhirDateTime = isValidFhirDateTime;
9
+ /**
10
+ * Exact FHIR R4 dateTime format regex (anchored for full-string matching).
11
+ * Format: YYYY, YYYY-MM, YYYY-MM-DD or YYYY-MM-DDThh:mm:ss(.sss)?(±zz:zz|Z).
12
+ * @see https://hl7.org/fhir/R4/datatypes.html#dateTime
13
+ */
14
+ exports.fhirDateTimeRegex = /^([0-9]([0-9]([0-9][1-9]|[1-9]0)|[1-9]00)|[1-9]000)(-(0[1-9]|1[0-2])(-(0[1-9]|[1-2][0-9]|3[0-1])(T([01][0-9]|2[0-3]):[0-5][0-9]:([0-5][0-9]|60)(\.[0-9]{1,9})?)?)?(Z|(\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00)?)?)?$/;
15
+ const timezoneSuffixRegex = /(Z|(\+|-)((0[0-9]|1[0-3]):[0-5][0-9]|14:00))$/;
16
+ /**
17
+ * Returns true when the value is a non-nullish string that is a valid FHIR R4 dateTime.
18
+ *
19
+ * Beyond matching fhirDateTimeRegex (format only), this enforces the spec's prose rule that a
20
+ * timezone offset SHALL be present when a time is present
21
+ */
22
+ function isValidFhirDateTime(value) {
23
+ if (value === undefined)
24
+ return false;
25
+ if (!exports.fhirDateTimeRegex.test(value))
26
+ return false;
27
+ if (value.includes("T") && !timezoneSuffixRegex.test(value))
28
+ return false;
29
+ return true;
30
+ }
31
+ //# sourceMappingURL=primitive-types.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"primitive-types.js","sourceRoot":"","sources":["../../../src/medical/fhir/primitive-types.ts"],"names":[],"mappings":";AAAA;;;GAGG;;;;AAEH;;;;GAIG;AACU,QAAA,iBAAiB,GAC5B,qNAAqN,CAAC;AAExN,MAAM,mBAAmB,GAAG,+CAA+C,CAAC;AAE5E;;;;;GAKG;AACH,6BAAoC,KAAyB;IAC3D,IAAI,KAAK,KAAK,SAAS;QAAE,OAAO,KAAK,CAAC;IACtC,IAAI,CAAC,QAAA,iBAAiB,CAAC,IAAI,CAAC,KAAK,CAAC;QAAE,OAAO,KAAK,CAAC;IACjD,IAAI,KAAK,CAAC,QAAQ,CAAC,GAAG,CAAC,IAAI,CAAC,mBAAmB,CAAC,IAAI,CAAC,KAAK,CAAC;QAAE,OAAO,KAAK,CAAC;IAC1E,OAAO,IAAI,CAAC;AACd,CAAC"}
@@ -7,6 +7,7 @@ export * from "./fhir/constants";
7
7
  export * from "./fhir/condition-clinical-status-map";
8
8
  export * from "./fhir/condition-clinical-status-priority";
9
9
  export * from "./fhir/imaging-detection";
10
+ export * from "./fhir/primitive-types";
10
11
  export * from "./fhir/procedure-category";
11
12
  export * from "./fhir/procedure-category-from-cpt";
12
13
  export * from "./webhook/webhook-request";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/medical/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC;AAC9B,cAAc,kBAAkB,CAAC;AACjC,cAAc,sCAAsC,CAAC;AACrD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,0BAA0B,CAAC;AACzC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,oCAAoC,CAAC;AACnD,cAAc,2BAA2B,CAAC;AAC1C,cAAc,mCAAmC,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/medical/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,mBAAmB,CAAC;AAClC,cAAc,qBAAqB,CAAC;AACpC,cAAc,kBAAkB,CAAC;AACjC,cAAc,eAAe,CAAC;AAC9B,cAAc,kBAAkB,CAAC;AACjC,cAAc,sCAAsC,CAAC;AACrD,cAAc,2CAA2C,CAAC;AAC1D,cAAc,0BAA0B,CAAC;AACzC,cAAc,wBAAwB,CAAC;AACvC,cAAc,2BAA2B,CAAC;AAC1C,cAAc,oCAAoC,CAAC;AACnD,cAAc,2BAA2B,CAAC;AAC1C,cAAc,mCAAmC,CAAC"}
@@ -23,6 +23,7 @@ __exportStar(require("./fhir/constants"), exports);
23
23
  __exportStar(require("./fhir/condition-clinical-status-map"), exports);
24
24
  __exportStar(require("./fhir/condition-clinical-status-priority"), exports);
25
25
  __exportStar(require("./fhir/imaging-detection"), exports);
26
+ __exportStar(require("./fhir/primitive-types"), exports);
26
27
  __exportStar(require("./fhir/procedure-category"), exports);
27
28
  __exportStar(require("./fhir/procedure-category-from-cpt"), exports);
28
29
  __exportStar(require("./webhook/webhook-request"), exports);
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/medical/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,gDAA8B;AAC9B,oDAAkC;AAClC,sDAAoC;AACpC,mDAAiC;AACjC,gDAA8B;AAC9B,mDAAiC;AACjC,uEAAqD;AACrD,4EAA0D;AAC1D,2DAAyC;AACzC,4DAA0C;AAC1C,qEAAmD;AACnD,4DAA0C;AAC1C,oEAAkD"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/medical/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,gDAA8B;AAC9B,oDAAkC;AAClC,sDAAoC;AACpC,mDAAiC;AACjC,gDAA8B;AAC9B,mDAAiC;AACjC,uEAAqD;AACrD,4EAA0D;AAC1D,2DAAyC;AACzC,yDAAuC;AACvC,4DAA0C;AAC1C,qEAAmD;AACnD,4DAA0C;AAC1C,oEAAkD"}
@@ -0,0 +1,11 @@
1
+ /** SQS max delivery delay is 15 minutes (900 seconds). Delay must not exceed this. */
2
+ export declare const SQS_MAX_DELAY_SECONDS = 900;
3
+ /**
4
+ * Maps a string (e.g. cxId or UUID v4) to a delivery delay in seconds for SQS,
5
+ * evenly distributed across 0 to 15 minutes (max). Same input always gets the same delay (deterministic).
6
+ *
7
+ * @param id - Any string identifier (e.g. cxId, UUID v4)
8
+ * @returns Delay in seconds in [0, 900] (≤ 15 min, SQS max)
9
+ */
10
+ export declare function uuidToDelaySeconds(id: string, maxDelaySeconds?: number): number;
11
+ //# sourceMappingURL=sqs-delay-from-uuid.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sqs-delay-from-uuid.d.ts","sourceRoot":"","sources":["../../src/util/sqs-delay-from-uuid.ts"],"names":[],"mappings":"AAEA,sFAAsF;AACtF,eAAO,MAAM,qBAAqB,MAAM,CAAC;AAEzC;;;;;;GAMG;AACH,wBAAgB,kBAAkB,CAChC,EAAE,EAAE,MAAM,EACV,eAAe,GAAE,MAA8B,GAC9C,MAAM,CAKR"}
@@ -0,0 +1,21 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.SQS_MAX_DELAY_SECONDS = void 0;
4
+ exports.uuidToDelaySeconds = uuidToDelaySeconds;
5
+ const node_crypto_1 = require("node:crypto");
6
+ /** SQS max delivery delay is 15 minutes (900 seconds). Delay must not exceed this. */
7
+ exports.SQS_MAX_DELAY_SECONDS = 900;
8
+ /**
9
+ * Maps a string (e.g. cxId or UUID v4) to a delivery delay in seconds for SQS,
10
+ * evenly distributed across 0 to 15 minutes (max). Same input always gets the same delay (deterministic).
11
+ *
12
+ * @param id - Any string identifier (e.g. cxId, UUID v4)
13
+ * @returns Delay in seconds in [0, 900] (≤ 15 min, SQS max)
14
+ */
15
+ function uuidToDelaySeconds(id, maxDelaySeconds = exports.SQS_MAX_DELAY_SECONDS) {
16
+ const BUCKET_COUNT = maxDelaySeconds + 1; // maxDelaySeconds + 1 → 0..maxDelaySeconds
17
+ const hash = (0, node_crypto_1.createHash)("sha256").update(id, "utf8").digest();
18
+ const value = hash.readUInt32BE(0) * 0x100000000 + hash.readUInt32BE(4);
19
+ return value % BUCKET_COUNT; // always in [0, maxDelaySeconds]
20
+ }
21
+ //# sourceMappingURL=sqs-delay-from-uuid.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"sqs-delay-from-uuid.js","sourceRoot":"","sources":["../../src/util/sqs-delay-from-uuid.ts"],"names":[],"mappings":";;;;AAAA,6CAAyC;AAEzC,sFAAsF;AACzE,QAAA,qBAAqB,GAAG,GAAG,CAAC;AAEzC;;;;;;GAMG;AACH,4BACE,EAAU,EACV,eAAe,GAAW,QAAA,qBAAqB;IAE/C,MAAM,YAAY,GAAG,eAAe,GAAG,CAAC,CAAC,CAAC,2CAA2C;IACrF,MAAM,IAAI,GAAG,IAAA,wBAAU,EAAC,QAAQ,CAAC,CAAC,MAAM,CAAC,EAAE,EAAE,MAAM,CAAC,CAAC,MAAM,EAAE,CAAC;IAC9D,MAAM,KAAK,GAAG,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,GAAG,WAAW,GAAG,IAAI,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC;IACxE,OAAO,KAAK,GAAG,YAAY,CAAC,CAAC,iCAAiC;AAChE,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@metriport/shared",
3
- "version": "0.33.7",
3
+ "version": "0.34.1-alpha.0",
4
4
  "description": "Common code shared across packages - by Metriport Inc.",
5
5
  "author": "Metriport Inc. <contact@metriport.com>",
6
6
  "homepage": "https://metriport.com/",
@@ -144,7 +144,7 @@
144
144
  "http-status": "~1.7.0",
145
145
  "lodash": "^4.18.0",
146
146
  "semver": ">=5.7.2",
147
- "uuid": "^9.0.0",
147
+ "uuid": "^13.0.1",
148
148
  "validator": "^13.15.15",
149
149
  "zod": "^3.22.1"
150
150
  },
@@ -155,7 +155,6 @@
155
155
  "@tsconfig/recommended": "^1.0.2",
156
156
  "@types/jest": "29.5.3",
157
157
  "@types/lodash": "4.14.194",
158
- "@types/uuid": "^9.0.0",
159
158
  "@typescript-eslint/eslint-plugin": "8.59.4",
160
159
  "@typescript-eslint/parser": "8.59.4",
161
160
  "eslint": "8.57.1",
@@ -164,6 +163,5 @@
164
163
  "ts-essentials": "^9.3.1",
165
164
  "ts-jest": "29.4.11",
166
165
  "typescript": "6.0.3"
167
- },
168
- "gitHead": "6dd319c81dd01fadb211518e0568ba60084c1eef"
166
+ }
169
167
  }
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=cohort-purpose-of-use-hies.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"cohort-purpose-of-use-hies.test.d.ts","sourceRoot":"","sources":["../../../src/domain/__tests__/cohort-purpose-of-use-hies.test.ts"],"names":[],"mappings":""}
@@ -1,10 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const constants_1 = require("../../external/hl7v2/constants");
4
- const cohort_purpose_of_use_hies_1 = require("../cohort-purpose-of-use-hies");
5
- describe("cohort-purpose-of-use-hies", () => {
6
- it("defines ops ADT HIE allowlist", () => {
7
- expect(cohort_purpose_of_use_hies_1.OPS_ADT_HIE_NAMES).toEqual([constants_1.HieName.Bamboo, constants_1.HieName.Riqi, constants_1.HieName.Pcc, constants_1.HieName.Konza]);
8
- });
9
- });
10
- //# sourceMappingURL=cohort-purpose-of-use-hies.test.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"cohort-purpose-of-use-hies.test.js","sourceRoot":"","sources":["../../../src/domain/__tests__/cohort-purpose-of-use-hies.test.ts"],"names":[],"mappings":";;AAAA,8DAAyD;AACzD,8EAAkE;AAElE,QAAQ,CAAC,4BAA4B,EAAE,GAAG,EAAE;IAC1C,EAAE,CAAC,+BAA+B,EAAE,GAAG,EAAE;QACvC,MAAM,CAAC,8CAAiB,CAAC,CAAC,OAAO,CAAC,CAAC,mBAAO,CAAC,MAAM,EAAE,mBAAO,CAAC,IAAI,EAAE,mBAAO,CAAC,GAAG,EAAE,mBAAO,CAAC,KAAK,CAAC,CAAC,CAAC;IAChG,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=cohort-response-dto.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"cohort-response-dto.test.d.ts","sourceRoot":"","sources":["../../../src/domain/__tests__/cohort-response-dto.test.ts"],"names":[],"mappings":""}
@@ -1,59 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const cohort_1 = require("../cohort");
4
- const now = new Date("2024-01-01T12:00:00Z");
5
- const cohortBase = {
6
- id: "cohort-id",
7
- eTag: "1",
8
- cxId: "cx-id",
9
- name: "Test Cohort",
10
- color: "red",
11
- description: "Test description",
12
- createdAt: now,
13
- updatedAt: now,
14
- };
15
- describe("resolveCohortPurposeOfUseForResponse", () => {
16
- it("returns explicit purposeOfUse when set", () => {
17
- expect((0, cohort_1.resolveCohortPurposeOfUseForResponse)("operations")).toBe("operations");
18
- });
19
- it("defaults to treatment when purposeOfUse is missing", () => {
20
- expect((0, cohort_1.resolveCohortPurposeOfUseForResponse)(undefined)).toBe("treatment");
21
- });
22
- });
23
- describe("responseDtoFromCohort", () => {
24
- it("includes purposeOfUse when set on domain cohort", () => {
25
- const response = (0, cohort_1.responseDtoFromCohort)({
26
- ...cohortBase,
27
- purposeOfUse: "operations",
28
- settings: {
29
- monitoring: cohort_1.DEFAULT_MONITORING,
30
- overrides: cohort_1.DEFAULT_OVERRIDES,
31
- },
32
- });
33
- expect(response.purposeOfUse).toBe("operations");
34
- expect(response.settings.monitoring).toEqual(cohort_1.DEFAULT_MONITORING);
35
- });
36
- it("defaults purposeOfUse to treatment when missing", () => {
37
- const response = (0, cohort_1.responseDtoFromCohort)({
38
- ...cohortBase,
39
- purposeOfUse: "treatment",
40
- settings: {
41
- monitoring: cohort_1.DEFAULT_MONITORING,
42
- overrides: cohort_1.DEFAULT_OVERRIDES,
43
- },
44
- });
45
- expect(response.purposeOfUse).toBe("treatment");
46
- });
47
- it("strips overrides from public response", () => {
48
- const response = (0, cohort_1.responseDtoFromCohort)({
49
- ...cohortBase,
50
- purposeOfUse: "treatment",
51
- settings: {
52
- monitoring: cohort_1.DEFAULT_MONITORING,
53
- overrides: { [cohort_1.STATE_VALIDATION_OVERRIDE_KEY]: true },
54
- },
55
- });
56
- expect(response.settings).not.toHaveProperty("overrides");
57
- });
58
- });
59
- //# sourceMappingURL=cohort-response-dto.test.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"cohort-response-dto.test.js","sourceRoot":"","sources":["../../../src/domain/__tests__/cohort-response-dto.test.ts"],"names":[],"mappings":";;AAAA,sCAMmB;AAEnB,MAAM,GAAG,GAAG,IAAI,IAAI,CAAC,sBAAsB,CAAC,CAAC;AAE7C,MAAM,UAAU,GAAG;IACjB,EAAE,EAAE,WAAW;IACf,IAAI,EAAE,GAAG;IACT,IAAI,EAAE,OAAO;IACb,IAAI,EAAE,aAAa;IACnB,KAAK,EAAE,KAAc;IACrB,WAAW,EAAE,kBAAkB;IAC/B,SAAS,EAAE,GAAG;IACd,SAAS,EAAE,GAAG;CACf,CAAC;AAEF,QAAQ,CAAC,sCAAsC,EAAE,GAAG,EAAE;IACpD,EAAE,CAAC,wCAAwC,EAAE,GAAG,EAAE;QAChD,MAAM,CAAC,IAAA,6CAAoC,EAAC,YAAY,CAAC,CAAC,CAAC,IAAI,CAAC,YAAY,CAAC,CAAC;IAChF,CAAC,CAAC,CAAC;IAEH,EAAE,CAAC,oDAAoD,EAAE,GAAG,EAAE;QAC5D,MAAM,CAAC,IAAA,6CAAoC,EAAC,SAAS,CAAC,CAAC,CAAC,IAAI,CAAC,WAAW,CAAC,CAAC;IAC5E,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC;AAEH,QAAQ,CAAC,uBAAuB,EAAE,GAAG,EAAE;IACrC,EA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