@metriport/shared 0.20.2 → 0.20.3

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 (59) hide show
  1. package/dist/domain/db.d.ts +2 -2
  2. package/dist/index.d.ts +6 -6
  3. package/dist/index.d.ts.map +1 -1
  4. package/dist/index.js +5 -5
  5. package/dist/index.js.map +1 -1
  6. package/dist/interface/external/ehr/athenahealth/appointment.d.ts +26 -4
  7. package/dist/interface/external/ehr/athenahealth/appointment.d.ts.map +1 -1
  8. package/dist/interface/external/ehr/athenahealth/appointment.js +7 -3
  9. package/dist/interface/external/ehr/athenahealth/appointment.js.map +1 -1
  10. package/dist/interface/external/ehr/athenahealth/cx-mapping.d.ts +3 -0
  11. package/dist/interface/external/ehr/athenahealth/cx-mapping.d.ts.map +1 -1
  12. package/dist/interface/external/ehr/athenahealth/cx-mapping.js +1 -0
  13. package/dist/interface/external/ehr/athenahealth/cx-mapping.js.map +1 -1
  14. package/dist/interface/external/ehr/canvas/appointment.d.ts +38 -20
  15. package/dist/interface/external/ehr/canvas/appointment.d.ts.map +1 -1
  16. package/dist/interface/external/ehr/canvas/appointment.js +6 -5
  17. package/dist/interface/external/ehr/canvas/appointment.js.map +1 -1
  18. package/dist/interface/external/ehr/elation/appointment.d.ts +5 -2
  19. package/dist/interface/external/ehr/elation/appointment.d.ts.map +1 -1
  20. package/dist/interface/external/ehr/elation/appointment.js +3 -2
  21. package/dist/interface/external/ehr/elation/appointment.js.map +1 -1
  22. package/dist/interface/external/ehr/elation/cx-mapping.d.ts +43 -0
  23. package/dist/interface/external/ehr/elation/cx-mapping.d.ts.map +1 -0
  24. package/dist/interface/external/ehr/elation/cx-mapping.js +19 -0
  25. package/dist/interface/external/ehr/elation/cx-mapping.js.map +1 -0
  26. package/dist/interface/external/ehr/elation/event.d.ts +106 -0
  27. package/dist/interface/external/ehr/elation/event.d.ts.map +1 -0
  28. package/dist/interface/external/ehr/elation/event.js +31 -0
  29. package/dist/interface/external/ehr/elation/event.js.map +1 -0
  30. package/dist/interface/external/ehr/elation/index.d.ts +1 -0
  31. package/dist/interface/external/ehr/elation/index.d.ts.map +1 -1
  32. package/dist/interface/external/ehr/elation/index.js +1 -0
  33. package/dist/interface/external/ehr/elation/index.js.map +1 -1
  34. package/dist/interface/external/ehr/elation/jwt-token.d.ts +0 -15
  35. package/dist/interface/external/ehr/elation/jwt-token.d.ts.map +1 -1
  36. package/dist/interface/external/ehr/elation/jwt-token.js +1 -7
  37. package/dist/interface/external/ehr/elation/jwt-token.js.map +1 -1
  38. package/dist/interface/external/ehr/elation/subscription.d.ts +53 -0
  39. package/dist/interface/external/ehr/elation/subscription.d.ts.map +1 -0
  40. package/dist/interface/external/ehr/elation/subscription.js +22 -0
  41. package/dist/interface/external/ehr/elation/subscription.js.map +1 -0
  42. package/dist/interface/external/ehr/patient.d.ts +12 -12
  43. package/package.json +2 -2
  44. package/dist/common/titleCase.d.ts +0 -2
  45. package/dist/common/titleCase.d.ts.map +0 -1
  46. package/dist/common/titleCase.js +0 -10
  47. package/dist/common/titleCase.js.map +0 -1
  48. package/dist/domain/address/__tests__/normalize-zip.test.d.ts +0 -2
  49. package/dist/domain/address/__tests__/normalize-zip.test.d.ts.map +0 -1
  50. package/dist/domain/address/__tests__/normalize-zip.test.js +0 -83
  51. package/dist/domain/address/__tests__/normalize-zip.test.js.map +0 -1
  52. package/dist/interface/external/athenahealth/patient.d.ts +0 -44
  53. package/dist/interface/external/athenahealth/patient.d.ts.map +0 -1
  54. package/dist/interface/external/athenahealth/patient.js +0 -15
  55. package/dist/interface/external/athenahealth/patient.js.map +0 -1
  56. package/dist/interface/external/elation/subscription.d.ts +0 -2
  57. package/dist/interface/external/elation/subscription.d.ts.map +0 -1
  58. package/dist/interface/external/elation/subscription.js +0 -3
  59. package/dist/interface/external/elation/subscription.js.map +0 -1
@@ -0,0 +1,106 @@
1
+ import { z } from "zod";
2
+ export declare const elationAppointmentEventSchema: z.ZodObject<{
3
+ event_id: z.ZodString;
4
+ application_id: z.ZodString;
5
+ resource: z.ZodLiteral<"appointments">;
6
+ action: z.ZodEnum<["saved", "deleted"]>;
7
+ data: z.ZodObject<{
8
+ id: z.ZodString;
9
+ patient: z.ZodString;
10
+ created_date: z.ZodString;
11
+ last_modified_date: z.ZodString;
12
+ status: z.ZodObject<{
13
+ status: z.ZodString;
14
+ }, "strip", z.ZodTypeAny, {
15
+ status: string;
16
+ }, {
17
+ status: string;
18
+ }>;
19
+ }, "strip", z.ZodTypeAny, {
20
+ status: {
21
+ status: string;
22
+ };
23
+ id: string;
24
+ patient: string;
25
+ created_date: string;
26
+ last_modified_date: string;
27
+ }, {
28
+ status: {
29
+ status: string;
30
+ };
31
+ id: string;
32
+ patient: string;
33
+ created_date: string;
34
+ last_modified_date: string;
35
+ }>;
36
+ }, "strip", z.ZodTypeAny, {
37
+ data: {
38
+ status: {
39
+ status: string;
40
+ };
41
+ id: string;
42
+ patient: string;
43
+ created_date: string;
44
+ last_modified_date: string;
45
+ };
46
+ resource: "appointments";
47
+ event_id: string;
48
+ application_id: string;
49
+ action: "saved" | "deleted";
50
+ }, {
51
+ data: {
52
+ status: {
53
+ status: string;
54
+ };
55
+ id: string;
56
+ patient: string;
57
+ created_date: string;
58
+ last_modified_date: string;
59
+ };
60
+ resource: "appointments";
61
+ event_id: string;
62
+ application_id: string;
63
+ action: "saved" | "deleted";
64
+ }>;
65
+ export type ElationAppointmentEvent = z.infer<typeof elationAppointmentEventSchema>;
66
+ export declare const elationPatientEventSchema: z.ZodObject<{
67
+ event_id: z.ZodString;
68
+ application_id: z.ZodString;
69
+ resource: z.ZodLiteral<"patients">;
70
+ action: z.ZodEnum<["saved", "deleted"]>;
71
+ data: z.ZodObject<{
72
+ id: z.ZodString;
73
+ created_date: z.ZodString;
74
+ last_modified: z.ZodString;
75
+ }, "strip", z.ZodTypeAny, {
76
+ id: string;
77
+ created_date: string;
78
+ last_modified: string;
79
+ }, {
80
+ id: string;
81
+ created_date: string;
82
+ last_modified: string;
83
+ }>;
84
+ }, "strip", z.ZodTypeAny, {
85
+ data: {
86
+ id: string;
87
+ created_date: string;
88
+ last_modified: string;
89
+ };
90
+ resource: "patients";
91
+ event_id: string;
92
+ application_id: string;
93
+ action: "saved" | "deleted";
94
+ }, {
95
+ data: {
96
+ id: string;
97
+ created_date: string;
98
+ last_modified: string;
99
+ };
100
+ resource: "patients";
101
+ event_id: string;
102
+ application_id: string;
103
+ action: "saved" | "deleted";
104
+ }>;
105
+ export type ElationPatientEvent = z.infer<typeof elationPatientEventSchema>;
106
+ //# sourceMappingURL=event.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"event.d.ts","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/elation/event.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,6BAA6B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAcxC,CAAC;AACH,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAC;AAEpF,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAUpC,CAAC;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAC"}
@@ -0,0 +1,31 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.elationPatientEventSchema = exports.elationAppointmentEventSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ exports.elationAppointmentEventSchema = zod_1.z.object({
6
+ event_id: zod_1.z.coerce.string(),
7
+ application_id: zod_1.z.string(),
8
+ resource: zod_1.z.literal("appointments"),
9
+ action: zod_1.z.enum(["saved", "deleted"]),
10
+ data: zod_1.z.object({
11
+ id: zod_1.z.coerce.string(),
12
+ patient: zod_1.z.coerce.string(),
13
+ created_date: zod_1.z.string(),
14
+ last_modified_date: zod_1.z.string(),
15
+ status: zod_1.z.object({
16
+ status: zod_1.z.string(),
17
+ }),
18
+ }),
19
+ });
20
+ exports.elationPatientEventSchema = zod_1.z.object({
21
+ event_id: zod_1.z.coerce.string(),
22
+ application_id: zod_1.z.string(),
23
+ resource: zod_1.z.literal("patients"),
24
+ action: zod_1.z.enum(["saved", "deleted"]),
25
+ data: zod_1.z.object({
26
+ id: zod_1.z.coerce.string(),
27
+ created_date: zod_1.z.string(),
28
+ last_modified: zod_1.z.string(),
29
+ }),
30
+ });
31
+ //# sourceMappingURL=event.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"event.js","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/elation/event.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAEX,QAAA,6BAA6B,GAAG,OAAC,CAAC,MAAM,CAAC;IACpD,QAAQ,EAAE,OAAC,CAAC,MAAM,CAAC,MAAM,EAAE;IAC3B,cAAc,EAAE,OAAC,CAAC,MAAM,EAAE;IAC1B,QAAQ,EAAE,OAAC,CAAC,OAAO,CAAC,cAAc,CAAC;IACnC,MAAM,EAAE,OAAC,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,SAAS,CAAC,CAAC;IACpC,IAAI,EAAE,OAAC,CAAC,MAAM,CAAC;QACb,EAAE,EAAE,OAAC,CAAC,MAAM,CAAC,MAAM,EAAE;QACrB,OAAO,EAAE,OAAC,CAAC,MAAM,CAAC,MAAM,EAAE;QAC1B,YAAY,EAAE,OAAC,CAAC,MAAM,EAAE;QACxB,kBAAkB,EAAE,OAAC,CAAC,MAAM,EAAE;QAC9B,MAAM,EAAE,OAAC,CAAC,MAAM,CAAC;YACf,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE;SACnB,CAAC;KACH,CAAC;CACH,CAAC,CAAC;AAGU,QAAA,yBAAyB,GAAG,OAAC,CAAC,MAAM,CAAC;IAChD,QAAQ,EAAE,OAAC,CAAC,MAAM,CAAC,MAAM,EAAE;IAC3B,cAAc,EAAE,OAAC,CAAC,MAAM,EAAE;IAC1B,QAAQ,EAAE,OAAC,CAAC,OAAO,CAAC,UAAU,CAAC;IAC/B,MAAM,EAAE,OAAC,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,SAAS,CAAC,CAAC;IACpC,IAAI,EAAE,OAAC,CAAC,MAAM,CAAC;QACb,EAAE,EAAE,OAAC,CAAC,MAAM,CAAC,MAAM,EAAE;QACrB,YAAY,EAAE,OAAC,CAAC,MAAM,EAAE;QACxB,aAAa,EAAE,OAAC,CAAC,MAAM,EAAE;KAC1B,CAAC;CACH,CAAC,CAAC"}
@@ -2,4 +2,5 @@ export * from "./appointment";
2
2
  export * from "./patient";
3
3
  export * from "./jwt-token";
4
4
  export * from "./problem";
5
+ export * from "./subscription";
5
6
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/elation/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,WAAW,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/elation/index.ts"],"names":[],"mappings":"AAAA,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,WAAW,CAAC;AAC1B,cAAc,gBAAgB,CAAC"}
@@ -18,4 +18,5 @@ __exportStar(require("./appointment"), exports);
18
18
  __exportStar(require("./patient"), exports);
19
19
  __exportStar(require("./jwt-token"), exports);
20
20
  __exportStar(require("./problem"), exports);
21
+ __exportStar(require("./subscription"), exports);
21
22
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/elation/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,gDAA8B;AAC9B,4CAA0B;AAC1B,8CAA4B;AAC5B,4CAA0B"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/elation/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,gDAA8B;AAC9B,4CAA0B;AAC1B,8CAA4B;AAC5B,4CAA0B;AAC1B,iDAA+B"}
@@ -30,21 +30,6 @@ export declare const elationClientJwtTokenDataSchema: z.ZodObject<{
30
30
  practiceId: string;
31
31
  }>;
32
32
  export type ElationClientJwtTokenData = z.infer<typeof elationClientJwtTokenDataSchema>;
33
- export declare const elationWebhookSource: "elation-webhook";
34
- export declare const elationWebhookJwtTokenDataSchema: z.ZodObject<{
35
- practiceId: z.ZodString;
36
- cxId: z.ZodString;
37
- source: z.ZodLiteral<"elation-webhook">;
38
- }, "strip", z.ZodTypeAny, {
39
- cxId: string;
40
- source: "elation-webhook";
41
- practiceId: string;
42
- }, {
43
- cxId: string;
44
- source: "elation-webhook";
45
- practiceId: string;
46
- }>;
47
- export type ElationWebhookJwtTokenData = z.infer<typeof elationWebhookJwtTokenDataSchema>;
48
33
  export declare const elationClientJwtTokenResponseSchema: z.ZodObject<{
49
34
  scope: z.ZodString;
50
35
  access_token: z.ZodString;
@@ -1 +1 @@
1
- {"version":3,"file":"jwt-token.d.ts","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/elation/jwt-token.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AACpB,OAAO,EAAE,UAAU,EAA2C,MAAM,WAAW,CAAC;AAEhF,eAAO,MAAM,iBAAiB,oBAA8B,CAAC;AAC7D,eAAO,MAAM,6BAA6B;;;;;;;;;;;;EAIxC,CAAC;AACH,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAC;AAEpF,eAAO,MAAM,mBAAmB,kBAAwD,CAAC;AACzF,eAAO,MAAM,+BAA+B;;;;;;;;;;;;EAI1C,CAAC;AACH,MAAM,MAAM,yBAAyB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAC;AAExF,eAAO,MAAM,oBAAoB,mBAAyD,CAAC;AAC3F,eAAO,MAAM,gCAAgC;;;;;;;;;;;;EAI3C,CAAC;AACH,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gCAAgC,CAAC,CAAC;AAE1F,eAAO,MAAM,mCAAmC;;;;;;;;;;;;EAI9C,CAAC"}
1
+ {"version":3,"file":"jwt-token.d.ts","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/elation/jwt-token.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AACpB,OAAO,EAAE,UAAU,EAAsB,MAAM,WAAW,CAAC;AAE3D,eAAO,MAAM,iBAAiB,oBAA8B,CAAC;AAC7D,eAAO,MAAM,6BAA6B;;;;;;;;;;;;EAIxC,CAAC;AACH,MAAM,MAAM,uBAAuB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,6BAA6B,CAAC,CAAC;AAEpF,eAAO,MAAM,mBAAmB,kBAAwD,CAAC;AACzF,eAAO,MAAM,+BAA+B;;;;;;;;;;;;EAI1C,CAAC;AACH,MAAM,MAAM,yBAAyB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAC;AAExF,eAAO,MAAM,mCAAmC;;;;;;;;;;;;EAI9C,CAAC"}
@@ -3,7 +3,7 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
3
3
  return (mod && mod.__esModule) ? mod : { "default": mod };
4
4
  };
5
5
  Object.defineProperty(exports, "__esModule", { value: true });
6
- exports.elationClientJwtTokenResponseSchema = exports.elationWebhookJwtTokenDataSchema = exports.elationWebhookSource = exports.elationClientJwtTokenDataSchema = exports.elationClientSource = exports.elationDashJwtTokenDataSchema = exports.elationDashSource = void 0;
6
+ exports.elationClientJwtTokenResponseSchema = exports.elationClientJwtTokenDataSchema = exports.elationClientSource = exports.elationDashJwtTokenDataSchema = exports.elationDashSource = void 0;
7
7
  const zod_1 = __importDefault(require("zod"));
8
8
  const source_1 = require("../source");
9
9
  exports.elationDashSource = source_1.EhrSources.elation;
@@ -18,12 +18,6 @@ exports.elationClientJwtTokenDataSchema = zod_1.default.object({
18
18
  cxId: zod_1.default.string(),
19
19
  source: zod_1.default.literal(`${exports.elationClientSource}`),
20
20
  });
21
- exports.elationWebhookSource = `${source_1.EhrSources.elation}${source_1.webhookSourceSuffix}`;
22
- exports.elationWebhookJwtTokenDataSchema = zod_1.default.object({
23
- practiceId: zod_1.default.string(),
24
- cxId: zod_1.default.string(),
25
- source: zod_1.default.literal(`${exports.elationWebhookSource}`),
26
- });
27
21
  exports.elationClientJwtTokenResponseSchema = zod_1.default.object({
28
22
  scope: zod_1.default.string(),
29
23
  access_token: zod_1.default.string(),
@@ -1 +1 @@
1
- {"version":3,"file":"jwt-token.js","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/elation/jwt-token.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAoB;AACpB,sCAAgF;AAEnE,QAAA,iBAAiB,GAAG,mBAAU,CAAC,OAAgB,CAAC;AAChD,QAAA,6BAA6B,GAAG,aAAC,CAAC,MAAM,CAAC;IACpD,UAAU,EAAE,aAAC,CAAC,MAAM,EAAE;IACtB,SAAS,EAAE,aAAC,CAAC,MAAM,EAAE;IACrB,MAAM,EAAE,aAAC,CAAC,OAAO,CAAC,GAAG,yBAAiB,EAAE,CAAC;CAC1C,CAAC,CAAC;AAGU,QAAA,mBAAmB,GAAG,GAAG,mBAAU,CAAC,OAAO,GAAG,2BAAkB,EAAW,CAAC;AAC5E,QAAA,+BAA+B,GAAG,aAAC,CAAC,MAAM,CAAC;IACtD,UAAU,EAAE,aAAC,CAAC,MAAM,EAAE;IACtB,IAAI,EAAE,aAAC,CAAC,MAAM,EAAE;IAChB,MAAM,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AC,OAAO,CAAC,GAAG,2BAAmB,EAAE,CAAC;CAC5C,CAAC,CAAC;AAGU,QAAA,mCAAmC,GAAG,aAAC,CAAC,MAAM,CAAC;IAC1D,KAAK,EAAE,aAAC,CAAC,MAAM,EAAE;IACjB,YAAY,EAAE,aAAC,CAAC,MAAM,EAAE;IACxB,UAAU,EAAE,aAAC,CAAC,MAAM,CAAC,MAAM,EAAE;CAC9B,CAAC,CAAC"}
@@ -0,0 +1,53 @@
1
+ import { z } from "zod";
2
+ export declare const subscriptionResources: readonly ["appointments", "patients"];
3
+ export type SubscriptionResource = (typeof subscriptionResources)[number];
4
+ export declare function isSubscriptionResource(resource: string): resource is SubscriptionResource;
5
+ export declare const subscriptionSchema: z.ZodObject<{
6
+ id: z.ZodString;
7
+ resource: z.ZodEnum<["appointments", "patients"]>;
8
+ }, "strip", z.ZodTypeAny, {
9
+ id: string;
10
+ resource: "patients" | "appointments";
11
+ }, {
12
+ id: string;
13
+ resource: "patients" | "appointments";
14
+ }>;
15
+ export type Subscription = z.infer<typeof subscriptionSchema>;
16
+ export declare const subscriptionsSchema: z.ZodObject<{
17
+ results: z.ZodArray<z.ZodObject<{
18
+ id: z.ZodString;
19
+ resource: z.ZodEnum<["appointments", "patients"]>;
20
+ }, "strip", z.ZodTypeAny, {
21
+ id: string;
22
+ resource: "patients" | "appointments";
23
+ }, {
24
+ id: string;
25
+ resource: "patients" | "appointments";
26
+ }>, "many">;
27
+ }, "strip", z.ZodTypeAny, {
28
+ results: {
29
+ id: string;
30
+ resource: "patients" | "appointments";
31
+ }[];
32
+ }, {
33
+ results: {
34
+ id: string;
35
+ resource: "patients" | "appointments";
36
+ }[];
37
+ }>;
38
+ export type Subscriptions = z.infer<typeof subscriptionsSchema>;
39
+ export declare const createdSubscriptionSchema: z.ZodObject<{
40
+ resource: z.ZodEnum<["appointments", "patients"]>;
41
+ target: z.ZodString;
42
+ signing_pub_key: z.ZodString;
43
+ }, "strip", z.ZodTypeAny, {
44
+ resource: "patients" | "appointments";
45
+ target: string;
46
+ signing_pub_key: string;
47
+ }, {
48
+ resource: "patients" | "appointments";
49
+ target: string;
50
+ signing_pub_key: string;
51
+ }>;
52
+ export type CreatedSubscription = z.infer<typeof createdSubscriptionSchema>;
53
+ //# sourceMappingURL=subscription.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"subscription.d.ts","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/elation/subscription.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,qBAAqB,uCAAwC,CAAC;AAC3E,MAAM,MAAM,oBAAoB,GAAG,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,CAAC,CAAC;AAC1E,wBAAgB,sBAAsB,CAAC,QAAQ,EAAE,MAAM,GAAG,QAAQ,IAAI,oBAAoB,CAEzF;AAED,eAAO,MAAM,kBAAkB;;;;;;;;;EAG7B,CAAC;AACH,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC;AAC9D,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;EAE9B,CAAC;AACH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEhE,eAAO,MAAM,yBAAyB;;;;;;;;;;;;EAIpC,CAAC;AACH,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,yBAAyB,CAAC,CAAC"}
@@ -0,0 +1,22 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.createdSubscriptionSchema = exports.subscriptionsSchema = exports.subscriptionSchema = exports.isSubscriptionResource = exports.subscriptionResources = void 0;
4
+ const zod_1 = require("zod");
5
+ exports.subscriptionResources = ["appointments", "patients"];
6
+ function isSubscriptionResource(resource) {
7
+ return exports.subscriptionResources.includes(resource);
8
+ }
9
+ exports.isSubscriptionResource = isSubscriptionResource;
10
+ exports.subscriptionSchema = zod_1.z.object({
11
+ id: zod_1.z.coerce.string(),
12
+ resource: zod_1.z.enum(exports.subscriptionResources),
13
+ });
14
+ exports.subscriptionsSchema = zod_1.z.object({
15
+ results: exports.subscriptionSchema.array(),
16
+ });
17
+ exports.createdSubscriptionSchema = zod_1.z.object({
18
+ resource: zod_1.z.enum(exports.subscriptionResources),
19
+ target: zod_1.z.string(),
20
+ signing_pub_key: zod_1.z.string(),
21
+ });
22
+ //# sourceMappingURL=subscription.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"subscription.js","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/elation/subscription.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAEX,QAAA,qBAAqB,GAAG,CAAC,cAAc,EAAE,UAAU,CAAU,CAAC;AAE3E,SAAgB,sBAAsB,CAAC,QAAgB;IACrD,OAAO,6BAAqB,CAAC,QAAQ,CAAC,QAAgC,CAAC,CAAC;AAC1E,CAAC;AAFD,wDAEC;AAEY,QAAA,kBAAkB,GAAG,OAAC,CAAC,MAAM,CAAC;IACzC,EAAE,EAAE,OAAC,CAAC,MAAM,CAAC,MAAM,EAAE;IACrB,QAAQ,EAAE,OAAC,CAAC,IAAI,CAAC,6BAAqB,CAAC;CACxC,CAAC,CAAC;AAEU,QAAA,mBAAmB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC1C,OAAO,EAAE,0BAAkB,CAAC,KAAK,EAAE;CACpC,CAAC,CAAC;AAGU,QAAA,yBAAyB,GAAG,OAAC,CAAC,MAAM,CAAC;IAChD,QAAQ,EAAE,OAAC,CAAC,IAAI,CAAC,6BAAqB,CAAC;IACvC,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE;IAClB,eAAe,EAAE,OAAC,CAAC,MAAM,EAAE;CAC5B,CAAC,CAAC"}
@@ -18,14 +18,14 @@ export declare const patientSchema: z.ZodObject<{
18
18
  postalCode: z.ZodOptional<z.ZodString>;
19
19
  country: z.ZodOptional<z.ZodString>;
20
20
  }, "strip", z.ZodTypeAny, {
21
- state?: string | undefined;
22
21
  country?: string | undefined;
22
+ state?: string | undefined;
23
23
  city?: string | undefined;
24
24
  line?: string[] | undefined;
25
25
  postalCode?: string | undefined;
26
26
  }, {
27
- state?: string | undefined;
28
27
  country?: string | undefined;
28
+ state?: string | undefined;
29
29
  city?: string | undefined;
30
30
  line?: string[] | undefined;
31
31
  postalCode?: string | undefined;
@@ -49,8 +49,8 @@ export declare const patientSchema: z.ZodObject<{
49
49
  given?: string[] | undefined;
50
50
  }[] | undefined;
51
51
  address?: {
52
- state?: string | undefined;
53
52
  country?: string | undefined;
53
+ state?: string | undefined;
54
54
  city?: string | undefined;
55
55
  line?: string[] | undefined;
56
56
  postalCode?: string | undefined;
@@ -67,8 +67,8 @@ export declare const patientSchema: z.ZodObject<{
67
67
  given?: string[] | undefined;
68
68
  }[] | undefined;
69
69
  address?: {
70
- state?: string | undefined;
71
70
  country?: string | undefined;
71
+ state?: string | undefined;
72
72
  city?: string | undefined;
73
73
  line?: string[] | undefined;
74
74
  postalCode?: string | undefined;
@@ -100,14 +100,14 @@ export declare const patientSearchSchema: z.ZodObject<{
100
100
  postalCode: z.ZodOptional<z.ZodString>;
101
101
  country: z.ZodOptional<z.ZodString>;
102
102
  }, "strip", z.ZodTypeAny, {
103
- state?: string | undefined;
104
103
  country?: string | undefined;
104
+ state?: string | undefined;
105
105
  city?: string | undefined;
106
106
  line?: string[] | undefined;
107
107
  postalCode?: string | undefined;
108
108
  }, {
109
- state?: string | undefined;
110
109
  country?: string | undefined;
110
+ state?: string | undefined;
111
111
  city?: string | undefined;
112
112
  line?: string[] | undefined;
113
113
  postalCode?: string | undefined;
@@ -131,8 +131,8 @@ export declare const patientSearchSchema: z.ZodObject<{
131
131
  given?: string[] | undefined;
132
132
  }[] | undefined;
133
133
  address?: {
134
- state?: string | undefined;
135
134
  country?: string | undefined;
135
+ state?: string | undefined;
136
136
  city?: string | undefined;
137
137
  line?: string[] | undefined;
138
138
  postalCode?: string | undefined;
@@ -149,8 +149,8 @@ export declare const patientSearchSchema: z.ZodObject<{
149
149
  given?: string[] | undefined;
150
150
  }[] | undefined;
151
151
  address?: {
152
- state?: string | undefined;
153
152
  country?: string | undefined;
153
+ state?: string | undefined;
154
154
  city?: string | undefined;
155
155
  line?: string[] | undefined;
156
156
  postalCode?: string | undefined;
@@ -169,8 +169,8 @@ export declare const patientSearchSchema: z.ZodObject<{
169
169
  given?: string[] | undefined;
170
170
  }[] | undefined;
171
171
  address?: {
172
- state?: string | undefined;
173
172
  country?: string | undefined;
173
+ state?: string | undefined;
174
174
  city?: string | undefined;
175
175
  line?: string[] | undefined;
176
176
  postalCode?: string | undefined;
@@ -189,8 +189,8 @@ export declare const patientSearchSchema: z.ZodObject<{
189
189
  given?: string[] | undefined;
190
190
  }[] | undefined;
191
191
  address?: {
192
- state?: string | undefined;
193
192
  country?: string | undefined;
193
+ state?: string | undefined;
194
194
  city?: string | undefined;
195
195
  line?: string[] | undefined;
196
196
  postalCode?: string | undefined;
@@ -211,8 +211,8 @@ export declare const patientSearchSchema: z.ZodObject<{
211
211
  given?: string[] | undefined;
212
212
  }[] | undefined;
213
213
  address?: {
214
- state?: string | undefined;
215
214
  country?: string | undefined;
215
+ state?: string | undefined;
216
216
  city?: string | undefined;
217
217
  line?: string[] | undefined;
218
218
  postalCode?: string | undefined;
@@ -233,8 +233,8 @@ export declare const patientSearchSchema: z.ZodObject<{
233
233
  given?: string[] | undefined;
234
234
  }[] | undefined;
235
235
  address?: {
236
- state?: string | undefined;
237
236
  country?: string | undefined;
237
+ state?: string | undefined;
238
238
  city?: string | undefined;
239
239
  line?: string[] | undefined;
240
240
  postalCode?: string | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@metriport/shared",
3
- "version": "0.20.2",
3
+ "version": "0.20.3",
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/",
@@ -101,5 +101,5 @@
101
101
  "ts-jest": "29.1.1",
102
102
  "typescript": "^4.9.5"
103
103
  },
104
- "gitHead": "a7e0df6f4f0e389bb6151ae131dc72a8e987aa9d"
104
+ "gitHead": "3a485fbe1005f9ef08b992468ee15b5b5353eeeb"
105
105
  }
@@ -1,2 +0,0 @@
1
- export declare function toTitleCase(str: string): string;
2
- //# sourceMappingURL=titleCase.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"titleCase.d.ts","sourceRoot":"","sources":["../../src/common/titleCase.ts"],"names":[],"mappings":"AAEA,wBAAgB,WAAW,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAG/C"}
@@ -1,10 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.toTitleCase = void 0;
4
- const lodash_1 = require("lodash");
5
- function toTitleCase(str) {
6
- const trimmedStr = str.trim();
7
- return (0, lodash_1.startCase)(trimmedStr.toLowerCase());
8
- }
9
- exports.toTitleCase = toTitleCase;
10
- //# sourceMappingURL=titleCase.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"titleCase.js","sourceRoot":"","sources":["../../src/common/titleCase.ts"],"names":[],"mappings":";;;AAAA,mCAAmC;AAEnC,SAAgB,WAAW,CAAC,GAAW;IACrC,MAAM,UAAU,GAAG,GAAG,CAAC,IAAI,EAAE,CAAC;IAC9B,OAAO,IAAA,kBAAS,EAAC,UAAU,CAAC,WAAW,EAAE,CAAC,CAAC;AAC7C,CAAC;AAHD,kCAGC"}
@@ -1,2 +0,0 @@
1
- export {};
2
- //# sourceMappingURL=normalize-zip.test.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"normalize-zip.test.d.ts","sourceRoot":"","sources":["../../../../src/domain/address/__tests__/normalize-zip.test.ts"],"names":[],"mappings":""}
@@ -1,83 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- const faker_1 = require("@faker-js/faker");
4
- const zip_1 = require("../zip");
5
- function getFiveDigitZip() {
6
- return faker_1.faker.number.int({ min: 10000, max: 99999 }).toString();
7
- }
8
- describe("zip", () => {
9
- describe("normalizeZipCodeNew", () => {
10
- it("returns the result of the normalizeFn param", () => {
11
- const expectedOutput = getFiveDigitZip();
12
- const normalizeFn = jest.fn(() => expectedOutput);
13
- expect((0, zip_1.normalizeZipCodeNew)("54321", normalizeFn)).toBe(expectedOutput);
14
- });
15
- it("should throw an error if zip is an empty string", () => {
16
- const normalizeFn = jest.fn(() => undefined);
17
- expect(() => (0, zip_1.normalizeZipCodeNew)("54321", normalizeFn)).toThrow();
18
- });
19
- });
20
- describe("safe normalizeZipCodeNewSafe", () => {
21
- it("should return undefined when it gets empty string", () => {
22
- const input = "";
23
- const expectedOutput = undefined;
24
- expect((0, zip_1.normalizeZipCodeNewSafe)(input)).toBe(expectedOutput);
25
- });
26
- it("should return undefined when it gets space", () => {
27
- const input = " ";
28
- const expectedOutput = undefined;
29
- expect((0, zip_1.normalizeZipCodeNewSafe)(input)).toBe(expectedOutput);
30
- });
31
- it("should handle 5 digits", () => {
32
- const input = getFiveDigitZip();
33
- const expectedOutput = input;
34
- expect((0, zip_1.normalizeZipCodeNewSafe)(input)).toBe(expectedOutput);
35
- });
36
- it("should trim input prefix", () => {
37
- const expectedOutput = getFiveDigitZip();
38
- const input = " " + expectedOutput;
39
- expect((0, zip_1.normalizeZipCodeNewSafe)(input)).toBe(expectedOutput);
40
- });
41
- it("should trim input suffix", () => {
42
- const expectedOutput = getFiveDigitZip();
43
- const input = expectedOutput + " ";
44
- expect((0, zip_1.normalizeZipCodeNewSafe)(input)).toBe(expectedOutput);
45
- });
46
- it("should return undefined for zip codes that are too short", () => {
47
- const input = "12";
48
- expect((0, zip_1.normalizeZipCodeNewSafe)(input)).toBeUndefined();
49
- });
50
- it("should handle short zip codes", () => {
51
- const input = "123";
52
- const expectedOutput = "00123";
53
- expect((0, zip_1.normalizeZipCodeNewSafe)(input)).toBe(expectedOutput);
54
- });
55
- it("should return padded first 4 characters when contains dash at position 4", () => {
56
- const input = "1234-6677";
57
- const expectedOutput = "01234";
58
- expect((0, zip_1.normalizeZipCodeNewSafe)(input)).toBe(expectedOutput);
59
- });
60
- it("should return first 5 characters when zip code length is 10", () => {
61
- const input = "12345-6677";
62
- const expectedOutput = "12345";
63
- expect((0, zip_1.normalizeZipCodeNewSafe)(input)).toBe(expectedOutput);
64
- });
65
- it("should return undefined if zip contains non-digit and non-dash characters (length 9)", () => {
66
- const input = "12345-667a";
67
- expect((0, zip_1.normalizeZipCodeNewSafe)(input)).toBeUndefined();
68
- });
69
- it("should return undefined if zip contains non-digit and non-dash characters (length 5)", () => {
70
- const input = "1234a";
71
- expect((0, zip_1.normalizeZipCodeNewSafe)(input)).toBeUndefined();
72
- });
73
- describe("examples from the wild", () => {
74
- const tests = [{ input: "2468", expectedOutput: "02468" }];
75
- for (const { input, expectedOutput } of tests) {
76
- it(`should return ${expectedOutput} when input is ${input}`, () => {
77
- expect((0, zip_1.normalizeZipCodeNewSafe)(input)).toBe(expectedOutput);
78
- });
79
- }
80
- });
81
- });
82
- });
83
- //# sourceMappingURL=normalize-zip.test.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"normalize-zip.test.js","sourceRoot":"","sources":["../../../../src/domain/address/__tests__/normalize-zip.test.ts"],"names":[],"mappings":";;AAAA,2CAAwC;AACxC,gCAAsE;AAEtE,SAAS,eAAe;IACtB,OAAO,aAAK,CAAC,MAAM,CAAC,GAAG,CAAC,EAAE,GAAG,EAAE,KAAK,EAAE,GAAG,EAAE,KAAK,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC;AACjE,CAAC;AAED,QAAQ,CAAC,KAAK,EAAE,GAAG,EAAE;IACnB,QAAQ,CAAC,qBAAqB,EAAE,GAAG,EAAE;QACnC,EAAE,CAAC,6CAA6C,EAAE,GAAG,EAAE;YACrD,MAAM,cAAc,GAAG,eAAe,EAAE,CA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,EAAE;YACrE,MAAM,KAAK,GAAG,YAAY,CAAC;YAC3B,MAAM,cAAc,GAAG,OAAO,CAAC;YAC/B,MAAM,CAAC,IAAA,6BAAuB,EAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC;QAC9D,CAAC,CAAC,CAAC;QAEH,EAAE,CAAC,sFAAsF,EAAE,GAAG,EAAE;YAC9F,MAAM,KAAK,GAAG,YAAY,CAAC;YAC3B,MAAM,CAAC,IAAA,6BAAuB,EAAC,KAAK,CAAC,CAAC,CAAC,aAAa,EAAE,CAAC;QACzD,CAAC,CAAC,CAAC;QAEH,EAAE,CAAC,sFAAsF,EAAE,GAAG,EAAE;YAC9F,MAAM,KAAK,GAAG,OAAO,CAAC;YACtB,MAAM,CAAC,IAAA,6BAAuB,EAAC,KAAK,CAAC,CAAC,CAAC,aAAa,EAAE,CAAC;QACzD,CAAC,CAAC,CAAC;QAEH,QAAQ,CAAC,wBAAwB,EAAE,GAAG,EAAE;YACtC,MAAM,KAAK,GAAG,CAAC,EAAE,KAAK,EAAE,MAAM,EAAE,cAAc,EAAE,OAAO,EAAE,CAAC,CAAC;YAC3D,KAAK,MAAM,EAAE,KAAK,EAAE,cAAc,EAAE,IAAI,KAAK,EAAE;gBAC7C,EAAE,CAAC,iBAAiB,cAAc,kBAAkB,KAAK,EAAE,EAAE,GAAG,EAAE;oBAChE,MAAM,CAAC,IAAA,6BAAuB,EAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC;gBAC9D,CAAC,CAAC,CAAC;aACJ;QACH,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;AACL,CAAC,CAAC,CAAC"}
@@ -1,44 +0,0 @@
1
- import { z } from "zod";
2
- export declare const patientCustomFieldSchema: z.ZodObject<{
3
- customfieldid: z.ZodString;
4
- customfieldvalue: z.ZodString;
5
- optionid: z.ZodOptional<z.ZodString>;
6
- }, "strip", z.ZodTypeAny, {
7
- customfieldid: string;
8
- customfieldvalue: string;
9
- optionid?: string | undefined;
10
- }, {
11
- customfieldid: string;
12
- customfieldvalue: string;
13
- optionid?: string | undefined;
14
- }>;
15
- export type PatientCustomField = z.infer<typeof patientCustomFieldSchema>;
16
- export declare const patientsCustomFieldsSchema: z.ZodArray<z.ZodObject<{
17
- customfields: z.ZodArray<z.ZodObject<{
18
- customfieldid: z.ZodString;
19
- customfieldvalue: z.ZodString;
20
- optionid: z.ZodOptional<z.ZodString>;
21
- }, "strip", z.ZodTypeAny, {
22
- customfieldid: string;
23
- customfieldvalue: string;
24
- optionid?: string | undefined;
25
- }, {
26
- customfieldid: string;
27
- customfieldvalue: string;
28
- optionid?: string | undefined;
29
- }>, "many">;
30
- }, "strip", z.ZodTypeAny, {
31
- customfields: {
32
- customfieldid: string;
33
- customfieldvalue: string;
34
- optionid?: string | undefined;
35
- }[];
36
- }, {
37
- customfields: {
38
- customfieldid: string;
39
- customfieldvalue: string;
40
- optionid?: string | undefined;
41
- }[];
42
- }>, "many">;
43
- export type PatientsCustomFields = z.infer<typeof patientsCustomFieldsSchema>;
44
- //# sourceMappingURL=patient.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"patient.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/athenahealth/patient.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,wBAAwB;;;;;;;;;;;;EAInC,CAAC;AACH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAC1E,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;;;;;;;;;;;WAI7B,CAAC;AACX,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,0BAA0B,CAAC,CAAC"}
@@ -1,15 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.patientsCustomFieldsSchema = exports.patientCustomFieldSchema = void 0;
4
- const zod_1 = require("zod");
5
- exports.patientCustomFieldSchema = zod_1.z.object({
6
- customfieldid: zod_1.z.string(),
7
- customfieldvalue: zod_1.z.string(),
8
- optionid: zod_1.z.string().optional(),
9
- });
10
- exports.patientsCustomFieldsSchema = zod_1.z
11
- .object({
12
- customfields: exports.patientCustomFieldSchema.array(),
13
- })
14
- .array();
15
- //# sourceMappingURL=patient.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"patient.js","sourceRoot":"","sources":["../../../../src/interface/external/athenahealth/patient.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAEX,QAAA,wBAAwB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC/C,aAAa,EAAE,OAAC,CAAC,MAAM,EAAE;IACzB,gBAAgB,EAAE,OAAC,CAAC,MAAM,EAAE;IAC5B,QAAQ,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAChC,CAAC,CAAC;AAEU,QAAA,0BAA0B,GAAG,OAAC;KACxC,MAAM,CAAC;IACN,YAAY,EAAE,gCAAwB,CAAC,KAAK,EAAE;CAC/C,CAAC;KACD,KAAK,EAAE,CAAC"}
@@ -1,2 +0,0 @@
1
- export type Resource = "appointments";
2
- //# sourceMappingURL=subscription.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"subscription.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/elation/subscription.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,QAAQ,GAAG,cAAc,CAAC"}