@blackcode_sa/metaestetics-api 1.5.16 → 1.5.17

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -356,7 +356,7 @@ interface PractitionerBasicInfo {
356
356
  email: string;
357
357
  phoneNumber: string;
358
358
  dateOfBirth: Timestamp;
359
- gender: "male" | "female" | "other";
359
+ gender: 'male' | 'female' | 'other';
360
360
  profileImageUrl?: string;
361
361
  bio?: string;
362
362
  languages: string[];
@@ -371,7 +371,7 @@ interface PractitionerCertification {
371
371
  issuingAuthority: string;
372
372
  issueDate: Timestamp;
373
373
  expiryDate?: Timestamp;
374
- verificationStatus: "pending" | "verified" | "rejected";
374
+ verificationStatus: 'pending' | 'verified' | 'rejected';
375
375
  }
376
376
  /**
377
377
  * Interfejs za radno vreme zdravstvenog radnika u klinici
@@ -910,6 +910,8 @@ interface PatientProfile {
910
910
  dateOfBirth?: Timestamp | null;
911
911
  doctors: PatientDoctor[];
912
912
  clinics: PatientClinic[];
913
+ doctorIds: string[];
914
+ clinicIds: string[];
913
915
  createdAt: Timestamp;
914
916
  updatedAt: Timestamp;
915
917
  }
@@ -925,13 +927,37 @@ interface CreatePatientProfileData {
925
927
  isVerified: boolean;
926
928
  doctors?: PatientDoctor[];
927
929
  clinics?: PatientClinic[];
930
+ doctorIds?: string[];
931
+ clinicIds?: string[];
928
932
  }
929
933
  /**
930
934
  * Tip za ažuriranje Patient profila
931
935
  */
932
- interface UpdatePatientProfileData extends Partial<CreatePatientProfileData> {
936
+ interface UpdatePatientProfileData extends Partial<Omit<PatientProfile, "id" | "createdAt" | "updatedAt">> {
933
937
  updatedAt?: FieldValue;
934
938
  }
939
+ /**
940
+ * Parameters for searching patient profiles.
941
+ */
942
+ interface SearchPatientsParams {
943
+ /** Optional: Filter patients associated with this clinic ID. */
944
+ clinicId?: string;
945
+ /** Optional: Filter patients associated with this practitioner ID. */
946
+ practitionerId?: string;
947
+ }
948
+ /**
949
+ * Information about the entity requesting the patient search.
950
+ */
951
+ interface RequesterInfo {
952
+ /** ID of the clinic admin user or practitioner user making the request. */
953
+ id: string;
954
+ /** Role of the requester, determining the search context. */
955
+ role: "clinic_admin" | "practitioner";
956
+ /** If role is 'clinic_admin', this is the associated clinic ID. */
957
+ associatedClinicId?: string;
958
+ /** If role is 'practitioner', this is the associated practitioner profile ID. */
959
+ associatedPractitionerId?: string;
960
+ }
935
961
 
936
962
  interface PatientProfileComplete {
937
963
  patientProfile?: PatientProfile;
@@ -3499,8 +3525,8 @@ declare class CategoryService extends BaseService {
3499
3525
  isActive: boolean;
3500
3526
  updatedAt: Date;
3501
3527
  name: string;
3502
- description: string;
3503
3528
  createdAt: Date;
3529
+ description: string;
3504
3530
  family: ProcedureFamily;
3505
3531
  id: string;
3506
3532
  }>;
@@ -3564,8 +3590,8 @@ declare class SubcategoryService extends BaseService {
3564
3590
  isActive: boolean;
3565
3591
  updatedAt: Date;
3566
3592
  name: string;
3567
- description?: string | undefined;
3568
3593
  createdAt: Date;
3594
+ description?: string | undefined;
3569
3595
  categoryId: string;
3570
3596
  id: string;
3571
3597
  }>;
@@ -3638,8 +3664,8 @@ declare class TechnologyService extends BaseService {
3638
3664
  blockingConditions: BlockingCondition[];
3639
3665
  contraindications: Contraindication[];
3640
3666
  name: string;
3641
- description: string;
3642
3667
  createdAt: Date;
3668
+ description: string;
3643
3669
  technicalDetails?: string | undefined;
3644
3670
  family: ProcedureFamily;
3645
3671
  categoryId: string;
@@ -3859,8 +3885,8 @@ declare class BrandService extends BaseService {
3859
3885
  isActive: boolean;
3860
3886
  updatedAt: Date;
3861
3887
  name: string;
3862
- description?: string | undefined;
3863
3888
  createdAt: Date;
3889
+ description?: string | undefined;
3864
3890
  manufacturer: string;
3865
3891
  website?: string | undefined;
3866
3892
  id: string;
@@ -4131,6 +4157,44 @@ interface UpdateAppointmentParams {
4131
4157
  * Collection names for calendar
4132
4158
  */
4133
4159
  declare const CALENDAR_COLLECTION = "calendar";
4160
+ /**
4161
+ * Enum for specifying the primary search location for calendar events
4162
+ */
4163
+ declare enum SearchLocationEnum {
4164
+ PRACTITIONER = "practitioner",
4165
+ PATIENT = "patient",
4166
+ CLINIC = "clinic"
4167
+ }
4168
+ /**
4169
+ * Interface for defining a date range
4170
+ */
4171
+ interface DateRange {
4172
+ start: Timestamp;
4173
+ end: Timestamp;
4174
+ }
4175
+ /**
4176
+ * Interface for general calendar event search parameters
4177
+ */
4178
+ interface SearchCalendarEventsParams {
4179
+ /** The primary location to search within (practitioner, patient, or clinic calendar). */
4180
+ searchLocation: SearchLocationEnum;
4181
+ /** The ID of the entity (practitioner, patient, or clinic) whose calendar/events are being searched. */
4182
+ entityId: string;
4183
+ /** Optional filter for clinic ID. If searchLocation is CLINIC, this is implicitly applied using entityId. */
4184
+ clinicId?: string;
4185
+ /** Optional filter for practitioner ID. */
4186
+ practitionerId?: string;
4187
+ /** Optional filter for patient ID. */
4188
+ patientId?: string;
4189
+ /** Optional filter for procedure ID. */
4190
+ procedureId?: string;
4191
+ /** Optional filter for a specific date range (based on event start time). */
4192
+ dateRange?: DateRange;
4193
+ /** Optional filter for event status. */
4194
+ eventStatus?: CalendarEventStatus;
4195
+ /** Optional filter for event type. */
4196
+ eventType?: CalendarEventType;
4197
+ }
4134
4198
 
4135
4199
  declare enum UserRole {
4136
4200
  PATIENT = "patient",
@@ -4212,6 +4276,15 @@ declare class PatientService extends BaseService {
4212
4276
  deleteProfilePhoto(patientId: string): Promise<void>;
4213
4277
  updatePatientProfile(patientId: string, data: Partial<Omit<PatientProfile, "id" | "createdAt" | "updatedAt">>): Promise<PatientProfile>;
4214
4278
  updatePatientProfileByUserRef(userRef: string, data: Partial<Omit<PatientProfile, "id" | "createdAt" | "updatedAt">>): Promise<PatientProfile>;
4279
+ /**
4280
+ * Searches for patient profiles based on clinic/practitioner association.
4281
+ * Requires information about the requester for security checks.
4282
+ *
4283
+ * @param {SearchPatientsParams} params - The search criteria (clinicId, practitionerId).
4284
+ * @param {RequesterInfo} requester - Information about the user performing the search (ID, role, associated IDs).
4285
+ * @returns {Promise<PatientProfile[]>} A promise resolving to an array of matching patient profiles.
4286
+ */
4287
+ searchPatients(params: SearchPatientsParams, requester: RequesterInfo): Promise<PatientProfile[]>;
4215
4288
  }
4216
4289
 
4217
4290
  declare class ClinicGroupService extends BaseService {
@@ -5247,6 +5320,54 @@ declare class CalendarServiceV2 extends BaseService {
5247
5320
  * @param interval - Interval in hours
5248
5321
  */
5249
5322
  createScheduledSyncJob(interval?: number): void;
5323
+ /**
5324
+ * Searches for calendar events based on specified criteria.
5325
+ *
5326
+ * @param {SearchCalendarEventsParams} params - The search parameters.
5327
+ * @param {SearchLocationEnum} params.searchLocation - The primary location to search (practitioner, patient, or clinic).
5328
+ * @param {string} params.entityId - The ID of the entity (practitioner, patient, or clinic) to search within/for.
5329
+ * @param {string} [params.clinicId] - Optional clinic ID to filter by.
5330
+ * @param {string} [params.practitionerId] - Optional practitioner ID to filter by.
5331
+ * @param {string} [params.patientId] - Optional patient ID to filter by.
5332
+ * @param {string} [params.procedureId] - Optional procedure ID to filter by.
5333
+ * @param {DateRange} [params.dateRange] - Optional date range to filter by (event start time).
5334
+ * @param {CalendarEventStatus} [params.eventStatus] - Optional event status to filter by.
5335
+ * @param {CalendarEventType} [params.eventType] - Optional event type to filter by.
5336
+ * @returns {Promise<CalendarEvent[]>} A promise that resolves to an array of matching calendar events.
5337
+ * @throws {Error} If the search location requires an entity ID that is not provided.
5338
+ */
5339
+ searchCalendarEvents(params: SearchCalendarEventsParams): Promise<CalendarEvent[]>;
5340
+ /**
5341
+ * Gets a doctor's upcoming appointments for a specific date range
5342
+ *
5343
+ * @param {string} doctorId - ID of the practitioner
5344
+ * @param {Date} startDate - Start date of the range
5345
+ * @param {Date} endDate - End date of the range
5346
+ * @param {CalendarEventStatus} [status] - Optional status filter (defaults to CONFIRMED)
5347
+ * @returns {Promise<CalendarEvent[]>} A promise that resolves to an array of appointments
5348
+ */
5349
+ getPractitionerUpcomingAppointments(doctorId: string, startDate: Date, endDate: Date, status?: CalendarEventStatus): Promise<CalendarEvent[]>;
5350
+ /**
5351
+ * Gets a patient's appointments for a specific date range
5352
+ *
5353
+ * @param {string} patientId - ID of the patient
5354
+ * @param {Date} startDate - Start date of the range
5355
+ * @param {Date} endDate - End date of the range
5356
+ * @param {CalendarEventStatus} [status] - Optional status filter (defaults to all non-canceled appointments)
5357
+ * @returns {Promise<CalendarEvent[]>} A promise that resolves to an array of appointments
5358
+ */
5359
+ getPatientAppointments(patientId: string, startDate: Date, endDate: Date, status?: CalendarEventStatus): Promise<CalendarEvent[]>;
5360
+ /**
5361
+ * Gets all appointments for a clinic within a specific date range
5362
+ *
5363
+ * @param {string} clinicId - ID of the clinic
5364
+ * @param {Date} startDate - Start date of the range
5365
+ * @param {Date} endDate - End date of the range
5366
+ * @param {string} [doctorId] - Optional doctor ID to filter by
5367
+ * @param {CalendarEventStatus} [status] - Optional status filter
5368
+ * @returns {Promise<CalendarEvent[]>} A promise that resolves to an array of appointments
5369
+ */
5370
+ getClinicAppointments(clinicId: string, startDate: Date, endDate: Date, doctorId?: string, status?: CalendarEventStatus): Promise<CalendarEvent[]>;
5250
5371
  /**
5251
5372
  * Validates appointment creation parameters
5252
5373
  * @param params - Appointment parameters to validate
@@ -8274,6 +8395,8 @@ declare const patientProfileSchema: z.ZodObject<{
8274
8395
  notes?: string | undefined;
8275
8396
  assignedBy?: string | undefined;
8276
8397
  }>, "many">;
8398
+ doctorIds: z.ZodArray<z.ZodString, "many">;
8399
+ clinicIds: z.ZodArray<z.ZodString, "many">;
8277
8400
  createdAt: z.ZodType<Timestamp, z.ZodTypeDef, Timestamp>;
8278
8401
  updatedAt: z.ZodType<Timestamp, z.ZodTypeDef, Timestamp>;
8279
8402
  }, "strip", z.ZodTypeAny, {
@@ -8289,12 +8412,14 @@ declare const patientProfileSchema: z.ZodObject<{
8289
8412
  isActive: boolean;
8290
8413
  isVerified: boolean;
8291
8414
  updatedAt: Timestamp;
8415
+ createdAt: Timestamp;
8292
8416
  displayName: string;
8293
- expoTokens: string[];
8417
+ profilePhoto: string | null;
8294
8418
  gamification: {
8295
8419
  level: number;
8296
8420
  points: number;
8297
8421
  };
8422
+ expoTokens: string[];
8298
8423
  doctors: {
8299
8424
  userRef: string;
8300
8425
  isActive: boolean;
@@ -8302,8 +8427,8 @@ declare const patientProfileSchema: z.ZodObject<{
8302
8427
  notes?: string | undefined;
8303
8428
  assignedBy?: string | undefined;
8304
8429
  }[];
8305
- createdAt: Timestamp;
8306
- profilePhoto: string | null;
8430
+ doctorIds: string[];
8431
+ clinicIds: string[];
8307
8432
  }, {
8308
8433
  id: string;
8309
8434
  userRef: string;
@@ -8317,12 +8442,14 @@ declare const patientProfileSchema: z.ZodObject<{
8317
8442
  isActive: boolean;
8318
8443
  isVerified: boolean;
8319
8444
  updatedAt: Timestamp;
8445
+ createdAt: Timestamp;
8320
8446
  displayName: string;
8321
- expoTokens: string[];
8447
+ profilePhoto: string | null;
8322
8448
  gamification: {
8323
8449
  level: number;
8324
8450
  points: number;
8325
8451
  };
8452
+ expoTokens: string[];
8326
8453
  doctors: {
8327
8454
  userRef: string;
8328
8455
  isActive: boolean;
@@ -8330,8 +8457,8 @@ declare const patientProfileSchema: z.ZodObject<{
8330
8457
  notes?: string | undefined;
8331
8458
  assignedBy?: string | undefined;
8332
8459
  }[];
8333
- createdAt: Timestamp;
8334
- profilePhoto: string | null;
8460
+ doctorIds: string[];
8461
+ clinicIds: string[];
8335
8462
  }>;
8336
8463
  /**
8337
8464
  * Šema za validaciju podataka pri kreiranju profila
@@ -8391,6 +8518,8 @@ declare const createPatientProfileSchema: z.ZodObject<{
8391
8518
  notes?: string | undefined;
8392
8519
  assignedBy?: string | undefined;
8393
8520
  }>, "many">>;
8521
+ doctorIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
8522
+ clinicIds: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
8394
8523
  }, "strip", z.ZodTypeAny, {
8395
8524
  userRef: string;
8396
8525
  isActive: boolean;
@@ -8404,6 +8533,7 @@ declare const createPatientProfileSchema: z.ZodObject<{
8404
8533
  notes?: string | undefined;
8405
8534
  assignedBy?: string | undefined;
8406
8535
  }[] | undefined;
8536
+ profilePhoto?: string | null | undefined;
8407
8537
  gamification?: {
8408
8538
  level: number;
8409
8539
  points: number;
@@ -8415,7 +8545,8 @@ declare const createPatientProfileSchema: z.ZodObject<{
8415
8545
  notes?: string | undefined;
8416
8546
  assignedBy?: string | undefined;
8417
8547
  }[] | undefined;
8418
- profilePhoto?: string | null | undefined;
8548
+ doctorIds?: string[] | undefined;
8549
+ clinicIds?: string[] | undefined;
8419
8550
  }, {
8420
8551
  userRef: string;
8421
8552
  isActive: boolean;
@@ -8429,6 +8560,7 @@ declare const createPatientProfileSchema: z.ZodObject<{
8429
8560
  notes?: string | undefined;
8430
8561
  assignedBy?: string | undefined;
8431
8562
  }[] | undefined;
8563
+ profilePhoto?: string | null | undefined;
8432
8564
  gamification?: {
8433
8565
  level: number;
8434
8566
  points: number;
@@ -8440,7 +8572,8 @@ declare const createPatientProfileSchema: z.ZodObject<{
8440
8572
  notes?: string | undefined;
8441
8573
  assignedBy?: string | undefined;
8442
8574
  }[] | undefined;
8443
- profilePhoto?: string | null | undefined;
8575
+ doctorIds?: string[] | undefined;
8576
+ clinicIds?: string[] | undefined;
8444
8577
  }>;
8445
8578
  /**
8446
8579
  * Šema za validaciju podataka pri kreiranju osetljivih informacija
@@ -8535,6 +8668,54 @@ declare const createPatientSensitiveInfoSchema: z.ZodObject<{
8535
8668
  isNotifiable: boolean;
8536
8669
  }[] | undefined;
8537
8670
  }>;
8671
+ /**
8672
+ * Schema for validating patient search parameters.
8673
+ */
8674
+ declare const searchPatientsSchema: z.ZodEffects<z.ZodObject<{
8675
+ clinicId: z.ZodOptional<z.ZodString>;
8676
+ practitionerId: z.ZodOptional<z.ZodString>;
8677
+ }, "strip", z.ZodTypeAny, {
8678
+ practitionerId?: string | undefined;
8679
+ clinicId?: string | undefined;
8680
+ }, {
8681
+ practitionerId?: string | undefined;
8682
+ clinicId?: string | undefined;
8683
+ }>, {
8684
+ practitionerId?: string | undefined;
8685
+ clinicId?: string | undefined;
8686
+ }, {
8687
+ practitionerId?: string | undefined;
8688
+ clinicId?: string | undefined;
8689
+ }>;
8690
+ /**
8691
+ * Schema for validating requester information during patient search.
8692
+ */
8693
+ declare const requesterInfoSchema: z.ZodEffects<z.ZodObject<{
8694
+ id: z.ZodString;
8695
+ role: z.ZodEnum<["clinic_admin", "practitioner"]>;
8696
+ associatedClinicId: z.ZodOptional<z.ZodString>;
8697
+ associatedPractitionerId: z.ZodOptional<z.ZodString>;
8698
+ }, "strip", z.ZodTypeAny, {
8699
+ id: string;
8700
+ role: "clinic_admin" | "practitioner";
8701
+ associatedClinicId?: string | undefined;
8702
+ associatedPractitionerId?: string | undefined;
8703
+ }, {
8704
+ id: string;
8705
+ role: "clinic_admin" | "practitioner";
8706
+ associatedClinicId?: string | undefined;
8707
+ associatedPractitionerId?: string | undefined;
8708
+ }>, {
8709
+ id: string;
8710
+ role: "clinic_admin" | "practitioner";
8711
+ associatedClinicId?: string | undefined;
8712
+ associatedPractitionerId?: string | undefined;
8713
+ }, {
8714
+ id: string;
8715
+ role: "clinic_admin" | "practitioner";
8716
+ associatedClinicId?: string | undefined;
8717
+ associatedPractitionerId?: string | undefined;
8718
+ }>;
8538
8719
 
8539
8720
  /**
8540
8721
  * Šema za validaciju osnovnih informacija o zdravstvenom radniku
@@ -8884,6 +9065,7 @@ declare const practitionerClinicWorkingHoursSchema: z.ZodObject<{
8884
9065
  }, "strip", z.ZodTypeAny, {
8885
9066
  isActive: boolean;
8886
9067
  updatedAt: Timestamp;
9068
+ createdAt: Timestamp;
8887
9069
  workingHours: {
8888
9070
  monday: {
8889
9071
  start: string;
@@ -8914,11 +9096,11 @@ declare const practitionerClinicWorkingHoursSchema: z.ZodObject<{
8914
9096
  end: string;
8915
9097
  } | null;
8916
9098
  };
8917
- createdAt: Timestamp;
8918
9099
  clinicId: string;
8919
9100
  }, {
8920
9101
  isActive: boolean;
8921
9102
  updatedAt: Timestamp;
9103
+ createdAt: Timestamp;
8922
9104
  workingHours: {
8923
9105
  monday: {
8924
9106
  start: string;
@@ -8949,7 +9131,6 @@ declare const practitionerClinicWorkingHoursSchema: z.ZodObject<{
8949
9131
  end: string;
8950
9132
  } | null;
8951
9133
  };
8952
- createdAt: Timestamp;
8953
9134
  clinicId: string;
8954
9135
  }>;
8955
9136
  /**
@@ -9215,6 +9396,7 @@ declare const practitionerSchema: z.ZodObject<{
9215
9396
  }, "strip", z.ZodTypeAny, {
9216
9397
  isActive: boolean;
9217
9398
  updatedAt: Timestamp;
9399
+ createdAt: Timestamp;
9218
9400
  workingHours: {
9219
9401
  monday: {
9220
9402
  start: string;
@@ -9245,11 +9427,11 @@ declare const practitionerSchema: z.ZodObject<{
9245
9427
  end: string;
9246
9428
  } | null;
9247
9429
  };
9248
- createdAt: Timestamp;
9249
9430
  clinicId: string;
9250
9431
  }, {
9251
9432
  isActive: boolean;
9252
9433
  updatedAt: Timestamp;
9434
+ createdAt: Timestamp;
9253
9435
  workingHours: {
9254
9436
  monday: {
9255
9437
  start: string;
@@ -9280,7 +9462,6 @@ declare const practitionerSchema: z.ZodObject<{
9280
9462
  end: string;
9281
9463
  } | null;
9282
9464
  };
9283
- createdAt: Timestamp;
9284
9465
  clinicId: string;
9285
9466
  }>, "many">;
9286
9467
  isActive: z.ZodBoolean;
@@ -9316,6 +9497,7 @@ declare const practitionerSchema: z.ZodObject<{
9316
9497
  clinicWorkingHours: {
9317
9498
  isActive: boolean;
9318
9499
  updatedAt: Timestamp;
9500
+ createdAt: Timestamp;
9319
9501
  workingHours: {
9320
9502
  monday: {
9321
9503
  start: string;
@@ -9346,7 +9528,6 @@ declare const practitionerSchema: z.ZodObject<{
9346
9528
  end: string;
9347
9529
  } | null;
9348
9530
  };
9349
- createdAt: Timestamp;
9350
9531
  clinicId: string;
9351
9532
  }[];
9352
9533
  isActive: boolean;
@@ -9382,6 +9563,7 @@ declare const practitionerSchema: z.ZodObject<{
9382
9563
  clinicWorkingHours: {
9383
9564
  isActive: boolean;
9384
9565
  updatedAt: Timestamp;
9566
+ createdAt: Timestamp;
9385
9567
  workingHours: {
9386
9568
  monday: {
9387
9569
  start: string;
@@ -9412,7 +9594,6 @@ declare const practitionerSchema: z.ZodObject<{
9412
9594
  end: string;
9413
9595
  } | null;
9414
9596
  };
9415
- createdAt: Timestamp;
9416
9597
  clinicId: string;
9417
9598
  }[];
9418
9599
  isActive: boolean;
@@ -9624,6 +9805,7 @@ declare const createPractitionerSchema: z.ZodObject<{
9624
9805
  }, "strip", z.ZodTypeAny, {
9625
9806
  isActive: boolean;
9626
9807
  updatedAt: Timestamp;
9808
+ createdAt: Timestamp;
9627
9809
  workingHours: {
9628
9810
  monday: {
9629
9811
  start: string;
@@ -9654,11 +9836,11 @@ declare const createPractitionerSchema: z.ZodObject<{
9654
9836
  end: string;
9655
9837
  } | null;
9656
9838
  };
9657
- createdAt: Timestamp;
9658
9839
  clinicId: string;
9659
9840
  }, {
9660
9841
  isActive: boolean;
9661
9842
  updatedAt: Timestamp;
9843
+ createdAt: Timestamp;
9662
9844
  workingHours: {
9663
9845
  monday: {
9664
9846
  start: string;
@@ -9689,7 +9871,6 @@ declare const createPractitionerSchema: z.ZodObject<{
9689
9871
  end: string;
9690
9872
  } | null;
9691
9873
  };
9692
- createdAt: Timestamp;
9693
9874
  clinicId: string;
9694
9875
  }>, "many">>;
9695
9876
  isActive: z.ZodBoolean;
@@ -9724,6 +9905,7 @@ declare const createPractitionerSchema: z.ZodObject<{
9724
9905
  clinicWorkingHours?: {
9725
9906
  isActive: boolean;
9726
9907
  updatedAt: Timestamp;
9908
+ createdAt: Timestamp;
9727
9909
  workingHours: {
9728
9910
  monday: {
9729
9911
  start: string;
@@ -9754,7 +9936,6 @@ declare const createPractitionerSchema: z.ZodObject<{
9754
9936
  end: string;
9755
9937
  } | null;
9756
9938
  };
9757
- createdAt: Timestamp;
9758
9939
  clinicId: string;
9759
9940
  }[] | undefined;
9760
9941
  status?: PractitionerStatus | undefined;
@@ -9787,6 +9968,7 @@ declare const createPractitionerSchema: z.ZodObject<{
9787
9968
  clinicWorkingHours?: {
9788
9969
  isActive: boolean;
9789
9970
  updatedAt: Timestamp;
9971
+ createdAt: Timestamp;
9790
9972
  workingHours: {
9791
9973
  monday: {
9792
9974
  start: string;
@@ -9817,7 +9999,6 @@ declare const createPractitionerSchema: z.ZodObject<{
9817
9999
  end: string;
9818
10000
  } | null;
9819
10001
  };
9820
- createdAt: Timestamp;
9821
10002
  clinicId: string;
9822
10003
  }[] | undefined;
9823
10004
  status?: PractitionerStatus | undefined;
@@ -10024,6 +10205,7 @@ declare const createDraftPractitionerSchema: z.ZodObject<{
10024
10205
  }, "strip", z.ZodTypeAny, {
10025
10206
  isActive: boolean;
10026
10207
  updatedAt: Timestamp;
10208
+ createdAt: Timestamp;
10027
10209
  workingHours: {
10028
10210
  monday: {
10029
10211
  start: string;
@@ -10054,11 +10236,11 @@ declare const createDraftPractitionerSchema: z.ZodObject<{
10054
10236
  end: string;
10055
10237
  } | null;
10056
10238
  };
10057
- createdAt: Timestamp;
10058
10239
  clinicId: string;
10059
10240
  }, {
10060
10241
  isActive: boolean;
10061
10242
  updatedAt: Timestamp;
10243
+ createdAt: Timestamp;
10062
10244
  workingHours: {
10063
10245
  monday: {
10064
10246
  start: string;
@@ -10089,7 +10271,6 @@ declare const createDraftPractitionerSchema: z.ZodObject<{
10089
10271
  end: string;
10090
10272
  } | null;
10091
10273
  };
10092
- createdAt: Timestamp;
10093
10274
  clinicId: string;
10094
10275
  }>, "many">>;
10095
10276
  isActive: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
@@ -10122,6 +10303,7 @@ declare const createDraftPractitionerSchema: z.ZodObject<{
10122
10303
  clinicWorkingHours?: {
10123
10304
  isActive: boolean;
10124
10305
  updatedAt: Timestamp;
10306
+ createdAt: Timestamp;
10125
10307
  workingHours: {
10126
10308
  monday: {
10127
10309
  start: string;
@@ -10152,7 +10334,6 @@ declare const createDraftPractitionerSchema: z.ZodObject<{
10152
10334
  end: string;
10153
10335
  } | null;
10154
10336
  };
10155
- createdAt: Timestamp;
10156
10337
  clinicId: string;
10157
10338
  }[] | undefined;
10158
10339
  }, {
@@ -10181,6 +10362,7 @@ declare const createDraftPractitionerSchema: z.ZodObject<{
10181
10362
  clinicWorkingHours?: {
10182
10363
  isActive: boolean;
10183
10364
  updatedAt: Timestamp;
10365
+ createdAt: Timestamp;
10184
10366
  workingHours: {
10185
10367
  monday: {
10186
10368
  start: string;
@@ -10211,7 +10393,6 @@ declare const createDraftPractitionerSchema: z.ZodObject<{
10211
10393
  end: string;
10212
10394
  } | null;
10213
10395
  };
10214
- createdAt: Timestamp;
10215
10396
  clinicId: string;
10216
10397
  }[] | undefined;
10217
10398
  isActive?: boolean | undefined;
@@ -11006,6 +11187,7 @@ declare const clinicAdminSchema: z.ZodObject<{
11006
11187
  userRef: string;
11007
11188
  isActive: boolean;
11008
11189
  updatedAt: Timestamp | Date;
11190
+ createdAt: Timestamp | Date;
11009
11191
  clinicGroupId: string;
11010
11192
  isGroupOwner: boolean;
11011
11193
  clinicsManaged: string[];
@@ -11038,12 +11220,12 @@ declare const clinicAdminSchema: z.ZodObject<{
11038
11220
  title?: string | null | undefined;
11039
11221
  };
11040
11222
  roleTitle: string;
11041
- createdAt: Timestamp | Date;
11042
11223
  }, {
11043
11224
  id: string;
11044
11225
  userRef: string;
11045
11226
  isActive: boolean;
11046
11227
  updatedAt: Timestamp | Date;
11228
+ createdAt: Timestamp | Date;
11047
11229
  clinicGroupId: string;
11048
11230
  isGroupOwner: boolean;
11049
11231
  clinicsManaged: string[];
@@ -11076,7 +11258,6 @@ declare const clinicAdminSchema: z.ZodObject<{
11076
11258
  title?: string | null | undefined;
11077
11259
  };
11078
11260
  roleTitle: string;
11079
- createdAt: Timestamp | Date;
11080
11261
  }>;
11081
11262
  /**
11082
11263
  * Validaciona šema za admin token
@@ -11330,6 +11511,7 @@ declare const clinicGroupSchema: z.ZodObject<{
11330
11511
  isActive: boolean;
11331
11512
  updatedAt: Timestamp | Date;
11332
11513
  name: string;
11514
+ createdAt: Timestamp | Date;
11333
11515
  contactInfo: {
11334
11516
  email: string;
11335
11517
  phoneNumber: string;
@@ -11355,7 +11537,6 @@ declare const clinicGroupSchema: z.ZodObject<{
11355
11537
  ownerId: string | null;
11356
11538
  subscriptionModel: SubscriptionModel;
11357
11539
  admins: string[];
11358
- createdAt: Timestamp | Date;
11359
11540
  clinicsInfo: {
11360
11541
  id: string;
11361
11542
  name: string;
@@ -11404,6 +11585,7 @@ declare const clinicGroupSchema: z.ZodObject<{
11404
11585
  isActive: boolean;
11405
11586
  updatedAt: Timestamp | Date;
11406
11587
  name: string;
11588
+ createdAt: Timestamp | Date;
11407
11589
  contactInfo: {
11408
11590
  email: string;
11409
11591
  phoneNumber: string;
@@ -11429,7 +11611,6 @@ declare const clinicGroupSchema: z.ZodObject<{
11429
11611
  ownerId: string | null;
11430
11612
  subscriptionModel: SubscriptionModel;
11431
11613
  admins: string[];
11432
- createdAt: Timestamp | Date;
11433
11614
  clinicsInfo: {
11434
11615
  id: string;
11435
11616
  name: string;
@@ -12002,6 +12183,7 @@ declare const clinicSchema: z.ZodObject<{
12002
12183
  isVerified: boolean;
12003
12184
  updatedAt: Timestamp | Date;
12004
12185
  name: string;
12186
+ createdAt: Timestamp | Date;
12005
12187
  doctors: string[];
12006
12188
  clinicGroupId: string;
12007
12189
  contactInfo: {
@@ -12082,7 +12264,6 @@ declare const clinicSchema: z.ZodObject<{
12082
12264
  services: string[];
12083
12265
  admins: string[];
12084
12266
  featuredPhotos: string[];
12085
- createdAt: Timestamp | Date;
12086
12267
  rating: {
12087
12268
  average: number;
12088
12269
  count: number;
@@ -12135,6 +12316,7 @@ declare const clinicSchema: z.ZodObject<{
12135
12316
  isVerified: boolean;
12136
12317
  updatedAt: Timestamp | Date;
12137
12318
  name: string;
12319
+ createdAt: Timestamp | Date;
12138
12320
  doctors: string[];
12139
12321
  clinicGroupId: string;
12140
12322
  contactInfo: {
@@ -12215,7 +12397,6 @@ declare const clinicSchema: z.ZodObject<{
12215
12397
  services: string[];
12216
12398
  admins: string[];
12217
12399
  featuredPhotos: string[];
12218
- createdAt: Timestamp | Date;
12219
12400
  rating: {
12220
12401
  average: number;
12221
12402
  count: number;
@@ -15115,8 +15296,8 @@ declare const createCalendarEventSchema: z.ZodObject<{
15115
15296
  syncStatus: CalendarSyncStatus;
15116
15297
  eventType: CalendarEventType;
15117
15298
  updatedAt?: any;
15118
- description?: string | undefined;
15119
15299
  createdAt?: any;
15300
+ description?: string | undefined;
15120
15301
  appointmentId?: string | null | undefined;
15121
15302
  clinicBranchId?: string | null | undefined;
15122
15303
  procedureId?: string | null | undefined;
@@ -15172,8 +15353,8 @@ declare const createCalendarEventSchema: z.ZodObject<{
15172
15353
  syncStatus: CalendarSyncStatus;
15173
15354
  eventType: CalendarEventType;
15174
15355
  updatedAt?: any;
15175
- description?: string | undefined;
15176
15356
  createdAt?: any;
15357
+ description?: string | undefined;
15177
15358
  appointmentId?: string | null | undefined;
15178
15359
  clinicBranchId?: string | null | undefined;
15179
15360
  procedureId?: string | null | undefined;
@@ -15773,4 +15954,4 @@ declare enum FirebaseErrorCode {
15773
15954
  POPUP_ALREADY_OPEN = "auth/cancelled-popup-request"
15774
15955
  }
15775
15956
 
15776
- export { AUTH_ERRORS, type AddAllergyData, type AddBlockingConditionData, type AddContraindicationData, type AddMedicationData, type AddressData, type AdminInfo, type AdminToken, AdminTokenStatus, type Allergy, type AllergySubtype, AllergyType, type AllergyTypeWithSubtype, type AppointmentNotification, type AppointmentReminderNotification, AuthError, AuthService, type BaseNotification, BlockingCondition, type Brand, BrandService, CALENDAR_COLLECTION, CLINICS_COLLECTION, CLINIC_ADMINS_COLLECTION, CLINIC_GROUPS_COLLECTION, type CalendarEvent, CalendarEventStatus, type CalendarEventTime, CalendarEventType, CalendarServiceV2, CalendarSyncStatus, type Category, CategoryService, CertificationLevel, CertificationSpecialty, type Clinic, type ClinicAdmin, ClinicAdminService, type ClinicAdminSignupData, type ClinicBranchSetupData, type ClinicContactInfo, type ClinicGroup, ClinicGroupService, type ClinicGroupSetupData, type ClinicInfo, type ClinicLocation, ClinicPhotoTag, type ClinicReview, ClinicService, ClinicTag, type ClinicTags, type ContactPerson, Contraindication, CosmeticAllergySubtype, type CreateAdminTokenData, type CreateAppointmentParams, type CreateCalendarEventData, type CreateClinicAdminData, type CreateClinicData, type CreateClinicGroupData, type CreateDefaultClinicGroupData, type CreateDocumentTemplateData, type CreateDraftPractitionerData, type CreatePatientLocationInfoData, type CreatePatientMedicalInfoData, type CreatePatientProfileData, type CreatePatientSensitiveInfoData, type CreatePractitionerData, type CreatePractitionerTokenData, type CreateProcedureData, type CreateSyncedCalendarData, type CreateUserData, Currency, DOCUMENTATION_TEMPLATES_COLLECTION, type DoctorInfo, type DocumentElement, DocumentElementType, type DocumentTemplate, DocumentationTemplateService, DynamicVariable, type EmergencyContact, EnvironmentalAllergySubtype, FILLED_DOCUMENTS_COLLECTION, type FilledDocument, FilledDocumentService, FilledDocumentStatus, FirebaseErrorCode, type FirebaseUser, FoodAllergySubtype, type GamificationInfo, Gender, HeadingLevel, Language, ListType, type LocationData, MedicationAllergySubtype, type Notification, NotificationService, NotificationStatus, NotificationType, PATIENTS_COLLECTION, PATIENT_APPOINTMENTS_COLLECTION, PATIENT_LOCATION_INFO_COLLECTION, PATIENT_MEDICAL_HISTORY_COLLECTION, PATIENT_MEDICAL_INFO_COLLECTION, PATIENT_SENSITIVE_INFO_COLLECTION, PRACTITIONERS_COLLECTION, PROCEDURES_COLLECTION, type PatientClinic, type PatientDoctor, type PatientLocationInfo, type PatientMedicalInfo, type PatientProfile, type PatientProfileComplete, type PatientProfileInfo, type PatientSensitiveInfo, PatientService, type PostRequirementNotification, PracticeType, type Practitioner, type PractitionerBasicInfo, type PractitionerCertification, type PractitionerClinicProcedures, type PractitionerClinicWorkingHours, type PractitionerProfileInfo, type PractitionerReview, PractitionerService, PractitionerStatus, type PractitionerToken, PractitionerTokenStatus, type PractitionerWorkingHours, type PreRequirementNotification, PricingMeasure, type Procedure, type ProcedureCategorization, ProcedureFamily, type ProcedureInfo, ProcedureService, type Product, ProductService, REGISTER_TOKENS_COLLECTION, type Requirement, type ReviewInfo, SYNCED_CALENDARS_COLLECTION, type ServiceInfo, type Subcategory, SubcategoryService, SubscriptionModel, type SyncedCalendar, type SyncedCalendarEvent, SyncedCalendarProvider, SyncedCalendarsService, type Technology, TechnologyService, type TimeSlot, TreatmentBenefit, USER_ERRORS, type UpdateAllergyData, type UpdateAppointmentParams, type UpdateBlockingConditionData, type UpdateCalendarEventData, type UpdateClinicAdminData, type UpdateClinicData, type UpdateClinicGroupData, type UpdateContraindicationData, type UpdateDocumentTemplateData, type UpdateMedicationData, type UpdatePatientLocationInfoData, type UpdatePatientMedicalInfoData, type UpdatePatientProfileData, type UpdatePatientSensitiveInfoData, type UpdatePractitionerData, type UpdateProcedureData, type UpdateSyncedCalendarData, type UpdateVitalStatsData, type User, UserRole, UserService, type ValidationSchema, type VitalStats, type WorkingHours, addAllergySchema, addBlockingConditionSchema, addContraindicationSchema, addMedicationSchema, addressDataSchema, adminInfoSchema, adminTokenSchema, allergySchema, allergySubtypeSchema, appointmentNotificationSchema, appointmentReminderNotificationSchema, baseNotificationSchema, blockingConditionSchema, calendarEventSchema, calendarEventTimeSchema, clinicAdminOptionsSchema, clinicAdminSchema, clinicAdminSignupSchema, clinicBranchSetupSchema, clinicContactInfoSchema, clinicGroupSchema, clinicGroupSetupSchema, clinicInfoSchema, clinicLocationSchema, clinicReviewSchema, clinicSchema, clinicTagsSchema, contactPersonSchema, contraindicationSchema, createAdminTokenSchema, createAppointmentSchema, createCalendarEventSchema, createClinicAdminSchema, createClinicGroupSchema, createClinicSchema, createDefaultClinicGroupSchema, createDocumentTemplateSchema, createDraftPractitionerSchema, createPatientLocationInfoSchema, createPatientMedicalInfoSchema, createPatientProfileSchema, createPatientSensitiveInfoSchema, createPractitionerSchema, createPractitionerTokenSchema, createUserOptionsSchema, doctorInfoSchema, documentElementSchema, documentElementWithoutIdSchema, documentTemplateSchema, emailSchema, emergencyContactSchema, gamificationSchema, getFirebaseApp, getFirebaseAuth, getFirebaseDB, getFirebaseInstance, initializeFirebase, locationDataSchema, medicationSchema, notificationSchema, passwordSchema, patientClinicSchema, patientDoctorSchema, patientLocationInfoSchema, patientMedicalInfoSchema, patientProfileInfoSchema, patientProfileSchema, patientSensitiveInfoSchema, postRequirementNotificationSchema, practitionerBasicInfoSchema, practitionerCertificationSchema, practitionerClinicProceduresSchema, practitionerClinicWorkingHoursSchema, practitionerProfileInfoSchema, practitionerReviewSchema, practitionerSchema, practitionerTokenSchema, practitionerWorkingHoursSchema, preRequirementNotificationSchema, procedureCategorizationSchema, procedureInfoSchema, reviewInfoSchema, serviceInfoSchema, syncedCalendarEventSchema, timeSlotSchema, timestampSchema, updateAllergySchema, updateAppointmentSchema, updateBlockingConditionSchema, updateCalendarEventSchema, updateClinicAdminSchema, updateClinicGroupSchema, updateClinicSchema, updateContraindicationSchema, updateDocumentTemplateSchema, updateMedicationSchema, updatePatientMedicalInfoSchema, updateVitalStatsSchema, userRoleSchema, userRolesSchema, userSchema, vitalStatsSchema, workingHoursSchema };
15957
+ export { AUTH_ERRORS, type AddAllergyData, type AddBlockingConditionData, type AddContraindicationData, type AddMedicationData, type AddressData, type AdminInfo, type AdminToken, AdminTokenStatus, type Allergy, type AllergySubtype, AllergyType, type AllergyTypeWithSubtype, type AppointmentNotification, type AppointmentReminderNotification, AuthError, AuthService, type BaseNotification, BlockingCondition, type Brand, BrandService, CALENDAR_COLLECTION, CLINICS_COLLECTION, CLINIC_ADMINS_COLLECTION, CLINIC_GROUPS_COLLECTION, type CalendarEvent, CalendarEventStatus, type CalendarEventTime, CalendarEventType, CalendarServiceV2, CalendarSyncStatus, type Category, CategoryService, CertificationLevel, CertificationSpecialty, type Clinic, type ClinicAdmin, ClinicAdminService, type ClinicAdminSignupData, type ClinicBranchSetupData, type ClinicContactInfo, type ClinicGroup, ClinicGroupService, type ClinicGroupSetupData, type ClinicInfo, type ClinicLocation, ClinicPhotoTag, type ClinicReview, ClinicService, ClinicTag, type ClinicTags, type ContactPerson, Contraindication, CosmeticAllergySubtype, type CreateAdminTokenData, type CreateAppointmentParams, type CreateCalendarEventData, type CreateClinicAdminData, type CreateClinicData, type CreateClinicGroupData, type CreateDefaultClinicGroupData, type CreateDocumentTemplateData, type CreateDraftPractitionerData, type CreatePatientLocationInfoData, type CreatePatientMedicalInfoData, type CreatePatientProfileData, type CreatePatientSensitiveInfoData, type CreatePractitionerData, type CreatePractitionerTokenData, type CreateProcedureData, type CreateSyncedCalendarData, type CreateUserData, Currency, DOCUMENTATION_TEMPLATES_COLLECTION, type DoctorInfo, type DocumentElement, DocumentElementType, type DocumentTemplate, DocumentationTemplateService, DynamicVariable, type EmergencyContact, EnvironmentalAllergySubtype, FILLED_DOCUMENTS_COLLECTION, type FilledDocument, FilledDocumentService, FilledDocumentStatus, FirebaseErrorCode, type FirebaseUser, FoodAllergySubtype, type GamificationInfo, Gender, HeadingLevel, Language, ListType, type LocationData, MedicationAllergySubtype, type Notification, NotificationService, NotificationStatus, NotificationType, PATIENTS_COLLECTION, PATIENT_APPOINTMENTS_COLLECTION, PATIENT_LOCATION_INFO_COLLECTION, PATIENT_MEDICAL_HISTORY_COLLECTION, PATIENT_MEDICAL_INFO_COLLECTION, PATIENT_SENSITIVE_INFO_COLLECTION, PRACTITIONERS_COLLECTION, PROCEDURES_COLLECTION, type PatientClinic, type PatientDoctor, type PatientLocationInfo, type PatientMedicalInfo, type PatientProfile, type PatientProfileComplete, type PatientProfileInfo, type PatientSensitiveInfo, PatientService, type PostRequirementNotification, PracticeType, type Practitioner, type PractitionerBasicInfo, type PractitionerCertification, type PractitionerClinicProcedures, type PractitionerClinicWorkingHours, type PractitionerProfileInfo, type PractitionerReview, PractitionerService, PractitionerStatus, type PractitionerToken, PractitionerTokenStatus, type PractitionerWorkingHours, type PreRequirementNotification, PricingMeasure, type Procedure, type ProcedureCategorization, ProcedureFamily, type ProcedureInfo, ProcedureService, type Product, ProductService, REGISTER_TOKENS_COLLECTION, type RequesterInfo, type Requirement, type ReviewInfo, SYNCED_CALENDARS_COLLECTION, type SearchPatientsParams, type ServiceInfo, type Subcategory, SubcategoryService, SubscriptionModel, type SyncedCalendar, type SyncedCalendarEvent, SyncedCalendarProvider, SyncedCalendarsService, type Technology, TechnologyService, type TimeSlot, TreatmentBenefit, USER_ERRORS, type UpdateAllergyData, type UpdateAppointmentParams, type UpdateBlockingConditionData, type UpdateCalendarEventData, type UpdateClinicAdminData, type UpdateClinicData, type UpdateClinicGroupData, type UpdateContraindicationData, type UpdateDocumentTemplateData, type UpdateMedicationData, type UpdatePatientLocationInfoData, type UpdatePatientMedicalInfoData, type UpdatePatientProfileData, type UpdatePatientSensitiveInfoData, type UpdatePractitionerData, type UpdateProcedureData, type UpdateSyncedCalendarData, type UpdateVitalStatsData, type User, UserRole, UserService, type ValidationSchema, type VitalStats, type WorkingHours, addAllergySchema, addBlockingConditionSchema, addContraindicationSchema, addMedicationSchema, addressDataSchema, adminInfoSchema, adminTokenSchema, allergySchema, allergySubtypeSchema, appointmentNotificationSchema, appointmentReminderNotificationSchema, baseNotificationSchema, blockingConditionSchema, calendarEventSchema, calendarEventTimeSchema, clinicAdminOptionsSchema, clinicAdminSchema, clinicAdminSignupSchema, clinicBranchSetupSchema, clinicContactInfoSchema, clinicGroupSchema, clinicGroupSetupSchema, clinicInfoSchema, clinicLocationSchema, clinicReviewSchema, clinicSchema, clinicTagsSchema, contactPersonSchema, contraindicationSchema, createAdminTokenSchema, createAppointmentSchema, createCalendarEventSchema, createClinicAdminSchema, createClinicGroupSchema, createClinicSchema, createDefaultClinicGroupSchema, createDocumentTemplateSchema, createDraftPractitionerSchema, createPatientLocationInfoSchema, createPatientMedicalInfoSchema, createPatientProfileSchema, createPatientSensitiveInfoSchema, createPractitionerSchema, createPractitionerTokenSchema, createUserOptionsSchema, doctorInfoSchema, documentElementSchema, documentElementWithoutIdSchema, documentTemplateSchema, emailSchema, emergencyContactSchema, gamificationSchema, getFirebaseApp, getFirebaseAuth, getFirebaseDB, getFirebaseInstance, initializeFirebase, locationDataSchema, medicationSchema, notificationSchema, passwordSchema, patientClinicSchema, patientDoctorSchema, patientLocationInfoSchema, patientMedicalInfoSchema, patientProfileInfoSchema, patientProfileSchema, patientSensitiveInfoSchema, postRequirementNotificationSchema, practitionerBasicInfoSchema, practitionerCertificationSchema, practitionerClinicProceduresSchema, practitionerClinicWorkingHoursSchema, practitionerProfileInfoSchema, practitionerReviewSchema, practitionerSchema, practitionerTokenSchema, practitionerWorkingHoursSchema, preRequirementNotificationSchema, procedureCategorizationSchema, procedureInfoSchema, requesterInfoSchema, reviewInfoSchema, searchPatientsSchema, serviceInfoSchema, syncedCalendarEventSchema, timeSlotSchema, timestampSchema, updateAllergySchema, updateAppointmentSchema, updateBlockingConditionSchema, updateCalendarEventSchema, updateClinicAdminSchema, updateClinicGroupSchema, updateClinicSchema, updateContraindicationSchema, updateDocumentTemplateSchema, updateMedicationSchema, updatePatientMedicalInfoSchema, updateVitalStatsSchema, userRoleSchema, userRolesSchema, userSchema, vitalStatsSchema, workingHoursSchema };