@blackcode_sa/metaestetics-api 1.4.17 → 1.5.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.
Files changed (31) hide show
  1. package/dist/index.d.mts +9633 -7023
  2. package/dist/index.d.ts +9633 -7023
  3. package/dist/index.js +2773 -150
  4. package/dist/index.mjs +2809 -150
  5. package/package.json +4 -3
  6. package/src/index.ts +48 -1
  7. package/src/services/calendar/calendar-refactored.service.ts +1531 -0
  8. package/src/services/calendar/calendar.service.ts +1077 -0
  9. package/src/services/calendar/synced-calendars.service.ts +743 -0
  10. package/src/services/calendar/utils/appointment.utils.ts +314 -0
  11. package/src/services/calendar/utils/calendar-event.utils.ts +510 -0
  12. package/src/services/calendar/utils/clinic.utils.ts +237 -0
  13. package/src/services/calendar/utils/docs.utils.ts +157 -0
  14. package/src/services/calendar/utils/google-calendar.utils.ts +697 -0
  15. package/src/services/calendar/utils/index.ts +8 -0
  16. package/src/services/calendar/utils/patient.utils.ts +198 -0
  17. package/src/services/calendar/utils/practitioner.utils.ts +221 -0
  18. package/src/services/calendar/utils/synced-calendar.utils.ts +472 -0
  19. package/src/services/clinic/clinic.service.ts +2 -2
  20. package/src/services/clinic/utils/clinic.utils.ts +49 -47
  21. package/src/services/practitioner/practitioner.service.ts +1 -0
  22. package/src/types/calendar/index.ts +187 -0
  23. package/src/types/calendar/synced-calendar.types.ts +66 -0
  24. package/src/types/clinic/index.ts +4 -15
  25. package/src/types/index.ts +4 -0
  26. package/src/types/practitioner/index.ts +21 -0
  27. package/src/types/profile/index.ts +39 -0
  28. package/src/validations/calendar.schema.ts +223 -0
  29. package/src/validations/clinic.schema.ts +3 -3
  30. package/src/validations/practitioner.schema.ts +21 -0
  31. package/src/validations/profile-info.schema.ts +41 -0
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@blackcode_sa/metaestetics-api",
3
3
  "private": false,
4
- "version": "1.4.17",
4
+ "version": "1.5.0",
5
5
  "description": "Firebase authentication service with anonymous upgrade support",
6
6
  "main": "./dist/index.js",
7
7
  "module": "./dist/index.mjs",
@@ -84,14 +84,15 @@
84
84
  "@types/jest": "^29.5.14",
85
85
  "@types/node": "^20.17.13",
86
86
  "@types/react": "~18.3.12",
87
+ "expo-crypto": "^14.0.0",
87
88
  "firebase-mock": "^2.3.2",
88
89
  "jest": "^29.7.0",
89
90
  "ts-jest": "^29.2.5",
90
91
  "tsup": "^8.3.5",
91
- "typescript": "^5.7.3",
92
- "expo-crypto": "^14.0.0"
92
+ "typescript": "^5.7.3"
93
93
  },
94
94
  "dependencies": {
95
+ "axios": "^1.8.3",
95
96
  "expo-server-sdk": "^3.13.0",
96
97
  "firebase-admin": "^13.0.2",
97
98
  "geofire-common": "^6.0.0",
package/src/index.ts CHANGED
@@ -22,6 +22,8 @@ export {
22
22
  DocumentationTemplateService,
23
23
  FilledDocumentService,
24
24
  } from "./services/documentation-templates";
25
+ export { CalendarServiceV2 } from "./services/calendar/calendar-refactored.service";
26
+ export { SyncedCalendarsService } from "./services/calendar/synced-calendars.service";
25
27
 
26
28
  // Types
27
29
  export type { User, UserRole, CreateUserData, FirebaseUser } from "./types";
@@ -35,6 +37,11 @@ export * from "./validations/practitioner.schema";
35
37
  export * from "./validations/clinic.schema";
36
38
  export * from "./validations/patient/medical-info.schema";
37
39
  export * from "./validations/documentation-templates.schema";
40
+ export * from "./validations/calendar.schema";
41
+ export {
42
+ practitionerProfileInfoSchema,
43
+ patientProfileInfoSchema,
44
+ } from "./validations/profile-info.schema";
38
45
  export { FirebaseErrorCode } from "./errors/firebase.errors";
39
46
 
40
47
  // Notification types
@@ -115,6 +122,7 @@ export type {
115
122
  PractitionerClinicProcedures,
116
123
  PractitionerReview,
117
124
  PractitionerWorkingHours,
125
+ PractitionerClinicWorkingHours,
118
126
  } from "./types/practitioner";
119
127
  export { PRACTITIONERS_COLLECTION } from "./types/practitioner";
120
128
 
@@ -136,7 +144,6 @@ export type {
136
144
  ClinicReview,
137
145
  ClinicAdminSignupData,
138
146
  ContactPerson,
139
- ClinicInfo,
140
147
  AdminToken,
141
148
  AdminInfo,
142
149
  CreateAdminTokenData,
@@ -159,6 +166,46 @@ export {
159
166
  SubscriptionModel,
160
167
  } from "./types/clinic";
161
168
 
169
+ // Profile info types
170
+ export type {
171
+ ClinicInfo,
172
+ PractitionerProfileInfo,
173
+ PatientProfileInfo,
174
+ } from "./types/profile";
175
+
176
+ // Calendar types
177
+ export type {
178
+ CalendarEvent,
179
+ CalendarEventTime,
180
+ CreateCalendarEventData,
181
+ UpdateCalendarEventData,
182
+ TimeSlot,
183
+ ProcedureInfo,
184
+ ProcedureCategorization,
185
+ SyncedCalendarEvent,
186
+ CreateAppointmentParams,
187
+ UpdateAppointmentParams,
188
+ } from "./types/calendar";
189
+
190
+ export {
191
+ CalendarEventStatus,
192
+ CalendarEventType,
193
+ CalendarSyncStatus,
194
+ CALENDAR_COLLECTION,
195
+ } from "./types/calendar";
196
+
197
+ // Synced calendar types
198
+ export type {
199
+ SyncedCalendar,
200
+ CreateSyncedCalendarData,
201
+ UpdateSyncedCalendarData,
202
+ } from "./types/calendar/synced-calendar.types";
203
+
204
+ export {
205
+ SyncedCalendarProvider,
206
+ SYNCED_CALENDARS_COLLECTION,
207
+ } from "./types/calendar/synced-calendar.types";
208
+
162
209
  // Certification types
163
210
 
164
211
  // Brand types