evo360-types 1.2.23 → 1.2.25

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.
@@ -492,6 +492,7 @@ export declare const zAppointmentRequestTypeSchema: z.ZodObject<z.objectUtil.ext
492
492
  color?: string | undefined;
493
493
  }>, "many">>>;
494
494
  }>, z.ZodTypeAny, "passthrough">>;
495
+ export declare const zAppointmentStatusTypeSchema: z.ZodEnum<["rs", "cf", "ci", "co", "cx", "ns"]>;
495
496
  export declare const zAppointmentStatusSchema: z.ZodObject<z.objectUtil.extendShape<{
496
497
  id: z.ZodString;
497
498
  ref: z.ZodAny;
@@ -540,6 +541,7 @@ export declare const zMedicationSchema: z.ZodObject<{
540
541
  dosage?: string | null | undefined;
541
542
  frequency?: string | null | undefined;
542
543
  }>;
544
+ export declare const zSeveritySchema: z.ZodEnum<["Mild", "Moderate", "Severe", "Unknown"]>;
543
545
  export declare const zChronicConditionSchema: z.ZodObject<z.objectUtil.extendShape<{
544
546
  id: z.ZodString;
545
547
  ref: z.ZodAny;
@@ -552,7 +554,7 @@ export declare const zChronicConditionSchema: z.ZodObject<z.objectUtil.extendSha
552
554
  code: z.ZodString;
553
555
  name: z.ZodString;
554
556
  diagnosis_date: z.ZodOptional<z.ZodNullable<z.ZodString>>;
555
- severity: z.ZodDefault<z.ZodOptional<z.ZodEnum<["Mild", "Moderate", "Severe", "Unknown"]>>>;
557
+ severity: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodEnum<["Mild", "Moderate", "Severe", "Unknown"]>>>>;
556
558
  controlled: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
557
559
  medications: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
558
560
  name: z.ZodString;
@@ -574,7 +576,7 @@ export declare const zChronicConditionSchema: z.ZodObject<z.objectUtil.extendSha
574
576
  id: string;
575
577
  tenant: string;
576
578
  model_ver: number;
577
- severity: "Mild" | "Moderate" | "Severe" | "Unknown";
579
+ severity: "Mild" | "Moderate" | "Severe" | "Unknown" | null;
578
580
  controlled: boolean;
579
581
  notes: string | null;
580
582
  ref?: any;
@@ -598,7 +600,7 @@ export declare const zChronicConditionSchema: z.ZodObject<z.objectUtil.extendSha
598
600
  updated_at?: Date | null | undefined;
599
601
  deleted_at?: Date | null | undefined;
600
602
  diagnosis_date?: string | null | undefined;
601
- severity?: "Mild" | "Moderate" | "Severe" | "Unknown" | undefined;
603
+ severity?: "Mild" | "Moderate" | "Severe" | "Unknown" | null | undefined;
602
604
  controlled?: boolean | undefined;
603
605
  medications?: {
604
606
  name: string;
@@ -607,6 +609,8 @@ export declare const zChronicConditionSchema: z.ZodObject<z.objectUtil.extendSha
607
609
  }[] | null | undefined;
608
610
  notes?: string | null | undefined;
609
611
  }>;
612
+ export declare const zAllergyKindSchema: z.ZodEnum<["Food", "Drug", "Insect", "Other"]>;
613
+ export declare const zAllergySeveritySchema: z.ZodEnum<["Mild", "Moderate", "Severe", "Unknown"]>;
610
614
  export declare const zAllergySchema: z.ZodObject<z.objectUtil.extendShape<{
611
615
  id: z.ZodString;
612
616
  ref: z.ZodAny;
@@ -645,6 +649,7 @@ export declare const zAllergySchema: z.ZodObject<z.objectUtil.extendShape<{
645
649
  severity?: "Mild" | "Moderate" | "Severe" | "Unknown" | null | undefined;
646
650
  kind?: "Food" | "Drug" | "Insect" | "Other" | null | undefined;
647
651
  }>;
652
+ export declare const zMedicalCouncilUFSchema: z.ZodEnum<["AC", "AL", "AP", "AM", "BA", "CE", "ES", "GO", "MA", "MT", "MS", "MG", "PA", "PB", "PR", "PE", "PI", "RJ", "RN", "RS", "RO", "RR", "SC", "SP", "SE", "TO", "DF", "BR"]>;
648
653
  export declare const zMedicalCouncilSchema: z.ZodObject<z.objectUtil.extendShape<{
649
654
  id: z.ZodString;
650
655
  ref: z.ZodAny;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.zMedicalCouncilSchema = exports.zAllergySchema = exports.zChronicConditionSchema = exports.zMedicationSchema = exports.zAppointmentStatusSchema = exports.zAppointmentRequestTypeSchema = exports.zAppointmentSourceSchema = exports.zPatientSourceSchema = exports.zDistChannelSchema = exports.zDistChannelTypeSchema = exports.zSpecialtySchema = exports.zSpecialtyTypeSchema = void 0;
3
+ exports.zMedicalCouncilSchema = exports.zMedicalCouncilUFSchema = exports.zAllergySchema = exports.zAllergySeveritySchema = exports.zAllergyKindSchema = exports.zChronicConditionSchema = exports.zSeveritySchema = exports.zMedicationSchema = exports.zAppointmentStatusSchema = exports.zAppointmentStatusTypeSchema = exports.zAppointmentRequestTypeSchema = exports.zAppointmentSourceSchema = exports.zPatientSourceSchema = exports.zDistChannelSchema = exports.zDistChannelTypeSchema = exports.zSpecialtySchema = exports.zSpecialtyTypeSchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const zod_schemas_1 = require("../../shared/zod-schemas");
6
6
  exports.zSpecialtyTypeSchema = zod_schemas_1.zFireDocSchema
@@ -58,80 +58,87 @@ exports.zAppointmentRequestTypeSchema = zod_schemas_1.zFireDocSchema
58
58
  tags: zod_1.z.array(zod_schemas_1.zTagSchema).nullable().optional(),
59
59
  })
60
60
  .passthrough();
61
+ exports.zAppointmentStatusTypeSchema = zod_1.z.enum([
62
+ "rs",
63
+ "cf",
64
+ "ci",
65
+ "co",
66
+ "cx",
67
+ "ns",
68
+ ]);
61
69
  exports.zAppointmentStatusSchema = zod_schemas_1.zFireDocSchema.extend({
62
70
  code: zod_1.z.string().min(1).max(10),
63
71
  name: zod_1.z.string().min(1).max(255),
64
- type: zod_1.z.enum(["rs", "cf", "ci", "co", "cx", "ns"]).default("rs"),
72
+ type: exports.zAppointmentStatusTypeSchema.default("rs"),
65
73
  });
66
74
  exports.zMedicationSchema = zod_1.z.object({
67
75
  name: zod_1.z.string().min(1).max(255),
68
76
  dosage: zod_1.z.string().max(255).nullable().optional().default(""),
69
77
  frequency: zod_1.z.string().max(255).nullable().optional().default(""),
70
78
  });
79
+ exports.zSeveritySchema = zod_1.z.enum([
80
+ "Mild",
81
+ "Moderate",
82
+ "Severe",
83
+ "Unknown",
84
+ ]);
71
85
  exports.zChronicConditionSchema = zod_schemas_1.zFireDocSchema.extend({
72
86
  code: zod_1.z.string().min(1).max(10),
73
87
  name: zod_1.z.string().min(1).max(255),
74
88
  diagnosis_date: zod_1.z.string().nullable().optional(),
75
- severity: zod_1.z
76
- .enum(["Mild", "Moderate", "Severe", "Unknown"])
77
- .optional()
78
- .default("Unknown"),
89
+ severity: exports.zSeveritySchema.nullable().optional().default("Unknown"),
79
90
  controlled: zod_1.z.boolean().optional().default(false),
80
91
  medications: zod_1.z.array(exports.zMedicationSchema).nullable().optional(),
81
92
  notes: zod_1.z.string().max(1024).nullable().optional().default(""),
82
93
  });
94
+ exports.zAllergyKindSchema = zod_1.z.enum(["Food", "Drug", "Insect", "Other"]);
95
+ exports.zAllergySeveritySchema = zod_1.z.enum([
96
+ "Mild",
97
+ "Moderate",
98
+ "Severe",
99
+ "Unknown",
100
+ ]);
83
101
  exports.zAllergySchema = zod_schemas_1.zFireDocSchema.extend({
84
102
  code: zod_1.z.string().min(1).max(10),
85
103
  name: zod_1.z.string().min(1).max(255),
86
- kind: zod_1.z
87
- .enum(["Food", "Drug", "Insect", "Other"])
88
- .nullable()
89
- .optional()
90
- .default("Other"),
91
- severity: zod_1.z
92
- .enum(["Mild", "Moderate", "Severe", "Unknown"])
93
- .nullable()
94
- .optional()
95
- .default("Unknown"),
104
+ kind: exports.zAllergyKindSchema.nullable().optional().default("Other"),
105
+ severity: exports.zAllergySeveritySchema.nullable().optional().default("Unknown"),
96
106
  });
107
+ exports.zMedicalCouncilUFSchema = zod_1.z.enum([
108
+ "AC",
109
+ "AL",
110
+ "AP",
111
+ "AM",
112
+ "BA",
113
+ "CE",
114
+ "ES",
115
+ "GO",
116
+ "MA",
117
+ "MT",
118
+ "MS",
119
+ "MG",
120
+ "PA",
121
+ "PB",
122
+ "PR",
123
+ "PE",
124
+ "PI",
125
+ "RJ",
126
+ "RN",
127
+ "RS",
128
+ "RO",
129
+ "RR",
130
+ "SC",
131
+ "SP",
132
+ "SE",
133
+ "TO",
134
+ "DF",
135
+ "BR", //nacional
136
+ ]);
97
137
  exports.zMedicalCouncilSchema = zod_schemas_1.zFireDocSchema
98
138
  .extend({
99
139
  name: zod_1.z.string().min(1).max(255),
100
140
  acronym: zod_1.z.string().min(1).max(60),
101
- uf: zod_1.z
102
- .enum([
103
- "AC",
104
- "AL",
105
- "AP",
106
- "AM",
107
- "BA",
108
- "CE",
109
- "ES",
110
- "GO",
111
- "MA",
112
- "MT",
113
- "MS",
114
- "MG",
115
- "PA",
116
- "PB",
117
- "PR",
118
- "PE",
119
- "PI",
120
- "RJ",
121
- "RN",
122
- "RS",
123
- "RO",
124
- "RR",
125
- "SC",
126
- "SP",
127
- "SE",
128
- "TO",
129
- "DF",
130
- "BR", //nacional
131
- ])
132
- .nullable()
133
- .optional()
134
- .default("SP"),
141
+ uf: exports.zMedicalCouncilUFSchema.nullable().optional().default("SP"),
135
142
  country: zod_1.z.string().min(1).max(255).nullable().optional().default("Brasil"),
136
143
  })
137
144
  .passthrough();
@@ -63,10 +63,19 @@ export const zAppointmentRequestTypeSchema = zFireDocSchema
63
63
  })
64
64
  .passthrough();
65
65
 
66
+ export const zAppointmentStatusTypeSchema = z.enum([
67
+ "rs",
68
+ "cf",
69
+ "ci",
70
+ "co",
71
+ "cx",
72
+ "ns",
73
+ ]);
74
+
66
75
  export const zAppointmentStatusSchema = zFireDocSchema.extend({
67
76
  code: z.string().min(1).max(10),
68
77
  name: z.string().min(1).max(255),
69
- type: z.enum(["rs", "cf", "ci", "co", "cx", "ns"]).default("rs"),
78
+ type: zAppointmentStatusTypeSchema.default("rs"),
70
79
  });
71
80
 
72
81
  export const zMedicationSchema = z.object({
@@ -75,72 +84,74 @@ export const zMedicationSchema = z.object({
75
84
  frequency: z.string().max(255).nullable().optional().default(""),
76
85
  });
77
86
 
87
+ export const zSeveritySchema = z.enum([
88
+ "Mild",
89
+ "Moderate",
90
+ "Severe",
91
+ "Unknown",
92
+ ]);
93
+
78
94
  export const zChronicConditionSchema = zFireDocSchema.extend({
79
95
  code: z.string().min(1).max(10),
80
96
  name: z.string().min(1).max(255),
81
97
  diagnosis_date: z.string().nullable().optional(),
82
- severity: z
83
- .enum(["Mild", "Moderate", "Severe", "Unknown"])
84
- .optional()
85
- .default("Unknown"),
98
+ severity: zSeveritySchema.nullable().optional().default("Unknown"),
86
99
  controlled: z.boolean().optional().default(false),
87
100
  medications: z.array(zMedicationSchema).nullable().optional(),
88
101
  notes: z.string().max(1024).nullable().optional().default(""),
89
102
  });
90
103
 
104
+ export const zAllergyKindSchema = z.enum(["Food", "Drug", "Insect", "Other"]);
105
+ export const zAllergySeveritySchema = z.enum([
106
+ "Mild",
107
+ "Moderate",
108
+ "Severe",
109
+ "Unknown",
110
+ ]);
111
+
91
112
  export const zAllergySchema = zFireDocSchema.extend({
92
113
  code: z.string().min(1).max(10),
93
114
  name: z.string().min(1).max(255),
94
- kind: z
95
- .enum(["Food", "Drug", "Insect", "Other"])
96
- .nullable()
97
- .optional()
98
- .default("Other"),
99
- severity: z
100
- .enum(["Mild", "Moderate", "Severe", "Unknown"])
101
- .nullable()
102
- .optional()
103
- .default("Unknown"),
115
+ kind: zAllergyKindSchema.nullable().optional().default("Other"),
116
+ severity: zAllergySeveritySchema.nullable().optional().default("Unknown"),
104
117
  });
105
118
 
119
+ export const zMedicalCouncilUFSchema = z.enum([
120
+ "AC",
121
+ "AL",
122
+ "AP",
123
+ "AM",
124
+ "BA",
125
+ "CE",
126
+ "ES",
127
+ "GO",
128
+ "MA",
129
+ "MT",
130
+ "MS",
131
+ "MG",
132
+ "PA",
133
+ "PB",
134
+ "PR",
135
+ "PE",
136
+ "PI",
137
+ "RJ",
138
+ "RN",
139
+ "RS",
140
+ "RO",
141
+ "RR",
142
+ "SC",
143
+ "SP",
144
+ "SE",
145
+ "TO",
146
+ "DF",
147
+ "BR", //nacional
148
+ ]);
149
+
106
150
  export const zMedicalCouncilSchema = zFireDocSchema
107
151
  .extend({
108
152
  name: z.string().min(1).max(255),
109
153
  acronym: z.string().min(1).max(60),
110
- uf: z
111
- .enum([
112
- "AC",
113
- "AL",
114
- "AP",
115
- "AM",
116
- "BA",
117
- "CE",
118
- "ES",
119
- "GO",
120
- "MA",
121
- "MT",
122
- "MS",
123
- "MG",
124
- "PA",
125
- "PB",
126
- "PR",
127
- "PE",
128
- "PI",
129
- "RJ",
130
- "RN",
131
- "RS",
132
- "RO",
133
- "RR",
134
- "SC",
135
- "SP",
136
- "SE",
137
- "TO",
138
- "DF",
139
- "BR", //nacional
140
- ])
141
- .nullable()
142
- .optional()
143
- .default("SP"),
154
+ uf: zMedicalCouncilUFSchema.nullable().optional().default("SP"),
144
155
  country: z.string().min(1).max(255).nullable().optional().default("Brasil"),
145
156
  })
146
157
  .passthrough();
@@ -4,12 +4,12 @@ export declare const zProfessionalCouncilSchema: z.ZodObject<{
4
4
  doc: z.ZodString;
5
5
  name: z.ZodString;
6
6
  acronym: z.ZodString;
7
- uf: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
7
+ uf: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodEnum<["AC", "AL", "AP", "AM", "BA", "CE", "ES", "GO", "MA", "MT", "MS", "MG", "PA", "PB", "PR", "PE", "PI", "RJ", "RN", "RS", "RO", "RR", "SC", "SP", "SE", "TO", "DF", "BR"]>>>>;
8
8
  ref: z.ZodAny;
9
9
  }, "strip", z.ZodTypeAny, {
10
10
  name: string;
11
11
  acronym: string;
12
- uf: string | null;
12
+ uf: "AC" | "AL" | "AP" | "AM" | "BA" | "CE" | "ES" | "GO" | "MA" | "MT" | "MS" | "MG" | "PA" | "PB" | "PR" | "PE" | "PI" | "RJ" | "RN" | "RS" | "RO" | "RR" | "SC" | "SP" | "SE" | "TO" | "DF" | "BR" | null;
13
13
  doc: string;
14
14
  ref?: any;
15
15
  }, {
@@ -17,7 +17,7 @@ export declare const zProfessionalCouncilSchema: z.ZodObject<{
17
17
  acronym: string;
18
18
  doc: string;
19
19
  ref?: any;
20
- uf?: string | null | undefined;
20
+ uf?: "AC" | "AL" | "AP" | "AM" | "BA" | "CE" | "ES" | "GO" | "MA" | "MT" | "MS" | "MG" | "PA" | "PB" | "PR" | "PE" | "PI" | "RJ" | "RN" | "RS" | "RO" | "RR" | "SC" | "SP" | "SE" | "TO" | "DF" | "BR" | null | undefined;
21
21
  }>;
22
22
  export declare const zProfessionalSpecialtySchema: z.ZodObject<{
23
23
  code: z.ZodString;
@@ -64,19 +64,19 @@ export declare const zProfessionalSchema: z.ZodObject<z.objectUtil.extendShape<z
64
64
  }>, {
65
65
  status: z.ZodDefault<z.ZodEnum<["active", "inactive", "draft"]>>;
66
66
  professionalId: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
67
- title: z.ZodDefault<z.ZodString>;
68
- type: z.ZodDefault<z.ZodString>;
69
- job_title: z.ZodOptional<z.ZodNullable<z.ZodString>>;
67
+ title: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
68
+ type: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
69
+ job_title: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
70
70
  councils: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
71
71
  doc: z.ZodString;
72
72
  name: z.ZodString;
73
73
  acronym: z.ZodString;
74
- uf: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
74
+ uf: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodEnum<["AC", "AL", "AP", "AM", "BA", "CE", "ES", "GO", "MA", "MT", "MS", "MG", "PA", "PB", "PR", "PE", "PI", "RJ", "RN", "RS", "RO", "RR", "SC", "SP", "SE", "TO", "DF", "BR"]>>>>;
75
75
  ref: z.ZodAny;
76
76
  }, "strip", z.ZodTypeAny, {
77
77
  name: string;
78
78
  acronym: string;
79
- uf: string | null;
79
+ uf: "AC" | "AL" | "AP" | "AM" | "BA" | "CE" | "ES" | "GO" | "MA" | "MT" | "MS" | "MG" | "PA" | "PB" | "PR" | "PE" | "PI" | "RJ" | "RN" | "RS" | "RO" | "RR" | "SC" | "SP" | "SE" | "TO" | "DF" | "BR" | null;
80
80
  doc: string;
81
81
  ref?: any;
82
82
  }, {
@@ -84,7 +84,7 @@ export declare const zProfessionalSchema: z.ZodObject<z.objectUtil.extendShape<z
84
84
  acronym: string;
85
85
  doc: string;
86
86
  ref?: any;
87
- uf?: string | null | undefined;
87
+ uf?: "AC" | "AL" | "AP" | "AM" | "BA" | "CE" | "ES" | "GO" | "MA" | "MT" | "MS" | "MG" | "PA" | "PB" | "PR" | "PE" | "PI" | "RJ" | "RN" | "RS" | "RO" | "RR" | "SC" | "SP" | "SE" | "TO" | "DF" | "BR" | null | undefined;
88
88
  }>, "many">>>;
89
89
  specialties: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
90
90
  code: z.ZodString;
@@ -192,19 +192,19 @@ export declare const zProfessionalSchema: z.ZodObject<z.objectUtil.extendShape<z
192
192
  }>, {
193
193
  status: z.ZodDefault<z.ZodEnum<["active", "inactive", "draft"]>>;
194
194
  professionalId: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
195
- title: z.ZodDefault<z.ZodString>;
196
- type: z.ZodDefault<z.ZodString>;
197
- job_title: z.ZodOptional<z.ZodNullable<z.ZodString>>;
195
+ title: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
196
+ type: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
197
+ job_title: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
198
198
  councils: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
199
199
  doc: z.ZodString;
200
200
  name: z.ZodString;
201
201
  acronym: z.ZodString;
202
- uf: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
202
+ uf: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodEnum<["AC", "AL", "AP", "AM", "BA", "CE", "ES", "GO", "MA", "MT", "MS", "MG", "PA", "PB", "PR", "PE", "PI", "RJ", "RN", "RS", "RO", "RR", "SC", "SP", "SE", "TO", "DF", "BR"]>>>>;
203
203
  ref: z.ZodAny;
204
204
  }, "strip", z.ZodTypeAny, {
205
205
  name: string;
206
206
  acronym: string;
207
- uf: string | null;
207
+ uf: "AC" | "AL" | "AP" | "AM" | "BA" | "CE" | "ES" | "GO" | "MA" | "MT" | "MS" | "MG" | "PA" | "PB" | "PR" | "PE" | "PI" | "RJ" | "RN" | "RS" | "RO" | "RR" | "SC" | "SP" | "SE" | "TO" | "DF" | "BR" | null;
208
208
  doc: string;
209
209
  ref?: any;
210
210
  }, {
@@ -212,7 +212,7 @@ export declare const zProfessionalSchema: z.ZodObject<z.objectUtil.extendShape<z
212
212
  acronym: string;
213
213
  doc: string;
214
214
  ref?: any;
215
- uf?: string | null | undefined;
215
+ uf?: "AC" | "AL" | "AP" | "AM" | "BA" | "CE" | "ES" | "GO" | "MA" | "MT" | "MS" | "MG" | "PA" | "PB" | "PR" | "PE" | "PI" | "RJ" | "RN" | "RS" | "RO" | "RR" | "SC" | "SP" | "SE" | "TO" | "DF" | "BR" | null | undefined;
216
216
  }>, "many">>>;
217
217
  specialties: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
218
218
  code: z.ZodString;
@@ -320,19 +320,19 @@ export declare const zProfessionalSchema: z.ZodObject<z.objectUtil.extendShape<z
320
320
  }>, {
321
321
  status: z.ZodDefault<z.ZodEnum<["active", "inactive", "draft"]>>;
322
322
  professionalId: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
323
- title: z.ZodDefault<z.ZodString>;
324
- type: z.ZodDefault<z.ZodString>;
325
- job_title: z.ZodOptional<z.ZodNullable<z.ZodString>>;
323
+ title: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
324
+ type: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
325
+ job_title: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
326
326
  councils: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
327
327
  doc: z.ZodString;
328
328
  name: z.ZodString;
329
329
  acronym: z.ZodString;
330
- uf: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
330
+ uf: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodEnum<["AC", "AL", "AP", "AM", "BA", "CE", "ES", "GO", "MA", "MT", "MS", "MG", "PA", "PB", "PR", "PE", "PI", "RJ", "RN", "RS", "RO", "RR", "SC", "SP", "SE", "TO", "DF", "BR"]>>>>;
331
331
  ref: z.ZodAny;
332
332
  }, "strip", z.ZodTypeAny, {
333
333
  name: string;
334
334
  acronym: string;
335
- uf: string | null;
335
+ uf: "AC" | "AL" | "AP" | "AM" | "BA" | "CE" | "ES" | "GO" | "MA" | "MT" | "MS" | "MG" | "PA" | "PB" | "PR" | "PE" | "PI" | "RJ" | "RN" | "RS" | "RO" | "RR" | "SC" | "SP" | "SE" | "TO" | "DF" | "BR" | null;
336
336
  doc: string;
337
337
  ref?: any;
338
338
  }, {
@@ -340,7 +340,7 @@ export declare const zProfessionalSchema: z.ZodObject<z.objectUtil.extendShape<z
340
340
  acronym: string;
341
341
  doc: string;
342
342
  ref?: any;
343
- uf?: string | null | undefined;
343
+ uf?: "AC" | "AL" | "AP" | "AM" | "BA" | "CE" | "ES" | "GO" | "MA" | "MT" | "MS" | "MG" | "PA" | "PB" | "PR" | "PE" | "PI" | "RJ" | "RN" | "RS" | "RO" | "RR" | "SC" | "SP" | "SE" | "TO" | "DF" | "BR" | null | undefined;
344
344
  }>, "many">>>;
345
345
  specialties: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
346
346
  code: z.ZodString;
@@ -431,6 +431,7 @@ export declare const zProfessionalSchema: z.ZodObject<z.objectUtil.extendShape<z
431
431
  userRef: z.ZodAny;
432
432
  }>, z.ZodTypeAny, "passthrough">>;
433
433
  export declare const zPatientStatusSchema: z.ZodEnum<["active", "inactive", "draft"]>;
434
+ export declare const zBloodTypeSchema: z.ZodEnum<["A+", "A-", "B+", "B-", "AB+", "AB-", "O+", "O-", "Unknown"]>;
434
435
  export declare const zPatientSchema: z.ZodObject<z.objectUtil.extendShape<z.objectUtil.extendShape<{
435
436
  id: z.ZodString;
436
437
  ref: z.ZodAny;
@@ -496,7 +497,7 @@ export declare const zPatientSchema: z.ZodObject<z.objectUtil.extendShape<z.obje
496
497
  }>>>;
497
498
  height_cm: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
498
499
  weight_kg: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
499
- blood_type: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
500
+ blood_type: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodEnum<["A+", "A-", "B+", "B-", "AB+", "AB-", "O+", "O-", "Unknown"]>>>>;
500
501
  allergies: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<z.objectUtil.extendShape<{
501
502
  id: z.ZodString;
502
503
  ref: z.ZodAny;
@@ -547,7 +548,7 @@ export declare const zPatientSchema: z.ZodObject<z.objectUtil.extendShape<z.obje
547
548
  code: z.ZodString;
548
549
  name: z.ZodString;
549
550
  diagnosis_date: z.ZodOptional<z.ZodNullable<z.ZodString>>;
550
- severity: z.ZodDefault<z.ZodOptional<z.ZodEnum<["Mild", "Moderate", "Severe", "Unknown"]>>>;
551
+ severity: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodEnum<["Mild", "Moderate", "Severe", "Unknown"]>>>>;
551
552
  controlled: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
552
553
  medications: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
553
554
  name: z.ZodString;
@@ -569,7 +570,7 @@ export declare const zPatientSchema: z.ZodObject<z.objectUtil.extendShape<z.obje
569
570
  id: string;
570
571
  tenant: string;
571
572
  model_ver: number;
572
- severity: "Mild" | "Moderate" | "Severe" | "Unknown";
573
+ severity: "Mild" | "Moderate" | "Severe" | "Unknown" | null;
573
574
  controlled: boolean;
574
575
  notes: string | null;
575
576
  ref?: any;
@@ -593,7 +594,7 @@ export declare const zPatientSchema: z.ZodObject<z.objectUtil.extendShape<z.obje
593
594
  updated_at?: Date | null | undefined;
594
595
  deleted_at?: Date | null | undefined;
595
596
  diagnosis_date?: string | null | undefined;
596
- severity?: "Mild" | "Moderate" | "Severe" | "Unknown" | undefined;
597
+ severity?: "Mild" | "Moderate" | "Severe" | "Unknown" | null | undefined;
597
598
  controlled?: boolean | undefined;
598
599
  medications?: {
599
600
  name: string;
@@ -681,7 +682,7 @@ export declare const zPatientSchema: z.ZodObject<z.objectUtil.extendShape<z.obje
681
682
  }>>>;
682
683
  height_cm: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
683
684
  weight_kg: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
684
- blood_type: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
685
+ blood_type: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodEnum<["A+", "A-", "B+", "B-", "AB+", "AB-", "O+", "O-", "Unknown"]>>>>;
685
686
  allergies: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<z.objectUtil.extendShape<{
686
687
  id: z.ZodString;
687
688
  ref: z.ZodAny;
@@ -732,7 +733,7 @@ export declare const zPatientSchema: z.ZodObject<z.objectUtil.extendShape<z.obje
732
733
  code: z.ZodString;
733
734
  name: z.ZodString;
734
735
  diagnosis_date: z.ZodOptional<z.ZodNullable<z.ZodString>>;
735
- severity: z.ZodDefault<z.ZodOptional<z.ZodEnum<["Mild", "Moderate", "Severe", "Unknown"]>>>;
736
+ severity: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodEnum<["Mild", "Moderate", "Severe", "Unknown"]>>>>;
736
737
  controlled: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
737
738
  medications: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
738
739
  name: z.ZodString;
@@ -754,7 +755,7 @@ export declare const zPatientSchema: z.ZodObject<z.objectUtil.extendShape<z.obje
754
755
  id: string;
755
756
  tenant: string;
756
757
  model_ver: number;
757
- severity: "Mild" | "Moderate" | "Severe" | "Unknown";
758
+ severity: "Mild" | "Moderate" | "Severe" | "Unknown" | null;
758
759
  controlled: boolean;
759
760
  notes: string | null;
760
761
  ref?: any;
@@ -778,7 +779,7 @@ export declare const zPatientSchema: z.ZodObject<z.objectUtil.extendShape<z.obje
778
779
  updated_at?: Date | null | undefined;
779
780
  deleted_at?: Date | null | undefined;
780
781
  diagnosis_date?: string | null | undefined;
781
- severity?: "Mild" | "Moderate" | "Severe" | "Unknown" | undefined;
782
+ severity?: "Mild" | "Moderate" | "Severe" | "Unknown" | null | undefined;
782
783
  controlled?: boolean | undefined;
783
784
  medications?: {
784
785
  name: string;
@@ -866,7 +867,7 @@ export declare const zPatientSchema: z.ZodObject<z.objectUtil.extendShape<z.obje
866
867
  }>>>;
867
868
  height_cm: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
868
869
  weight_kg: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
869
- blood_type: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodString>>>;
870
+ blood_type: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodEnum<["A+", "A-", "B+", "B-", "AB+", "AB-", "O+", "O-", "Unknown"]>>>>;
870
871
  allergies: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<z.objectUtil.extendShape<{
871
872
  id: z.ZodString;
872
873
  ref: z.ZodAny;
@@ -917,7 +918,7 @@ export declare const zPatientSchema: z.ZodObject<z.objectUtil.extendShape<z.obje
917
918
  code: z.ZodString;
918
919
  name: z.ZodString;
919
920
  diagnosis_date: z.ZodOptional<z.ZodNullable<z.ZodString>>;
920
- severity: z.ZodDefault<z.ZodOptional<z.ZodEnum<["Mild", "Moderate", "Severe", "Unknown"]>>>;
921
+ severity: z.ZodDefault<z.ZodOptional<z.ZodNullable<z.ZodEnum<["Mild", "Moderate", "Severe", "Unknown"]>>>>;
921
922
  controlled: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
922
923
  medications: z.ZodOptional<z.ZodNullable<z.ZodArray<z.ZodObject<{
923
924
  name: z.ZodString;
@@ -939,7 +940,7 @@ export declare const zPatientSchema: z.ZodObject<z.objectUtil.extendShape<z.obje
939
940
  id: string;
940
941
  tenant: string;
941
942
  model_ver: number;
942
- severity: "Mild" | "Moderate" | "Severe" | "Unknown";
943
+ severity: "Mild" | "Moderate" | "Severe" | "Unknown" | null;
943
944
  controlled: boolean;
944
945
  notes: string | null;
945
946
  ref?: any;
@@ -963,7 +964,7 @@ export declare const zPatientSchema: z.ZodObject<z.objectUtil.extendShape<z.obje
963
964
  updated_at?: Date | null | undefined;
964
965
  deleted_at?: Date | null | undefined;
965
966
  diagnosis_date?: string | null | undefined;
966
- severity?: "Mild" | "Moderate" | "Severe" | "Unknown" | undefined;
967
+ severity?: "Mild" | "Moderate" | "Severe" | "Unknown" | null | undefined;
967
968
  controlled?: boolean | undefined;
968
969
  medications?: {
969
970
  name: string;
@@ -1,6 +1,6 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
- exports.zPatientSchema = exports.zPatientStatusSchema = exports.zProfessionalSchema = exports.zProfessionalOfficeSchema = exports.zProfessionalSpecialtySchema = exports.zProfessionalCouncilSchema = exports.zProfessionalStatusSchema = void 0;
3
+ exports.zPatientSchema = exports.zBloodTypeSchema = exports.zPatientStatusSchema = exports.zProfessionalSchema = exports.zProfessionalOfficeSchema = exports.zProfessionalSpecialtySchema = exports.zProfessionalCouncilSchema = exports.zProfessionalStatusSchema = void 0;
4
4
  const zod_1 = require("zod");
5
5
  const zod_schemas_1 = require("../dic/zod-schemas");
6
6
  const zod_schemas_2 = require("../../shared/zod-schemas");
@@ -15,7 +15,7 @@ exports.zProfessionalCouncilSchema = zod_1.z.object({
15
15
  doc: zod_1.z.string().min(1).max(255),
16
16
  name: zod_1.z.string().min(1).max(255),
17
17
  acronym: zod_1.z.string().min(1).max(60),
18
- uf: zod_1.z.string().min(2).max(2).nullable().optional().default("SP"),
18
+ uf: zod_schemas_1.zMedicalCouncilUFSchema.nullable().optional().default("SP"),
19
19
  ref: zod_1.z.any(),
20
20
  });
21
21
  exports.zProfessionalSpecialtySchema = zod_1.z.object({
@@ -32,9 +32,9 @@ exports.zProfessionalSchema = zod_schemas_3.zProfileSchema // Extend from Profil
32
32
  .extend({
33
33
  status: exports.zProfessionalStatusSchema.default("draft"),
34
34
  professionalId: zod_1.z.string().max(255).nullable().optional().default(""),
35
- title: zod_1.z.string().max(255).default(""),
36
- type: zod_1.z.string().max(255).default("doctor"),
37
- job_title: zod_1.z.string().nullable().optional(),
35
+ title: zod_1.z.string().max(255).nullable().optional().default(""),
36
+ type: zod_1.z.string().max(255).nullable().optional().default("doctor"),
37
+ job_title: zod_1.z.string().max(255).nullable().optional().default(""),
38
38
  councils: zod_1.z.array(exports.zProfessionalCouncilSchema).nullable().optional(),
39
39
  specialties: zod_1.z.array(exports.zProfessionalSpecialtySchema).nullable().optional(),
40
40
  offices: zod_1.z.array(exports.zProfessionalOfficeSchema).nullable().optional(),
@@ -48,6 +48,17 @@ exports.zProfessionalSchema = zod_schemas_3.zProfileSchema // Extend from Profil
48
48
  })
49
49
  .passthrough();
50
50
  exports.zPatientStatusSchema = zod_1.z.enum(["active", "inactive", "draft"]);
51
+ exports.zBloodTypeSchema = zod_1.z.enum([
52
+ "A+",
53
+ "A-",
54
+ "B+",
55
+ "B-",
56
+ "AB+",
57
+ "AB-",
58
+ "O+",
59
+ "O-",
60
+ "Unknown",
61
+ ]);
51
62
  exports.zPatientSchema = zod_schemas_3.zProfileSchema // Extend from ProfileSchema
52
63
  .extend({
53
64
  social_id: zod_1.z.string().nullable().optional(),
@@ -56,13 +67,7 @@ exports.zPatientSchema = zod_schemas_3.zProfileSchema // Extend from ProfileSche
56
67
  contact: zod_schemas_2.zContactSchema.nullable().optional(),
57
68
  height_cm: zod_1.z.number().nullable().optional(),
58
69
  weight_kg: zod_1.z.number().nullable().optional(),
59
- blood_type: zod_1.z
60
- .string()
61
- .min(2)
62
- .max(10)
63
- .nullable()
64
- .optional()
65
- .default("Unknown"),
70
+ blood_type: exports.zBloodTypeSchema.nullable().optional().default("Unknown"),
66
71
  allergies: zod_1.z.array(zod_schemas_1.zAllergySchema).nullable().optional(),
67
72
  chronic_conditions: zod_1.z.array(zod_schemas_1.zChronicConditionSchema).nullable().optional(),
68
73
  tags: zod_1.z.array(zod_schemas_2.zTagSchema).nullable().optional(),
@@ -1,5 +1,9 @@
1
1
  import { z } from "zod";
2
- import { zAllergySchema, zChronicConditionSchema } from "../dic/zod-schemas";
2
+ import {
3
+ zAllergySchema,
4
+ zChronicConditionSchema,
5
+ zMedicalCouncilUFSchema,
6
+ } from "../dic/zod-schemas";
3
7
  import {
4
8
  zAddressSchema,
5
9
  zContactSchema,
@@ -19,7 +23,7 @@ export const zProfessionalCouncilSchema = z.object({
19
23
  doc: z.string().min(1).max(255),
20
24
  name: z.string().min(1).max(255),
21
25
  acronym: z.string().min(1).max(60),
22
- uf: z.string().min(2).max(2).nullable().optional().default("SP"),
26
+ uf: zMedicalCouncilUFSchema.nullable().optional().default("SP"),
23
27
  ref: z.any(),
24
28
  });
25
29
 
@@ -39,9 +43,9 @@ export const zProfessionalSchema = zProfileSchema // Extend from ProfileSchema
39
43
  .extend({
40
44
  status: zProfessionalStatusSchema.default("draft"),
41
45
  professionalId: z.string().max(255).nullable().optional().default(""),
42
- title: z.string().max(255).default(""),
43
- type: z.string().max(255).default("doctor"),
44
- job_title: z.string().nullable().optional(),
46
+ title: z.string().max(255).nullable().optional().default(""),
47
+ type: z.string().max(255).nullable().optional().default("doctor"),
48
+ job_title: z.string().max(255).nullable().optional().default(""),
45
49
  councils: z.array(zProfessionalCouncilSchema).nullable().optional(),
46
50
  specialties: z.array(zProfessionalSpecialtySchema).nullable().optional(),
47
51
  offices: z.array(zProfessionalOfficeSchema).nullable().optional(),
@@ -57,6 +61,18 @@ export const zProfessionalSchema = zProfileSchema // Extend from ProfileSchema
57
61
 
58
62
  export const zPatientStatusSchema = z.enum(["active", "inactive", "draft"]);
59
63
 
64
+ export const zBloodTypeSchema = z.enum([
65
+ "A+",
66
+ "A-",
67
+ "B+",
68
+ "B-",
69
+ "AB+",
70
+ "AB-",
71
+ "O+",
72
+ "O-",
73
+ "Unknown",
74
+ ]);
75
+
60
76
  export const zPatientSchema = zProfileSchema // Extend from ProfileSchema
61
77
  .extend({
62
78
  social_id: z.string().nullable().optional(),
@@ -65,13 +81,7 @@ export const zPatientSchema = zProfileSchema // Extend from ProfileSchema
65
81
  contact: zContactSchema.nullable().optional(),
66
82
  height_cm: z.number().nullable().optional(),
67
83
  weight_kg: z.number().nullable().optional(),
68
- blood_type: z
69
- .string()
70
- .min(2)
71
- .max(10)
72
- .nullable()
73
- .optional()
74
- .default("Unknown"),
84
+ blood_type: zBloodTypeSchema.nullable().optional().default("Unknown"),
75
85
  allergies: z.array(zAllergySchema).nullable().optional(),
76
86
  chronic_conditions: z.array(zChronicConditionSchema).nullable().optional(),
77
87
  tags: z.array(zTagSchema).nullable().optional(),
@@ -44,8 +44,8 @@ export interface IProfessionalOffice {
44
44
  export interface IProfessional extends IProfile {
45
45
  status?: ProfessionalStatus;
46
46
  professionalId?: string | null;
47
- title: string;
48
- type: string | null;
47
+ title?: string | null;
48
+ type?: string | null;
49
49
  job_title?: string | null;
50
50
  councils?: IProfessionalCouncil[] | null;
51
51
  specialties?: IProfessionalSpecialty[] | null;
@@ -81,8 +81,8 @@ export interface IProfessionalOffice {
81
81
  export interface IProfessional extends IProfile {
82
82
  status?: ProfessionalStatus;
83
83
  professionalId?: string | null;
84
- title: string;
85
- type: string | null;
84
+ title?: string | null;
85
+ type?: string | null;
86
86
  job_title?: string | null;
87
87
  councils?: IProfessionalCouncil[] | null;
88
88
  specialties?: IProfessionalSpecialty[] | null;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "evo360-types",
3
- "version": "1.2.23",
3
+ "version": "1.2.25",
4
4
  "description": "HREVO360 Shared Types",
5
5
  "main": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",