@metriport/api-sdk 14.13.2 → 14.14.1-alpha.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -425,7 +425,7 @@ export declare class MetriportMedicalApi {
425
425
  * @param throwOnError Whether to throw an Error if the request body is not a valid webhook request.
426
426
  * Optional, defaults to true.
427
427
  * @returns The webhook request - instance of WebhookRequest, or an instance of
428
- * WebhookRequestParsingError if the payload is invalid and throwOnError is 'true'.
428
+ * WebhookRequestParsingError if the payload is invalid and throwOnError is 'false'.
429
429
  * @throws Error if the request body is not a valid webhook request and throwOnError is 'true'.
430
430
  * Details can be obtained from the error object under the 'cause' property (instance
431
431
  * of ZodError).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@metriport/api-sdk",
3
- "version": "14.13.2",
3
+ "version": "14.14.1-alpha.0",
4
4
  "description": "Metriport helps you access and manage health and medical data, through a single open source API.",
5
5
  "author": "Metriport Inc. <contact@metriport.com>",
6
6
  "homepage": "https://metriport.com/",
@@ -58,8 +58,8 @@
58
58
  },
59
59
  "dependencies": {
60
60
  "@medplum/fhirtypes": "^2.0.32",
61
- "@metriport/commonwell-sdk": "^5.7.2",
62
- "@metriport/shared": "^0.21.2",
61
+ "@metriport/commonwell-sdk": "^5.8.1-alpha.0",
62
+ "@metriport/shared": "^0.23.1-alpha.0",
63
63
  "axios": "^1.4.0",
64
64
  "dayjs": "^1.11.7",
65
65
  "dotenv": "^16.3.1",
@@ -77,5 +77,5 @@
77
77
  "ts-jest": "29.1.1",
78
78
  "typescript": "^4.9.5"
79
79
  },
80
- "gitHead": "fcf640a1a8141fb0fcc2a64f2ddd4d5fa224e6b6"
80
+ "gitHead": "232c28cd912c50d630c0b273b614789ae212b7f1"
81
81
  }
@@ -1,3 +0,0 @@
1
- import { PatientModel } from "../../../models/medical/patient";
2
- export declare function getAdtSubscribers(states: string[]): Promise<PatientModel[]>;
3
- //# sourceMappingURL=get-adt-subscribers-backup.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"get-adt-subscribers-backup.d.ts","sourceRoot":"","sources":["../../../src/medical/client/get-adt-subscribers-backup.ts"],"names":[],"mappings":"AAGA,OAAO,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAG/D,wBAAsB,iBAAiB,CAAC,MAAM,EAAE,MAAM,EAAE,GAAG,OAAO,CAAC,YAAY,EAAE,CAAC,CAmCjF"}
@@ -1,42 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.getAdtSubscribers = void 0;
4
- const util_1 = require("@metriport/core/util");
5
- const log_1 = require("@metriport/core/util/log");
6
- const shared_1 = require("@metriport/shared");
7
- const patient_1 = require("../../../models/medical/patient");
8
- const patient_settings_1 = require("../../../models/patient-settings");
9
- async function getAdtSubscribers(states) {
10
- const { log } = (0, log_1.out)(`Get ADT Subscribers`);
11
- log(`States: ${states}`);
12
- try {
13
- const patientIds = await patient_settings_1.PatientSettingsModel.findAll({
14
- where: {
15
- subscribeTo: { adt: true },
16
- },
17
- attributes: ["patientId"],
18
- });
19
- if (patientIds.length === 0)
20
- return [];
21
- const patients = await patient_1.PatientModel.findAll({
22
- where: {
23
- id: patientIds.map(p => p.patientId),
24
- },
25
- });
26
- const patientsInSelectedStates = patients.filter(p => p.data.address?.some(a => states.includes(a.state)));
27
- return patientsInSelectedStates;
28
- }
29
- catch (error) {
30
- const msg = `Failed to get ADT subscribers`;
31
- log(`${msg} - err: ${(0, shared_1.errorToString)(error)}`);
32
- util_1.capture.error(msg, {
33
- extra: {
34
- error,
35
- states,
36
- },
37
- });
38
- throw new Error(msg, { cause: error });
39
- }
40
- }
41
- exports.getAdtSubscribers = getAdtSubscribers;
42
- //# sourceMappingURL=get-adt-subscribers-backup.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"get-adt-subscribers-backup.js","sourceRoot":"","sources":["../../../src/medical/client/get-adt-subscribers-backup.ts"],"names":[],"mappings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G,EAAE,EAAE,KAAK,EAAE,KAAK,EAAE,CAAC,CAAC;KACxC;AACH,CAAC;AAnCD,8CAmCC"}
@@ -1,903 +0,0 @@
1
- import { z } from "zod";
2
- export declare const generalPersonalIdentifiers: readonly ["ssn"];
3
- export declare const driversLicensePersonalIdentifier: readonly ["driversLicense"];
4
- export type GeneralPersonalIdentifiers = (typeof generalPersonalIdentifiers)[number];
5
- export type DriversLicensePersonalIdentifier = (typeof driversLicensePersonalIdentifier)[number];
6
- export declare const driverLicenseIdentifierSchema: z.ZodObject<{
7
- type: z.ZodEnum<["driversLicense"]>;
8
- state: z.ZodEffects<z.ZodNativeEnum<{
9
- AL: import("@metriport/shared").USState.AL;
10
- AK: import("@metriport/shared").USState.AK;
11
- AZ: import("@metriport/shared").USState.AZ;
12
- AR: import("@metriport/shared").USState.AR;
13
- CA: import("@metriport/shared").USState.CA;
14
- CO: import("@metriport/shared").USState.CO;
15
- CT: import("@metriport/shared").USState.CT;
16
- DE: import("@metriport/shared").USState.DE;
17
- DC: import("@metriport/shared").USState.DC;
18
- FL: import("@metriport/shared").USState.FL;
19
- GA: import("@metriport/shared").USState.GA;
20
- HI: import("@metriport/shared").USState.HI;
21
- ID: import("@metriport/shared").USState.ID;
22
- IL: import("@metriport/shared").USState.IL;
23
- IN: import("@metriport/shared").USState.IN;
24
- IA: import("@metriport/shared").USState.IA;
25
- KS: import("@metriport/shared").USState.KS;
26
- KY: import("@metriport/shared").USState.KY;
27
- LA: import("@metriport/shared").USState.LA;
28
- ME: import("@metriport/shared").USState.ME;
29
- MD: import("@metriport/shared").USState.MD;
30
- MA: import("@metriport/shared").USState.MA;
31
- MI: import("@metriport/shared").USState.MI;
32
- MN: import("@metriport/shared").USState.MN;
33
- MS: import("@metriport/shared").USState.MS;
34
- MO: import("@metriport/shared").USState.MO;
35
- MT: import("@metriport/shared").USState.MT;
36
- NE: import("@metriport/shared").USState.NE;
37
- NV: import("@metriport/shared").USState.NV;
38
- NH: import("@metriport/shared").USState.NH;
39
- NJ: import("@metriport/shared").USState.NJ;
40
- NM: import("@metriport/shared").USState.NM;
41
- NY: import("@metriport/shared").USState.NY;
42
- NC: import("@metriport/shared").USState.NC;
43
- ND: import("@metriport/shared").USState.ND;
44
- OH: import("@metriport/shared").USState.OH;
45
- OK: import("@metriport/shared").USState.OK;
46
- OR: import("@metriport/shared").USState.OR;
47
- PA: import("@metriport/shared").USState.PA;
48
- RI: import("@metriport/shared").USState.RI;
49
- SC: import("@metriport/shared").USState.SC;
50
- SD: import("@metriport/shared").USState.SD;
51
- TN: import("@metriport/shared").USState.TN;
52
- TX: import("@metriport/shared").USState.TX;
53
- UT: import("@metriport/shared").USState.UT;
54
- VT: import("@metriport/shared").USState.VT;
55
- VA: import("@metriport/shared").USState.VA;
56
- WA: import("@metriport/shared").USState.WA;
57
- WV: import("@metriport/shared").USState.WV;
58
- WI: import("@metriport/shared").USState.WI;
59
- WY: import("@metriport/shared").USState.WY;
60
- }>, import("@metriport/shared").USState, unknown>;
61
- }, "strip", z.ZodTypeAny, {
62
- type: "driversLicense";
63
- state: import("@metriport/shared").USState;
64
- }, {
65
- type: "driversLicense";
66
- state?: unknown;
67
- }>;
68
- export declare const driverLicenseIdentifierWithBaseSchema: z.ZodObject<z.objectUtil.extendShape<{
69
- value: z.ZodString;
70
- period: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
71
- start: z.ZodString;
72
- end: z.ZodOptional<z.ZodString>;
73
- }, "strip", z.ZodTypeAny, {
74
- start: string;
75
- end?: string | undefined;
76
- }, {
77
- start: string;
78
- end?: string | undefined;
79
- }>, z.ZodObject<{
80
- start: z.ZodOptional<z.ZodString>;
81
- end: z.ZodString;
82
- }, "strip", z.ZodTypeAny, {
83
- end: string;
84
- start?: string | undefined;
85
- }, {
86
- end: string;
87
- start?: string | undefined;
88
- }>]>>;
89
- assigner: z.ZodOptional<z.ZodString>;
90
- }, {
91
- type: z.ZodEnum<["driversLicense"]>;
92
- state: z.ZodEffects<z.ZodNativeEnum<{
93
- AL: import("@metriport/shared").USState.AL;
94
- AK: import("@metriport/shared").USState.AK;
95
- AZ: import("@metriport/shared").USState.AZ;
96
- AR: import("@metriport/shared").USState.AR;
97
- CA: import("@metriport/shared").USState.CA;
98
- CO: import("@metriport/shared").USState.CO;
99
- CT: import("@metriport/shared").USState.CT;
100
- DE: import("@metriport/shared").USState.DE;
101
- DC: import("@metriport/shared").USState.DC;
102
- FL: import("@metriport/shared").USState.FL;
103
- GA: import("@metriport/shared").USState.GA;
104
- HI: import("@metriport/shared").USState.HI;
105
- ID: import("@metriport/shared").USState.ID;
106
- IL: import("@metriport/shared").USState.IL;
107
- IN: import("@metriport/shared").USState.IN;
108
- IA: import("@metriport/shared").USState.IA;
109
- KS: import("@metriport/shared").USState.KS;
110
- KY: import("@metriport/shared").USState.KY;
111
- LA: import("@metriport/shared").USState.LA;
112
- ME: import("@metriport/shared").USState.ME;
113
- MD: import("@metriport/shared").USState.MD;
114
- MA: import("@metriport/shared").USState.MA;
115
- MI: import("@metriport/shared").USState.MI;
116
- MN: import("@metriport/shared").USState.MN;
117
- MS: import("@metriport/shared").USState.MS;
118
- MO: import("@metriport/shared").USState.MO;
119
- MT: import("@metriport/shared").USState.MT;
120
- NE: import("@metriport/shared").USState.NE;
121
- NV: import("@metriport/shared").USState.NV;
122
- NH: import("@metriport/shared").USState.NH;
123
- NJ: import("@metriport/shared").USState.NJ;
124
- NM: import("@metriport/shared").USState.NM;
125
- NY: import("@metriport/shared").USState.NY;
126
- NC: import("@metriport/shared").USState.NC;
127
- ND: import("@metriport/shared").USState.ND;
128
- OH: import("@metriport/shared").USState.OH;
129
- OK: import("@metriport/shared").USState.OK;
130
- OR: import("@metriport/shared").USState.OR;
131
- PA: import("@metriport/shared").USState.PA;
132
- RI: import("@metriport/shared").USState.RI;
133
- SC: import("@metriport/shared").USState.SC;
134
- SD: import("@metriport/shared").USState.SD;
135
- TN: import("@metriport/shared").USState.TN;
136
- TX: import("@metriport/shared").USState.TX;
137
- UT: import("@metriport/shared").USState.UT;
138
- VT: import("@metriport/shared").USState.VT;
139
- VA: import("@metriport/shared").USState.VA;
140
- WA: import("@metriport/shared").USState.WA;
141
- WV: import("@metriport/shared").USState.WV;
142
- WI: import("@metriport/shared").USState.WI;
143
- WY: import("@metriport/shared").USState.WY;
144
- }>, import("@metriport/shared").USState, unknown>;
145
- }>, "strip", z.ZodTypeAny, {
146
- value: string;
147
- type: "driversLicense";
148
- state: import("@metriport/shared").USState;
149
- period?: {
150
- start: string;
151
- end?: string | undefined;
152
- } | {
153
- end: string;
154
- start?: string | undefined;
155
- } | undefined;
156
- assigner?: string | undefined;
157
- }, {
158
- value: string;
159
- type: "driversLicense";
160
- period?: {
161
- start: string;
162
- end?: string | undefined;
163
- } | {
164
- end: string;
165
- start?: string | undefined;
166
- } | undefined;
167
- assigner?: string | undefined;
168
- state?: unknown;
169
- }>;
170
- export type DriverLicenseIdentifier = z.infer<typeof driverLicenseIdentifierWithBaseSchema>;
171
- export declare const generalTypeIdentifierSchema: z.ZodObject<{
172
- type: z.ZodEnum<["ssn"]>;
173
- }, "strip", z.ZodTypeAny, {
174
- type: "ssn";
175
- }, {
176
- type: "ssn";
177
- }>;
178
- export declare const generalTypeIdentifierWithBaseSchema: z.ZodObject<z.objectUtil.extendShape<{
179
- value: z.ZodString;
180
- period: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
181
- start: z.ZodString;
182
- end: z.ZodOptional<z.ZodString>;
183
- }, "strip", z.ZodTypeAny, {
184
- start: string;
185
- end?: string | undefined;
186
- }, {
187
- start: string;
188
- end?: string | undefined;
189
- }>, z.ZodObject<{
190
- start: z.ZodOptional<z.ZodString>;
191
- end: z.ZodString;
192
- }, "strip", z.ZodTypeAny, {
193
- end: string;
194
- start?: string | undefined;
195
- }, {
196
- end: string;
197
- start?: string | undefined;
198
- }>]>>;
199
- assigner: z.ZodOptional<z.ZodString>;
200
- }, {
201
- type: z.ZodEnum<["ssn"]>;
202
- }>, "strip", z.ZodTypeAny, {
203
- value: string;
204
- type: "ssn";
205
- period?: {
206
- start: string;
207
- end?: string | undefined;
208
- } | {
209
- end: string;
210
- start?: string | undefined;
211
- } | undefined;
212
- assigner?: string | undefined;
213
- }, {
214
- value: string;
215
- type: "ssn";
216
- period?: {
217
- start: string;
218
- end?: string | undefined;
219
- } | {
220
- end: string;
221
- start?: string | undefined;
222
- } | undefined;
223
- assigner?: string | undefined;
224
- }>;
225
- export type GeneralTypeIdentifier = z.infer<typeof generalTypeIdentifierWithBaseSchema>;
226
- export declare const personalIdentifierSchema: z.ZodUnion<[z.ZodObject<z.objectUtil.extendShape<{
227
- value: z.ZodString;
228
- period: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
229
- start: z.ZodString;
230
- end: z.ZodOptional<z.ZodString>;
231
- }, "strip", z.ZodTypeAny, {
232
- start: string;
233
- end?: string | undefined;
234
- }, {
235
- start: string;
236
- end?: string | undefined;
237
- }>, z.ZodObject<{
238
- start: z.ZodOptional<z.ZodString>;
239
- end: z.ZodString;
240
- }, "strip", z.ZodTypeAny, {
241
- end: string;
242
- start?: string | undefined;
243
- }, {
244
- end: string;
245
- start?: string | undefined;
246
- }>]>>;
247
- assigner: z.ZodOptional<z.ZodString>;
248
- }, {
249
- type: z.ZodEnum<["driversLicense"]>;
250
- state: z.ZodEffects<z.ZodNativeEnum<{
251
- AL: import("@metriport/shared").USState.AL;
252
- AK: import("@metriport/shared").USState.AK;
253
- AZ: import("@metriport/shared").USState.AZ;
254
- AR: import("@metriport/shared").USState.AR;
255
- CA: import("@metriport/shared").USState.CA;
256
- CO: import("@metriport/shared").USState.CO;
257
- CT: import("@metriport/shared").USState.CT;
258
- DE: import("@metriport/shared").USState.DE;
259
- DC: import("@metriport/shared").USState.DC;
260
- FL: import("@metriport/shared").USState.FL;
261
- GA: import("@metriport/shared").USState.GA;
262
- HI: import("@metriport/shared").USState.HI;
263
- ID: import("@metriport/shared").USState.ID;
264
- IL: import("@metriport/shared").USState.IL;
265
- IN: import("@metriport/shared").USState.IN;
266
- IA: import("@metriport/shared").USState.IA;
267
- KS: import("@metriport/shared").USState.KS;
268
- KY: import("@metriport/shared").USState.KY;
269
- LA: import("@metriport/shared").USState.LA;
270
- ME: import("@metriport/shared").USState.ME;
271
- MD: import("@metriport/shared").USState.MD;
272
- MA: import("@metriport/shared").USState.MA;
273
- MI: import("@metriport/shared").USState.MI;
274
- MN: import("@metriport/shared").USState.MN;
275
- MS: import("@metriport/shared").USState.MS;
276
- MO: import("@metriport/shared").USState.MO;
277
- MT: import("@metriport/shared").USState.MT;
278
- NE: import("@metriport/shared").USState.NE;
279
- NV: import("@metriport/shared").USState.NV;
280
- NH: import("@metriport/shared").USState.NH;
281
- NJ: import("@metriport/shared").USState.NJ;
282
- NM: import("@metriport/shared").USState.NM;
283
- NY: import("@metriport/shared").USState.NY;
284
- NC: import("@metriport/shared").USState.NC;
285
- ND: import("@metriport/shared").USState.ND;
286
- OH: import("@metriport/shared").USState.OH;
287
- OK: import("@metriport/shared").USState.OK;
288
- OR: import("@metriport/shared").USState.OR;
289
- PA: import("@metriport/shared").USState.PA;
290
- RI: import("@metriport/shared").USState.RI;
291
- SC: import("@metriport/shared").USState.SC;
292
- SD: import("@metriport/shared").USState.SD;
293
- TN: import("@metriport/shared").USState.TN;
294
- TX: import("@metriport/shared").USState.TX;
295
- UT: import("@metriport/shared").USState.UT;
296
- VT: import("@metriport/shared").USState.VT;
297
- VA: import("@metriport/shared").USState.VA;
298
- WA: import("@metriport/shared").USState.WA;
299
- WV: import("@metriport/shared").USState.WV;
300
- WI: import("@metriport/shared").USState.WI;
301
- WY: import("@metriport/shared").USState.WY;
302
- }>, import("@metriport/shared").USState, unknown>;
303
- }>, "strip", z.ZodTypeAny, {
304
- value: string;
305
- type: "driversLicense";
306
- state: import("@metriport/shared").USState;
307
- period?: {
308
- start: string;
309
- end?: string | undefined;
310
- } | {
311
- end: string;
312
- start?: string | undefined;
313
- } | undefined;
314
- assigner?: string | undefined;
315
- }, {
316
- value: string;
317
- type: "driversLicense";
318
- period?: {
319
- start: string;
320
- end?: string | undefined;
321
- } | {
322
- end: string;
323
- start?: string | undefined;
324
- } | undefined;
325
- assigner?: string | undefined;
326
- state?: unknown;
327
- }>, z.ZodObject<z.objectUtil.extendShape<{
328
- value: z.ZodString;
329
- period: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
330
- start: z.ZodString;
331
- end: z.ZodOptional<z.ZodString>;
332
- }, "strip", z.ZodTypeAny, {
333
- start: string;
334
- end?: string | undefined;
335
- }, {
336
- start: string;
337
- end?: string | undefined;
338
- }>, z.ZodObject<{
339
- start: z.ZodOptional<z.ZodString>;
340
- end: z.ZodString;
341
- }, "strip", z.ZodTypeAny, {
342
- end: string;
343
- start?: string | undefined;
344
- }, {
345
- end: string;
346
- start?: string | undefined;
347
- }>]>>;
348
- assigner: z.ZodOptional<z.ZodString>;
349
- }, {
350
- type: z.ZodEnum<["ssn"]>;
351
- }>, "strip", z.ZodTypeAny, {
352
- value: string;
353
- type: "ssn";
354
- period?: {
355
- start: string;
356
- end?: string | undefined;
357
- } | {
358
- end: string;
359
- start?: string | undefined;
360
- } | undefined;
361
- assigner?: string | undefined;
362
- }, {
363
- value: string;
364
- type: "ssn";
365
- period?: {
366
- start: string;
367
- end?: string | undefined;
368
- } | {
369
- end: string;
370
- start?: string | undefined;
371
- } | undefined;
372
- assigner?: string | undefined;
373
- }>]>;
374
- export type PersonalIdentifier = z.infer<typeof personalIdentifierSchema>;
375
- export declare const genderAtBirthSchema: z.ZodEnum<["F", "M", "O", "U"]>;
376
- export declare const emailSchema: z.ZodString;
377
- export declare const contactSchema: z.ZodEffects<z.ZodObject<{
378
- phone: z.ZodUnion<[z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, z.ZodNull]>, z.ZodUndefined]>;
379
- email: z.ZodOptional<z.ZodNullable<z.ZodString>>;
380
- }, "strip", z.ZodTypeAny, {
381
- phone?: string | null | undefined;
382
- email?: string | null | undefined;
383
- }, {
384
- phone?: string | null | undefined;
385
- email?: string | null | undefined;
386
- }>, {
387
- phone?: string | null | undefined;
388
- email?: string | null | undefined;
389
- }, {
390
- phone?: string | null | undefined;
391
- email?: string | null | undefined;
392
- }>;
393
- export type Contact = z.infer<typeof contactSchema>;
394
- export declare const demographicsSchema: z.ZodObject<{
395
- firstName: z.ZodString;
396
- lastName: z.ZodString;
397
- dob: z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>;
398
- genderAtBirth: z.ZodEnum<["F", "M", "O", "U"]>;
399
- personalIdentifiers: z.ZodOptional<z.ZodArray<z.ZodUnion<[z.ZodObject<z.objectUtil.extendShape<{
400
- value: z.ZodString;
401
- period: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
402
- start: z.ZodString;
403
- end: z.ZodOptional<z.ZodString>;
404
- }, "strip", z.ZodTypeAny, {
405
- start: string;
406
- end?: string | undefined;
407
- }, {
408
- start: string;
409
- end?: string | undefined;
410
- }>, z.ZodObject<{
411
- start: z.ZodOptional<z.ZodString>;
412
- end: z.ZodString;
413
- }, "strip", z.ZodTypeAny, {
414
- end: string;
415
- start?: string | undefined;
416
- }, {
417
- end: string;
418
- start?: string | undefined;
419
- }>]>>;
420
- assigner: z.ZodOptional<z.ZodString>;
421
- }, {
422
- type: z.ZodEnum<["driversLicense"]>;
423
- state: z.ZodEffects<z.ZodNativeEnum<{
424
- AL: import("@metriport/shared").USState.AL;
425
- AK: import("@metriport/shared").USState.AK;
426
- AZ: import("@metriport/shared").USState.AZ;
427
- AR: import("@metriport/shared").USState.AR;
428
- CA: import("@metriport/shared").USState.CA;
429
- CO: import("@metriport/shared").USState.CO;
430
- CT: import("@metriport/shared").USState.CT;
431
- DE: import("@metriport/shared").USState.DE;
432
- DC: import("@metriport/shared").USState.DC;
433
- FL: import("@metriport/shared").USState.FL;
434
- GA: import("@metriport/shared").USState.GA;
435
- HI: import("@metriport/shared").USState.HI;
436
- ID: import("@metriport/shared").USState.ID;
437
- IL: import("@metriport/shared").USState.IL;
438
- IN: import("@metriport/shared").USState.IN;
439
- IA: import("@metriport/shared").USState.IA;
440
- KS: import("@metriport/shared").USState.KS;
441
- KY: import("@metriport/shared").USState.KY;
442
- LA: import("@metriport/shared").USState.LA;
443
- ME: import("@metriport/shared").USState.ME;
444
- MD: import("@metriport/shared").USState.MD;
445
- MA: import("@metriport/shared").USState.MA;
446
- MI: import("@metriport/shared").USState.MI;
447
- MN: import("@metriport/shared").USState.MN;
448
- MS: import("@metriport/shared").USState.MS;
449
- MO: import("@metriport/shared").USState.MO;
450
- MT: import("@metriport/shared").USState.MT;
451
- NE: import("@metriport/shared").USState.NE;
452
- NV: import("@metriport/shared").USState.NV;
453
- NH: import("@metriport/shared").USState.NH;
454
- NJ: import("@metriport/shared").USState.NJ;
455
- NM: import("@metriport/shared").USState.NM;
456
- NY: import("@metriport/shared").USState.NY;
457
- NC: import("@metriport/shared").USState.NC;
458
- ND: import("@metriport/shared").USState.ND;
459
- OH: import("@metriport/shared").USState.OH;
460
- OK: import("@metriport/shared").USState.OK;
461
- OR: import("@metriport/shared").USState.OR;
462
- PA: import("@metriport/shared").USState.PA;
463
- RI: import("@metriport/shared").USState.RI;
464
- SC: import("@metriport/shared").USState.SC;
465
- SD: import("@metriport/shared").USState.SD;
466
- TN: import("@metriport/shared").USState.TN;
467
- TX: import("@metriport/shared").USState.TX;
468
- UT: import("@metriport/shared").USState.UT;
469
- VT: import("@metriport/shared").USState.VT;
470
- VA: import("@metriport/shared").USState.VA;
471
- WA: import("@metriport/shared").USState.WA;
472
- WV: import("@metriport/shared").USState.WV;
473
- WI: import("@metriport/shared").USState.WI;
474
- WY: import("@metriport/shared").USState.WY;
475
- }>, import("@metriport/shared").USState, unknown>;
476
- }>, "strip", z.ZodTypeAny, {
477
- value: string;
478
- type: "driversLicense";
479
- state: import("@metriport/shared").USState;
480
- period?: {
481
- start: string;
482
- end?: string | undefined;
483
- } | {
484
- end: string;
485
- start?: string | undefined;
486
- } | undefined;
487
- assigner?: string | undefined;
488
- }, {
489
- value: string;
490
- type: "driversLicense";
491
- period?: {
492
- start: string;
493
- end?: string | undefined;
494
- } | {
495
- end: string;
496
- start?: string | undefined;
497
- } | undefined;
498
- assigner?: string | undefined;
499
- state?: unknown;
500
- }>, z.ZodObject<z.objectUtil.extendShape<{
501
- value: z.ZodString;
502
- period: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
503
- start: z.ZodString;
504
- end: z.ZodOptional<z.ZodString>;
505
- }, "strip", z.ZodTypeAny, {
506
- start: string;
507
- end?: string | undefined;
508
- }, {
509
- start: string;
510
- end?: string | undefined;
511
- }>, z.ZodObject<{
512
- start: z.ZodOptional<z.ZodString>;
513
- end: z.ZodString;
514
- }, "strip", z.ZodTypeAny, {
515
- end: string;
516
- start?: string | undefined;
517
- }, {
518
- end: string;
519
- start?: string | undefined;
520
- }>]>>;
521
- assigner: z.ZodOptional<z.ZodString>;
522
- }, {
523
- type: z.ZodEnum<["ssn"]>;
524
- }>, "strip", z.ZodTypeAny, {
525
- value: string;
526
- type: "ssn";
527
- period?: {
528
- start: string;
529
- end?: string | undefined;
530
- } | {
531
- end: string;
532
- start?: string | undefined;
533
- } | undefined;
534
- assigner?: string | undefined;
535
- }, {
536
- value: string;
537
- type: "ssn";
538
- period?: {
539
- start: string;
540
- end?: string | undefined;
541
- } | {
542
- end: string;
543
- start?: string | undefined;
544
- } | undefined;
545
- assigner?: string | undefined;
546
- }>]>, "many">>;
547
- address: z.ZodUnion<[z.ZodArray<z.ZodObject<{
548
- addressLine1: z.ZodString;
549
- addressLine2: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodOptional<z.ZodString>]>, string | undefined, string | undefined>;
550
- city: z.ZodString;
551
- state: z.ZodUnion<[z.ZodEffects<z.ZodNativeEnum<{
552
- AL: import("@metriport/shared").USState.AL;
553
- AK: import("@metriport/shared").USState.AK;
554
- AZ: import("@metriport/shared").USState.AZ;
555
- AR: import("@metriport/shared").USState.AR;
556
- CA: import("@metriport/shared").USState.CA;
557
- CO: import("@metriport/shared").USState.CO;
558
- CT: import("@metriport/shared").USState.CT;
559
- DE: import("@metriport/shared").USState.DE;
560
- DC: import("@metriport/shared").USState.DC;
561
- FL: import("@metriport/shared").USState.FL;
562
- GA: import("@metriport/shared").USState.GA;
563
- HI: import("@metriport/shared").USState.HI;
564
- ID: import("@metriport/shared").USState.ID;
565
- IL: import("@metriport/shared").USState.IL;
566
- IN: import("@metriport/shared").USState.IN;
567
- IA: import("@metriport/shared").USState.IA;
568
- KS: import("@metriport/shared").USState.KS;
569
- KY: import("@metriport/shared").USState.KY;
570
- LA: import("@metriport/shared").USState.LA;
571
- ME: import("@metriport/shared").USState.ME;
572
- MD: import("@metriport/shared").USState.MD;
573
- MA: import("@metriport/shared").USState.MA;
574
- MI: import("@metriport/shared").USState.MI;
575
- MN: import("@metriport/shared").USState.MN;
576
- MS: import("@metriport/shared").USState.MS;
577
- MO: import("@metriport/shared").USState.MO;
578
- MT: import("@metriport/shared").USState.MT;
579
- NE: import("@metriport/shared").USState.NE;
580
- NV: import("@metriport/shared").USState.NV;
581
- NH: import("@metriport/shared").USState.NH;
582
- NJ: import("@metriport/shared").USState.NJ;
583
- NM: import("@metriport/shared").USState.NM;
584
- NY: import("@metriport/shared").USState.NY;
585
- NC: import("@metriport/shared").USState.NC;
586
- ND: import("@metriport/shared").USState.ND;
587
- OH: import("@metriport/shared").USState.OH;
588
- OK: import("@metriport/shared").USState.OK;
589
- OR: import("@metriport/shared").USState.OR;
590
- PA: import("@metriport/shared").USState.PA;
591
- RI: import("@metriport/shared").USState.RI;
592
- SC: import("@metriport/shared").USState.SC;
593
- SD: import("@metriport/shared").USState.SD;
594
- TN: import("@metriport/shared").USState.TN;
595
- TX: import("@metriport/shared").USState.TX;
596
- UT: import("@metriport/shared").USState.UT;
597
- VT: import("@metriport/shared").USState.VT;
598
- VA: import("@metriport/shared").USState.VA;
599
- WA: import("@metriport/shared").USState.WA;
600
- WV: import("@metriport/shared").USState.WV;
601
- WI: import("@metriport/shared").USState.WI;
602
- WY: import("@metriport/shared").USState.WY;
603
- }>, import("@metriport/shared").USState, unknown>, z.ZodEffects<z.ZodNativeEnum<typeof import("@metriport/shared").USTerritory>, import("@metriport/shared").USTerritory, unknown>]>;
604
- zip: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
605
- coordinates: z.ZodOptional<z.ZodObject<{
606
- lat: z.ZodNumber;
607
- lon: z.ZodNumber;
608
- }, "strip", z.ZodTypeAny, {
609
- lat: number;
610
- lon: number;
611
- }, {
612
- lat: number;
613
- lon: number;
614
- }>>;
615
- country: z.ZodDefault<z.ZodOptional<z.ZodLiteral<"USA">>>;
616
- }, "strip", z.ZodTypeAny, {
617
- state: import("@metriport/shared").USState | import("@metriport/shared").USTerritory;
618
- addressLine1: string;
619
- city: string;
620
- zip: string;
621
- country: "USA";
622
- addressLine2?: string | undefined;
623
- coordinates?: {
624
- lat: number;
625
- lon: number;
626
- } | undefined;
627
- }, {
628
- addressLine1: string;
629
- city: string;
630
- zip: string;
631
- state?: unknown;
632
- addressLine2?: string | undefined;
633
- coordinates?: {
634
- lat: number;
635
- lon: number;
636
- } | undefined;
637
- country?: "USA" | undefined;
638
- }>, "atleastone">, z.ZodObject<{
639
- addressLine1: z.ZodString;
640
- addressLine2: z.ZodEffects<z.ZodUnion<[z.ZodString, z.ZodOptional<z.ZodString>]>, string | undefined, string | undefined>;
641
- city: z.ZodString;
642
- state: z.ZodUnion<[z.ZodEffects<z.ZodNativeEnum<{
643
- AL: import("@metriport/shared").USState.AL;
644
- AK: import("@metriport/shared").USState.AK;
645
- AZ: import("@metriport/shared").USState.AZ;
646
- AR: import("@metriport/shared").USState.AR;
647
- CA: import("@metriport/shared").USState.CA;
648
- CO: import("@metriport/shared").USState.CO;
649
- CT: import("@metriport/shared").USState.CT;
650
- DE: import("@metriport/shared").USState.DE;
651
- DC: import("@metriport/shared").USState.DC;
652
- FL: import("@metriport/shared").USState.FL;
653
- GA: import("@metriport/shared").USState.GA;
654
- HI: import("@metriport/shared").USState.HI;
655
- ID: import("@metriport/shared").USState.ID;
656
- IL: import("@metriport/shared").USState.IL;
657
- IN: import("@metriport/shared").USState.IN;
658
- IA: import("@metriport/shared").USState.IA;
659
- KS: import("@metriport/shared").USState.KS;
660
- KY: import("@metriport/shared").USState.KY;
661
- LA: import("@metriport/shared").USState.LA;
662
- ME: import("@metriport/shared").USState.ME;
663
- MD: import("@metriport/shared").USState.MD;
664
- MA: import("@metriport/shared").USState.MA;
665
- MI: import("@metriport/shared").USState.MI;
666
- MN: import("@metriport/shared").USState.MN;
667
- MS: import("@metriport/shared").USState.MS;
668
- MO: import("@metriport/shared").USState.MO;
669
- MT: import("@metriport/shared").USState.MT;
670
- NE: import("@metriport/shared").USState.NE;
671
- NV: import("@metriport/shared").USState.NV;
672
- NH: import("@metriport/shared").USState.NH;
673
- NJ: import("@metriport/shared").USState.NJ;
674
- NM: import("@metriport/shared").USState.NM;
675
- NY: import("@metriport/shared").USState.NY;
676
- NC: import("@metriport/shared").USState.NC;
677
- ND: import("@metriport/shared").USState.ND;
678
- OH: import("@metriport/shared").USState.OH;
679
- OK: import("@metriport/shared").USState.OK;
680
- OR: import("@metriport/shared").USState.OR;
681
- PA: import("@metriport/shared").USState.PA;
682
- RI: import("@metriport/shared").USState.RI;
683
- SC: import("@metriport/shared").USState.SC;
684
- SD: import("@metriport/shared").USState.SD;
685
- TN: import("@metriport/shared").USState.TN;
686
- TX: import("@metriport/shared").USState.TX;
687
- UT: import("@metriport/shared").USState.UT;
688
- VT: import("@metriport/shared").USState.VT;
689
- VA: import("@metriport/shared").USState.VA;
690
- WA: import("@metriport/shared").USState.WA;
691
- WV: import("@metriport/shared").USState.WV;
692
- WI: import("@metriport/shared").USState.WI;
693
- WY: import("@metriport/shared").USState.WY;
694
- }>, import("@metriport/shared").USState, unknown>, z.ZodEffects<z.ZodNativeEnum<typeof import("@metriport/shared").USTerritory>, import("@metriport/shared").USTerritory, unknown>]>;
695
- zip: z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>;
696
- coordinates: z.ZodOptional<z.ZodObject<{
697
- lat: z.ZodNumber;
698
- lon: z.ZodNumber;
699
- }, "strip", z.ZodTypeAny, {
700
- lat: number;
701
- lon: number;
702
- }, {
703
- lat: number;
704
- lon: number;
705
- }>>;
706
- country: z.ZodDefault<z.ZodOptional<z.ZodLiteral<"USA">>>;
707
- }, "strip", z.ZodTypeAny, {
708
- state: import("@metriport/shared").USState | import("@metriport/shared").USTerritory;
709
- addressLine1: string;
710
- city: string;
711
- zip: string;
712
- country: "USA";
713
- addressLine2?: string | undefined;
714
- coordinates?: {
715
- lat: number;
716
- lon: number;
717
- } | undefined;
718
- }, {
719
- addressLine1: string;
720
- city: string;
721
- zip: string;
722
- state?: unknown;
723
- addressLine2?: string | undefined;
724
- coordinates?: {
725
- lat: number;
726
- lon: number;
727
- } | undefined;
728
- country?: "USA" | undefined;
729
- }>]>;
730
- contact: z.ZodUnion<[z.ZodOptional<z.ZodArray<z.ZodEffects<z.ZodObject<{
731
- phone: z.ZodUnion<[z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, z.ZodNull]>, z.ZodUndefined]>;
732
- email: z.ZodOptional<z.ZodNullable<z.ZodString>>;
733
- }, "strip", z.ZodTypeAny, {
734
- phone?: string | null | undefined;
735
- email?: string | null | undefined;
736
- }, {
737
- phone?: string | null | undefined;
738
- email?: string | null | undefined;
739
- }>, {
740
- phone?: string | null | undefined;
741
- email?: string | null | undefined;
742
- }, {
743
- phone?: string | null | undefined;
744
- email?: string | null | undefined;
745
- }>, "many">>, z.ZodOptional<z.ZodEffects<z.ZodObject<{
746
- phone: z.ZodUnion<[z.ZodUnion<[z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, z.ZodNull]>, z.ZodUndefined]>;
747
- email: z.ZodOptional<z.ZodNullable<z.ZodString>>;
748
- }, "strip", z.ZodTypeAny, {
749
- phone?: string | null | undefined;
750
- email?: string | null | undefined;
751
- }, {
752
- phone?: string | null | undefined;
753
- email?: string | null | undefined;
754
- }>, {
755
- phone?: string | null | undefined;
756
- email?: string | null | undefined;
757
- }, {
758
- phone?: string | null | undefined;
759
- email?: string | null | undefined;
760
- }>>]>;
761
- }, "strip", z.ZodTypeAny, {
762
- firstName: string;
763
- lastName: string;
764
- dob: string;
765
- genderAtBirth: "F" | "M" | "O" | "U";
766
- address: {
767
- state: import("@metriport/shared").USState | import("@metriport/shared").USTerritory;
768
- addressLine1: string;
769
- city: string;
770
- zip: string;
771
- country: "USA";
772
- addressLine2?: string | undefined;
773
- coordinates?: {
774
- lat: number;
775
- lon: number;
776
- } | undefined;
777
- } | [{
778
- state: import("@metriport/shared").USState | import("@metriport/shared").USTerritory;
779
- addressLine1: string;
780
- city: string;
781
- zip: string;
782
- country: "USA";
783
- addressLine2?: string | undefined;
784
- coordinates?: {
785
- lat: number;
786
- lon: number;
787
- } | undefined;
788
- }, ...{
789
- state: import("@metriport/shared").USState | import("@metriport/shared").USTerritory;
790
- addressLine1: string;
791
- city: string;
792
- zip: string;
793
- country: "USA";
794
- addressLine2?: string | undefined;
795
- coordinates?: {
796
- lat: number;
797
- lon: number;
798
- } | undefined;
799
- }[]];
800
- personalIdentifiers?: ({
801
- value: string;
802
- type: "driversLicense";
803
- state: import("@metriport/shared").USState;
804
- period?: {
805
- start: string;
806
- end?: string | undefined;
807
- } | {
808
- end: string;
809
- start?: string | undefined;
810
- } | undefined;
811
- assigner?: string | undefined;
812
- } | {
813
- value: string;
814
- type: "ssn";
815
- period?: {
816
- start: string;
817
- end?: string | undefined;
818
- } | {
819
- end: string;
820
- start?: string | undefined;
821
- } | undefined;
822
- assigner?: string | undefined;
823
- })[] | undefined;
824
- contact?: {
825
- phone?: string | null | undefined;
826
- email?: string | null | undefined;
827
- } | {
828
- phone?: string | null | undefined;
829
- email?: string | null | undefined;
830
- }[] | undefined;
831
- }, {
832
- firstName: string;
833
- lastName: string;
834
- dob: string;
835
- genderAtBirth: "F" | "M" | "O" | "U";
836
- address: {
837
- addressLine1: string;
838
- city: string;
839
- zip: string;
840
- state?: unknown;
841
- addressLine2?: string | undefined;
842
- coordinates?: {
843
- lat: number;
844
- lon: number;
845
- } | undefined;
846
- country?: "USA" | undefined;
847
- } | [{
848
- addressLine1: string;
849
- city: string;
850
- zip: string;
851
- state?: unknown;
852
- addressLine2?: string | undefined;
853
- coordinates?: {
854
- lat: number;
855
- lon: number;
856
- } | undefined;
857
- country?: "USA" | undefined;
858
- }, ...{
859
- addressLine1: string;
860
- city: string;
861
- zip: string;
862
- state?: unknown;
863
- addressLine2?: string | undefined;
864
- coordinates?: {
865
- lat: number;
866
- lon: number;
867
- } | undefined;
868
- country?: "USA" | undefined;
869
- }[]];
870
- personalIdentifiers?: ({
871
- value: string;
872
- type: "driversLicense";
873
- period?: {
874
- start: string;
875
- end?: string | undefined;
876
- } | {
877
- end: string;
878
- start?: string | undefined;
879
- } | undefined;
880
- assigner?: string | undefined;
881
- state?: unknown;
882
- } | {
883
- value: string;
884
- type: "ssn";
885
- period?: {
886
- start: string;
887
- end?: string | undefined;
888
- } | {
889
- end: string;
890
- start?: string | undefined;
891
- } | undefined;
892
- assigner?: string | undefined;
893
- })[] | undefined;
894
- contact?: {
895
- phone?: string | null | undefined;
896
- email?: string | null | undefined;
897
- } | {
898
- phone?: string | null | undefined;
899
- email?: string | null | undefined;
900
- }[] | undefined;
901
- }>;
902
- export type Demographics = z.infer<typeof demographicsSchema>;
903
- //# sourceMappingURL=demographics%20copy.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"demographics copy.d.ts","sourceRoot":"","sources":["../../../src/medical/models/demographics copy.ts"],"names":[],"mappings":"AAMA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,eAAO,MAAM,0BAA0B,kBAAmB,CAAC;AAC3D,eAAO,MAAM,gCAAgC,6BAA8B,CAAC;AAC5E,MAAM,MAAM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AAC;AAEpD,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAQ7B,CAAC;AAEH,MAAM,MAAM,YAAY,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kBAAkB,CAAC,CAAC"}
@@ -1,59 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.demographicsSchema = exports.contactSchema = exports.emailSchema = exports.genderAtBirthSchema = exports.personalIdentifierSchema = exports.generalTypeIdentifierWithBaseSchema = exports.generalTypeIdentifierSchema = exports.driverLicenseIdentifierWithBaseSchema = exports.driverLicenseIdentifierSchema = exports.driversLicensePersonalIdentifier = exports.generalPersonalIdentifiers = void 0;
4
- const shared_1 = require("@metriport/shared");
5
- const zod_1 = require("zod");
6
- const shared_2 = require("../../shared");
7
- const address_1 = require("./common/address");
8
- const us_data_1 = require("./common/us-data");
9
- exports.generalPersonalIdentifiers = ["ssn"];
10
- exports.driversLicensePersonalIdentifier = ["driversLicense"];
11
- const basePersonalIdentifierSchema = zod_1.z.object({
12
- value: zod_1.z.string(),
13
- period: zod_1.z
14
- .object({
15
- start: zod_1.z.string(),
16
- end: zod_1.z.string().optional(),
17
- })
18
- .or(zod_1.z.object({
19
- start: zod_1.z.string().optional(),
20
- end: zod_1.z.string(),
21
- }))
22
- .optional(),
23
- assigner: zod_1.z.string().optional(),
24
- });
25
- exports.driverLicenseIdentifierSchema = zod_1.z.object({
26
- type: zod_1.z.enum(exports.driversLicensePersonalIdentifier),
27
- state: us_data_1.usStateSchema,
28
- });
29
- exports.driverLicenseIdentifierWithBaseSchema = basePersonalIdentifierSchema.merge(exports.driverLicenseIdentifierSchema);
30
- exports.generalTypeIdentifierSchema = zod_1.z.object({
31
- type: zod_1.z.enum(exports.generalPersonalIdentifiers),
32
- });
33
- exports.generalTypeIdentifierWithBaseSchema = basePersonalIdentifierSchema.merge(exports.generalTypeIdentifierSchema);
34
- exports.personalIdentifierSchema = exports.driverLicenseIdentifierWithBaseSchema.or(exports.generalTypeIdentifierWithBaseSchema);
35
- exports.genderAtBirthSchema = zod_1.z.enum(["F", "M", "O", "U"]);
36
- exports.emailSchema = zod_1.z.string().email();
37
- exports.contactSchema = zod_1.z
38
- .object({
39
- phone: zod_1.z.coerce
40
- .string()
41
- .transform(shared_1.normalizeUsPhoneWithPlusOne)
42
- .refine(shared_1.isPhoneValid, {
43
- message: `Phone must be a string consisting of ${shared_1.phoneLength} numbers. For example: ${shared_1.examplePhoneNumber}`,
44
- })
45
- .or(zod_1.z.null())
46
- .or(zod_1.z.undefined()),
47
- email: exports.emailSchema.nullish(),
48
- })
49
- .refine(c => c.email || c.phone, { message: "Either email or phone must be present" });
50
- exports.demographicsSchema = zod_1.z.object({
51
- firstName: shared_2.defaultNameString,
52
- lastName: shared_2.defaultNameString,
53
- dob: shared_2.validDateOfBirthString,
54
- genderAtBirth: exports.genderAtBirthSchema,
55
- personalIdentifiers: zod_1.z.array(exports.personalIdentifierSchema).optional(),
56
- address: zod_1.z.array(address_1.addressSchema).nonempty().or(address_1.addressSchema),
57
- contact: zod_1.z.array(exports.contactSchema).optional().or(exports.contactSchema.optional()),
58
- });
59
- //# sourceMappingURL=demographics%20copy.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"demographics copy.js","sourceRoot":"","sources":["../../../src/medical/models/demographics copy.ts"],"names":[],"mappings":";;;AAAA,8CAK2B;AAC3B,6BAAwB;AACxB,yCAAyE;AACzE,8CAAiD;AACjD,8CAAiD;AAEpC,QAAA,0BAA0B,GAAG,CAAC,KAAK,CAAU,CAAC;AAC9C,QAAA,gCAAgC,GAAG,CAAC,gBAAgB,CAAU,CAAC;AAI5E,MAAM,4BAA4B,GAAG,OAAC,CAAC,MAAM,CAAC;IAC5C,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE;IACjB,MAAM,EAAE,OAAC;SACN,MAAM,CAAC;QACN,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE;QACjB,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;KAC3B,CAAC;SACD,EAAE,CACD,OAAC,CAAC,MAAM,CAAC;QACP,KAAK,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;QAC5B,GAAG,EAAE,OAAC,CAAC,MAAM,EAAE;KAChB,CAAC,CACH;SACA,QAAQ,EAAE;IACb,QAAQ,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;CAChC,CAAC,CAAC;AAEU,QAAA,6BAA6B,GAAG,OAAC,CAAC,MAAM,CAAC;IACpD,IAAI,EAAE,OAAC,CAAC,IAAI,CAAC,wCAAgC,CAAC;IAC9C,KAAK,EAAE,uBAAa;CACrB,CAAC,CAAC;AACU,QAAA,qCAAqC,GAAG,4BAA4B,CAAC,KAAK,CACrF,qCAA6B,CAC9B,CAAC;AAGW,QAAA,2BAA2B,GAAG,OAAC,CAAC,MAAM,CAAC;IAClD,IAAI,EAAE,OAAC,CAAC,IAAI,CAAC,kCAA0B,CAAC;CACzC,CAAC,CAAC;A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AC,KAAK,CAAC,qBAAa,CAAC,CAAC,QAAQ,EAAE,CAAC,EAAE,CAAC,qBAAa,CAAC,QAAQ,EAAE,CAAC;CACxE,CAAC,CAAC"}
@@ -1,28 +0,0 @@
1
- import { z } from "zod";
2
- declare const subscriptions: z.ZodObject<{
3
- adt: z.ZodOptional<z.ZodBoolean>;
4
- }, "strip", z.ZodTypeAny, {
5
- adt?: boolean | undefined;
6
- }, {
7
- adt?: boolean | undefined;
8
- }>;
9
- export type PatientSubscriptions = z.infer<typeof subscriptions>;
10
- export declare const patientSubscriptionsSchema: z.ZodObject<{
11
- subscriptions: z.ZodOptional<z.ZodObject<{
12
- adt: z.ZodOptional<z.ZodBoolean>;
13
- }, "strip", z.ZodTypeAny, {
14
- adt?: boolean | undefined;
15
- }, {
16
- adt?: boolean | undefined;
17
- }>>;
18
- }, "strip", z.ZodTypeAny, {
19
- subscriptions?: {
20
- adt?: boolean | undefined;
21
- } | undefined;
22
- }, {
23
- subscriptions?: {
24
- adt?: boolean | undefined;
25
- } | undefined;
26
- }>;
27
- export {};
28
- //# sourceMappingURL=subscriptions.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"subscriptions.d.ts","sourceRoot":"","sources":["../../../src/medical/models/subscriptions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,QAAA,MAAM,aAAa;;;;;;EAEjB,CAAC;AAEH,MAAM,MAAM,oBAAoB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,aAAa,CAAC,CAAC;AAEjE,eAAO,MAAM,0BAA0B;;;;;;;;;;;;;;;;EAErC,CAAC"}
@@ -1,11 +0,0 @@
1
- "use strict";
2
- Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.patientSubscriptionsSchema = void 0;
4
- const zod_1 = require("zod");
5
- const subscriptions = zod_1.z.object({
6
- adt: zod_1.z.boolean().optional(),
7
- });
8
- exports.patientSubscriptionsSchema = zod_1.z.object({
9
- subscriptions: subscriptions.optional(),
10
- });
11
- //# sourceMappingURL=subscriptions.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"subscriptions.js","sourceRoot":"","sources":["../../../src/medical/models/subscriptions.ts"],"names":[],"mappings":";;;AAAA,6BAAwB;AAExB,MAAM,aAAa,GAAG,OAAC,CAAC,MAAM,CAAC;IAC7B,GAAG,EAAE,OAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;CAC5B,CAAC,CAAC;AAIU,QAAA,0BAA0B,GAAG,OAAC,CAAC,MAAM,CAAC;IACjD,aAAa,EAAE,aAAa,CAAC,QAAQ,EAAE;CACxC,CAAC,CAAC"}