@eeplatform/core 1.5.1 → 1.6.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @eeplatform/core
2
2
 
3
+ ## 1.6.0
4
+
5
+ ### Minor Changes
6
+
7
+ - 9eb974a: Grade Level - add track and track strands
8
+
9
+ ## 1.5.2
10
+
11
+ ### Patch Changes
12
+
13
+ - a4149a6: Grade Level - use schemaGradeLevel in controller
14
+
3
15
  ## 1.5.1
4
16
 
5
17
  ### Patch Changes
@@ -0,0 +1,145 @@
1
+ #!/usr/bin/env node
2
+
3
+ /**
4
+ * Simple demonstration script for Gemini AI Audio Transcription
5
+ *
6
+ * Usage:
7
+ * node demo-transcription.js /path/to/audio/file.wav
8
+ *
9
+ * Or with options:
10
+ * LANGUAGE=English ENABLE_TIMESTAMPS=true node demo-transcription.js /path/to/audio/file.mp3
11
+ */
12
+
13
+ const { useGeminiAiService } = require("../dist/index.js");
14
+ const path = require("path");
15
+
16
+ async function demonstrateTranscription() {
17
+ // Get command line arguments
18
+ const audioFilePath = process.argv[2];
19
+
20
+ if (!audioFilePath) {
21
+ console.error("Please provide an audio file path");
22
+ console.error("Usage: node demo-transcription.js /path/to/audio/file.wav");
23
+ process.exit(1);
24
+ }
25
+
26
+ // Initialize the service
27
+ const geminiService = useGeminiAiService();
28
+
29
+ try {
30
+ console.log("🎵 Gemini AI Audio Transcription Demo");
31
+ console.log("=====================================\n");
32
+
33
+ // Check if file exists and format is supported
34
+ const fs = require("fs");
35
+ if (!fs.existsSync(audioFilePath)) {
36
+ throw new Error("Audio file not found: " + audioFilePath);
37
+ }
38
+
39
+ const extension = path.extname(audioFilePath).toLowerCase();
40
+ const mimeTypeMap = {
41
+ ".wav": "audio/wav",
42
+ ".mp3": "audio/mp3",
43
+ ".aiff": "audio/aiff",
44
+ ".aac": "audio/aac",
45
+ ".ogg": "audio/ogg",
46
+ ".flac": "audio/flac",
47
+ };
48
+
49
+ const mimeType = mimeTypeMap[extension];
50
+ if (!mimeType || !geminiService.validateAudioFormat(mimeType)) {
51
+ console.error("❌ Unsupported audio format:", extension);
52
+ console.log(
53
+ "Supported formats:",
54
+ geminiService.getSupportedAudioFormats()
55
+ );
56
+ process.exit(1);
57
+ }
58
+
59
+ console.log("📁 File:", path.basename(audioFilePath));
60
+ console.log("🎵 Format:", mimeType);
61
+ console.log(
62
+ "✅ Format supported:",
63
+ geminiService.validateAudioFormat(mimeType)
64
+ );
65
+ console.log("");
66
+
67
+ // Prepare options from environment variables
68
+ const options = {
69
+ language: process.env.LANGUAGE || undefined,
70
+ enableTimestamps: process.env.ENABLE_TIMESTAMPS === "true",
71
+ prompt: process.env.CUSTOM_PROMPT || undefined,
72
+ };
73
+
74
+ console.log("⚙️ Options:");
75
+ console.log(" Language:", options.language || "Auto-detect");
76
+ console.log(
77
+ " Timestamps:",
78
+ options.enableTimestamps ? "Enabled" : "Disabled"
79
+ );
80
+ console.log(" Custom prompt:", options.prompt || "None");
81
+ console.log("");
82
+
83
+ // Start transcription
84
+ console.log("🔄 Starting transcription...");
85
+ const startTime = Date.now();
86
+
87
+ const result = await geminiService.transcribeAudioFromFile(
88
+ audioFilePath,
89
+ options
90
+ );
91
+
92
+ const endTime = Date.now();
93
+ const duration = ((endTime - startTime) / 1000).toFixed(2);
94
+
95
+ // Display results
96
+ console.log("");
97
+ console.log("✅ Transcription completed in", duration, "seconds");
98
+ console.log("");
99
+ console.log("📝 TRANSCRIPTION:");
100
+ console.log("==================");
101
+ console.log(result.transcription);
102
+ console.log("");
103
+
104
+ if (result.language) {
105
+ console.log("🌐 Language:", result.language);
106
+ }
107
+
108
+ if (result.timestamps && result.timestamps.length > 0) {
109
+ console.log("⏰ Timestamps:");
110
+ result.timestamps.forEach((timestamp, index) => {
111
+ console.log(
112
+ ` ${index + 1}. [${timestamp.start}s - ${timestamp.end}s] ${
113
+ timestamp.text
114
+ }`
115
+ );
116
+ });
117
+ console.log("");
118
+ }
119
+
120
+ console.log("🎉 Demo completed successfully!");
121
+ } catch (error) {
122
+ console.error("");
123
+ console.error("❌ Transcription failed:");
124
+ console.error(" Error:", error.message);
125
+ console.error("");
126
+
127
+ if (error.message.includes("API key")) {
128
+ console.error(
129
+ "💡 Make sure your GEMINI_API_KEY environment variable is set"
130
+ );
131
+ } else if (error.message.includes("audio format")) {
132
+ console.error(
133
+ "💡 Supported formats:",
134
+ geminiService.getSupportedAudioFormats().join(", ")
135
+ );
136
+ } else if (error.message.includes("Failed to read")) {
137
+ console.error("💡 Check that the file path is correct and accessible");
138
+ }
139
+
140
+ process.exit(1);
141
+ }
142
+ }
143
+
144
+ // Run the demonstration
145
+ demonstrateTranscription();
package/dist/index.d.ts CHANGED
@@ -2683,6 +2683,70 @@ declare function useGitHubService(): {
2683
2683
  }) => Promise<string>;
2684
2684
  };
2685
2685
 
2686
+ interface AudioTranscriptionOptions {
2687
+ prompt?: string;
2688
+ language?: string;
2689
+ enableTimestamps?: boolean;
2690
+ maxTokens?: number;
2691
+ }
2692
+ interface AudioTranscriptionResult {
2693
+ transcription: string;
2694
+ confidence?: number;
2695
+ language?: string;
2696
+ duration?: number;
2697
+ timestamps?: Array<{
2698
+ start: number;
2699
+ end: number;
2700
+ text: string;
2701
+ }>;
2702
+ }
2703
+ interface AudioFileData {
2704
+ data: Buffer;
2705
+ mimeType: string;
2706
+ }
2707
+ interface PhonemeMatchOptions {
2708
+ language?: string;
2709
+ caseSensitive?: boolean;
2710
+ partialMatch?: boolean;
2711
+ }
2712
+ interface PhonemeMatchResult {
2713
+ transcription: string;
2714
+ targetPhoneme: string;
2715
+ isMatch: boolean;
2716
+ confidence?: number;
2717
+ detectedPhonemes?: string[];
2718
+ matchDetails?: {
2719
+ exactMatch: boolean;
2720
+ partialMatch: boolean;
2721
+ position?: number;
2722
+ context?: string;
2723
+ };
2724
+ }
2725
+ declare function useGeminiAiService(): {
2726
+ transcribeAudio: (audioData: AudioFileData, options?: AudioTranscriptionOptions) => Promise<AudioTranscriptionResult>;
2727
+ transcribeAudioFromFile: (filePath: string, options?: AudioTranscriptionOptions) => Promise<AudioTranscriptionResult>;
2728
+ transcribeAudioFromBuffer: (audioBuffer: Buffer, mimeType: string, options?: AudioTranscriptionOptions) => Promise<AudioTranscriptionResult>;
2729
+ getSupportedAudioFormats: () => string[];
2730
+ validateAudioFormat: (mimeType: string) => boolean;
2731
+ generateContent: (prompt: string, options?: {
2732
+ maxTokens?: number;
2733
+ }) => Promise<string>;
2734
+ checkPhonemeMatch: (audioData: AudioFileData, targetPhoneme: string, options?: PhonemeMatchOptions) => Promise<PhonemeMatchResult>;
2735
+ checkPhonemeMatchFromFile: (filePath: string, targetPhoneme: string, options?: PhonemeMatchOptions) => Promise<PhonemeMatchResult>;
2736
+ checkPhonemeMatchFromBuffer: (audioBuffer: Buffer, mimeType: string, targetPhoneme: string, options?: PhonemeMatchOptions) => Promise<PhonemeMatchResult>;
2737
+ };
2738
+
2739
+ declare function useAudioTranscriptionController(): {
2740
+ transcribeFromFile: (req: Request, res: Response, next: NextFunction) => Promise<void>;
2741
+ transcribeFromBase64: (req: Request, res: Response, next: NextFunction) => Promise<void>;
2742
+ getSupportedFormats: (req: Request, res: Response, next: NextFunction) => Promise<void>;
2743
+ validateFormat: (req: Request, res: Response, next: NextFunction) => Promise<void>;
2744
+ healthCheck: (req: Request, res: Response, next: NextFunction) => Promise<void>;
2745
+ checkPhonemeFromFile: (req: Request, res: Response, next: NextFunction) => Promise<void>;
2746
+ checkPhonemeFromBase64: (req: Request, res: Response, next: NextFunction) => Promise<void>;
2747
+ batchPhonemeCheck: (req: Request, res: Response, next: NextFunction) => Promise<void>;
2748
+ };
2749
+
2686
2750
  declare function useUtilController(): {
2687
2751
  healthCheck: (req: Request, res: Response, next: NextFunction) => Promise<void>;
2688
2752
  setGitHubVariables: (req: Request, res: Response, next: NextFunction) => Promise<void>;
@@ -2867,7 +2931,10 @@ type TGradeLevel = {
2867
2931
  school?: ObjectId | string;
2868
2932
  educationLevel: string;
2869
2933
  gradeLevel: string;
2934
+ tracks?: string[];
2935
+ trackStrands?: string[];
2870
2936
  teachingStyle: string;
2937
+ maxNumberOfLearners: number;
2871
2938
  defaultStartTime?: string;
2872
2939
  defaultEndTime?: string;
2873
2940
  status?: string;
@@ -2884,7 +2951,10 @@ declare function MGradeLevel(value: TGradeLevel): {
2884
2951
  school: string | ObjectId | undefined;
2885
2952
  educationLevel: string;
2886
2953
  gradeLevel: string;
2954
+ tracks: string[];
2955
+ trackStrands: string[];
2887
2956
  teachingStyle: string;
2957
+ maxNumberOfLearners: number;
2888
2958
  defaultStartTime: string;
2889
2959
  defaultEndTime: string;
2890
2960
  status: string;
@@ -2934,6 +3004,327 @@ declare function useGradeLevelController(): {
2934
3004
  getByEducationLevel: (req: Request, res: Response, next: NextFunction) => Promise<void>;
2935
3005
  };
2936
3006
 
3007
+ type BasicEducEnrForm = {
3008
+ _id?: ObjectId;
3009
+ region: ObjectId;
3010
+ sdo: ObjectId;
3011
+ school: ObjectId;
3012
+ schoolYear: string;
3013
+ gradeLevelToEnroll: string;
3014
+ learnerInfo: EnrLearnerInfo;
3015
+ parentGuardianInfo: EnrParentGuardianInfo;
3016
+ addressInfo: AddressInformation;
3017
+ returningLearnerInfo?: EnrReturningLearnerInfo;
3018
+ seniorHighInfo?: EnrSeniorHighInformation;
3019
+ preferredLearningModalities?: EnrLearningModality[];
3020
+ certification: EnrCert;
3021
+ status?: string;
3022
+ rejectionReason?: string;
3023
+ createdAt?: Date | string;
3024
+ updatedAt?: Date | string;
3025
+ deletedAt?: Date | string;
3026
+ createdBy?: string;
3027
+ updatedBy?: string;
3028
+ deletedBy?: string;
3029
+ };
3030
+ type EnrLearnerInfo = {
3031
+ lrn?: string;
3032
+ lastName: string;
3033
+ firstName: string;
3034
+ middleName?: string;
3035
+ extensionName?: string;
3036
+ birthDate: string;
3037
+ sex: "Male" | "Female";
3038
+ age: number;
3039
+ placeOfBirth?: {
3040
+ municipalityCity: string;
3041
+ province?: string;
3042
+ country?: string;
3043
+ };
3044
+ motherTongue?: string;
3045
+ hasDisability: boolean;
3046
+ disabilityTypes?: DisabilityType[];
3047
+ otherDisabilityDetails?: string;
3048
+ isIndigenous?: boolean;
3049
+ indigenousCommunity?: string;
3050
+ is4PsBeneficiary?: boolean;
3051
+ fourPsHouseholdId?: string;
3052
+ };
3053
+ type DisabilityType = "Visual Impairment (Blind)" | "Visual Impairment (Low Vision)" | "Hearing Impairment" | "Learning Disability" | "Intellectual Disability" | "Autism Spectrum Disorder" | "Emotional-Behavioral Disorder" | "Orthopedic/Physical Handicap" | "Speech/Language Disorder" | "Cerebral Palsy" | "Special Health Problem/Chronic Disease" | "Multiple Disorder" | "Cancer" | "Other";
3054
+ type EnrParentGuardianInfo = {
3055
+ father?: PersonContact;
3056
+ mother?: PersonContact;
3057
+ legalGuardian?: PersonContact;
3058
+ };
3059
+ type PersonContact = {
3060
+ lastName: string;
3061
+ firstName: string;
3062
+ middleName?: string;
3063
+ contactNumber?: string;
3064
+ };
3065
+ type AddressInformation = {
3066
+ currentAddress: EnrAddress;
3067
+ permanentAddress?: EnrAddress;
3068
+ sameAsCurrent?: boolean;
3069
+ };
3070
+ type EnrAddress = {
3071
+ houseNumber?: string;
3072
+ streetName?: string;
3073
+ sitio?: string;
3074
+ barangay: string;
3075
+ municipalityCity: string;
3076
+ province: string;
3077
+ country?: string;
3078
+ zipCode?: string;
3079
+ };
3080
+ type EnrReturningLearnerInfo = {
3081
+ lastGradeLevelCompleted: string;
3082
+ lastSchoolYearCompleted: string;
3083
+ lastSchoolAttended: string;
3084
+ lastSchoolId?: string;
3085
+ isReturningLearner: boolean;
3086
+ isTransferIn: boolean;
3087
+ };
3088
+ type EnrSeniorHighInformation = {
3089
+ semester: "1st" | "2nd";
3090
+ track: string;
3091
+ strand: string;
3092
+ };
3093
+ type EnrLearningModality = "Modular (Print)" | "Modular (Digital)" | "Online" | "Radio-Based Instruction" | "Educational Television" | "Blended" | "Homeschooling";
3094
+ type EnrCert = {
3095
+ certifiedBy: string;
3096
+ date: string;
3097
+ consentGiven: boolean;
3098
+ };
3099
+ declare const schemaEnrollment: Joi.ObjectSchema<any>;
3100
+ declare function MEnrollment(value: BasicEducEnrForm): {
3101
+ _id: ObjectId | undefined;
3102
+ region: ObjectId;
3103
+ sdo: ObjectId;
3104
+ school: ObjectId;
3105
+ schoolYear: string;
3106
+ gradeLevelToEnroll: string;
3107
+ learnerInfo: EnrLearnerInfo;
3108
+ parentGuardianInfo: EnrParentGuardianInfo;
3109
+ addressInfo: AddressInformation;
3110
+ returningLearnerInfo: EnrReturningLearnerInfo | undefined;
3111
+ seniorHighInfo: EnrSeniorHighInformation | undefined;
3112
+ preferredLearningModalities: EnrLearningModality[];
3113
+ certification: EnrCert;
3114
+ status: string;
3115
+ rejectionReason: string;
3116
+ createdAt: string | Date;
3117
+ updatedAt: string | Date;
3118
+ deletedAt: string | Date;
3119
+ createdBy: string;
3120
+ updatedBy: string;
3121
+ deletedBy: string;
3122
+ };
3123
+
3124
+ declare function useEnrollmentRepo(): {
3125
+ createIndexes: () => Promise<void>;
3126
+ add: (value: BasicEducEnrForm, session?: ClientSession) => Promise<ObjectId>;
3127
+ updateById: (_id: ObjectId | string, value: Partial<BasicEducEnrForm>, session?: ClientSession) => Promise<mongodb.UpdateResult<bson.Document>>;
3128
+ getAll: ({ search, page, limit, sort, status, school, schoolYear, gradeLevelToEnroll, }?: {
3129
+ search?: string | undefined;
3130
+ page?: number | undefined;
3131
+ limit?: number | undefined;
3132
+ sort?: {} | undefined;
3133
+ status?: string | undefined;
3134
+ school?: string | undefined;
3135
+ schoolYear?: string | undefined;
3136
+ gradeLevelToEnroll?: string | undefined;
3137
+ }) => Promise<Record<string, any>>;
3138
+ getById: (_id: string | ObjectId) => Promise<BasicEducEnrForm>;
3139
+ getByLrn: (lrn: string, schoolYear?: string) => Promise<BasicEducEnrForm | null>;
3140
+ deleteById: (_id: string | ObjectId, deletedBy?: string, session?: ClientSession) => Promise<mongodb.UpdateResult<bson.Document>>;
3141
+ getBySchoolAndYear: (school: string | ObjectId, schoolYear: string) => Promise<BasicEducEnrForm[]>;
3142
+ };
3143
+
3144
+ declare function useEnrollmentService(): {
3145
+ createEnrollment: (value: BasicEducEnrForm) => Promise<{
3146
+ message: string;
3147
+ id: ObjectId;
3148
+ }>;
3149
+ updateEnrollment: (_id: string | ObjectId, value: Partial<BasicEducEnrForm>) => Promise<{
3150
+ message: string;
3151
+ modifiedCount: number;
3152
+ }>;
3153
+ getEnrollments: ({ search, page, limit, sort, status, school, schoolYear, gradeLevelToEnroll, }?: {
3154
+ search?: string | undefined;
3155
+ page?: number | undefined;
3156
+ limit?: number | undefined;
3157
+ sort?: {} | undefined;
3158
+ status?: string | undefined;
3159
+ school?: string | undefined;
3160
+ schoolYear?: string | undefined;
3161
+ gradeLevelToEnroll?: string | undefined;
3162
+ }) => Promise<Record<string, any>>;
3163
+ getEnrollmentById: (_id: string | ObjectId) => Promise<BasicEducEnrForm>;
3164
+ getEnrollmentByLrn: (lrn: string, schoolYear?: string) => Promise<BasicEducEnrForm | null>;
3165
+ deleteEnrollment: (_id: string | ObjectId, deletedBy?: string) => Promise<{
3166
+ message: string;
3167
+ modifiedCount: number;
3168
+ }>;
3169
+ getEnrollmentsBySchoolAndYear: (school: string | ObjectId, schoolYear: string) => Promise<BasicEducEnrForm[]>;
3170
+ approveEnrollment: (_id: string | ObjectId, approvedBy: string) => Promise<{
3171
+ message: string;
3172
+ modifiedCount: number;
3173
+ }>;
3174
+ rejectEnrollment: (_id: string | ObjectId, rejectedBy: string, rejectionReason?: string) => Promise<{
3175
+ message: string;
3176
+ modifiedCount: number;
3177
+ }>;
3178
+ };
3179
+
3180
+ declare function useEnrollmentController(): {
3181
+ add: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3182
+ updateById: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3183
+ getAll: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3184
+ getById: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3185
+ getByLrn: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3186
+ deleteById: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3187
+ getBySchoolAndYear: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3188
+ approve: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3189
+ reject: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3190
+ getStatsBySchool: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3191
+ };
3192
+
3193
+ type TProvince = {
3194
+ _id?: ObjectId;
3195
+ name?: string;
3196
+ status?: string;
3197
+ createdAt?: string;
3198
+ updatedAt?: string;
3199
+ deletedAt?: string;
3200
+ };
3201
+ declare const schemaProvince: Joi.ObjectSchema<any>;
3202
+ declare function MProvince(value: TProvince): TProvince;
3203
+
3204
+ declare function useProvinceRepo(): {
3205
+ createIndex: () => Promise<void>;
3206
+ createTextIndex: () => Promise<void>;
3207
+ createUniqueIndex: () => Promise<void>;
3208
+ add: (value: TProvince, session?: ClientSession) => Promise<ObjectId>;
3209
+ getAll: ({ search, page, limit, sort }?: {
3210
+ search?: string | undefined;
3211
+ page?: number | undefined;
3212
+ limit?: number | undefined;
3213
+ sort?: {} | undefined;
3214
+ }) => Promise<Record<string, any>>;
3215
+ getById: (_id: string | ObjectId) => Promise<TProvince>;
3216
+ updateFieldById: ({ _id, field, value }?: {
3217
+ _id: string | ObjectId;
3218
+ field: string;
3219
+ value: string;
3220
+ }, session?: ClientSession) => Promise<string>;
3221
+ deleteById: (_id: string | ObjectId) => Promise<string>;
3222
+ getByName: (name: string) => Promise<TProvince>;
3223
+ };
3224
+
3225
+ declare function useProvinceService(): {
3226
+ add: (value: TProvince) => Promise<string>;
3227
+ };
3228
+
3229
+ declare function useProvinceController(): {
3230
+ createProvince: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3231
+ getAll: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3232
+ getById: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3233
+ getByName: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3234
+ updateField: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3235
+ deleteProvince: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3236
+ };
3237
+
3238
+ type TCityMunicipality = {
3239
+ _id?: ObjectId;
3240
+ name?: string;
3241
+ status?: string;
3242
+ createdAt?: string;
3243
+ updatedAt?: string;
3244
+ deletedAt?: string;
3245
+ };
3246
+ declare const schemaCityMunicipality: Joi.ObjectSchema<any>;
3247
+ declare function MCityMunicipality(value: TCityMunicipality): TCityMunicipality;
3248
+
3249
+ declare function useCityMunicipalityRepo(): {
3250
+ createIndex: () => Promise<void>;
3251
+ createTextIndex: () => Promise<void>;
3252
+ createUniqueIndex: () => Promise<void>;
3253
+ add: (value: TCityMunicipality, session?: ClientSession) => Promise<ObjectId>;
3254
+ getAll: ({ search, page, limit, sort }?: {
3255
+ search?: string | undefined;
3256
+ page?: number | undefined;
3257
+ limit?: number | undefined;
3258
+ sort?: {} | undefined;
3259
+ }) => Promise<Record<string, any>>;
3260
+ getById: (_id: string | ObjectId) => Promise<TCityMunicipality>;
3261
+ updateFieldById: ({ _id, field, value }?: {
3262
+ _id: string | ObjectId;
3263
+ field: string;
3264
+ value: string;
3265
+ }, session?: ClientSession) => Promise<string>;
3266
+ deleteById: (_id: string | ObjectId) => Promise<string>;
3267
+ getByName: (name: string) => Promise<TCityMunicipality>;
3268
+ };
3269
+
3270
+ declare function useCityMunicipalityService(): {
3271
+ add: (value: TCityMunicipality) => Promise<string>;
3272
+ };
3273
+
3274
+ declare function useCityMunicipalityController(): {
3275
+ createCityMunicipality: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3276
+ getAll: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3277
+ getById: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3278
+ getByName: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3279
+ updateField: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3280
+ deleteCityMunicipality: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3281
+ };
3282
+
3283
+ type TBarangay = {
3284
+ _id?: ObjectId;
3285
+ name?: string;
3286
+ status?: string;
3287
+ createdAt?: string;
3288
+ updatedAt?: string;
3289
+ deletedAt?: string;
3290
+ };
3291
+ declare const schemaBarangay: Joi.ObjectSchema<any>;
3292
+ declare function MBarangay(value: TBarangay): TBarangay;
3293
+
3294
+ declare function useBarangayRepo(): {
3295
+ createIndex: () => Promise<void>;
3296
+ createTextIndex: () => Promise<void>;
3297
+ createUniqueIndex: () => Promise<void>;
3298
+ add: (value: TBarangay, session?: ClientSession) => Promise<ObjectId>;
3299
+ getAll: ({ search, page, limit, sort }?: {
3300
+ search?: string | undefined;
3301
+ page?: number | undefined;
3302
+ limit?: number | undefined;
3303
+ sort?: {} | undefined;
3304
+ }) => Promise<Record<string, any>>;
3305
+ getById: (_id: string | ObjectId) => Promise<TBarangay>;
3306
+ updateFieldById: ({ _id, field, value }?: {
3307
+ _id: string | ObjectId;
3308
+ field: string;
3309
+ value: string;
3310
+ }, session?: ClientSession) => Promise<string>;
3311
+ deleteById: (_id: string | ObjectId) => Promise<string>;
3312
+ getByName: (name: string) => Promise<TBarangay>;
3313
+ };
3314
+
3315
+ declare function useBarangayService(): {
3316
+ add: (value: TBarangay) => Promise<string>;
3317
+ };
3318
+
3319
+ declare function useBarangayController(): {
3320
+ createBarangay: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3321
+ getAll: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3322
+ getById: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3323
+ getByName: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3324
+ updateField: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3325
+ deleteBarangay: (req: Request, res: Response, next: NextFunction) => Promise<void>;
3326
+ };
3327
+
2937
3328
  declare const MONGO_URI: string;
2938
3329
  declare const MONGO_DB: string;
2939
3330
  declare const PORT: number;
@@ -2969,5 +3360,7 @@ declare const PAYPAL_CLIENT_SECRET: string;
2969
3360
  declare const PAYPAL_API_URL: string;
2970
3361
  declare const XENDIT_SECRET_KEY: string;
2971
3362
  declare const XENDIT_BASE_URL: string;
3363
+ declare const GEMINI_API_KEY: string;
3364
+ declare const ASSEMBLY_AI_API_KEY: string;
2972
3365
 
2973
- export { ACCESS_TOKEN_EXPIRY, ACCESS_TOKEN_SECRET, APP_ACCOUNT, APP_MAIN, CardPayment, CardPaymentSchema, DEFAULT_USER_EMAIL, DEFAULT_USER_FIRST_NAME, DEFAULT_USER_LAST_NAME, DEFAULT_USER_PASSWORD, DirectDebit, DirectDebitSchema, EWalletPayment, EWalletPaymentSchema, MAILER_EMAIL, MAILER_PASSWORD, MAILER_TRANSPORT_HOST, MAILER_TRANSPORT_PORT, MAILER_TRANSPORT_SECURE, MAddress, MAsset, MBuilding, MBuildingUnit, MCurriculum, MDivision, MEntity, MFile, MGradeLevel, MMember, MONGO_DB, MONGO_URI, MOffice, MOrder, MOrg, MPaymentMethod, MPlantilla, MPromoCode, MRegion, MRole, MSchool, MStockCard, MSubscription, MToken, MUser, MUserRole, MVerification, PAYPAL_API_URL, PAYPAL_CLIENT_ID, PAYPAL_CLIENT_SECRET, PORT, REDIS_HOST, REDIS_PASSWORD, REDIS_PORT, REFRESH_TOKEN_EXPIRY, REFRESH_TOKEN_SECRET, SECRET_KEY, SPACES_ACCESS_KEY, SPACES_BUCKET, SPACES_ENDPOINT, SPACES_REGION, SPACES_SECRET_KEY, TAddress, TAsset, TBillingRecipient, TBuilding, TBuildingUnit, TCounter, TCurriculum, TCurriculumSubject, TDivision, TEntity, TFile, TGradeLevel, TInvoice, TMember, TMiniRole, TOffice, TOrder, TOrderMetadata, TOrg, TPayment, TPaymentMethod$1 as TPaymentMethod, TPaymentMethodType, TPlantilla, TPrice, TPriceType, TPromoCode, TPromoTier, TRegion, TRole, TSchool, TStockCard, TSubscription, TToken, TUser, TUserRole, TVerification, TVerificationMetadata, VERIFICATION_FORGET_PASSWORD_DURATION, VERIFICATION_USER_INVITE_DURATION, XENDIT_BASE_URL, XENDIT_SECRET_KEY, addressSchema, isDev, schema, schemaAsset, schemaAssetUpdateOption, schemaBuilding, schemaBuildingUnit, schemaCurriculum, schemaDivision, schemaGradeLevel, schemaOffice, schemaPlantilla, schemaRegion, schemaSchool, schemaStockCard, schemaUpdateOptions, useAddressController, useAddressRepo, useAssetController, useAssetRepo, useAuthController, useAuthService, useBuildingController, useBuildingRepo, useBuildingUnitController, useBuildingUnitRepo, useCounterModel, useCounterRepo, useCurriculumController, useCurriculumRepo, useDivisionController, useDivisionRepo, useDivisionService, useEntityController, useEntityRepo, useFileController, useFileRepo, useFileService, useGitHubService, useGradeLevelController, useGradeLevelRepo, useInvoiceController, useInvoiceModel, useInvoiceRepo, useInvoiceService, useMemberController, useMemberRepo, useOfficeController, useOfficeRepo, useOfficeService, useOrderController, useOrderRepo, useOrgController, useOrgRepo, useOrgService, usePaymentController, usePaymentMethodController, usePaymentMethodRepo, usePaymentMethodService, usePaymentModel, usePaymentRepo, usePaypalService, usePlantillaController, usePlantillaRepo, usePriceController, usePriceModel, usePriceRepo, usePromoCodeController, usePromoCodeRepo, useRegionController, useRegionRepo, useRegionService, useRoleController, useRoleRepo, useSchoolController, useSchoolRepo, useSchoolService, useStockCardController, useStockCardRepository, useSubscriptionController, useSubscriptionRepo, useSubscriptionService, useTokenRepo, useUserController, useUserRepo, useUserService, useUtilController, useVerificationController, useVerificationRepo, useVerificationService, useXenditService, validateCardPayment, validateDirectDebit, validateEWalletPayment };
3366
+ export { ACCESS_TOKEN_EXPIRY, ACCESS_TOKEN_SECRET, APP_ACCOUNT, APP_MAIN, ASSEMBLY_AI_API_KEY, AddressInformation, AudioFileData, AudioTranscriptionOptions, AudioTranscriptionResult, BasicEducEnrForm, CardPayment, CardPaymentSchema, DEFAULT_USER_EMAIL, DEFAULT_USER_FIRST_NAME, DEFAULT_USER_LAST_NAME, DEFAULT_USER_PASSWORD, DirectDebit, DirectDebitSchema, DisabilityType, EWalletPayment, EWalletPaymentSchema, EnrAddress, EnrCert, EnrLearnerInfo, EnrLearningModality, EnrParentGuardianInfo, EnrReturningLearnerInfo, EnrSeniorHighInformation, GEMINI_API_KEY, MAILER_EMAIL, MAILER_PASSWORD, MAILER_TRANSPORT_HOST, MAILER_TRANSPORT_PORT, MAILER_TRANSPORT_SECURE, MAddress, MAsset, MBarangay, MBuilding, MBuildingUnit, MCityMunicipality, MCurriculum, MDivision, MEnrollment, MEntity, MFile, MGradeLevel, MMember, MONGO_DB, MONGO_URI, MOffice, MOrder, MOrg, MPaymentMethod, MPlantilla, MPromoCode, MProvince, MRegion, MRole, MSchool, MStockCard, MSubscription, MToken, MUser, MUserRole, MVerification, PAYPAL_API_URL, PAYPAL_CLIENT_ID, PAYPAL_CLIENT_SECRET, PORT, PersonContact, PhonemeMatchOptions, PhonemeMatchResult, REDIS_HOST, REDIS_PASSWORD, REDIS_PORT, REFRESH_TOKEN_EXPIRY, REFRESH_TOKEN_SECRET, SECRET_KEY, SPACES_ACCESS_KEY, SPACES_BUCKET, SPACES_ENDPOINT, SPACES_REGION, SPACES_SECRET_KEY, TAddress, TAsset, TBarangay, TBillingRecipient, TBuilding, TBuildingUnit, TCityMunicipality, TCounter, TCurriculum, TCurriculumSubject, TDivision, TEntity, TFile, TGradeLevel, TInvoice, TMember, TMiniRole, TOffice, TOrder, TOrderMetadata, TOrg, TPayment, TPaymentMethod$1 as TPaymentMethod, TPaymentMethodType, TPlantilla, TPrice, TPriceType, TPromoCode, TPromoTier, TProvince, TRegion, TRole, TSchool, TStockCard, TSubscription, TToken, TUser, TUserRole, TVerification, TVerificationMetadata, VERIFICATION_FORGET_PASSWORD_DURATION, VERIFICATION_USER_INVITE_DURATION, XENDIT_BASE_URL, XENDIT_SECRET_KEY, addressSchema, isDev, schema, schemaAsset, schemaAssetUpdateOption, schemaBarangay, schemaBuilding, schemaBuildingUnit, schemaCityMunicipality, schemaCurriculum, schemaDivision, schemaEnrollment, schemaGradeLevel, schemaOffice, schemaPlantilla, schemaProvince, schemaRegion, schemaSchool, schemaStockCard, schemaUpdateOptions, useAddressController, useAddressRepo, useAssetController, useAssetRepo, useAudioTranscriptionController, useAuthController, useAuthService, useBarangayController, useBarangayRepo, useBarangayService, useBuildingController, useBuildingRepo, useBuildingUnitController, useBuildingUnitRepo, useCityMunicipalityController, useCityMunicipalityRepo, useCityMunicipalityService, useCounterModel, useCounterRepo, useCurriculumController, useCurriculumRepo, useDivisionController, useDivisionRepo, useDivisionService, useEnrollmentController, useEnrollmentRepo, useEnrollmentService, useEntityController, useEntityRepo, useFileController, useFileRepo, useFileService, useGeminiAiService, useGitHubService, useGradeLevelController, useGradeLevelRepo, useInvoiceController, useInvoiceModel, useInvoiceRepo, useInvoiceService, useMemberController, useMemberRepo, useOfficeController, useOfficeRepo, useOfficeService, useOrderController, useOrderRepo, useOrgController, useOrgRepo, useOrgService, usePaymentController, usePaymentMethodController, usePaymentMethodRepo, usePaymentMethodService, usePaymentModel, usePaymentRepo, usePaypalService, usePlantillaController, usePlantillaRepo, usePriceController, usePriceModel, usePriceRepo, usePromoCodeController, usePromoCodeRepo, useProvinceController, useProvinceRepo, useProvinceService, useRegionController, useRegionRepo, useRegionService, useRoleController, useRoleRepo, useSchoolController, useSchoolRepo, useSchoolService, useStockCardController, useStockCardRepository, useSubscriptionController, useSubscriptionRepo, useSubscriptionService, useTokenRepo, useUserController, useUserRepo, useUserService, useUtilController, useVerificationController, useVerificationRepo, useVerificationService, useXenditService, validateCardPayment, validateDirectDebit, validateEWalletPayment };