@blackcode_sa/metaestetics-api 1.12.5 → 1.12.6
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/admin/index.d.mts +83 -1
- package/dist/admin/index.d.ts +83 -1
- package/dist/admin/index.js +37 -14
- package/dist/admin/index.mjs +35 -14
- package/package.json +2 -1
- package/src/admin/index.ts +43 -36
package/dist/admin/index.d.mts
CHANGED
|
@@ -1028,6 +1028,88 @@ interface WorkingHours {
|
|
|
1028
1028
|
}[];
|
|
1029
1029
|
} | null;
|
|
1030
1030
|
}
|
|
1031
|
+
/**
|
|
1032
|
+
* Enum for subscription status
|
|
1033
|
+
*/
|
|
1034
|
+
declare enum SubscriptionStatus {
|
|
1035
|
+
PENDING = "pending",
|
|
1036
|
+
ACTIVE = "active",
|
|
1037
|
+
PENDING_CANCELLATION = "pending_cancellation",
|
|
1038
|
+
CANCELED = "canceled",
|
|
1039
|
+
PAST_DUE = "past_due",
|
|
1040
|
+
TRIALING = "trialing"
|
|
1041
|
+
}
|
|
1042
|
+
/**
|
|
1043
|
+
* Interface for billing information
|
|
1044
|
+
*/
|
|
1045
|
+
interface BillingInfo {
|
|
1046
|
+
stripeCustomerId: string;
|
|
1047
|
+
subscriptionStatus: SubscriptionStatus;
|
|
1048
|
+
planType: string;
|
|
1049
|
+
stripeSubscriptionId: string | null;
|
|
1050
|
+
stripePriceId: string | null;
|
|
1051
|
+
currentPeriodStart: Timestamp | null;
|
|
1052
|
+
currentPeriodEnd: Timestamp | null;
|
|
1053
|
+
updatedAt: Timestamp;
|
|
1054
|
+
}
|
|
1055
|
+
/**
|
|
1056
|
+
* Enum for billing transaction types
|
|
1057
|
+
*/
|
|
1058
|
+
declare enum BillingTransactionType {
|
|
1059
|
+
SUBSCRIPTION_CREATED = "subscription_created",
|
|
1060
|
+
SUBSCRIPTION_ACTIVATED = "subscription_activated",
|
|
1061
|
+
SUBSCRIPTION_RENEWED = "subscription_renewed",
|
|
1062
|
+
SUBSCRIPTION_UPDATED = "subscription_updated",
|
|
1063
|
+
SUBSCRIPTION_CANCELED = "subscription_canceled",
|
|
1064
|
+
SUBSCRIPTION_REACTIVATED = "subscription_reactivated",
|
|
1065
|
+
SUBSCRIPTION_DELETED = "subscription_deleted"
|
|
1066
|
+
}
|
|
1067
|
+
/**
|
|
1068
|
+
* Interface for Stripe data in billing transactions
|
|
1069
|
+
*/
|
|
1070
|
+
interface StripeTransactionData {
|
|
1071
|
+
sessionId?: string;
|
|
1072
|
+
subscriptionId?: string;
|
|
1073
|
+
invoiceId?: string;
|
|
1074
|
+
priceId: string;
|
|
1075
|
+
customerId: string;
|
|
1076
|
+
}
|
|
1077
|
+
/**
|
|
1078
|
+
* Interface for plan details in billing transactions
|
|
1079
|
+
*/
|
|
1080
|
+
interface PlanDetails {
|
|
1081
|
+
planName: string;
|
|
1082
|
+
planPeriod: string;
|
|
1083
|
+
planDisplayName: string;
|
|
1084
|
+
}
|
|
1085
|
+
/**
|
|
1086
|
+
* Interface for billing transactions
|
|
1087
|
+
*/
|
|
1088
|
+
interface BillingTransaction {
|
|
1089
|
+
id: string;
|
|
1090
|
+
clinicGroupId: string;
|
|
1091
|
+
type: BillingTransactionType;
|
|
1092
|
+
description: string;
|
|
1093
|
+
amount: number;
|
|
1094
|
+
currency: string;
|
|
1095
|
+
stripeData: StripeTransactionData;
|
|
1096
|
+
planDetails: PlanDetails;
|
|
1097
|
+
metadata?: Record<string, any>;
|
|
1098
|
+
timestamp: Timestamp;
|
|
1099
|
+
createdAt: Timestamp;
|
|
1100
|
+
}
|
|
1101
|
+
/**
|
|
1102
|
+
* Interface for creating a billing transaction
|
|
1103
|
+
*/
|
|
1104
|
+
interface CreateBillingTransactionData {
|
|
1105
|
+
type: BillingTransactionType;
|
|
1106
|
+
description: string;
|
|
1107
|
+
amount: number;
|
|
1108
|
+
currency: string;
|
|
1109
|
+
stripeData: StripeTransactionData;
|
|
1110
|
+
planDetails: PlanDetails;
|
|
1111
|
+
metadata?: Record<string, any>;
|
|
1112
|
+
}
|
|
1031
1113
|
/**
|
|
1032
1114
|
* Interface for doctor information
|
|
1033
1115
|
*/
|
|
@@ -3529,4 +3611,4 @@ declare class UserProfileAdminService {
|
|
|
3529
3611
|
initializePractitionerRole(userId: string): Promise<User>;
|
|
3530
3612
|
}
|
|
3531
3613
|
|
|
3532
|
-
export { type Appointment, AppointmentAggregationService, type AppointmentCancellationEmailData, type AppointmentConfirmationEmailData, type AppointmentEmailDataBase, AppointmentMailingService, type AppointmentReminderNotification, type AppointmentRequestedEmailData, type AppointmentRescheduledProposalEmailData, AppointmentStatus, type AvailableSlot, BaseMailingService, type BaseNotification, BookingAdmin, BookingAvailabilityCalculator, type BookingAvailabilityRequest, type BookingAvailabilityResponse, CalendarAdminService, type Clinic, type ClinicAdminNotificationData, ClinicAggregationService, type ClinicInfo, type ClinicLocation, type DoctorInfo, DocumentManagerAdminService, type ExistingPractitionerInviteEmailData, ExistingPractitionerInviteMailingService, type FilledDocument, FilledFormsAggregationService, type InitializeAppointmentFormsResult, Logger, NOTIFICATIONS_COLLECTION, type NewMailgunClient$2 as NewMailgunClient, type Notification, NotificationStatus, NotificationType, NotificationsAdmin, type OrchestrateAppointmentCreationData, PATIENTS_COLLECTION, PATIENT_REQUIREMENTS_SUBCOLLECTION_NAME, PATIENT_SENSITIVE_INFO_COLLECTION, type PatientProfile as Patient, PatientAggregationService, PatientInstructionStatus, type PatientProfile, type PatientRequirementInstance, type PatientRequirementInstruction, PatientRequirementOverallStatus, PatientRequirementsAdminService, type PatientSensitiveInfo, type PostRequirementNotification, type Practitioner, PractitionerAggregationService, type PractitionerInvite, PractitionerInviteAggregationService, type PractitionerInviteEmailData, PractitionerInviteMailingService, PractitionerInviteStatus, type PractitionerToken, PractitionerTokenStatus, type PreRequirementNotification, type Procedure, ProcedureAggregationService, type ProcedureSummaryInfo, type Review, type ReviewAddedEmailData, type ReviewRequestEmailData, ReviewsAggregationService, type TimeInterval, UserProfileAdminService, UserRole, freeConsultationInfrastructure };
|
|
3614
|
+
export { type Appointment, AppointmentAggregationService, type AppointmentCancellationEmailData, type AppointmentConfirmationEmailData, type AppointmentEmailDataBase, AppointmentMailingService, type AppointmentReminderNotification, type AppointmentRequestedEmailData, type AppointmentRescheduledProposalEmailData, AppointmentStatus, type AvailableSlot, BaseMailingService, type BaseNotification, type BillingInfo, type BillingTransaction, BillingTransactionType, BookingAdmin, BookingAvailabilityCalculator, type BookingAvailabilityRequest, type BookingAvailabilityResponse, CalendarAdminService, type Clinic, type ClinicAdminNotificationData, ClinicAggregationService, type ClinicInfo, type ClinicLocation, type CreateBillingTransactionData, type DoctorInfo, DocumentManagerAdminService, type ExistingPractitionerInviteEmailData, ExistingPractitionerInviteMailingService, type FilledDocument, FilledFormsAggregationService, type InitializeAppointmentFormsResult, Logger, NOTIFICATIONS_COLLECTION, type NewMailgunClient$2 as NewMailgunClient, type Notification, NotificationStatus, NotificationType, NotificationsAdmin, type OrchestrateAppointmentCreationData, PATIENTS_COLLECTION, PATIENT_REQUIREMENTS_SUBCOLLECTION_NAME, PATIENT_SENSITIVE_INFO_COLLECTION, type PatientProfile as Patient, PatientAggregationService, PatientInstructionStatus, type PatientProfile, type PatientRequirementInstance, type PatientRequirementInstruction, PatientRequirementOverallStatus, PatientRequirementsAdminService, type PatientSensitiveInfo, type PlanDetails, type PostRequirementNotification, type Practitioner, PractitionerAggregationService, type PractitionerInvite, PractitionerInviteAggregationService, type PractitionerInviteEmailData, PractitionerInviteMailingService, PractitionerInviteStatus, type PractitionerToken, PractitionerTokenStatus, type PreRequirementNotification, type Procedure, ProcedureAggregationService, type ProcedureSummaryInfo, type Review, type ReviewAddedEmailData, type ReviewRequestEmailData, ReviewsAggregationService, type StripeTransactionData, SubscriptionStatus, type TimeInterval, UserProfileAdminService, UserRole, freeConsultationInfrastructure };
|
package/dist/admin/index.d.ts
CHANGED
|
@@ -1028,6 +1028,88 @@ interface WorkingHours {
|
|
|
1028
1028
|
}[];
|
|
1029
1029
|
} | null;
|
|
1030
1030
|
}
|
|
1031
|
+
/**
|
|
1032
|
+
* Enum for subscription status
|
|
1033
|
+
*/
|
|
1034
|
+
declare enum SubscriptionStatus {
|
|
1035
|
+
PENDING = "pending",
|
|
1036
|
+
ACTIVE = "active",
|
|
1037
|
+
PENDING_CANCELLATION = "pending_cancellation",
|
|
1038
|
+
CANCELED = "canceled",
|
|
1039
|
+
PAST_DUE = "past_due",
|
|
1040
|
+
TRIALING = "trialing"
|
|
1041
|
+
}
|
|
1042
|
+
/**
|
|
1043
|
+
* Interface for billing information
|
|
1044
|
+
*/
|
|
1045
|
+
interface BillingInfo {
|
|
1046
|
+
stripeCustomerId: string;
|
|
1047
|
+
subscriptionStatus: SubscriptionStatus;
|
|
1048
|
+
planType: string;
|
|
1049
|
+
stripeSubscriptionId: string | null;
|
|
1050
|
+
stripePriceId: string | null;
|
|
1051
|
+
currentPeriodStart: Timestamp | null;
|
|
1052
|
+
currentPeriodEnd: Timestamp | null;
|
|
1053
|
+
updatedAt: Timestamp;
|
|
1054
|
+
}
|
|
1055
|
+
/**
|
|
1056
|
+
* Enum for billing transaction types
|
|
1057
|
+
*/
|
|
1058
|
+
declare enum BillingTransactionType {
|
|
1059
|
+
SUBSCRIPTION_CREATED = "subscription_created",
|
|
1060
|
+
SUBSCRIPTION_ACTIVATED = "subscription_activated",
|
|
1061
|
+
SUBSCRIPTION_RENEWED = "subscription_renewed",
|
|
1062
|
+
SUBSCRIPTION_UPDATED = "subscription_updated",
|
|
1063
|
+
SUBSCRIPTION_CANCELED = "subscription_canceled",
|
|
1064
|
+
SUBSCRIPTION_REACTIVATED = "subscription_reactivated",
|
|
1065
|
+
SUBSCRIPTION_DELETED = "subscription_deleted"
|
|
1066
|
+
}
|
|
1067
|
+
/**
|
|
1068
|
+
* Interface for Stripe data in billing transactions
|
|
1069
|
+
*/
|
|
1070
|
+
interface StripeTransactionData {
|
|
1071
|
+
sessionId?: string;
|
|
1072
|
+
subscriptionId?: string;
|
|
1073
|
+
invoiceId?: string;
|
|
1074
|
+
priceId: string;
|
|
1075
|
+
customerId: string;
|
|
1076
|
+
}
|
|
1077
|
+
/**
|
|
1078
|
+
* Interface for plan details in billing transactions
|
|
1079
|
+
*/
|
|
1080
|
+
interface PlanDetails {
|
|
1081
|
+
planName: string;
|
|
1082
|
+
planPeriod: string;
|
|
1083
|
+
planDisplayName: string;
|
|
1084
|
+
}
|
|
1085
|
+
/**
|
|
1086
|
+
* Interface for billing transactions
|
|
1087
|
+
*/
|
|
1088
|
+
interface BillingTransaction {
|
|
1089
|
+
id: string;
|
|
1090
|
+
clinicGroupId: string;
|
|
1091
|
+
type: BillingTransactionType;
|
|
1092
|
+
description: string;
|
|
1093
|
+
amount: number;
|
|
1094
|
+
currency: string;
|
|
1095
|
+
stripeData: StripeTransactionData;
|
|
1096
|
+
planDetails: PlanDetails;
|
|
1097
|
+
metadata?: Record<string, any>;
|
|
1098
|
+
timestamp: Timestamp;
|
|
1099
|
+
createdAt: Timestamp;
|
|
1100
|
+
}
|
|
1101
|
+
/**
|
|
1102
|
+
* Interface for creating a billing transaction
|
|
1103
|
+
*/
|
|
1104
|
+
interface CreateBillingTransactionData {
|
|
1105
|
+
type: BillingTransactionType;
|
|
1106
|
+
description: string;
|
|
1107
|
+
amount: number;
|
|
1108
|
+
currency: string;
|
|
1109
|
+
stripeData: StripeTransactionData;
|
|
1110
|
+
planDetails: PlanDetails;
|
|
1111
|
+
metadata?: Record<string, any>;
|
|
1112
|
+
}
|
|
1031
1113
|
/**
|
|
1032
1114
|
* Interface for doctor information
|
|
1033
1115
|
*/
|
|
@@ -3529,4 +3611,4 @@ declare class UserProfileAdminService {
|
|
|
3529
3611
|
initializePractitionerRole(userId: string): Promise<User>;
|
|
3530
3612
|
}
|
|
3531
3613
|
|
|
3532
|
-
export { type Appointment, AppointmentAggregationService, type AppointmentCancellationEmailData, type AppointmentConfirmationEmailData, type AppointmentEmailDataBase, AppointmentMailingService, type AppointmentReminderNotification, type AppointmentRequestedEmailData, type AppointmentRescheduledProposalEmailData, AppointmentStatus, type AvailableSlot, BaseMailingService, type BaseNotification, BookingAdmin, BookingAvailabilityCalculator, type BookingAvailabilityRequest, type BookingAvailabilityResponse, CalendarAdminService, type Clinic, type ClinicAdminNotificationData, ClinicAggregationService, type ClinicInfo, type ClinicLocation, type DoctorInfo, DocumentManagerAdminService, type ExistingPractitionerInviteEmailData, ExistingPractitionerInviteMailingService, type FilledDocument, FilledFormsAggregationService, type InitializeAppointmentFormsResult, Logger, NOTIFICATIONS_COLLECTION, type NewMailgunClient$2 as NewMailgunClient, type Notification, NotificationStatus, NotificationType, NotificationsAdmin, type OrchestrateAppointmentCreationData, PATIENTS_COLLECTION, PATIENT_REQUIREMENTS_SUBCOLLECTION_NAME, PATIENT_SENSITIVE_INFO_COLLECTION, type PatientProfile as Patient, PatientAggregationService, PatientInstructionStatus, type PatientProfile, type PatientRequirementInstance, type PatientRequirementInstruction, PatientRequirementOverallStatus, PatientRequirementsAdminService, type PatientSensitiveInfo, type PostRequirementNotification, type Practitioner, PractitionerAggregationService, type PractitionerInvite, PractitionerInviteAggregationService, type PractitionerInviteEmailData, PractitionerInviteMailingService, PractitionerInviteStatus, type PractitionerToken, PractitionerTokenStatus, type PreRequirementNotification, type Procedure, ProcedureAggregationService, type ProcedureSummaryInfo, type Review, type ReviewAddedEmailData, type ReviewRequestEmailData, ReviewsAggregationService, type TimeInterval, UserProfileAdminService, UserRole, freeConsultationInfrastructure };
|
|
3614
|
+
export { type Appointment, AppointmentAggregationService, type AppointmentCancellationEmailData, type AppointmentConfirmationEmailData, type AppointmentEmailDataBase, AppointmentMailingService, type AppointmentReminderNotification, type AppointmentRequestedEmailData, type AppointmentRescheduledProposalEmailData, AppointmentStatus, type AvailableSlot, BaseMailingService, type BaseNotification, type BillingInfo, type BillingTransaction, BillingTransactionType, BookingAdmin, BookingAvailabilityCalculator, type BookingAvailabilityRequest, type BookingAvailabilityResponse, CalendarAdminService, type Clinic, type ClinicAdminNotificationData, ClinicAggregationService, type ClinicInfo, type ClinicLocation, type CreateBillingTransactionData, type DoctorInfo, DocumentManagerAdminService, type ExistingPractitionerInviteEmailData, ExistingPractitionerInviteMailingService, type FilledDocument, FilledFormsAggregationService, type InitializeAppointmentFormsResult, Logger, NOTIFICATIONS_COLLECTION, type NewMailgunClient$2 as NewMailgunClient, type Notification, NotificationStatus, NotificationType, NotificationsAdmin, type OrchestrateAppointmentCreationData, PATIENTS_COLLECTION, PATIENT_REQUIREMENTS_SUBCOLLECTION_NAME, PATIENT_SENSITIVE_INFO_COLLECTION, type PatientProfile as Patient, PatientAggregationService, PatientInstructionStatus, type PatientProfile, type PatientRequirementInstance, type PatientRequirementInstruction, PatientRequirementOverallStatus, PatientRequirementsAdminService, type PatientSensitiveInfo, type PlanDetails, type PostRequirementNotification, type Practitioner, PractitionerAggregationService, type PractitionerInvite, PractitionerInviteAggregationService, type PractitionerInviteEmailData, PractitionerInviteMailingService, PractitionerInviteStatus, type PractitionerToken, PractitionerTokenStatus, type PreRequirementNotification, type Procedure, ProcedureAggregationService, type ProcedureSummaryInfo, type Review, type ReviewAddedEmailData, type ReviewRequestEmailData, ReviewsAggregationService, type StripeTransactionData, SubscriptionStatus, type TimeInterval, UserProfileAdminService, UserRole, freeConsultationInfrastructure };
|
package/dist/admin/index.js
CHANGED
|
@@ -222,6 +222,7 @@ __export(index_exports, {
|
|
|
222
222
|
AppointmentMailingService: () => AppointmentMailingService,
|
|
223
223
|
AppointmentStatus: () => AppointmentStatus,
|
|
224
224
|
BaseMailingService: () => BaseMailingService,
|
|
225
|
+
BillingTransactionType: () => BillingTransactionType,
|
|
225
226
|
BookingAdmin: () => BookingAdmin,
|
|
226
227
|
BookingAvailabilityCalculator: () => BookingAvailabilityCalculator,
|
|
227
228
|
CalendarAdminService: () => CalendarAdminService,
|
|
@@ -248,6 +249,7 @@ __export(index_exports, {
|
|
|
248
249
|
PractitionerTokenStatus: () => PractitionerTokenStatus,
|
|
249
250
|
ProcedureAggregationService: () => ProcedureAggregationService,
|
|
250
251
|
ReviewsAggregationService: () => ReviewsAggregationService,
|
|
252
|
+
SubscriptionStatus: () => SubscriptionStatus,
|
|
251
253
|
UserProfileAdminService: () => UserProfileAdminService,
|
|
252
254
|
UserRole: () => UserRole,
|
|
253
255
|
freeConsultationInfrastructure: () => freeConsultationInfrastructure
|
|
@@ -442,6 +444,39 @@ var PATIENT_MEDICAL_INFO_COLLECTION = "medical_info";
|
|
|
442
444
|
var PATIENTS_COLLECTION = "patients";
|
|
443
445
|
var PATIENT_SENSITIVE_INFO_COLLECTION = "sensitive-info";
|
|
444
446
|
|
|
447
|
+
// src/types/clinic/practitioner-invite.types.ts
|
|
448
|
+
var PractitionerInviteStatus = /* @__PURE__ */ ((PractitionerInviteStatus2) => {
|
|
449
|
+
PractitionerInviteStatus2["PENDING"] = "pending";
|
|
450
|
+
PractitionerInviteStatus2["ACCEPTED"] = "accepted";
|
|
451
|
+
PractitionerInviteStatus2["REJECTED"] = "rejected";
|
|
452
|
+
PractitionerInviteStatus2["CANCELLED"] = "cancelled";
|
|
453
|
+
return PractitionerInviteStatus2;
|
|
454
|
+
})(PractitionerInviteStatus || {});
|
|
455
|
+
|
|
456
|
+
// src/types/clinic/index.ts
|
|
457
|
+
var CLINIC_GROUPS_COLLECTION = "clinic_groups";
|
|
458
|
+
var CLINIC_ADMINS_COLLECTION = "clinic_admins";
|
|
459
|
+
var CLINICS_COLLECTION = "clinics";
|
|
460
|
+
var SubscriptionStatus = /* @__PURE__ */ ((SubscriptionStatus2) => {
|
|
461
|
+
SubscriptionStatus2["PENDING"] = "pending";
|
|
462
|
+
SubscriptionStatus2["ACTIVE"] = "active";
|
|
463
|
+
SubscriptionStatus2["PENDING_CANCELLATION"] = "pending_cancellation";
|
|
464
|
+
SubscriptionStatus2["CANCELED"] = "canceled";
|
|
465
|
+
SubscriptionStatus2["PAST_DUE"] = "past_due";
|
|
466
|
+
SubscriptionStatus2["TRIALING"] = "trialing";
|
|
467
|
+
return SubscriptionStatus2;
|
|
468
|
+
})(SubscriptionStatus || {});
|
|
469
|
+
var BillingTransactionType = /* @__PURE__ */ ((BillingTransactionType2) => {
|
|
470
|
+
BillingTransactionType2["SUBSCRIPTION_CREATED"] = "subscription_created";
|
|
471
|
+
BillingTransactionType2["SUBSCRIPTION_ACTIVATED"] = "subscription_activated";
|
|
472
|
+
BillingTransactionType2["SUBSCRIPTION_RENEWED"] = "subscription_renewed";
|
|
473
|
+
BillingTransactionType2["SUBSCRIPTION_UPDATED"] = "subscription_updated";
|
|
474
|
+
BillingTransactionType2["SUBSCRIPTION_CANCELED"] = "subscription_canceled";
|
|
475
|
+
BillingTransactionType2["SUBSCRIPTION_REACTIVATED"] = "subscription_reactivated";
|
|
476
|
+
BillingTransactionType2["SUBSCRIPTION_DELETED"] = "subscription_deleted";
|
|
477
|
+
return BillingTransactionType2;
|
|
478
|
+
})(BillingTransactionType || {});
|
|
479
|
+
|
|
445
480
|
// src/types/notifications/index.ts
|
|
446
481
|
var NotificationType = /* @__PURE__ */ ((NotificationType2) => {
|
|
447
482
|
NotificationType2["APPOINTMENT_REMINDER"] = "appointmentReminder";
|
|
@@ -493,15 +528,6 @@ var PractitionerTokenStatus = /* @__PURE__ */ ((PractitionerTokenStatus2) => {
|
|
|
493
528
|
return PractitionerTokenStatus2;
|
|
494
529
|
})(PractitionerTokenStatus || {});
|
|
495
530
|
|
|
496
|
-
// src/types/clinic/practitioner-invite.types.ts
|
|
497
|
-
var PractitionerInviteStatus = /* @__PURE__ */ ((PractitionerInviteStatus2) => {
|
|
498
|
-
PractitionerInviteStatus2["PENDING"] = "pending";
|
|
499
|
-
PractitionerInviteStatus2["ACCEPTED"] = "accepted";
|
|
500
|
-
PractitionerInviteStatus2["REJECTED"] = "rejected";
|
|
501
|
-
PractitionerInviteStatus2["CANCELLED"] = "cancelled";
|
|
502
|
-
return PractitionerInviteStatus2;
|
|
503
|
-
})(PractitionerInviteStatus || {});
|
|
504
|
-
|
|
505
531
|
// src/types/appointment/index.ts
|
|
506
532
|
var AppointmentStatus = /* @__PURE__ */ ((AppointmentStatus2) => {
|
|
507
533
|
AppointmentStatus2["PENDING"] = "pending";
|
|
@@ -543,11 +569,6 @@ var PATIENT_REQUIREMENTS_SUBCOLLECTION_NAME = "patientRequirements";
|
|
|
543
569
|
// src/admin/aggregation/appointment/appointment.aggregation.service.ts
|
|
544
570
|
var admin6 = __toESM(require("firebase-admin"));
|
|
545
571
|
|
|
546
|
-
// src/types/clinic/index.ts
|
|
547
|
-
var CLINIC_GROUPS_COLLECTION = "clinic_groups";
|
|
548
|
-
var CLINIC_ADMINS_COLLECTION = "clinic_admins";
|
|
549
|
-
var CLINICS_COLLECTION = "clinics";
|
|
550
|
-
|
|
551
572
|
// src/admin/requirements/patient-requirements.admin.service.ts
|
|
552
573
|
var admin3 = __toESM(require("firebase-admin"));
|
|
553
574
|
|
|
@@ -9075,6 +9096,7 @@ TimestampUtils.enableServerMode();
|
|
|
9075
9096
|
AppointmentMailingService,
|
|
9076
9097
|
AppointmentStatus,
|
|
9077
9098
|
BaseMailingService,
|
|
9099
|
+
BillingTransactionType,
|
|
9078
9100
|
BookingAdmin,
|
|
9079
9101
|
BookingAvailabilityCalculator,
|
|
9080
9102
|
CalendarAdminService,
|
|
@@ -9101,6 +9123,7 @@ TimestampUtils.enableServerMode();
|
|
|
9101
9123
|
PractitionerTokenStatus,
|
|
9102
9124
|
ProcedureAggregationService,
|
|
9103
9125
|
ReviewsAggregationService,
|
|
9126
|
+
SubscriptionStatus,
|
|
9104
9127
|
UserProfileAdminService,
|
|
9105
9128
|
UserRole,
|
|
9106
9129
|
freeConsultationInfrastructure
|
package/dist/admin/index.mjs
CHANGED
|
@@ -382,6 +382,39 @@ var PATIENT_MEDICAL_INFO_COLLECTION = "medical_info";
|
|
|
382
382
|
var PATIENTS_COLLECTION = "patients";
|
|
383
383
|
var PATIENT_SENSITIVE_INFO_COLLECTION = "sensitive-info";
|
|
384
384
|
|
|
385
|
+
// src/types/clinic/practitioner-invite.types.ts
|
|
386
|
+
var PractitionerInviteStatus = /* @__PURE__ */ ((PractitionerInviteStatus2) => {
|
|
387
|
+
PractitionerInviteStatus2["PENDING"] = "pending";
|
|
388
|
+
PractitionerInviteStatus2["ACCEPTED"] = "accepted";
|
|
389
|
+
PractitionerInviteStatus2["REJECTED"] = "rejected";
|
|
390
|
+
PractitionerInviteStatus2["CANCELLED"] = "cancelled";
|
|
391
|
+
return PractitionerInviteStatus2;
|
|
392
|
+
})(PractitionerInviteStatus || {});
|
|
393
|
+
|
|
394
|
+
// src/types/clinic/index.ts
|
|
395
|
+
var CLINIC_GROUPS_COLLECTION = "clinic_groups";
|
|
396
|
+
var CLINIC_ADMINS_COLLECTION = "clinic_admins";
|
|
397
|
+
var CLINICS_COLLECTION = "clinics";
|
|
398
|
+
var SubscriptionStatus = /* @__PURE__ */ ((SubscriptionStatus2) => {
|
|
399
|
+
SubscriptionStatus2["PENDING"] = "pending";
|
|
400
|
+
SubscriptionStatus2["ACTIVE"] = "active";
|
|
401
|
+
SubscriptionStatus2["PENDING_CANCELLATION"] = "pending_cancellation";
|
|
402
|
+
SubscriptionStatus2["CANCELED"] = "canceled";
|
|
403
|
+
SubscriptionStatus2["PAST_DUE"] = "past_due";
|
|
404
|
+
SubscriptionStatus2["TRIALING"] = "trialing";
|
|
405
|
+
return SubscriptionStatus2;
|
|
406
|
+
})(SubscriptionStatus || {});
|
|
407
|
+
var BillingTransactionType = /* @__PURE__ */ ((BillingTransactionType2) => {
|
|
408
|
+
BillingTransactionType2["SUBSCRIPTION_CREATED"] = "subscription_created";
|
|
409
|
+
BillingTransactionType2["SUBSCRIPTION_ACTIVATED"] = "subscription_activated";
|
|
410
|
+
BillingTransactionType2["SUBSCRIPTION_RENEWED"] = "subscription_renewed";
|
|
411
|
+
BillingTransactionType2["SUBSCRIPTION_UPDATED"] = "subscription_updated";
|
|
412
|
+
BillingTransactionType2["SUBSCRIPTION_CANCELED"] = "subscription_canceled";
|
|
413
|
+
BillingTransactionType2["SUBSCRIPTION_REACTIVATED"] = "subscription_reactivated";
|
|
414
|
+
BillingTransactionType2["SUBSCRIPTION_DELETED"] = "subscription_deleted";
|
|
415
|
+
return BillingTransactionType2;
|
|
416
|
+
})(BillingTransactionType || {});
|
|
417
|
+
|
|
385
418
|
// src/types/notifications/index.ts
|
|
386
419
|
var NotificationType = /* @__PURE__ */ ((NotificationType2) => {
|
|
387
420
|
NotificationType2["APPOINTMENT_REMINDER"] = "appointmentReminder";
|
|
@@ -433,15 +466,6 @@ var PractitionerTokenStatus = /* @__PURE__ */ ((PractitionerTokenStatus2) => {
|
|
|
433
466
|
return PractitionerTokenStatus2;
|
|
434
467
|
})(PractitionerTokenStatus || {});
|
|
435
468
|
|
|
436
|
-
// src/types/clinic/practitioner-invite.types.ts
|
|
437
|
-
var PractitionerInviteStatus = /* @__PURE__ */ ((PractitionerInviteStatus2) => {
|
|
438
|
-
PractitionerInviteStatus2["PENDING"] = "pending";
|
|
439
|
-
PractitionerInviteStatus2["ACCEPTED"] = "accepted";
|
|
440
|
-
PractitionerInviteStatus2["REJECTED"] = "rejected";
|
|
441
|
-
PractitionerInviteStatus2["CANCELLED"] = "cancelled";
|
|
442
|
-
return PractitionerInviteStatus2;
|
|
443
|
-
})(PractitionerInviteStatus || {});
|
|
444
|
-
|
|
445
469
|
// src/types/appointment/index.ts
|
|
446
470
|
var AppointmentStatus = /* @__PURE__ */ ((AppointmentStatus2) => {
|
|
447
471
|
AppointmentStatus2["PENDING"] = "pending";
|
|
@@ -483,11 +507,6 @@ var PATIENT_REQUIREMENTS_SUBCOLLECTION_NAME = "patientRequirements";
|
|
|
483
507
|
// src/admin/aggregation/appointment/appointment.aggregation.service.ts
|
|
484
508
|
import * as admin6 from "firebase-admin";
|
|
485
509
|
|
|
486
|
-
// src/types/clinic/index.ts
|
|
487
|
-
var CLINIC_GROUPS_COLLECTION = "clinic_groups";
|
|
488
|
-
var CLINIC_ADMINS_COLLECTION = "clinic_admins";
|
|
489
|
-
var CLINICS_COLLECTION = "clinics";
|
|
490
|
-
|
|
491
510
|
// src/admin/requirements/patient-requirements.admin.service.ts
|
|
492
511
|
import * as admin3 from "firebase-admin";
|
|
493
512
|
|
|
@@ -9014,6 +9033,7 @@ export {
|
|
|
9014
9033
|
AppointmentMailingService,
|
|
9015
9034
|
AppointmentStatus,
|
|
9016
9035
|
BaseMailingService,
|
|
9036
|
+
BillingTransactionType,
|
|
9017
9037
|
BookingAdmin,
|
|
9018
9038
|
BookingAvailabilityCalculator,
|
|
9019
9039
|
CalendarAdminService,
|
|
@@ -9040,6 +9060,7 @@ export {
|
|
|
9040
9060
|
PractitionerTokenStatus,
|
|
9041
9061
|
ProcedureAggregationService,
|
|
9042
9062
|
ReviewsAggregationService,
|
|
9063
|
+
SubscriptionStatus,
|
|
9043
9064
|
UserProfileAdminService,
|
|
9044
9065
|
UserRole,
|
|
9045
9066
|
freeConsultationInfrastructure
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@blackcode_sa/metaestetics-api",
|
|
3
3
|
"private": false,
|
|
4
|
-
"version": "1.12.
|
|
4
|
+
"version": "1.12.6",
|
|
5
5
|
"description": "Firebase authentication service with anonymous upgrade support",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"module": "dist/index.mjs",
|
|
@@ -95,6 +95,7 @@
|
|
|
95
95
|
"typescript": "^5.7.3"
|
|
96
96
|
},
|
|
97
97
|
"dependencies": {
|
|
98
|
+
"@blackcode_sa/metaestetics-api": "^1.12.5",
|
|
98
99
|
"axios": "^1.8.3",
|
|
99
100
|
"expo-server-sdk": "^3.13.0",
|
|
100
101
|
"firebase-admin": "^13.0.2",
|
package/src/admin/index.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { TimestampUtils } from
|
|
1
|
+
import { TimestampUtils } from '../utils/';
|
|
2
2
|
|
|
3
3
|
// Re-export types needed by Cloud Functions consuming this module
|
|
4
4
|
export type {
|
|
@@ -7,62 +7,69 @@ export type {
|
|
|
7
7
|
PreRequirementNotification,
|
|
8
8
|
PostRequirementNotification,
|
|
9
9
|
AppointmentReminderNotification,
|
|
10
|
-
} from
|
|
11
|
-
export type { PatientProfile, PatientSensitiveInfo } from
|
|
12
|
-
export {
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
} from
|
|
16
|
-
export type {
|
|
17
|
-
export type {
|
|
18
|
-
export type {
|
|
19
|
-
export type {
|
|
20
|
-
export type {
|
|
21
|
-
export type {
|
|
22
|
-
export type {
|
|
23
|
-
|
|
24
|
-
export
|
|
25
|
-
export type {
|
|
10
|
+
} from '../types/notifications';
|
|
11
|
+
export type { PatientProfile, PatientSensitiveInfo } from '../types/patient';
|
|
12
|
+
export { PATIENTS_COLLECTION, PATIENT_SENSITIVE_INFO_COLLECTION } from '../types/patient';
|
|
13
|
+
export type { Clinic, ClinicLocation } from '../types/clinic';
|
|
14
|
+
export type { ClinicInfo } from '../types/profile';
|
|
15
|
+
export type { Practitioner, PractitionerToken } from '../types/practitioner';
|
|
16
|
+
export type { PractitionerInvite } from '../types/clinic/practitioner-invite.types';
|
|
17
|
+
export type { DoctorInfo } from '../types/clinic';
|
|
18
|
+
export type { Procedure, ProcedureSummaryInfo } from '../types/procedure';
|
|
19
|
+
export type { PatientProfile as Patient } from '../types/patient';
|
|
20
|
+
export type { Appointment } from '../types/appointment';
|
|
21
|
+
export type { FilledDocument } from '../types/documentation-templates';
|
|
22
|
+
export type { Review } from '../types/reviews';
|
|
23
|
+
|
|
24
|
+
// Re-export billing types for Stripe integration
|
|
25
|
+
export type {
|
|
26
|
+
BillingInfo,
|
|
27
|
+
BillingTransaction,
|
|
28
|
+
CreateBillingTransactionData,
|
|
29
|
+
StripeTransactionData,
|
|
30
|
+
PlanDetails,
|
|
31
|
+
} from '../types/clinic';
|
|
32
|
+
export { BillingTransactionType, SubscriptionStatus } from '../types/clinic';
|
|
26
33
|
|
|
27
34
|
// Re-export enums/consts
|
|
28
35
|
export {
|
|
29
36
|
NotificationType,
|
|
30
37
|
NotificationStatus,
|
|
31
38
|
NOTIFICATIONS_COLLECTION,
|
|
32
|
-
} from
|
|
33
|
-
export { UserRole } from
|
|
34
|
-
export { PractitionerTokenStatus } from
|
|
35
|
-
export { PractitionerInviteStatus } from
|
|
36
|
-
export { AppointmentStatus } from
|
|
39
|
+
} from '../types/notifications';
|
|
40
|
+
export { UserRole } from '../types/user';
|
|
41
|
+
export { PractitionerTokenStatus } from '../types/practitioner';
|
|
42
|
+
export { PractitionerInviteStatus } from '../types/clinic/practitioner-invite.types';
|
|
43
|
+
export { AppointmentStatus } from '../types/appointment';
|
|
37
44
|
|
|
38
45
|
// Export mailing service interfaces
|
|
39
46
|
export type {
|
|
40
47
|
ExistingPractitionerInviteEmailData,
|
|
41
48
|
ClinicAdminNotificationData,
|
|
42
|
-
} from
|
|
49
|
+
} from './mailing/practitionerInvite/';
|
|
43
50
|
|
|
44
51
|
// Re-export types needed by admin services
|
|
45
|
-
export type * from
|
|
46
|
-
export * from
|
|
52
|
+
export type * from '../types/patient/patient-requirements';
|
|
53
|
+
export * from '../types/patient/patient-requirements';
|
|
47
54
|
|
|
48
55
|
/**
|
|
49
56
|
* Main entry point for the Admin module.
|
|
50
57
|
* This module contains services and utilities intended for administrative tasks,
|
|
51
58
|
* background processing, and direct use by Cloud Functions.
|
|
52
59
|
*/
|
|
53
|
-
console.log(
|
|
60
|
+
console.log('[Admin Module] Initialized and services exported.');
|
|
54
61
|
|
|
55
62
|
// Initialize TimestampUtils for server-side use
|
|
56
63
|
TimestampUtils.enableServerMode();
|
|
57
64
|
|
|
58
65
|
// Export all services and utilities from the admin sub-modules.
|
|
59
|
-
export * from
|
|
60
|
-
export * from
|
|
61
|
-
export * from
|
|
62
|
-
export * from
|
|
63
|
-
export * from
|
|
64
|
-
export * from
|
|
65
|
-
export * from
|
|
66
|
-
export * from
|
|
67
|
-
export * from
|
|
68
|
-
export * from
|
|
66
|
+
export * from './aggregation';
|
|
67
|
+
export * from './booking';
|
|
68
|
+
export * from './calendar';
|
|
69
|
+
export * from './documentation-templates';
|
|
70
|
+
export * from './free-consultation';
|
|
71
|
+
export * from './logger';
|
|
72
|
+
export * from './mailing';
|
|
73
|
+
export * from './notifications';
|
|
74
|
+
export * from './requirements';
|
|
75
|
+
export * from './users';
|