@metriport/shared 0.24.5 → 0.24.7
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/dist/common/__tests__/oid.d.ts +20 -0
- package/dist/common/__tests__/oid.d.ts.map +1 -0
- package/dist/common/__tests__/oid.js +30 -0
- package/dist/common/__tests__/oid.js.map +1 -0
- package/dist/common/__tests__/oid.test.d.ts +2 -0
- package/dist/common/__tests__/oid.test.d.ts.map +1 -0
- package/dist/common/__tests__/oid.test.js +50 -0
- package/dist/common/__tests__/oid.test.js.map +1 -0
- package/dist/common/retry.d.ts.map +1 -1
- package/dist/common/retry.js +7 -0
- package/dist/common/retry.js.map +1 -1
- package/dist/common/zod.d.ts +3 -0
- package/dist/common/zod.d.ts.map +1 -0
- package/dist/common/zod.js +11 -0
- package/dist/common/zod.js.map +1 -0
- package/dist/domain/cohort.d.ts +89 -0
- package/dist/domain/cohort.d.ts.map +1 -0
- package/dist/domain/cohort.js +69 -0
- package/dist/domain/cohort.js.map +1 -0
- package/dist/domain/pagination.d.ts +30 -0
- package/dist/domain/pagination.d.ts.map +1 -0
- package/dist/domain/pagination.js +27 -0
- package/dist/domain/pagination.js.map +1 -0
- package/dist/domain/patient/patient-monitoring/discharge-requery.d.ts +2 -2
- package/dist/domain/patient/patient-monitoring/discharge-requery.d.ts.map +1 -1
- package/dist/domain/patient/patient-monitoring/discharge-requery.js +1 -1
- package/dist/domain/patient/patient-monitoring/discharge-requery.js.map +1 -1
- package/dist/domain/patient/patient-settings.d.ts +115 -0
- package/dist/domain/patient/patient-settings.d.ts.map +1 -0
- package/dist/domain/patient/patient-settings.js +25 -0
- package/dist/domain/patient/patient-settings.js.map +1 -0
- package/dist/domain/patient copy.d.ts +72 -0
- package/dist/domain/patient copy.d.ts.map +1 -0
- package/dist/domain/patient copy.js +25 -0
- package/dist/domain/patient copy.js.map +1 -0
- package/dist/external/index.d.ts +2 -0
- package/dist/external/index.d.ts.map +1 -0
- package/dist/external/index.js +18 -0
- package/dist/external/index.js.map +1 -0
- package/dist/external/zod/__tests__/iso-date.test.d.ts +2 -0
- package/dist/external/zod/__tests__/iso-date.test.d.ts.map +1 -0
- package/dist/external/zod/__tests__/iso-date.test.js +115 -0
- package/dist/external/zod/__tests__/iso-date.test.js.map +1 -0
- package/dist/external/zod/date.d.ts +12 -0
- package/dist/external/zod/date.d.ts.map +1 -0
- package/dist/external/zod/date.js +28 -0
- package/dist/external/zod/date.js.map +1 -0
- package/dist/external/zod/index.d.ts +4 -0
- package/dist/external/zod/index.d.ts.map +1 -0
- package/dist/external/zod/index.js +20 -0
- package/dist/external/zod/index.js.map +1 -0
- package/dist/external/zod/string.d.ts +11 -0
- package/dist/external/zod/string.d.ts.map +1 -0
- package/dist/external/zod/string.js +27 -0
- package/dist/external/zod/string.js.map +1 -0
- package/dist/external/zod/zip.d.ts +3 -0
- package/dist/external/zod/zip.d.ts.map +1 -0
- package/dist/external/zod/zip.js +13 -0
- package/dist/external/zod/zip.js.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2 -0
- package/dist/index.js.map +1 -1
- package/dist/interface/external/ehr/athenahealth/patient.d.ts +8 -8
- package/dist/interface/external/ehr/athenahealth/patient.js +1 -1
- package/dist/interface/external/ehr/athenahealth/patient.js.map +1 -1
- package/dist/interface/external/ehr/healthie/patient.d.ts +14 -14
- package/dist/interface/external/ehr/healthie/patient.js +1 -1
- package/dist/interface/external/ehr/healthie/patient.js.map +1 -1
- package/dist/interface/external/ehr/resource-diff.d.ts +7 -0
- package/dist/interface/external/ehr/resource-diff.d.ts.map +1 -0
- package/dist/interface/external/ehr/resource-diff.js +12 -0
- package/dist/interface/external/ehr/resource-diff.js.map +1 -0
- package/dist/interface/external/ehr/source.d.ts +1 -0
- package/dist/interface/external/ehr/source.d.ts.map +1 -1
- package/dist/interface/external/ehr/source.js +11 -1
- package/dist/interface/external/ehr/source.js.map +1 -1
- package/dist/medical/fhir/coding.d.ts +4 -0
- package/dist/medical/fhir/coding.d.ts.map +1 -0
- package/dist/medical/fhir/coding.js +20 -0
- package/dist/medical/fhir/coding.js.map +1 -0
- package/dist/medical/fhir/constants.d.ts +29 -0
- package/dist/medical/fhir/constants.d.ts.map +1 -0
- package/dist/medical/fhir/constants.js +42 -0
- package/dist/medical/fhir/constants.js.map +1 -0
- package/dist/medical/fhir/system.d.ts +1 -0
- package/dist/medical/fhir/system.d.ts.map +1 -0
- package/dist/medical/fhir/system.js +2 -0
- package/dist/medical/fhir/system.js.map +1 -0
- package/dist/medical/index.d.ts +2 -0
- package/dist/medical/index.d.ts.map +1 -1
- package/dist/medical/index.js +2 -0
- package/dist/medical/index.js.map +1 -1
- package/package.json +2 -2
|
@@ -9,7 +9,7 @@ export declare const patientSchema: z.ZodObject<{
|
|
|
9
9
|
phone_number: z.ZodNullable<z.ZodString>;
|
|
10
10
|
locations: z.ZodArray<z.ZodObject<{
|
|
11
11
|
line1: z.ZodString;
|
|
12
|
-
line2: z.ZodString
|
|
12
|
+
line2: z.ZodNullable<z.ZodString>;
|
|
13
13
|
city: z.ZodString;
|
|
14
14
|
state: z.ZodString;
|
|
15
15
|
zip: z.ZodString;
|
|
@@ -20,14 +20,14 @@ export declare const patientSchema: z.ZodObject<{
|
|
|
20
20
|
city: string;
|
|
21
21
|
zip: string;
|
|
22
22
|
line1: string;
|
|
23
|
-
line2: string;
|
|
23
|
+
line2: string | null;
|
|
24
24
|
}, {
|
|
25
25
|
country: string;
|
|
26
26
|
state: string;
|
|
27
27
|
city: string;
|
|
28
28
|
zip: string;
|
|
29
29
|
line1: string;
|
|
30
|
-
line2: string;
|
|
30
|
+
line2: string | null;
|
|
31
31
|
}>, "many">;
|
|
32
32
|
}, "strip", z.ZodTypeAny, {
|
|
33
33
|
id: string;
|
|
@@ -43,7 +43,7 @@ export declare const patientSchema: z.ZodObject<{
|
|
|
43
43
|
city: string;
|
|
44
44
|
zip: string;
|
|
45
45
|
line1: string;
|
|
46
|
-
line2: string;
|
|
46
|
+
line2: string | null;
|
|
47
47
|
}[];
|
|
48
48
|
}, {
|
|
49
49
|
id: string;
|
|
@@ -59,7 +59,7 @@ export declare const patientSchema: z.ZodObject<{
|
|
|
59
59
|
city: string;
|
|
60
60
|
zip: string;
|
|
61
61
|
line1: string;
|
|
62
|
-
line2: string;
|
|
62
|
+
line2: string | null;
|
|
63
63
|
}[];
|
|
64
64
|
}>;
|
|
65
65
|
export type Patient = z.infer<typeof patientSchema>;
|
|
@@ -75,7 +75,7 @@ export declare const patientGraphqlSchema: z.ZodObject<{
|
|
|
75
75
|
phone_number: z.ZodNullable<z.ZodString>;
|
|
76
76
|
locations: z.ZodArray<z.ZodObject<{
|
|
77
77
|
line1: z.ZodString;
|
|
78
|
-
line2: z.ZodString
|
|
78
|
+
line2: z.ZodNullable<z.ZodString>;
|
|
79
79
|
city: z.ZodString;
|
|
80
80
|
state: z.ZodString;
|
|
81
81
|
zip: z.ZodString;
|
|
@@ -86,14 +86,14 @@ export declare const patientGraphqlSchema: z.ZodObject<{
|
|
|
86
86
|
city: string;
|
|
87
87
|
zip: string;
|
|
88
88
|
line1: string;
|
|
89
|
-
line2: string;
|
|
89
|
+
line2: string | null;
|
|
90
90
|
}, {
|
|
91
91
|
country: string;
|
|
92
92
|
state: string;
|
|
93
93
|
city: string;
|
|
94
94
|
zip: string;
|
|
95
95
|
line1: string;
|
|
96
|
-
line2: string;
|
|
96
|
+
line2: string | null;
|
|
97
97
|
}>, "many">;
|
|
98
98
|
}, "strip", z.ZodTypeAny, {
|
|
99
99
|
id: string;
|
|
@@ -109,7 +109,7 @@ export declare const patientGraphqlSchema: z.ZodObject<{
|
|
|
109
109
|
city: string;
|
|
110
110
|
zip: string;
|
|
111
111
|
line1: string;
|
|
112
|
-
line2: string;
|
|
112
|
+
line2: string | null;
|
|
113
113
|
}[];
|
|
114
114
|
}, {
|
|
115
115
|
id: string;
|
|
@@ -125,7 +125,7 @@ export declare const patientGraphqlSchema: z.ZodObject<{
|
|
|
125
125
|
city: string;
|
|
126
126
|
zip: string;
|
|
127
127
|
line1: string;
|
|
128
|
-
line2: string;
|
|
128
|
+
line2: string | null;
|
|
129
129
|
}[];
|
|
130
130
|
}>>;
|
|
131
131
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -143,7 +143,7 @@ export declare const patientGraphqlSchema: z.ZodObject<{
|
|
|
143
143
|
city: string;
|
|
144
144
|
zip: string;
|
|
145
145
|
line1: string;
|
|
146
|
-
line2: string;
|
|
146
|
+
line2: string | null;
|
|
147
147
|
}[];
|
|
148
148
|
} | null;
|
|
149
149
|
}, {
|
|
@@ -161,7 +161,7 @@ export declare const patientGraphqlSchema: z.ZodObject<{
|
|
|
161
161
|
city: string;
|
|
162
162
|
zip: string;
|
|
163
163
|
line1: string;
|
|
164
|
-
line2: string;
|
|
164
|
+
line2: string | null;
|
|
165
165
|
}[];
|
|
166
166
|
} | null;
|
|
167
167
|
}>;
|
|
@@ -181,7 +181,7 @@ export declare const patientGraphqlSchema: z.ZodObject<{
|
|
|
181
181
|
city: string;
|
|
182
182
|
zip: string;
|
|
183
183
|
line1: string;
|
|
184
|
-
line2: string;
|
|
184
|
+
line2: string | null;
|
|
185
185
|
}[];
|
|
186
186
|
} | null;
|
|
187
187
|
};
|
|
@@ -201,7 +201,7 @@ export declare const patientGraphqlSchema: z.ZodObject<{
|
|
|
201
201
|
city: string;
|
|
202
202
|
zip: string;
|
|
203
203
|
line1: string;
|
|
204
|
-
line2: string;
|
|
204
|
+
line2: string | null;
|
|
205
205
|
}[];
|
|
206
206
|
} | null;
|
|
207
207
|
};
|
|
@@ -4,7 +4,7 @@ exports.patientUpdateQuickNotesGraphqlSchema = exports.patientQuickNotesGraphqlS
|
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
5
|
const locationSchema = zod_1.z.object({
|
|
6
6
|
line1: zod_1.z.string(),
|
|
7
|
-
line2: zod_1.z.string(),
|
|
7
|
+
line2: zod_1.z.string().nullable(),
|
|
8
8
|
city: zod_1.z.string(),
|
|
9
9
|
state: zod_1.z.string(),
|
|
10
10
|
zip: zod_1.z.string(),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"patient.js","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/healthie/patient.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAExB,MAAM,cAAc,GAAG,OAAC,CAAC,MAAM,CAAC;IAC9B,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE;IACjB,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE;
|
|
1
|
+
{"version":3,"file":"patient.js","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/healthie/patient.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAExB,MAAM,cAAc,GAAG,OAAC,CAAC,MAAM,CAAC;IAC9B,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE;IACjB,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC5B,IAAI,EAAE,OAAC,CAAC,MAAM,EAAE;IAChB,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE;IACjB,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,OAAO,EAAE,OAAC,CAAC,MAAM,EAAE;CACpB,CAAC,CAAC;AAEU,QAAA,aAAa,GAAG,OAAC,CAAC,MAAM,CAAC;IACpC,EAAE,EAAE,OAAC,CAAC,MAAM,EAAE;IACd,UAAU,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACjC,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAChC,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC1B,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC7B,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC5B,YAAY,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACnC,SAAS,EAAE,cAAc,CAAC,KAAK,EAAE;CAClC,CAAC,CAAC;AAGU,QAAA,oBAAoB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC3C,IAAI,EAAE,OAAC,CAAC,MAAM,CAAC;QACb,IAAI,EAAE,qBAAa,CAAC,QAAQ,EAAE;KAC/B,CAAC;CACH,CAAC,CAAC;AAGU,QAAA,uBAAuB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC9C,EAAE,EAAE,OAAC,CAAC,MAAM,EAAE;IACd,WAAW,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CACnC,CAAC,CAAC;AAGU,QAAA,8BAA8B,GAAG,OAAC,CAAC,MAAM,CAAC;IACrD,IAAI,EAAE,OAAC,CAAC,MAAM,CAAC;QACb,IAAI,EAAE,+BAAuB,CAAC,QAAQ,EAAE;KACzC,CAAC;CACH,CAAC,CAAC;AAGU,QAAA,oCAAoC,GAAG,OAAC,CAAC,MAAM,CAAC;IAC3D,IAAI,EAAE,OAAC,CAAC,MAAM,CAAC;QACb,YAAY,EAAE,OAAC,CAAC,MAAM,CAAC;YACrB,IAAI,EAAE,+BAAuB,CAAC,QAAQ,EAAE;SACzC,CAAC;KACH,CAAC;CACH,CAAC,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
export declare const ResourceDiffDirection: {
|
|
2
|
+
readonly METRIPORT_ONLY: "metriport-only";
|
|
3
|
+
readonly CANVAS_ONLY: "canvas-only";
|
|
4
|
+
};
|
|
5
|
+
export type ResourceDiffDirection = (typeof ResourceDiffDirection)[keyof typeof ResourceDiffDirection];
|
|
6
|
+
export declare function isResourceDiffDirection(direction: string): direction is ResourceDiffDirection;
|
|
7
|
+
//# sourceMappingURL=resource-diff.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resource-diff.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/ehr/resource-diff.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,qBAAqB;;;CAGxB,CAAC;AACX,MAAM,MAAM,qBAAqB,GAC/B,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,OAAO,qBAAqB,CAAC,CAAC;AACrE,wBAAgB,uBAAuB,CAAC,SAAS,EAAE,MAAM,GAAG,SAAS,IAAI,qBAAqB,CAE7F"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.isResourceDiffDirection = exports.ResourceDiffDirection = void 0;
|
|
4
|
+
exports.ResourceDiffDirection = {
|
|
5
|
+
METRIPORT_ONLY: "metriport-only",
|
|
6
|
+
CANVAS_ONLY: "canvas-only",
|
|
7
|
+
};
|
|
8
|
+
function isResourceDiffDirection(direction) {
|
|
9
|
+
return Object.values(exports.ResourceDiffDirection).includes(direction);
|
|
10
|
+
}
|
|
11
|
+
exports.isResourceDiffDirection = isResourceDiffDirection;
|
|
12
|
+
//# sourceMappingURL=resource-diff.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"resource-diff.js","sourceRoot":"","sources":["../../../../src/interface/external/ehr/resource-diff.ts"],"names":[],"mappings":";;;AAAa,QAAA,qBAAqB,GAAG;IACnC,cAAc,EAAE,gBAAgB;IAChC,WAAW,EAAE,aAAa;CAClB,CAAC;AAGX,SAAgB,uBAAuB,CAAC,SAAiB;IACvD,OAAO,MAAM,CAAC,MAAM,CAAC,6BAAqB,CAAC,CAAC,QAAQ,CAAC,SAAkC,CAAC,CAAC;AAC3F,CAAC;AAFD,0DAEC"}
|
|
@@ -8,6 +8,7 @@ export declare enum EhrSources {
|
|
|
8
8
|
export declare const ehrSources: readonly EhrSources[];
|
|
9
9
|
export type EhrSource = (typeof ehrSources)[number];
|
|
10
10
|
export declare function isEhrSource(source: string): source is EhrSource;
|
|
11
|
+
export declare function parseEhrSourceOrFail(source: string | undefined): EhrSource | undefined;
|
|
11
12
|
export declare const clientSourceSuffix = "-client";
|
|
12
13
|
export declare const webhookSourceSuffix = "-webhook";
|
|
13
14
|
export declare function removeClientSource(source: string): EhrSource;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"source.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/ehr/source.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"source.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/ehr/source.ts"],"names":[],"mappings":"AAEA,oBAAY,UAAU;IACpB,MAAM,iBAAiB;IACvB,OAAO,YAAY;IACnB,MAAM,WAAW;IACjB,QAAQ,aAAa;IACrB,cAAc,mBAAmB;CAClC;AACD,eAAO,MAAM,UAAU,uBAA0C,CAAC;AAClE,MAAM,MAAM,SAAS,GAAG,CAAC,OAAO,UAAU,CAAC,CAAC,MAAM,CAAC,CAAC;AACpD,wBAAgB,WAAW,CAAC,MAAM,EAAE,MAAM,GAAG,MAAM,IAAI,SAAS,CAE/D;AAED,wBAAgB,oBAAoB,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,GAAG,SAAS,GAAG,SAAS,CAQtF;AAED,eAAO,MAAM,kBAAkB,YAAY,CAAC;AAC5C,eAAO,MAAM,mBAAmB,aAAa,CAAC;AAE9C,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAE5D;AAED,wBAAgB,mBAAmB,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,CAE7D"}
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.removeWebhookSource = exports.removeClientSource = exports.webhookSourceSuffix = exports.clientSourceSuffix = exports.isEhrSource = exports.ehrSources = exports.EhrSources = void 0;
|
|
3
|
+
exports.removeWebhookSource = exports.removeClientSource = exports.webhookSourceSuffix = exports.clientSourceSuffix = exports.parseEhrSourceOrFail = exports.isEhrSource = exports.ehrSources = exports.EhrSources = void 0;
|
|
4
|
+
const bad_request_1 = require("../../../error/bad-request");
|
|
4
5
|
var EhrSources;
|
|
5
6
|
(function (EhrSources) {
|
|
6
7
|
EhrSources["athena"] = "athenahealth";
|
|
@@ -14,6 +15,15 @@ function isEhrSource(source) {
|
|
|
14
15
|
return exports.ehrSources.includes(source);
|
|
15
16
|
}
|
|
16
17
|
exports.isEhrSource = isEhrSource;
|
|
18
|
+
function parseEhrSourceOrFail(source) {
|
|
19
|
+
if (!source)
|
|
20
|
+
return undefined;
|
|
21
|
+
if (!isEhrSource(source)) {
|
|
22
|
+
throw new bad_request_1.BadRequestError(`Invalid source: ${source}. Must be one of: ${exports.ehrSources.join(", ")}`);
|
|
23
|
+
}
|
|
24
|
+
return source;
|
|
25
|
+
}
|
|
26
|
+
exports.parseEhrSourceOrFail = parseEhrSourceOrFail;
|
|
17
27
|
exports.clientSourceSuffix = "-client";
|
|
18
28
|
exports.webhookSourceSuffix = "-webhook";
|
|
19
29
|
function removeClientSource(source) {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"source.js","sourceRoot":"","sources":["../../../../src/interface/external/ehr/source.ts"],"names":[],"mappings":";;;AAAA,IAAY,UAMX;AAND,WAAY,UAAU;IACpB,qCAAuB,CAAA;IACvB,iCAAmB,CAAA;IACnB,+BAAiB,CAAA;IACjB,mCAAqB,CAAA;IACrB,+CAAiC,CAAA;AACnC,CAAC,EANW,UAAU,GAAV,kBAAU,KAAV,kBAAU,QAMrB;AACY,QAAA,UAAU,GAAG,CAAC,GAAG,MAAM,CAAC,MAAM,CAAC,UAAU,CAAC,CAAU,CAAC;AAElE,SAAgB,WAAW,CAAC,MAAc;IACxC,OAAO,kBAAU,CAAC,QAAQ,CAAC,MAAmB,CAAC,CAAC;AAClD,CAAC;AAFD,kCAEC;AAEY,QAAA,kBAAkB,GAAG,SAAS,CAAC;AAC/B,QAAA,mBAAmB,GAAG,UAAU,CAAC;AAE9C,SAAgB,kBAAkB,CA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;AAED,SAAgB,mBAAmB,CAAC,MAAc;IAChD,OAAO,MAAM,CAAC,OAAO,CAAC,2BAAmB,EAAE,EAAE,CAAc,CAAC;AAC9D,CAAC;AAFD,kDAEC"}
|
|
@@ -0,0 +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;AAG5C,wBAAgB,OAAO,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,CAQ3D;AAED,wBAAgB,aAAa,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,CAKjE"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.isLoincCoding = exports.isLoinc = void 0;
|
|
4
|
+
const constants_1 = require("./constants");
|
|
5
|
+
function isLoinc(system) {
|
|
6
|
+
if (system?.toLowerCase().trim().includes(constants_1.LOINC_CODE) ||
|
|
7
|
+
system?.toLowerCase().trim().includes(constants_1.LOINC_OID)) {
|
|
8
|
+
return true;
|
|
9
|
+
}
|
|
10
|
+
return false;
|
|
11
|
+
}
|
|
12
|
+
exports.isLoinc = isLoinc;
|
|
13
|
+
function isLoincCoding(coding) {
|
|
14
|
+
if (isLoinc(coding?.system)) {
|
|
15
|
+
return true;
|
|
16
|
+
}
|
|
17
|
+
return false;
|
|
18
|
+
}
|
|
19
|
+
exports.isLoincCoding = isLoincCoding;
|
|
20
|
+
//# sourceMappingURL=coding.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"coding.js","sourceRoot":"","sources":["../../../src/medical/fhir/coding.ts"],"names":[],"mappings":";;;AACA,2CAAoD;AAEpD,SAAgB,OAAO,CAAC,MAA0B;IAChD,IACE,MAAM,EAAE,WAAW,EAAE,CAAC,IAAI,EAAE,CAAC,QAAQ,CAAC,sBAAU,CAAC;QACjD,MAAM,EAAE,WAAW,EAAE,CAAC,IAAI,EAAE,CAAC,QAAQ,CAAC,qBAAS,CAAC,EAChD;QACA,OAAO,IAAI,CAAC;KACb;IACD,OAAO,KAAK,CAAC;AACf,CAAC;AARD,0BAQC;AAED,SAAgB,aAAa,CAAC,MAA0B;IACtD,IAAI,OAAO,CAAC,MAAM,EAAE,MAAM,CAAC,EAAE;QAC3B,OAAO,IAAI,CAAC;KACb;IACD,OAAO,KAAK,CAAC;AACf,CAAC;AALD,sCAKC"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
export declare const SNOMED_CODE = "snomed";
|
|
2
|
+
export declare const SNOMED_URL = "http://snomed.info/sct";
|
|
3
|
+
export declare const SNOMED_OID = "2.16.840.1.113883.6.96";
|
|
4
|
+
export declare const LOINC_CODE = "loinc";
|
|
5
|
+
export declare const LOINC_URL = "http://loinc.org";
|
|
6
|
+
export declare const LOINC_OID = "2.16.840.1.113883.6.1";
|
|
7
|
+
export declare const ICD_10_CODE = "icd-10";
|
|
8
|
+
export declare const ICD_10_URL = "http://hl7.org/fhir/sid/icd-10-cm";
|
|
9
|
+
export declare const ICD_10_OID = "2.16.840.1.113883.6.90";
|
|
10
|
+
export declare const ICD_9_CODE = "icd-9";
|
|
11
|
+
export declare const ICD_9_URL = "http://terminology.hl7.org/CodeSystem/ICD-9CM-diagnosiscodes9";
|
|
12
|
+
export declare const RXNORM_CODE = "rxnorm";
|
|
13
|
+
export declare const RXNORM_URL = "http://www.nlm.nih.gov/research/umls/rxnorm";
|
|
14
|
+
export declare const RXNORM_OID = "2.16.840.1.113883.6.88";
|
|
15
|
+
export declare const NDC_CODE = "ndc";
|
|
16
|
+
export declare const NDC_URL = "http://hl7.org/fhir/sid/ndc";
|
|
17
|
+
export declare const NDC_OID = "2.16.840.1.113883.6.69";
|
|
18
|
+
export declare const CVX_CODE = "cvx";
|
|
19
|
+
export declare const CVX_URL = "http://hl7.org/fhir/sid/cvx";
|
|
20
|
+
export declare const CVX_OID = "2.16.840.1.113883.12.292";
|
|
21
|
+
export declare const CPT_CODE = "cpt";
|
|
22
|
+
export declare const CPT_URL = "http://www.ama-assn.org/go/cpt";
|
|
23
|
+
export declare const CPT_OID = "2.16.840.1.113883.6.12";
|
|
24
|
+
export declare const NDDF_URL = "http://terminology.hl7.org/CodeSystem/nddf";
|
|
25
|
+
export declare const HL7_ACT_URL = "http://terminology.hl7.org/CodeSystem/v3-ActCode";
|
|
26
|
+
export declare const EPIC_PARTIAL_URN = "1.2.840.114350.1.13";
|
|
27
|
+
export declare const HL7_PARTIAL_URN = "2.16.840.1.113883";
|
|
28
|
+
export declare const knownSystemUrls: string[];
|
|
29
|
+
//# sourceMappingURL=constants.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"constants.d.ts","sourceRoot":"","sources":["../../../src/medical/fhir/constants.ts"],"names":[],"mappings":"AAAA,eAAO,MAAM,WAAW,WAAW,CAAC;AACpC,eAAO,MAAM,UAAU,2BAA2B,CAAC;AACnD,eAAO,MAAM,UAAU,2BAA2B,CAAC;AAEnD,eAAO,MAAM,UAAU,UAAU,CAAC;AAClC,eAAO,MAAM,SAAS,qBAAqB,CAAC;AAC5C,eAAO,MAAM,SAAS,0BAA0B,CAAC;AAEjD,eAAO,MAAM,WAAW,WAAW,CAAC;AACpC,eAAO,MAAM,UAAU,sCAAsC,CAAC;AAC9D,eAAO,MAAM,UAAU,2BAA2B,CAAC;AAEnD,eAAO,MAAM,UAAU,UAAU,CAAC;AAClC,eAAO,MAAM,SAAS,kEAAkE,CAAC;AAEzF,eAAO,MAAM,WAAW,WAAW,CAAC;AACpC,eAAO,MAAM,UAAU,gDAAgD,CAAC;AACxE,eAAO,MAAM,UAAU,2BAA2B,CAAC;AAEnD,eAAO,MAAM,QAAQ,QAAQ,CAAC;AAC9B,eAAO,MAAM,OAAO,gCAAgC,CAAC;AACrD,eAAO,MAAM,OAAO,2BAA2B,CAAC;AAEhD,eAAO,MAAM,QAAQ,QAAQ,CAAC;AAC9B,eAAO,MAAM,OAAO,gCAAgC,CAAC;AACrD,eAAO,MAAM,OAAO,6BAA6B,CAAC;AAElD,eAAO,MAAM,QAAQ,QAAQ,CAAC;AAC9B,eAAO,MAAM,OAAO,mCAAmC,CAAC;AACxD,eAAO,MAAM,OAAO,2BAA2B,CAAC;AAEhD,eAAO,MAAM,QAAQ,+CAA+C,CAAC;AAErE,eAAO,MAAM,WAAW,qDAAqD,CAAC;AAE9E,eAAO,MAAM,gBAAgB,wBAAwB,CAAC;AACtD,eAAO,MAAM,eAAe,sBAAsB,CAAC;AAEnD,eAAO,MAAM,eAAe,UAU3B,CAAC"}
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.knownSystemUrls = exports.HL7_PARTIAL_URN = exports.EPIC_PARTIAL_URN = exports.HL7_ACT_URL = exports.NDDF_URL = exports.CPT_OID = exports.CPT_URL = exports.CPT_CODE = exports.CVX_OID = exports.CVX_URL = exports.CVX_CODE = exports.NDC_OID = exports.NDC_URL = exports.NDC_CODE = exports.RXNORM_OID = exports.RXNORM_URL = exports.RXNORM_CODE = exports.ICD_9_URL = exports.ICD_9_CODE = exports.ICD_10_OID = exports.ICD_10_URL = exports.ICD_10_CODE = exports.LOINC_OID = exports.LOINC_URL = exports.LOINC_CODE = exports.SNOMED_OID = exports.SNOMED_URL = exports.SNOMED_CODE = void 0;
|
|
4
|
+
exports.SNOMED_CODE = "snomed";
|
|
5
|
+
exports.SNOMED_URL = "http://snomed.info/sct";
|
|
6
|
+
exports.SNOMED_OID = "2.16.840.1.113883.6.96";
|
|
7
|
+
exports.LOINC_CODE = "loinc";
|
|
8
|
+
exports.LOINC_URL = "http://loinc.org";
|
|
9
|
+
exports.LOINC_OID = "2.16.840.1.113883.6.1";
|
|
10
|
+
exports.ICD_10_CODE = "icd-10";
|
|
11
|
+
exports.ICD_10_URL = "http://hl7.org/fhir/sid/icd-10-cm";
|
|
12
|
+
exports.ICD_10_OID = "2.16.840.1.113883.6.90";
|
|
13
|
+
exports.ICD_9_CODE = "icd-9";
|
|
14
|
+
exports.ICD_9_URL = "http://terminology.hl7.org/CodeSystem/ICD-9CM-diagnosiscodes9";
|
|
15
|
+
exports.RXNORM_CODE = "rxnorm";
|
|
16
|
+
exports.RXNORM_URL = "http://www.nlm.nih.gov/research/umls/rxnorm";
|
|
17
|
+
exports.RXNORM_OID = "2.16.840.1.113883.6.88";
|
|
18
|
+
exports.NDC_CODE = "ndc";
|
|
19
|
+
exports.NDC_URL = "http://hl7.org/fhir/sid/ndc";
|
|
20
|
+
exports.NDC_OID = "2.16.840.1.113883.6.69";
|
|
21
|
+
exports.CVX_CODE = "cvx";
|
|
22
|
+
exports.CVX_URL = "http://hl7.org/fhir/sid/cvx";
|
|
23
|
+
exports.CVX_OID = "2.16.840.1.113883.12.292";
|
|
24
|
+
exports.CPT_CODE = "cpt";
|
|
25
|
+
exports.CPT_URL = "http://www.ama-assn.org/go/cpt";
|
|
26
|
+
exports.CPT_OID = "2.16.840.1.113883.6.12";
|
|
27
|
+
exports.NDDF_URL = "http://terminology.hl7.org/CodeSystem/nddf";
|
|
28
|
+
exports.HL7_ACT_URL = "http://terminology.hl7.org/CodeSystem/v3-ActCode";
|
|
29
|
+
exports.EPIC_PARTIAL_URN = "1.2.840.114350.1.13";
|
|
30
|
+
exports.HL7_PARTIAL_URN = "2.16.840.1.113883";
|
|
31
|
+
exports.knownSystemUrls = [
|
|
32
|
+
exports.RXNORM_URL,
|
|
33
|
+
exports.NDC_URL,
|
|
34
|
+
exports.CPT_URL,
|
|
35
|
+
exports.CVX_URL,
|
|
36
|
+
exports.ICD_10_URL,
|
|
37
|
+
exports.ICD_9_URL,
|
|
38
|
+
exports.LOINC_URL,
|
|
39
|
+
exports.SNOMED_URL,
|
|
40
|
+
exports.HL7_ACT_URL,
|
|
41
|
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ACV,eAAO;IACP,eAAO;IACP,eAAO;IACP,kBAAU;IACV,iBAAS;IACT,iBAAS;IACT,kBAAU;IACV,mBAAW;CACZ,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
//# sourceMappingURL=system.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"system.d.ts","sourceRoot":"","sources":["../../../src/medical/fhir/system.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"system.js","sourceRoot":"","sources":["../../../src/medical/fhir/system.ts"],"names":[],"mappings":""}
|
package/dist/medical/index.d.ts
CHANGED
|
@@ -2,6 +2,8 @@ export * from "./fhir/bundle";
|
|
|
2
2
|
export * from "./fhir/conversion";
|
|
3
3
|
export * from "./fhir/observations";
|
|
4
4
|
export * from "./fhir/resources";
|
|
5
|
+
export * from "./fhir/coding";
|
|
6
|
+
export * from "./fhir/constants";
|
|
5
7
|
export * from "./webhook/webhook-request";
|
|
6
8
|
export * from "./webhook/webhook-status-response";
|
|
7
9
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -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,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,2BAA2B,CAAC;AAC1C,cAAc,mCAAmC,CAAC"}
|
package/dist/medical/index.js
CHANGED
|
@@ -18,6 +18,8 @@ __exportStar(require("./fhir/bundle"), exports);
|
|
|
18
18
|
__exportStar(require("./fhir/conversion"), exports);
|
|
19
19
|
__exportStar(require("./fhir/observations"), exports);
|
|
20
20
|
__exportStar(require("./fhir/resources"), exports);
|
|
21
|
+
__exportStar(require("./fhir/coding"), exports);
|
|
22
|
+
__exportStar(require("./fhir/constants"), exports);
|
|
21
23
|
__exportStar(require("./webhook/webhook-request"), exports);
|
|
22
24
|
__exportStar(require("./webhook/webhook-status-response"), exports);
|
|
23
25
|
//# sourceMappingURL=index.js.map
|
|
@@ -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,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,4DAA0C;AAC1C,oEAAkD"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@metriport/shared",
|
|
3
|
-
"version": "0.24.
|
|
3
|
+
"version": "0.24.7",
|
|
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/",
|
|
@@ -115,5 +115,5 @@
|
|
|
115
115
|
"ts-jest": "29.1.1",
|
|
116
116
|
"typescript": "^4.9.5"
|
|
117
117
|
},
|
|
118
|
-
"gitHead": "
|
|
118
|
+
"gitHead": "1f75d94ddd768bcc3387a70607220ea4cf9f2b79"
|
|
119
119
|
}
|