@metriport/shared 0.20.1-alpha.0 → 0.20.2

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 (51) hide show
  1. package/dist/common/titleCase.d.ts +2 -0
  2. package/dist/common/titleCase.d.ts.map +1 -0
  3. package/dist/common/titleCase.js +10 -0
  4. package/dist/common/titleCase.js.map +1 -0
  5. package/dist/domain/address/__tests__/normalize-zip.test.d.ts +2 -0
  6. package/dist/domain/address/__tests__/normalize-zip.test.d.ts.map +1 -0
  7. package/dist/domain/address/__tests__/normalize-zip.test.js +83 -0
  8. package/dist/domain/address/__tests__/normalize-zip.test.js.map +1 -0
  9. package/dist/domain/db.d.ts +58 -0
  10. package/dist/domain/db.d.ts.map +1 -0
  11. package/dist/domain/db.js +25 -0
  12. package/dist/domain/db.js.map +1 -0
  13. package/dist/index.d.ts +1 -0
  14. package/dist/index.d.ts.map +1 -1
  15. package/dist/index.js +1 -0
  16. package/dist/index.js.map +1 -1
  17. package/dist/interface/external/athenahealth/index.d.ts +0 -1
  18. package/dist/interface/external/athenahealth/index.d.ts.map +1 -1
  19. package/dist/interface/external/athenahealth/index.js +0 -1
  20. package/dist/interface/external/athenahealth/index.js.map +1 -1
  21. package/dist/interface/external/canvas/appointment.d.ts +48 -132
  22. package/dist/interface/external/canvas/appointment.d.ts.map +1 -1
  23. package/dist/interface/external/canvas/appointment.js +8 -16
  24. package/dist/interface/external/canvas/appointment.js.map +1 -1
  25. package/dist/interface/external/canvas/jwt-token.d.ts +0 -14
  26. package/dist/interface/external/canvas/jwt-token.d.ts.map +1 -1
  27. package/dist/interface/external/canvas/jwt-token.js +1 -6
  28. package/dist/interface/external/canvas/jwt-token.js.map +1 -1
  29. package/dist/interface/external/ehr/elation/index.d.ts +1 -0
  30. package/dist/interface/external/ehr/elation/index.d.ts.map +1 -1
  31. package/dist/interface/external/ehr/elation/index.js +1 -0
  32. package/dist/interface/external/ehr/elation/index.js.map +1 -1
  33. package/dist/interface/external/ehr/elation/jwt-token.d.ts +16 -0
  34. package/dist/interface/external/ehr/elation/jwt-token.d.ts.map +1 -1
  35. package/dist/interface/external/ehr/elation/jwt-token.js +7 -1
  36. package/dist/interface/external/ehr/elation/jwt-token.js.map +1 -1
  37. package/dist/interface/external/ehr/elation/problem.d.ts +10 -0
  38. package/dist/interface/external/ehr/elation/problem.d.ts.map +1 -0
  39. package/dist/interface/external/ehr/elation/problem.js +8 -0
  40. package/dist/interface/external/ehr/elation/problem.js.map +1 -0
  41. package/dist/interface/external/elation/jwt-token.d.ts +0 -14
  42. package/dist/interface/external/elation/jwt-token.d.ts.map +1 -1
  43. package/dist/interface/external/elation/jwt-token.js +1 -6
  44. package/dist/interface/external/elation/jwt-token.js.map +1 -1
  45. package/dist/interface/external/elation/patient.d.ts +10 -10
  46. package/dist/interface/external/elation/subscription.d.ts +2 -0
  47. package/dist/interface/external/elation/subscription.d.ts.map +1 -0
  48. package/dist/interface/external/elation/subscription.js +3 -0
  49. package/dist/interface/external/elation/subscription.js.map +1 -0
  50. package/dist/interface/external/shared/ehr/patient.d.ts +44 -44
  51. package/package.json +2 -2
@@ -0,0 +1,2 @@
1
+ export declare function toTitleCase(str: string): string;
2
+ //# sourceMappingURL=titleCase.d.ts.map
@@ -0,0 +1 @@
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"}
@@ -0,0 +1,10 @@
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
@@ -0,0 +1 @@
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"}
@@ -0,0 +1,2 @@
1
+ export {};
2
+ //# sourceMappingURL=normalize-zip.test.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"normalize-zip.test.d.ts","sourceRoot":"","sources":["../../../../src/domain/address/__tests__/normalize-zip.test.ts"],"names":[],"mappings":""}
@@ -0,0 +1,83 @@
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
@@ -0,0 +1 @@
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,CAAC;YACzC,MAAM,WAAW,GAAG,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,cAAc,CAAC,CAAC;YAClD,MAAM,CAAC,IAAA,yBAAmB,EAAC,OAAO,EAAE,WAAW,CAAC,CAAC,CAAC,IAAI,CAAC,cAAc,CAAC,CAAC;QACzE,CAAC,CAAC,CAAC;QAEH,EAAE,CAAC,iDAAiD,EAAE,GAAG,EAAE;YACzD,MAAM,WAAW,GAAG,IAAI,CAAC,EAAE,CAAC,GAAG,EAAE,CAAC,SAAS,CAAC,CAAC;YAC7C,MAAM,CAAC,GAAG,EAAE,CAAC,IAAA,yBAAmB,EAAC,OAAO,EAAE,WAAW,CAAC,CAAC,CAAC,OAAO,EAAE,CAAC;QACpE,CAAC,CAAC,CAAC;IACL,CAAC,CAAC,CAAC;IAEH,QAAQ,CAAC,8BAA8B,EAAE,GAAG,EAAE;QAC5C,EAAE,CAAC,mDAAmD,EAAE,GAAG,EAAE;YAC3D,MAAM,KAAK,GAAG,EAA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,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"}
@@ -0,0 +1,58 @@
1
+ import { z } from "zod";
2
+ import { Dialect } from "sequelize";
3
+ export declare const dbCredsSchema: z.ZodObject<{
4
+ dbname: z.ZodString;
5
+ username: z.ZodString;
6
+ password: z.ZodString;
7
+ host: z.ZodString;
8
+ port: z.ZodNumber;
9
+ engine: z.ZodType<Dialect, z.ZodTypeDef, Dialect>;
10
+ }, "strip", z.ZodTypeAny, {
11
+ dbname: string;
12
+ username: string;
13
+ password: string;
14
+ host: string;
15
+ port: number;
16
+ engine: Dialect;
17
+ }, {
18
+ dbname: string;
19
+ username: string;
20
+ password: string;
21
+ host: string;
22
+ port: number;
23
+ engine: Dialect;
24
+ }>;
25
+ export declare const dbCredsSchemaReadOnly: z.ZodObject<Omit<{
26
+ dbname: z.ZodString;
27
+ username: z.ZodString;
28
+ password: z.ZodString;
29
+ host: z.ZodString;
30
+ port: z.ZodNumber;
31
+ engine: z.ZodType<Dialect, z.ZodTypeDef, Dialect>;
32
+ }, "dbname" | "username" | "password" | "engine">, "strip", z.ZodTypeAny, {
33
+ host: string;
34
+ port: number;
35
+ }, {
36
+ host: string;
37
+ port: number;
38
+ }>;
39
+ export type DbCreds = z.infer<typeof dbCredsSchema>;
40
+ export type DbCredsReadOnly = z.infer<typeof dbCredsSchemaReadOnly>;
41
+ export declare const dbPoolSettingsSchema: z.ZodObject<{
42
+ max: z.ZodNumber;
43
+ min: z.ZodNumber;
44
+ acquire: z.ZodNumber;
45
+ idle: z.ZodNumber;
46
+ }, "strip", z.ZodTypeAny, {
47
+ min: number;
48
+ max: number;
49
+ acquire: number;
50
+ idle: number;
51
+ }, {
52
+ min: number;
53
+ max: number;
54
+ acquire: number;
55
+ idle: number;
56
+ }>;
57
+ export type DbPoolSettings = z.infer<typeof dbPoolSettingsSchema>;
58
+ //# sourceMappingURL=db.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"db.d.ts","sourceRoot":"","sources":["../../src/domain/db.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC;AAEpC,eAAO,MAAM,aAAa;;;;;;;;;;;;;;;;;;;;;EAOxB,CAAC;AAEH,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;EAKhC,CAAC;AAEH,MAAM,MAAM,OAAO,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;AACpD,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAEpE,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;EAK/B,CAAC;AACH,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC"}
@@ -0,0 +1,25 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.dbPoolSettingsSchema = exports.dbCredsSchemaReadOnly = exports.dbCredsSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ exports.dbCredsSchema = zod_1.z.object({
6
+ dbname: zod_1.z.string(),
7
+ username: zod_1.z.string(),
8
+ password: zod_1.z.string(),
9
+ host: zod_1.z.string(),
10
+ port: zod_1.z.number(),
11
+ engine: zod_1.z.custom(),
12
+ });
13
+ exports.dbCredsSchemaReadOnly = exports.dbCredsSchema.omit({
14
+ dbname: true,
15
+ username: true,
16
+ password: true,
17
+ engine: true,
18
+ });
19
+ exports.dbPoolSettingsSchema = zod_1.z.object({
20
+ max: zod_1.z.number(),
21
+ min: zod_1.z.number(),
22
+ acquire: zod_1.z.number(),
23
+ idle: zod_1.z.number(),
24
+ });
25
+ //# sourceMappingURL=db.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"db.js","sourceRoot":"","sources":["../../src/domain/db.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAGX,QAAA,aAAa,GAAG,OAAC,CAAC,MAAM,CAAC;IACpC,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE;IAClB,QAAQ,EAAE,OAAC,CAAC,MAAM,EAAE;IACpB,QAAQ,EAAE,OAAC,CAAC,MAAM,EAAE;IACpB,IAAI,EAAE,OAAC,CAAC,MAAM,EAAE;IAChB,IAAI,EAAE,OAAC,CAAC,MAAM,EAAE;IAChB,MAAM,EAAE,OAAC,CAAC,MAAM,EAAW;CAC5B,CAAC,CAAC;AAEU,QAAA,qBAAqB,GAAG,qBAAa,CAAC,IAAI,CAAC;IACtD,MAAM,EAAE,IAAI;IACZ,QAAQ,EAAE,IAAI;IACd,QAAQ,EAAE,IAAI;IACd,MAAM,EAAE,IAAI;CACb,CAAC,CAAC;AAKU,QAAA,oBAAoB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC3C,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;IACf,OAAO,EAAE,OAAC,CAAC,MAAM,EAAE;IACnB,IAAI,EAAE,OAAC,CAAC,MAAM,EAAE;CACjB,CAAC,CAAC"}
package/dist/index.d.ts CHANGED
@@ -32,6 +32,7 @@ export * from "./domain/patient/patient-import";
32
32
  export * from "./domain/secrets";
33
33
  export * from "./domain/rate-limiting";
34
34
  export * from "./domain/jwt-token";
35
+ export * from "./domain/db";
35
36
  export { BadRequestError } from "./error/bad-request";
36
37
  export { MetriportError, AdditionalInfo } from "./error/metriport-error";
37
38
  export { NotFoundError } from "./error/not-found";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,cAAc,aAAa,CAAC;AAC5B,OAAO,EAAE,OAAO,EAAE,MAAM,gBAAgB,CAAC;AACzC,OAAO,EAAE,MAAM,EAAE,MAAM,kBAAkB,CAAC;AAC1C,OAAO,EAAE,UAAU,EAAE,kBAAkB,EAAE,uBAAuB,EAAE,MAAM,eAAe,CAAC;AACxF,OAAO,EAAE,4BAA4B,EAAE,MAAM,gBAAgB,CAAC;AAC9D,cAAc,kBAAkB,CAAC;AACjC,OAAO,EAAE,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EAAE,qBAAqB,EAAE,MAAM,iCAAiC,CAAC;AACxE,OAAO,EAAE,UAAU,EAAE,MAAM,cAAc,CAAC;AAC1C,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AACtD,OAAO,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AACvD,cAAc,gBAAgB,CAAC;AAC/B,OAAO,EAAE,KAAK,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AACpD,cAAc,iBAAiB,CAAC;AAChC,OAAO,EAAE,WAAW,EAAE,MAAM,qBAAqB,CAAC;AAClD,OAAO,EAAE,UAAU,EAAE,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAC7D,OAAO,EAAE,WAAW,EAAE,MAAM,uBAAuB,CAAC;AACpD,cAAc,wBAAwB,CAAC;AACvC,cAAc,0BAA0B,CAAC;AACzC,cAAc,wBAAwB,CAAC;AACvC,cAAc,4BAA4B,CAAC;AAC3C,cAAc,sBAAsB,CAAC;AACrC,cAAc,uBAAuB,CAAC;AACtC,cAAc,wBAAwB,CAAC;AACvC,cAAc,wBAAwB,CAAC;AACvC,cAAc,cA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package/dist/index.js CHANGED
@@ -78,6 +78,7 @@ __exportStar(require("./domain/patient/patient-import"), exports);
78
78
  __exportStar(require("./domain/secrets"), exports);
79
79
  __exportStar(require("./domain/rate-limiting"), exports);
80
80
  __exportStar(require("./domain/jwt-token"), exports);
81
+ __exportStar(require("./domain/db"), exports);
81
82
  var bad_request_1 = require("./error/bad-request");
82
83
  Object.defineProperty(exports, "BadRequestError", { enumerable: true, get: function () { return bad_request_1.BadRequestError; } });
83
84
  var metriport_error_1 = require("./error/metriport-error");
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,8CAA4B;AAC5B,wCAAyC;AAAhC,gGAAA,OAAO,OAAA;AAChB,4CAA0C;AAAjC,iGAAA,MAAM,OAAA;AACf,sCAAwF;AAA/E,kGAAA,UAAU,OAAA;AAAE,0GAAA,kBAAkB,OAAA;AAAE,+GAAA,uBAAuB,OAAA;AAChE,wCAA8D;AAArD,qHAAA,4BAA4B,OAAA;AACrC,mDAAiC;AACjC,4CAAiD;AAAxC,wGAAA,aAAa,OAAA;AACtB,0EAAwE;AAA/D,+HAAA,qBAAqB,OAAA;AAC9B,oCAA0C;AAAjC,iGAAA,UAAU,OAAA;AACnB,wDAAsD;AAA7C,6GAAA,YAAY,OAAA;AACrB,0DAAuD;AAA9C,8GAAA,YAAY,OAAA;AACrB,iDAA+B;AAC/B,wCAAoD;AAA3C,8FAAA,KAAK,OAAA;AAAE,oGAAA,WAAW,OAAA;AAC3B,kDAAgC;AAChC,kDAAkD;AAAzC,yGAAA,WAAW,OAAA;AACpB,wCAA6D;AAAxC,wGAAA,eAAe,OAAA;AACpC,sDAAoD;AAA3C,2GAAA,WAAW,OAAA;AACpB,yDAAuC;AACvC,2DAAyC;AACzC,yDAAuC;AACvC,6DAA2C;AAC3C,uDAAqC;AACrC,wDAAsC;AACtC,yDAAuC;A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ACpB,yDAAuC;AACvC,2DAAyC;AACzC,yDAAuC;AACvC,6DAA2C;AAC3C,uDAAqC;AACrC,wDAAsC;AACtC,yDAAuC;AACvC,yDAAuC;AACvC,+CAA6B;AAC7B,sDAAoC;AACpC,kDAAgC;AAChC,gDAA6D;AAApD,oHAAA,uBAAuB,OAAA;AAChC,2DAAyC;AACzC,kEAAgD;AAChD,mDAAiC;AACjC,yDAAuC;AACvC,qDAAmC;AACnC,8CAA4B;AAC5B,mDAAsD;AAA7C,8GAAA,eAAe,OAAA;AACxB,2DAAyE;AAAhE,iHAAA,cAAc,OAAA;AACvB,+CAAkD;AAAzC,0GAAA,aAAa,OAAA;AACtB,yCAA+C;AAAtC,uGAAA,aAAa,OAAA;AACtB,+DAAiE;AAAxD,yHAAA,oBAAoB,OAAA;AAC7B,8CAA4B;AAC5B,qDAAqC;AACrC,8CAA4B;AAC5B,8CAA4B;AAC5B,4CAA0B"}
@@ -6,5 +6,4 @@ export * from "./subscription";
6
6
  export * from "./department";
7
7
  export * from "./problem";
8
8
  export * from "./vitals";
9
- export * from "./patient";
10
9
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/athenahealth/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/athenahealth/index.ts"],"names":[],"mappings":"AAAA,cAAc,cAAc,CAAC;AAC7B,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,cAAc,CAAC;AAC7B,cAAc,gBAAgB,CAAC;AAC/B,cAAc,cAAc,CAAC;AAC7B,cAAc,WAAW,CAAC;AAC1B,cAAc,UAAU,CAAC"}
@@ -22,5 +22,4 @@ __exportStar(require("./subscription"), exports);
22
22
  __exportStar(require("./department"), exports);
23
23
  __exportStar(require("./problem"), exports);
24
24
  __exportStar(require("./vitals"), exports);
25
- __exportStar(require("./patient"), exports);
26
25
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/interface/external/athenahealth/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,+CAA6B;AAC7B,8CAA4B;AAC5B,gDAA8B;AAC9B,+CAA6B;AAC7B,iDAA+B;AAC/B,+CAA6B;AAC7B,4CAA0B;AAC1B,2CAAyB;AACzB,4CAA0B"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/interface/external/athenahealth/index.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;AAAA,+CAA6B;AAC7B,8CAA4B;AAC5B,gDAA8B;AAC9B,+CAA6B;AAC7B,iDAA+B;AAC/B,+CAA6B;AAC7B,4CAA0B;AAC1B,2CAAyB"}
@@ -1,152 +1,68 @@
1
1
  import { z } from "zod";
2
- export declare const slimBookedAppointmentSchema: z.ZodObject<{
3
- patientId: z.ZodString;
2
+ export declare const bookedAppointmentSchema: z.ZodObject<{
3
+ patient: z.ZodString;
4
4
  }, "strip", z.ZodTypeAny, {
5
- patientId: string;
5
+ patient: string;
6
6
  }, {
7
- patientId: string;
7
+ patient: string;
8
8
  }>;
9
- export type SlimBookedAppointment = z.infer<typeof slimBookedAppointmentSchema>;
10
- export declare const bookedAppointmentSchema: z.ZodObject<{
11
- resourceType: z.ZodLiteral<"Appointment">;
12
- participant: z.ZodArray<z.ZodObject<{
13
- actor: z.ZodObject<{
14
- reference: z.ZodString;
15
- type: z.ZodEnum<["Patient", "Practitioner"]>;
16
- }, "strip", z.ZodTypeAny, {
17
- type: "Patient" | "Practitioner";
18
- reference: string;
19
- }, {
20
- type: "Patient" | "Practitioner";
21
- reference: string;
22
- }>;
9
+ export type BookedAppointment = z.infer<typeof bookedAppointmentSchema>;
10
+ export declare const appointmentSchema: z.ZodObject<{
11
+ patient: z.ZodNullable<z.ZodString>;
12
+ status: z.ZodNullable<z.ZodObject<{
13
+ status: z.ZodString;
23
14
  }, "strip", z.ZodTypeAny, {
24
- actor: {
25
- type: "Patient" | "Practitioner";
26
- reference: string;
27
- };
15
+ status: string;
28
16
  }, {
29
- actor: {
30
- type: "Patient" | "Practitioner";
31
- reference: string;
32
- };
33
- }>, "many">;
34
- status: z.ZodLiteral<"booked">;
17
+ status: string;
18
+ }>>;
35
19
  }, "strip", z.ZodTypeAny, {
36
- status: "booked";
37
- resourceType: "Appointment";
38
- participant: {
39
- actor: {
40
- type: "Patient" | "Practitioner";
41
- reference: string;
42
- };
43
- }[];
20
+ status: {
21
+ status: string;
22
+ } | null;
23
+ patient: string | null;
44
24
  }, {
45
- status: "booked";
46
- resourceType: "Appointment";
47
- participant: {
48
- actor: {
49
- type: "Patient" | "Practitioner";
50
- reference: string;
51
- };
52
- }[];
25
+ status: {
26
+ status: string;
27
+ } | null;
28
+ patient: string | null;
53
29
  }>;
54
- export type BookedAppointment = z.infer<typeof bookedAppointmentSchema>;
55
- export declare const bookedAppointmentsSchema: z.ZodObject<{
56
- entry: z.ZodArray<z.ZodObject<{
57
- resource: z.ZodObject<{
58
- resourceType: z.ZodLiteral<"Appointment">;
59
- participant: z.ZodArray<z.ZodObject<{
60
- actor: z.ZodObject<{
61
- reference: z.ZodString;
62
- type: z.ZodEnum<["Patient", "Practitioner"]>;
63
- }, "strip", z.ZodTypeAny, {
64
- type: "Patient" | "Practitioner";
65
- reference: string;
66
- }, {
67
- type: "Patient" | "Practitioner";
68
- reference: string;
69
- }>;
70
- }, "strip", z.ZodTypeAny, {
71
- actor: {
72
- type: "Patient" | "Practitioner";
73
- reference: string;
74
- };
75
- }, {
76
- actor: {
77
- type: "Patient" | "Practitioner";
78
- reference: string;
79
- };
80
- }>, "many">;
81
- status: z.ZodLiteral<"booked">;
30
+ export type Appointment = z.infer<typeof appointmentSchema>;
31
+ export declare const appointmentsSchema: z.ZodObject<{
32
+ results: z.ZodArray<z.ZodObject<{
33
+ patient: z.ZodNullable<z.ZodString>;
34
+ status: z.ZodNullable<z.ZodObject<{
35
+ status: z.ZodString;
82
36
  }, "strip", z.ZodTypeAny, {
83
- status: "booked";
84
- resourceType: "Appointment";
85
- participant: {
86
- actor: {
87
- type: "Patient" | "Practitioner";
88
- reference: string;
89
- };
90
- }[];
37
+ status: string;
91
38
  }, {
92
- status: "booked";
93
- resourceType: "Appointment";
94
- participant: {
95
- actor: {
96
- type: "Patient" | "Practitioner";
97
- reference: string;
98
- };
99
- }[];
100
- }>;
39
+ status: string;
40
+ }>>;
101
41
  }, "strip", z.ZodTypeAny, {
102
- resource: {
103
- status: "booked";
104
- resourceType: "Appointment";
105
- participant: {
106
- actor: {
107
- type: "Patient" | "Practitioner";
108
- reference: string;
109
- };
110
- }[];
111
- };
42
+ status: {
43
+ status: string;
44
+ } | null;
45
+ patient: string | null;
112
46
  }, {
113
- resource: {
114
- status: "booked";
115
- resourceType: "Appointment";
116
- participant: {
117
- actor: {
118
- type: "Patient" | "Practitioner";
119
- reference: string;
120
- };
121
- }[];
122
- };
47
+ status: {
48
+ status: string;
49
+ } | null;
50
+ patient: string | null;
123
51
  }>, "many">;
124
52
  }, "strip", z.ZodTypeAny, {
125
- entry: {
126
- resource: {
127
- status: "booked";
128
- resourceType: "Appointment";
129
- participant: {
130
- actor: {
131
- type: "Patient" | "Practitioner";
132
- reference: string;
133
- };
134
- }[];
135
- };
53
+ results: {
54
+ status: {
55
+ status: string;
56
+ } | null;
57
+ patient: string | null;
136
58
  }[];
137
59
  }, {
138
- entry: {
139
- resource: {
140
- status: "booked";
141
- resourceType: "Appointment";
142
- participant: {
143
- actor: {
144
- type: "Patient" | "Practitioner";
145
- reference: string;
146
- };
147
- }[];
148
- };
60
+ results: {
61
+ status: {
62
+ status: string;
63
+ } | null;
64
+ patient: string | null;
149
65
  }[];
150
66
  }>;
151
- export type BookedAppointments = z.infer<typeof bookedAppointmentsSchema>;
67
+ export type Appointments = z.infer<typeof appointmentsSchema>;
152
68
  //# sourceMappingURL=appointment.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"appointment.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/canvas/appointment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,2BAA2B;;;;;;EAEtC,CAAC;AACH,MAAM,MAAM,qBAAqB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,2BAA2B,CAAC,CAAC;AAEhF,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAWlC,CAAC;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AACxE,eAAO,MAAM,wBAAwB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAEnC,CAAC;AACH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC"}
1
+ {"version":3,"file":"appointment.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/canvas/appointment.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,uBAAuB;;;;;;EAElC,CAAC;AACH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAExE,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;EAG5B,CAAC;AACH,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAC5D,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAE7B,CAAC;AACH,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC"}
@@ -1,23 +1,15 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.bookedAppointmentsSchema = exports.bookedAppointmentSchema = exports.slimBookedAppointmentSchema = void 0;
3
+ exports.appointmentsSchema = exports.appointmentSchema = exports.bookedAppointmentSchema = void 0;
4
4
  const zod_1 = require("zod");
5
- exports.slimBookedAppointmentSchema = zod_1.z.object({
6
- patientId: zod_1.z.string(),
7
- });
8
5
  exports.bookedAppointmentSchema = zod_1.z.object({
9
- resourceType: zod_1.z.literal("Appointment"),
10
- participant: zod_1.z
11
- .object({
12
- actor: zod_1.z.object({
13
- reference: zod_1.z.string(),
14
- type: zod_1.z.enum(["Patient", "Practitioner"]),
15
- }),
16
- })
17
- .array(),
18
- status: zod_1.z.literal("booked"),
6
+ patient: zod_1.z.coerce.string(),
7
+ });
8
+ exports.appointmentSchema = zod_1.z.object({
9
+ patient: zod_1.z.coerce.string().nullable(),
10
+ status: zod_1.z.object({ status: zod_1.z.string() }).nullable(),
19
11
  });
20
- exports.bookedAppointmentsSchema = zod_1.z.object({
21
- entry: zod_1.z.object({ resource: exports.bookedAppointmentSchema }).array(),
12
+ exports.appointmentsSchema = zod_1.z.object({
13
+ results: exports.appointmentSchema.array(),
22
14
  });
23
15
  //# sourceMappingURL=appointment.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"appointment.js","sourceRoot":"","sources":["../../../../src/interface/external/canvas/appointment.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAEX,QAAA,2BAA2B,GAAG,OAAC,CAAC,MAAM,CAAC;IAClD,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE;CACtB,CAAC,CAAC;AAGU,QAAA,uBAAuB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC9C,YAAY,EAAE,OAAC,CAAC,OAAO,CAAC,aAAa,CAAC;IACtC,WAAW,EAAE,OAAC;SACX,MAAM,CAAC;QACN,KAAK,EAAE,OAAC,CAAC,MAAM,CAAC;YACd,SAAS,EAAE,OAAC,CAAC,MAAM,EAAE;YACrB,IAAI,EAAE,OAAC,CAAC,IAAI,CAAC,CAAC,SAAS,EAAE,cAAc,CAAC,CAAC;SAC1C,CAAC;KACH,CAAC;SACD,KAAK,EAAE;IACV,MAAM,EAAE,OAAC,CAAC,OAAO,CAAC,QAAQ,CAAC;CAC5B,CAAC,CAAC;AAEU,QAAA,wBAAwB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC/C,KAAK,EAAE,OAAC,CAAC,MAAM,CAAC,EAAE,QAAQ,EAAE,+BAAuB,EAAE,CAAC,CAAC,KAAK,EAAE;CAC/D,CAAC,CAAC"}
1
+ {"version":3,"file":"appointment.js","sourceRoot":"","sources":["../../../../src/interface/external/canvas/appointment.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAEX,QAAA,uBAAuB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC9C,OAAO,EAAE,OAAC,CAAC,MAAM,CAAC,MAAM,EAAE;CAC3B,CAAC,CAAC;AAGU,QAAA,iBAAiB,GAAG,OAAC,CAAC,MAAM,CAAC;IACxC,OAAO,EAAE,OAAC,CAAC,MAAM,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IACrC,MAAM,EAAE,OAAC,CAAC,MAAM,CAAC,EAAE,MAAM,EAAE,OAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,QAAQ,EAAE;CACpD,CAAC,CAAC;AAEU,QAAA,kBAAkB,GAAG,OAAC,CAAC,MAAM,CAAC;IACzC,OAAO,EAAE,yBAAiB,CAAC,KAAK,EAAE;CACnC,CAAC,CAAC"}
@@ -15,20 +15,6 @@ export type CanvasClientJwtTokenData = {
15
15
  cxId: string;
16
16
  source: "canvas-client";
17
17
  };
18
- export declare const canvasWebhookJwtTokenDataSchema: z.ZodObject<{
19
- practiceId: z.ZodString;
20
- cxId: z.ZodString;
21
- source: z.ZodLiteral<"canvas-webhook">;
22
- }, "strip", z.ZodTypeAny, {
23
- cxId: string;
24
- source: "canvas-webhook";
25
- practiceId: string;
26
- }, {
27
- cxId: string;
28
- source: "canvas-webhook";
29
- practiceId: string;
30
- }>;
31
- export type CanvasWebhookJwtTokenData = z.infer<typeof canvasWebhookJwtTokenDataSchema>;
32
18
  export declare const canvasClientJwtTokenResponseSchema: z.ZodObject<{
33
19
  scope: z.ZodString;
34
20
  access_token: z.ZodString;
@@ -1 +1 @@
1
- {"version":3,"file":"jwt-token.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/canvas/jwt-token.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AAEpB,eAAO,MAAM,wBAAwB;;;;;;;;;EAGnC,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAE1E,MAAM,MAAM,wBAAwB,GAAG;IACrC,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,eAAe,CAAC;CACzB,CAAC;AAEF,eAAO,MAAM,+BAA+B;;;;;;;;;;;;EAI1C,CAAC;AAEH,MAAM,MAAM,yBAAyB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAC;AAExF,eAAO,MAAM,kCAAkC;;;;;;;;;;;;EAI7C,CAAC"}
1
+ {"version":3,"file":"jwt-token.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/canvas/jwt-token.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AAEpB,eAAO,MAAM,wBAAwB;;;;;;;;;EAGnC,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAE1E,MAAM,MAAM,wBAAwB,GAAG;IACrC,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,eAAe,CAAC;CACzB,CAAC;AAEF,eAAO,MAAM,kCAAkC;;;;;;;;;;;;EAI7C,CAAC"}
@@ -3,17 +3,12 @@ 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.canvasClientJwtTokenResponseSchema = exports.canvasWebhookJwtTokenDataSchema = exports.canvasJwtTokenDataSchema = void 0;
6
+ exports.canvasClientJwtTokenResponseSchema = exports.canvasJwtTokenDataSchema = void 0;
7
7
  const zod_1 = __importDefault(require("zod"));
8
8
  exports.canvasJwtTokenDataSchema = zod_1.default.object({
9
9
  practiceId: zod_1.default.string(),
10
10
  source: zod_1.default.literal("canvas"),
11
11
  });
12
- exports.canvasWebhookJwtTokenDataSchema = zod_1.default.object({
13
- practiceId: zod_1.default.string(),
14
- cxId: zod_1.default.string(),
15
- source: zod_1.default.literal("canvas-webhook"),
16
- });
17
12
  exports.canvasClientJwtTokenResponseSchema = zod_1.default.object({
18
13
  scope: zod_1.default.string(),
19
14
  access_token: zod_1.default.string(),
@@ -1 +1 @@
1
- {"version":3,"file":"jwt-token.js","sourceRoot":"","sources":["../../../../src/interface/external/canvas/jwt-token.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAoB;AAEP,QAAA,wBAAwB,GAAG,aAAC,CAAC,MAAM,CAAC;IAC/C,UAAU,EAAE,aAAC,CAAC,MAAM,EAAE;IACtB,MAAM,EAAE,aAAC,CAAC,OAAO,CAAC,QAAQ,CAAC;CAC5B,CAAC,CAAC;AAUU,QAAA,+BAA+B,GAAG,aAAC,CAAC,MAAM,CAAC;IACtD,UAAU,EAAE,aAAC,CAAC,MAAM,EAAE;IACtB,IAAI,EAAE,aAAC,CAAC,MAAM,EAAE;IAChB,MAAM,EAAE,aAAC,CAAC,OAAO,CAAC,gBAAgB,CAAC;CACpC,CAAC,CAAC;AAIU,QAAA,kCAAkC,GAAG,aAAC,CAAC,MAAM,CAAC;IACzD,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"}
1
+ {"version":3,"file":"jwt-token.js","sourceRoot":"","sources":["../../../../src/interface/external/canvas/jwt-token.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAoB;AAEP,QAAA,wBAAwB,GAAG,aAAC,CAAC,MAAM,CAAC;IAC/C,UAAU,EAAE,aAAC,CAAC,MAAM,EAAE;IACtB,MAAM,EAAE,aAAC,CAAC,OAAO,CAAC,QAAQ,CAAC;CAC5B,CAAC,CAAC;AAUU,QAAA,kCAAkC,GAAG,aAAC,CAAC,MAAM,CAAC;IACzD,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"}
@@ -1,4 +1,5 @@
1
1
  export * from "./appointment";
2
2
  export * from "./patient";
3
3
  export * from "./jwt-token";
4
+ export * from "./problem";
4
5
  //# 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"}
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"}
@@ -17,4 +17,5 @@ Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./appointment"), exports);
18
18
  __exportStar(require("./patient"), exports);
19
19
  __exportStar(require("./jwt-token"), exports);
20
+ __exportStar(require("./problem"), exports);
20
21
  //# 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"}
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,4 +1,20 @@
1
1
  import z from "zod";
2
+ import { EhrSources } from "../source";
3
+ export declare const elationDashSource: EhrSources.elation;
4
+ export declare const elationDashJwtTokenDataSchema: z.ZodObject<{
5
+ practiceId: z.ZodString;
6
+ patientId: z.ZodString;
7
+ source: z.ZodLiteral<"elation">;
8
+ }, "strip", z.ZodTypeAny, {
9
+ patientId: string;
10
+ source: "elation";
11
+ practiceId: string;
12
+ }, {
13
+ patientId: string;
14
+ source: "elation";
15
+ practiceId: string;
16
+ }>;
17
+ export type ElationDashJwtTokenData = z.infer<typeof elationDashJwtTokenDataSchema>;
2
18
  export declare const elationClientSource: "elation-client";
3
19
  export declare const elationClientJwtTokenDataSchema: z.ZodObject<{
4
20
  practiceId: 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;AAGpB,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,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"}
@@ -3,9 +3,15 @@ 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 = void 0;
6
+ exports.elationClientJwtTokenResponseSchema = exports.elationWebhookJwtTokenDataSchema = exports.elationWebhookSource = 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
+ exports.elationDashSource = source_1.EhrSources.elation;
10
+ exports.elationDashJwtTokenDataSchema = zod_1.default.object({
11
+ practiceId: zod_1.default.string(),
12
+ patientId: zod_1.default.string(),
13
+ source: zod_1.default.literal(`${exports.elationDashSource}`),
14
+ });
9
15
  exports.elationClientSource = `${source_1.EhrSources.elation}${source_1.clientSourceSuffix}`;
10
16
  exports.elationClientJwtTokenDataSchema = zod_1.default.object({
11
17
  practiceId: 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,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,EAAE,aAAC,CAAC,OAAO,CAAC,GAAG,2BAAmB,EAAE,CAAC;CAC5C,CAAC,CAAC;AAGU,QAAA,oBAAoB,GAAG,GAAG,mBAAU,CAAC,OAAO,GAAG,4BAAmB,EAAW,CAAC;AAC9E,QAAA,gCAAgC,GAAG,aAAC,CAAC,MAAM,CAAC;IACvD,UAAU,EAAE,aAA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EAAE;IACtB,IAAI,EAAE,aAAC,CAAC,MAAM,EAAE;IAChB,MAAM,EAAE,aAAC,CAAC,OAAO,CAAC,GAAG,4BAAoB,EAAE,CAAC;CAC7C,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,10 @@
1
+ import { z } from "zod";
2
+ export declare const createdProblemSchema: z.ZodObject<{
3
+ id: z.ZodString;
4
+ }, "strip", z.ZodTypeAny, {
5
+ id: string;
6
+ }, {
7
+ id: string;
8
+ }>;
9
+ export type CreatedProblem = z.infer<typeof createdProblemSchema>;
10
+ //# sourceMappingURL=problem.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"problem.d.ts","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/elation/problem.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,eAAO,MAAM,oBAAoB;;;;;;EAE/B,CAAC;AACH,MAAM,MAAM,cAAc,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC"}
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.createdProblemSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ exports.createdProblemSchema = zod_1.z.object({
6
+ id: zod_1.z.coerce.string(),
7
+ });
8
+ //# sourceMappingURL=problem.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"problem.js","sourceRoot":"","sources":["../../../../../src/interface/external/ehr/elation/problem.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAEX,QAAA,oBAAoB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC3C,EAAE,EAAE,OAAC,CAAC,MAAM,CAAC,MAAM,EAAE;CACtB,CAAC,CAAC"}
@@ -4,20 +4,6 @@ export type ElationClientJwtTokenData = {
4
4
  cxId: string;
5
5
  source: "elation-client";
6
6
  };
7
- export declare const elationWebhookJwtTokenDataSchema: z.ZodObject<{
8
- practiceId: z.ZodString;
9
- cxId: z.ZodString;
10
- source: z.ZodLiteral<"elation-webhook">;
11
- }, "strip", z.ZodTypeAny, {
12
- cxId: string;
13
- source: "elation-webhook";
14
- practiceId: string;
15
- }, {
16
- cxId: string;
17
- source: "elation-webhook";
18
- practiceId: string;
19
- }>;
20
- export type ElationWebhookJwtTokenData = z.infer<typeof elationWebhookJwtTokenDataSchema>;
21
7
  export declare const elationClientJwtTokenResponseSchema: z.ZodObject<{
22
8
  scope: z.ZodString;
23
9
  access_token: z.ZodString;
@@ -1 +1 @@
1
- {"version":3,"file":"jwt-token.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/elation/jwt-token.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AAEpB,MAAM,MAAM,yBAAyB,GAAG;IACtC,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,gBAAgB,CAAC;CAC1B,CAAC;AAEF,eAAO,MAAM,gCAAgC;;;;;;;;;;;;EAI3C,CAAC;AAEH,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/elation/jwt-token.ts"],"names":[],"mappings":"AAAA,OAAO,CAAC,MAAM,KAAK,CAAC;AAEpB,MAAM,MAAM,yBAAyB,GAAG;IACtC,UAAU,EAAE,MAAM,CAAC;IACnB,IAAI,EAAE,MAAM,CAAC;IACb,MAAM,EAAE,gBAAgB,CAAC;CAC1B,CAAC;AAEF,eAAO,MAAM,mCAAmC;;;;;;;;;;;;EAI9C,CAAC"}
@@ -3,13 +3,8 @@ 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 = void 0;
6
+ exports.elationClientJwtTokenResponseSchema = void 0;
7
7
  const zod_1 = __importDefault(require("zod"));
8
- exports.elationWebhookJwtTokenDataSchema = zod_1.default.object({
9
- practiceId: zod_1.default.string(),
10
- cxId: zod_1.default.string(),
11
- source: zod_1.default.literal("elation-webhook"),
12
- });
13
8
  exports.elationClientJwtTokenResponseSchema = zod_1.default.object({
14
9
  scope: zod_1.default.string(),
15
10
  access_token: zod_1.default.string(),
@@ -1 +1 @@
1
- {"version":3,"file":"jwt-token.js","sourceRoot":"","sources":["../../../../src/interface/external/elation/jwt-token.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAoB;AAQP,QAAA,gCAAgC,GAAG,aAAC,CAAC,MAAM,CAAC;IACvD,UAAU,EAAE,aAAC,CAAC,MAAM,EAAE;IACtB,IAAI,EAAE,aAAC,CAAC,MAAM,EAAE;IAChB,MAAM,EAAE,aAAC,CAAC,OAAO,CAAC,iBAAiB,CAAC;CACrC,CAAC,CAAC;AAIU,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"}
1
+ {"version":3,"file":"jwt-token.js","sourceRoot":"","sources":["../../../../src/interface/external/elation/jwt-token.ts"],"names":[],"mappings":";;;;;;AAAA,8CAAoB;AAQP,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"}
@@ -12,16 +12,16 @@ export declare const patientSchema: z.ZodObject<{
12
12
  zip: z.ZodNullable<z.ZodString>;
13
13
  }, "strip", z.ZodTypeAny, {
14
14
  state: string | null;
15
- zip: string | null;
16
- city: string | null;
17
15
  address_line1: string | null;
18
16
  address_line2: string | null;
17
+ city: string | null;
18
+ zip: string | null;
19
19
  }, {
20
20
  state: string | null;
21
- zip: string | null;
22
- city: string | null;
23
21
  address_line1: string | null;
24
22
  address_line2: string | null;
23
+ city: string | null;
24
+ zip: string | null;
25
25
  }>>;
26
26
  dob: z.ZodString;
27
27
  phones: z.ZodNullable<z.ZodArray<z.ZodObject<{
@@ -40,7 +40,6 @@ export declare const patientSchema: z.ZodObject<{
40
40
  }>, "many">>;
41
41
  ssn: z.ZodNullable<z.ZodString>;
42
42
  }, "strip", z.ZodTypeAny, {
43
- dob: string;
44
43
  ssn: string | null;
45
44
  first_name: string | null;
46
45
  last_name: string | null;
@@ -48,11 +47,12 @@ export declare const patientSchema: z.ZodObject<{
48
47
  sex: string;
49
48
  address: {
50
49
  state: string | null;
51
- zip: string | null;
52
- city: string | null;
53
50
  address_line1: string | null;
54
51
  address_line2: string | null;
52
+ city: string | null;
53
+ zip: string | null;
55
54
  } | null;
55
+ dob: string;
56
56
  phones: {
57
57
  phone: string;
58
58
  }[] | null;
@@ -60,7 +60,6 @@ export declare const patientSchema: z.ZodObject<{
60
60
  email: string;
61
61
  }[] | null;
62
62
  }, {
63
- dob: string;
64
63
  ssn: string | null;
65
64
  first_name: string | null;
66
65
  last_name: string | null;
@@ -68,11 +67,12 @@ export declare const patientSchema: z.ZodObject<{
68
67
  sex: string;
69
68
  address: {
70
69
  state: string | null;
71
- zip: string | null;
72
- city: string | null;
73
70
  address_line1: string | null;
74
71
  address_line2: string | null;
72
+ city: string | null;
73
+ zip: string | null;
75
74
  } | null;
75
+ dob: string;
76
76
  phones: {
77
77
  phone: string;
78
78
  }[] | null;
@@ -0,0 +1,2 @@
1
+ export type Resource = "appointments";
2
+ //# sourceMappingURL=subscription.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"subscription.d.ts","sourceRoot":"","sources":["../../../../src/interface/external/elation/subscription.ts"],"names":[],"mappings":"AAAA,MAAM,MAAM,QAAQ,GAAG,cAAc,CAAC"}
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ //# sourceMappingURL=subscription.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"subscription.js","sourceRoot":"","sources":["../../../../src/interface/external/elation/subscription.ts"],"names":[],"mappings":""}
@@ -19,16 +19,16 @@ export declare const patientSchema: z.ZodObject<{
19
19
  country: z.ZodOptional<z.ZodString>;
20
20
  }, "strip", z.ZodTypeAny, {
21
21
  state?: string | undefined;
22
- country?: string | undefined;
23
22
  city?: string | undefined;
24
23
  line?: string[] | undefined;
25
24
  postalCode?: string | undefined;
25
+ country?: string | undefined;
26
26
  }, {
27
27
  state?: string | undefined;
28
- country?: string | undefined;
29
28
  city?: string | undefined;
30
29
  line?: string[] | undefined;
31
30
  postalCode?: string | undefined;
31
+ country?: string | undefined;
32
32
  }>, "many">>;
33
33
  birthDate: z.ZodString;
34
34
  telecom: z.ZodOptional<z.ZodArray<z.ZodObject<{
@@ -44,16 +44,16 @@ export declare const patientSchema: z.ZodObject<{
44
44
  }, "strip", z.ZodTypeAny, {
45
45
  gender: string;
46
46
  birthDate: string;
47
- name?: {
48
- family?: string | undefined;
49
- given?: string[] | undefined;
50
- }[] | undefined;
51
47
  address?: {
52
48
  state?: string | undefined;
53
- country?: string | undefined;
54
49
  city?: string | undefined;
55
50
  line?: string[] | undefined;
56
51
  postalCode?: string | undefined;
52
+ country?: string | undefined;
53
+ }[] | undefined;
54
+ name?: {
55
+ family?: string | undefined;
56
+ given?: string[] | undefined;
57
57
  }[] | undefined;
58
58
  telecom?: {
59
59
  value?: string | undefined;
@@ -62,16 +62,16 @@ export declare const patientSchema: z.ZodObject<{
62
62
  }, {
63
63
  gender: string;
64
64
  birthDate: string;
65
- name?: {
66
- family?: string | undefined;
67
- given?: string[] | undefined;
68
- }[] | undefined;
69
65
  address?: {
70
66
  state?: string | undefined;
71
- country?: string | undefined;
72
67
  city?: string | undefined;
73
68
  line?: string[] | undefined;
74
69
  postalCode?: string | undefined;
70
+ country?: string | undefined;
71
+ }[] | undefined;
72
+ name?: {
73
+ family?: string | undefined;
74
+ given?: string[] | undefined;
75
75
  }[] | undefined;
76
76
  telecom?: {
77
77
  value?: string | undefined;
@@ -101,16 +101,16 @@ export declare const patientSearchSchema: z.ZodObject<{
101
101
  country: z.ZodOptional<z.ZodString>;
102
102
  }, "strip", z.ZodTypeAny, {
103
103
  state?: string | undefined;
104
- country?: string | undefined;
105
104
  city?: string | undefined;
106
105
  line?: string[] | undefined;
107
106
  postalCode?: string | undefined;
107
+ country?: string | undefined;
108
108
  }, {
109
109
  state?: string | undefined;
110
- country?: string | undefined;
111
110
  city?: string | undefined;
112
111
  line?: string[] | undefined;
113
112
  postalCode?: string | undefined;
113
+ country?: string | undefined;
114
114
  }>, "many">>;
115
115
  birthDate: z.ZodString;
116
116
  telecom: z.ZodOptional<z.ZodArray<z.ZodObject<{
@@ -126,16 +126,16 @@ export declare const patientSearchSchema: z.ZodObject<{
126
126
  }, "strip", z.ZodTypeAny, {
127
127
  gender: string;
128
128
  birthDate: string;
129
- name?: {
130
- family?: string | undefined;
131
- given?: string[] | undefined;
132
- }[] | undefined;
133
129
  address?: {
134
130
  state?: string | undefined;
135
- country?: string | undefined;
136
131
  city?: string | undefined;
137
132
  line?: string[] | undefined;
138
133
  postalCode?: string | undefined;
134
+ country?: string | undefined;
135
+ }[] | undefined;
136
+ name?: {
137
+ family?: string | undefined;
138
+ given?: string[] | undefined;
139
139
  }[] | undefined;
140
140
  telecom?: {
141
141
  value?: string | undefined;
@@ -144,16 +144,16 @@ export declare const patientSearchSchema: z.ZodObject<{
144
144
  }, {
145
145
  gender: string;
146
146
  birthDate: string;
147
- name?: {
148
- family?: string | undefined;
149
- given?: string[] | undefined;
150
- }[] | undefined;
151
147
  address?: {
152
148
  state?: string | undefined;
153
- country?: string | undefined;
154
149
  city?: string | undefined;
155
150
  line?: string[] | undefined;
156
151
  postalCode?: string | undefined;
152
+ country?: string | undefined;
153
+ }[] | undefined;
154
+ name?: {
155
+ family?: string | undefined;
156
+ given?: string[] | undefined;
157
157
  }[] | undefined;
158
158
  telecom?: {
159
159
  value?: string | undefined;
@@ -164,16 +164,16 @@ export declare const patientSearchSchema: z.ZodObject<{
164
164
  resource: {
165
165
  gender: string;
166
166
  birthDate: string;
167
- name?: {
168
- family?: string | undefined;
169
- given?: string[] | undefined;
170
- }[] | undefined;
171
167
  address?: {
172
168
  state?: string | undefined;
173
- country?: string | undefined;
174
169
  city?: string | undefined;
175
170
  line?: string[] | undefined;
176
171
  postalCode?: string | undefined;
172
+ country?: string | undefined;
173
+ }[] | undefined;
174
+ name?: {
175
+ family?: string | undefined;
176
+ given?: string[] | undefined;
177
177
  }[] | undefined;
178
178
  telecom?: {
179
179
  value?: string | undefined;
@@ -184,16 +184,16 @@ export declare const patientSearchSchema: z.ZodObject<{
184
184
  resource: {
185
185
  gender: string;
186
186
  birthDate: string;
187
- name?: {
188
- family?: string | undefined;
189
- given?: string[] | undefined;
190
- }[] | undefined;
191
187
  address?: {
192
188
  state?: string | undefined;
193
- country?: string | undefined;
194
189
  city?: string | undefined;
195
190
  line?: string[] | undefined;
196
191
  postalCode?: string | undefined;
192
+ country?: string | undefined;
193
+ }[] | undefined;
194
+ name?: {
195
+ family?: string | undefined;
196
+ given?: string[] | undefined;
197
197
  }[] | undefined;
198
198
  telecom?: {
199
199
  value?: string | undefined;
@@ -206,16 +206,16 @@ export declare const patientSearchSchema: z.ZodObject<{
206
206
  resource: {
207
207
  gender: string;
208
208
  birthDate: string;
209
- name?: {
210
- family?: string | undefined;
211
- given?: string[] | undefined;
212
- }[] | undefined;
213
209
  address?: {
214
210
  state?: string | undefined;
215
- country?: string | undefined;
216
211
  city?: string | undefined;
217
212
  line?: string[] | undefined;
218
213
  postalCode?: string | undefined;
214
+ country?: string | undefined;
215
+ }[] | undefined;
216
+ name?: {
217
+ family?: string | undefined;
218
+ given?: string[] | undefined;
219
219
  }[] | undefined;
220
220
  telecom?: {
221
221
  value?: string | undefined;
@@ -228,16 +228,16 @@ export declare const patientSearchSchema: z.ZodObject<{
228
228
  resource: {
229
229
  gender: string;
230
230
  birthDate: string;
231
- name?: {
232
- family?: string | undefined;
233
- given?: string[] | undefined;
234
- }[] | undefined;
235
231
  address?: {
236
232
  state?: string | undefined;
237
- country?: string | undefined;
238
233
  city?: string | undefined;
239
234
  line?: string[] | undefined;
240
235
  postalCode?: string | undefined;
236
+ country?: string | undefined;
237
+ }[] | undefined;
238
+ name?: {
239
+ family?: string | undefined;
240
+ given?: string[] | undefined;
241
241
  }[] | undefined;
242
242
  telecom?: {
243
243
  value?: string | undefined;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@metriport/shared",
3
- "version": "0.20.1-alpha.0",
3
+ "version": "0.20.2",
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": "c305d40edd46d40233198199cf2f4b70531604b6"
104
+ "gitHead": "a7e0df6f4f0e389bb6151ae131dc72a8e987aa9d"
105
105
  }