@vitalfit/sdk 0.3.8 → 0.3.9

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.cts CHANGED
@@ -107,6 +107,115 @@ type RenewTokenRequest = {
107
107
  refresh_token: string;
108
108
  };
109
109
 
110
+ interface ServiceCategoryInfo {
111
+ category_id: string;
112
+ name: string;
113
+ }
114
+ interface ServiceImageResponse {
115
+ image_id: string;
116
+ image_url: string;
117
+ alt_text: string;
118
+ display_order: number;
119
+ is_primary: boolean;
120
+ }
121
+ interface BannerResponse {
122
+ banner_id: string;
123
+ name: string;
124
+ image_url: string;
125
+ link_url: string;
126
+ is_active: boolean;
127
+ }
128
+ interface ServiceFullDetail {
129
+ service_id: string;
130
+ category_id: string;
131
+ name: string;
132
+ description: string;
133
+ duration_minutes: number;
134
+ priority_score: number;
135
+ is_featured: boolean;
136
+ created_at: string;
137
+ updated_at: string;
138
+ service_category: ServiceCategoryInfo;
139
+ images: ServiceImageResponse[];
140
+ banners: BannerResponse[];
141
+ }
142
+ type CreateServiceImage = {
143
+ alt_text: string;
144
+ display_order: number;
145
+ image_url: string;
146
+ is_primary: boolean;
147
+ };
148
+ type CreateService = {
149
+ banner_id: string;
150
+ category_id: string;
151
+ description: string;
152
+ duration: number;
153
+ is_featured: boolean;
154
+ name: string;
155
+ priority: number;
156
+ service_images: CreateServiceImage[];
157
+ };
158
+ type UpdateServiceImageManual = {
159
+ alt_text?: string;
160
+ display_order?: number;
161
+ image_url?: string;
162
+ is_primary?: boolean;
163
+ };
164
+ type UpdateServiceManual = {
165
+ banner_id?: string;
166
+ category_id?: string;
167
+ description?: string;
168
+ duration?: number;
169
+ is_featured?: boolean;
170
+ name?: string;
171
+ priority?: number;
172
+ service_images?: UpdateServiceImageManual[];
173
+ };
174
+ type BranchServicePrice = {
175
+ branch_id: string;
176
+ service_id: string;
177
+ service_name: string;
178
+ is_visible: boolean;
179
+ max_capacity: number;
180
+ price_for_member: number;
181
+ price_for_non_member: number;
182
+ };
183
+ type CreateBranchServicePriceItem = {
184
+ service_id: string;
185
+ is_visible: boolean;
186
+ max_capacity: number;
187
+ price_for_member: number;
188
+ price_for_non_member: number;
189
+ };
190
+ type UpdateBranchServicePrice = {
191
+ is_visible?: boolean;
192
+ max_capacity?: number;
193
+ price_for_member?: number;
194
+ price_for_non_member?: number;
195
+ };
196
+ type PaginatedServiceRequest = PaginationRequest & {
197
+ category?: string;
198
+ };
199
+ type ServicesSummary = {
200
+ total: number;
201
+ actives: number;
202
+ featured: number;
203
+ };
204
+ type ServicePublicItem = ServiceFullDetail & {
205
+ lowest_price_member: number;
206
+ lowest_price_no_member: number;
207
+ base_currency: string;
208
+ ref_lowest_price_member: string;
209
+ ref_lowest_price_no_member: string;
210
+ ref_base_currency: string;
211
+ };
212
+ type PublicPaginationService = PaginationRequest & {
213
+ currency: string;
214
+ category: string;
215
+ price: number;
216
+ sortby: string;
217
+ };
218
+
110
219
  type ClientProfile = {
111
220
  user_id: string;
112
221
  qr_code: string;
@@ -206,6 +315,13 @@ type MedicalProfile = {
206
315
  type BlockUserRequest = {
207
316
  block_justification: string;
208
317
  };
318
+ type ClientBalance = {
319
+ user_id: string;
320
+ service_id: string;
321
+ balance: number;
322
+ updated_at: string;
323
+ service?: ServiceFullDetail;
324
+ };
209
325
 
210
326
  type PaginatedBranch = {
211
327
  branch_id: string;
@@ -409,6 +525,14 @@ type InstructorsSummary = {
409
525
  actives: number;
410
526
  blocked: number;
411
527
  };
528
+ type AssignedClientResponse = {
529
+ user_id: string;
530
+ first_name: string;
531
+ last_name: string;
532
+ email: string;
533
+ phone: string;
534
+ total_bookings: number;
535
+ };
412
536
 
413
537
  interface Permission {
414
538
  created_at?: string;
@@ -551,115 +675,6 @@ type BranchInfo = {
551
675
  phone: string;
552
676
  };
553
677
 
554
- interface ServiceCategoryInfo {
555
- category_id: string;
556
- name: string;
557
- }
558
- interface ServiceImageResponse {
559
- image_id: string;
560
- image_url: string;
561
- alt_text: string;
562
- display_order: number;
563
- is_primary: boolean;
564
- }
565
- interface BannerResponse {
566
- banner_id: string;
567
- name: string;
568
- image_url: string;
569
- link_url: string;
570
- is_active: boolean;
571
- }
572
- interface ServiceFullDetail {
573
- service_id: string;
574
- category_id: string;
575
- name: string;
576
- description: string;
577
- duration_minutes: number;
578
- priority_score: number;
579
- is_featured: boolean;
580
- created_at: string;
581
- updated_at: string;
582
- service_category: ServiceCategoryInfo;
583
- images: ServiceImageResponse[];
584
- banners: BannerResponse[];
585
- }
586
- type CreateServiceImage = {
587
- alt_text: string;
588
- display_order: number;
589
- image_url: string;
590
- is_primary: boolean;
591
- };
592
- type CreateService = {
593
- banner_id: string;
594
- category_id: string;
595
- description: string;
596
- duration: number;
597
- is_featured: boolean;
598
- name: string;
599
- priority: number;
600
- service_images: CreateServiceImage[];
601
- };
602
- type UpdateServiceImageManual = {
603
- alt_text?: string;
604
- display_order?: number;
605
- image_url?: string;
606
- is_primary?: boolean;
607
- };
608
- type UpdateServiceManual = {
609
- banner_id?: string;
610
- category_id?: string;
611
- description?: string;
612
- duration?: number;
613
- is_featured?: boolean;
614
- name?: string;
615
- priority?: number;
616
- service_images?: UpdateServiceImageManual[];
617
- };
618
- type BranchServicePrice = {
619
- branch_id: string;
620
- service_id: string;
621
- service_name: string;
622
- is_visible: boolean;
623
- max_capacity: number;
624
- price_for_member: number;
625
- price_for_non_member: number;
626
- };
627
- type CreateBranchServicePriceItem = {
628
- service_id: string;
629
- is_visible: boolean;
630
- max_capacity: number;
631
- price_for_member: number;
632
- price_for_non_member: number;
633
- };
634
- type UpdateBranchServicePrice = {
635
- is_visible?: boolean;
636
- max_capacity?: number;
637
- price_for_member?: number;
638
- price_for_non_member?: number;
639
- };
640
- type PaginatedServiceRequest = PaginationRequest & {
641
- category?: string;
642
- };
643
- type ServicesSummary = {
644
- total: number;
645
- actives: number;
646
- featured: number;
647
- };
648
- type ServicePublicItem = ServiceFullDetail & {
649
- lowest_price_member: number;
650
- lowest_price_no_member: number;
651
- base_currency: string;
652
- ref_lowest_price_member: string;
653
- ref_lowest_price_no_member: string;
654
- ref_base_currency: string;
655
- };
656
- type PublicPaginationService = PaginationRequest & {
657
- currency: string;
658
- category: string;
659
- price: number;
660
- sortby: string;
661
- };
662
-
663
678
  type EquipmentCategory = 'Cardio' | 'Strength' | 'FreeWeight' | 'Functional' | 'Accessory';
664
679
  type Equipment = {
665
680
  equipment_id: string;
@@ -955,7 +970,8 @@ type PaymentDetail = {
955
970
 
956
971
  type CheckIn = {
957
972
  branch_id: string;
958
- qr_jwt: string;
973
+ qr_jwt?: string;
974
+ user_id?: string;
959
975
  };
960
976
  type CheckInResponse = {
961
977
  access_type: string;
@@ -1230,6 +1246,7 @@ declare class InstructorService {
1230
1246
  deleteInstructor(instructorId: string, jwt: string): Promise<void>;
1231
1247
  addSpecialty(instructorId: string, specialty: Specialty[], jwt: string): Promise<void>;
1232
1248
  removeSpecialty(instructorId: string, specialtyId: string, jwt: string): Promise<void>;
1249
+ getAssignedClients(instructorId: string, jwt: string, { page, limit, sort, search }?: PaginationRequest): Promise<PaginatedTotal<AssignedClientResponse[]>>;
1233
1250
  addBranchInstructor(branchId: string, instructorIDs: string[], jwt: string): Promise<void>;
1234
1251
  removeBranchInstructor(branchId: string, instructorId: string, jwt: string): Promise<void>;
1235
1252
  getBranchInstructors(branchId: string, { search, identity_doc }: PaginatedInstructor, jwt: string): Promise<DataResponse<BranchInstructorInfo[]>>;
@@ -1299,6 +1316,7 @@ declare class ProductsService {
1299
1316
  createService(data: CreateService, jwt: string): Promise<void>;
1300
1317
  getServices(jwt: string, { page, limit, sort, search, category, }: PaginatedServiceRequest): Promise<PaginatedTotal<ServiceFullDetail[]>>;
1301
1318
  getSummary(jwt: string): Promise<DataResponse<ServicesSummary>>;
1319
+ getClientBalances(jwt: string, userId?: string): Promise<DataResponse<ClientBalance[]>>;
1302
1320
  getServiceByID(serviceId: string, jwt: string): Promise<DataResponse<ServiceFullDetail>>;
1303
1321
  updateService(serviceId: string, data: UpdateServiceManual, jwt: string): Promise<void>;
1304
1322
  deleteService(serviceId: string, jwt: string): Promise<void>;
@@ -1380,6 +1398,7 @@ declare class AccessService {
1380
1398
  private client;
1381
1399
  constructor(client: Client);
1382
1400
  checkIn(jwt: string, data: CheckIn): Promise<CheckInResponse>;
1401
+ checkInManual(jwt: string, data: CheckIn): Promise<CheckInResponse>;
1383
1402
  getClientAttendanceHistory(jwt: string, userId: string, start?: string, end?: string, { page, limit, sort }?: PaginationRequest): Promise<PaginatedTotal<AttendanceHistory[]>>;
1384
1403
  getClientServiceUsage(jwt: string, userId: string, start?: string, end?: string, { page, limit, sort }?: PaginationRequest): Promise<PaginatedTotal<ServiceUsage[]>>;
1385
1404
  getClassAttendanceHistory(jwt: string, classId: string, start?: string, end?: string, status?: 'Attended' | 'NoShow' | 'Cancelled'): Promise<DataResponse<AttendanceHistory[]>>;
@@ -1535,4 +1554,4 @@ declare class VitalFit {
1535
1554
  version(): string;
1536
1555
  }
1537
1556
 
1538
- export { APIError, type AddPaymentToInvoicePayload, type AddPaymentToInvoiceResponse, type AddToWishlistRequest, type AttendanceHistory, type AuditLog, type BankTransferConfig, type Banner, type BannerResponse, type BaseModel, type BillingMatrix, type BillingMatrixRow, type BlockUserRequest, type BookClassRequest, type BookingParticipant, type BranchClassInfo, type BranchDetails, type BranchEquipmentInventory, type BranchInfo, type BranchInstructorInfo, type BranchPaymentMethod, type BranchPaymentMethodInfo, type BranchPaymentVisibility, type BranchPerformance, type BranchScheduleResponse, type BranchServicePrice, type BranchStaff, type BranchStatusCount, type BroadcastRequest, type CancellationReason, type ChartData, type CheckIn, type CheckInResponse, type ClassBookingCount, type ClassCapacityStats, type ClassScheduleItem, type ClientBookingResponse, type ClientInvoice, type ClientMembership, type ClientMembershipDetail, type ClientMembershipItem, type ClientMembershipUser, type ClientProfile, type CohortRetention, type CreateBanner, type CreateBranchEquipment, type CreateBranchRequest, type CreateBranchServicePriceItem, type CreateCancellationReason, type CreateClassPayload, type CreateEquipment, type CreateFiscalDocumentRequest, type CreateInvoiceItem, type CreateInvoicePayload, type CreateInvoiceResponse, type CreateMembershipType, type CreatePackagePayload, type CreatePaymentMethod, type CreatePromotion, type CreateRole, type CreateService, type CreateServiceImage, type DataResponse, type Equipment, type EquipmentCategory, type EquipmentInfo, type EquipmentStatus, type ExchangeRateResponse, type FinancialSummary, type FinancialSummaryItem, type FiscalDocument, type GetUserResponse, type GlobalSalesStats, type GlobalStat, type HeatmapPoint, type Instructor, type InstructorData, type InstructorDataList, type InstructorsSummary, type InvoiceDetail, type InvoiceItemDetail, type InvoiceList, type InvoicePaymentDetail, type KPICard, type LoginRequest, type LoginResponse, type MedicalProfile, type MembershipType, type MembershipTypeDetail, type MembershipsSummary, type NotificationResponse, type Oauth, type OperatingHour, type PackageDetail, type PackageItemDetail, type PackageItemInput, type PackageListItem, type PackagePublicItem, type PaginatedBranch, type PaginatedEquipmentRequest, type PaginatedInstructor, type PaginatedServiceRequest, type PaginatedTotal, type Pagination, type PaginationBranchRequest, type PaginationRequest, type PaginationWithStatus, type PagoMovilConfig, type PaymentConfiguration, type PaymentDetail, type PaymentMethod, type PaymentMethodTypes, type Permission, type Policy, type Promotion, type PublicMembershipResponse, type PublicPaginatedPackage, type PublicPaginationService, type QrToken, type RandomBanner, type RecentAttendanceItem, type RenewTokenRequest, type Role, type RoleResponse, type ServiceCategoryInfo, type ServiceFullDetail, type ServiceImageResponse, type ServicePublicItem, type ServiceUsage, type ServicesSummary, type SignUpRequest, type Specialty, type StackedChartData, type Staff, type TaxRate, type TopBranch, type TotalSalesStats, type UUIDModel, type UnreadCountResponse, type UpdateBanner, type UpdateBranchEquipmentDetails, type UpdateBranchPaymentMethod, type UpdateBranchRequest, type UpdateBranchServicePrice, type UpdateClassPayload, type UpdateClientMembershipRequest, type UpdateEquipment, type UpdateMembershipType, type UpdateOperatingHour, type UpdatePackagePayload, type UpdateServiceImageManual, type UpdateServiceManual, type UpdateUserRequest, type UpdateUserStaffRequest, type User, type UserApiResponse, UserGender, type UserPaginationOptions, type UserSession, VitalFit, type WishlistItemResponse, type ZelleConfig, isAPIError, mainCurrencies, type updatePolicy };
1557
+ export { APIError, type AddPaymentToInvoicePayload, type AddPaymentToInvoiceResponse, type AddToWishlistRequest, type AssignedClientResponse, type AttendanceHistory, type AuditLog, type BankTransferConfig, type Banner, type BannerResponse, type BaseModel, type BillingMatrix, type BillingMatrixRow, type BlockUserRequest, type BookClassRequest, type BookingParticipant, type BranchClassInfo, type BranchDetails, type BranchEquipmentInventory, type BranchInfo, type BranchInstructorInfo, type BranchPaymentMethod, type BranchPaymentMethodInfo, type BranchPaymentVisibility, type BranchPerformance, type BranchScheduleResponse, type BranchServicePrice, type BranchStaff, type BranchStatusCount, type BroadcastRequest, type CancellationReason, type ChartData, type CheckIn, type CheckInResponse, type ClassBookingCount, type ClassCapacityStats, type ClassScheduleItem, type ClientBalance, type ClientBookingResponse, type ClientInvoice, type ClientMembership, type ClientMembershipDetail, type ClientMembershipItem, type ClientMembershipUser, type ClientProfile, type CohortRetention, type CreateBanner, type CreateBranchEquipment, type CreateBranchRequest, type CreateBranchServicePriceItem, type CreateCancellationReason, type CreateClassPayload, type CreateEquipment, type CreateFiscalDocumentRequest, type CreateInvoiceItem, type CreateInvoicePayload, type CreateInvoiceResponse, type CreateMembershipType, type CreatePackagePayload, type CreatePaymentMethod, type CreatePromotion, type CreateRole, type CreateService, type CreateServiceImage, type DataResponse, type Equipment, type EquipmentCategory, type EquipmentInfo, type EquipmentStatus, type ExchangeRateResponse, type FinancialSummary, type FinancialSummaryItem, type FiscalDocument, type GetUserResponse, type GlobalSalesStats, type GlobalStat, type HeatmapPoint, type Instructor, type InstructorData, type InstructorDataList, type InstructorsSummary, type InvoiceDetail, type InvoiceItemDetail, type InvoiceList, type InvoicePaymentDetail, type KPICard, type LoginRequest, type LoginResponse, type MedicalProfile, type MembershipType, type MembershipTypeDetail, type MembershipsSummary, type NotificationResponse, type Oauth, type OperatingHour, type PackageDetail, type PackageItemDetail, type PackageItemInput, type PackageListItem, type PackagePublicItem, type PaginatedBranch, type PaginatedEquipmentRequest, type PaginatedInstructor, type PaginatedServiceRequest, type PaginatedTotal, type Pagination, type PaginationBranchRequest, type PaginationRequest, type PaginationWithStatus, type PagoMovilConfig, type PaymentConfiguration, type PaymentDetail, type PaymentMethod, type PaymentMethodTypes, type Permission, type Policy, type Promotion, type PublicMembershipResponse, type PublicPaginatedPackage, type PublicPaginationService, type QrToken, type RandomBanner, type RecentAttendanceItem, type RenewTokenRequest, type Role, type RoleResponse, type ServiceCategoryInfo, type ServiceFullDetail, type ServiceImageResponse, type ServicePublicItem, type ServiceUsage, type ServicesSummary, type SignUpRequest, type Specialty, type StackedChartData, type Staff, type TaxRate, type TopBranch, type TotalSalesStats, type UUIDModel, type UnreadCountResponse, type UpdateBanner, type UpdateBranchEquipmentDetails, type UpdateBranchPaymentMethod, type UpdateBranchRequest, type UpdateBranchServicePrice, type UpdateClassPayload, type UpdateClientMembershipRequest, type UpdateEquipment, type UpdateMembershipType, type UpdateOperatingHour, type UpdatePackagePayload, type UpdateServiceImageManual, type UpdateServiceManual, type UpdateUserRequest, type UpdateUserStaffRequest, type User, type UserApiResponse, UserGender, type UserPaginationOptions, type UserSession, VitalFit, type WishlistItemResponse, type ZelleConfig, isAPIError, mainCurrencies, type updatePolicy };
package/dist/index.d.ts CHANGED
@@ -107,6 +107,115 @@ type RenewTokenRequest = {
107
107
  refresh_token: string;
108
108
  };
109
109
 
110
+ interface ServiceCategoryInfo {
111
+ category_id: string;
112
+ name: string;
113
+ }
114
+ interface ServiceImageResponse {
115
+ image_id: string;
116
+ image_url: string;
117
+ alt_text: string;
118
+ display_order: number;
119
+ is_primary: boolean;
120
+ }
121
+ interface BannerResponse {
122
+ banner_id: string;
123
+ name: string;
124
+ image_url: string;
125
+ link_url: string;
126
+ is_active: boolean;
127
+ }
128
+ interface ServiceFullDetail {
129
+ service_id: string;
130
+ category_id: string;
131
+ name: string;
132
+ description: string;
133
+ duration_minutes: number;
134
+ priority_score: number;
135
+ is_featured: boolean;
136
+ created_at: string;
137
+ updated_at: string;
138
+ service_category: ServiceCategoryInfo;
139
+ images: ServiceImageResponse[];
140
+ banners: BannerResponse[];
141
+ }
142
+ type CreateServiceImage = {
143
+ alt_text: string;
144
+ display_order: number;
145
+ image_url: string;
146
+ is_primary: boolean;
147
+ };
148
+ type CreateService = {
149
+ banner_id: string;
150
+ category_id: string;
151
+ description: string;
152
+ duration: number;
153
+ is_featured: boolean;
154
+ name: string;
155
+ priority: number;
156
+ service_images: CreateServiceImage[];
157
+ };
158
+ type UpdateServiceImageManual = {
159
+ alt_text?: string;
160
+ display_order?: number;
161
+ image_url?: string;
162
+ is_primary?: boolean;
163
+ };
164
+ type UpdateServiceManual = {
165
+ banner_id?: string;
166
+ category_id?: string;
167
+ description?: string;
168
+ duration?: number;
169
+ is_featured?: boolean;
170
+ name?: string;
171
+ priority?: number;
172
+ service_images?: UpdateServiceImageManual[];
173
+ };
174
+ type BranchServicePrice = {
175
+ branch_id: string;
176
+ service_id: string;
177
+ service_name: string;
178
+ is_visible: boolean;
179
+ max_capacity: number;
180
+ price_for_member: number;
181
+ price_for_non_member: number;
182
+ };
183
+ type CreateBranchServicePriceItem = {
184
+ service_id: string;
185
+ is_visible: boolean;
186
+ max_capacity: number;
187
+ price_for_member: number;
188
+ price_for_non_member: number;
189
+ };
190
+ type UpdateBranchServicePrice = {
191
+ is_visible?: boolean;
192
+ max_capacity?: number;
193
+ price_for_member?: number;
194
+ price_for_non_member?: number;
195
+ };
196
+ type PaginatedServiceRequest = PaginationRequest & {
197
+ category?: string;
198
+ };
199
+ type ServicesSummary = {
200
+ total: number;
201
+ actives: number;
202
+ featured: number;
203
+ };
204
+ type ServicePublicItem = ServiceFullDetail & {
205
+ lowest_price_member: number;
206
+ lowest_price_no_member: number;
207
+ base_currency: string;
208
+ ref_lowest_price_member: string;
209
+ ref_lowest_price_no_member: string;
210
+ ref_base_currency: string;
211
+ };
212
+ type PublicPaginationService = PaginationRequest & {
213
+ currency: string;
214
+ category: string;
215
+ price: number;
216
+ sortby: string;
217
+ };
218
+
110
219
  type ClientProfile = {
111
220
  user_id: string;
112
221
  qr_code: string;
@@ -206,6 +315,13 @@ type MedicalProfile = {
206
315
  type BlockUserRequest = {
207
316
  block_justification: string;
208
317
  };
318
+ type ClientBalance = {
319
+ user_id: string;
320
+ service_id: string;
321
+ balance: number;
322
+ updated_at: string;
323
+ service?: ServiceFullDetail;
324
+ };
209
325
 
210
326
  type PaginatedBranch = {
211
327
  branch_id: string;
@@ -409,6 +525,14 @@ type InstructorsSummary = {
409
525
  actives: number;
410
526
  blocked: number;
411
527
  };
528
+ type AssignedClientResponse = {
529
+ user_id: string;
530
+ first_name: string;
531
+ last_name: string;
532
+ email: string;
533
+ phone: string;
534
+ total_bookings: number;
535
+ };
412
536
 
413
537
  interface Permission {
414
538
  created_at?: string;
@@ -551,115 +675,6 @@ type BranchInfo = {
551
675
  phone: string;
552
676
  };
553
677
 
554
- interface ServiceCategoryInfo {
555
- category_id: string;
556
- name: string;
557
- }
558
- interface ServiceImageResponse {
559
- image_id: string;
560
- image_url: string;
561
- alt_text: string;
562
- display_order: number;
563
- is_primary: boolean;
564
- }
565
- interface BannerResponse {
566
- banner_id: string;
567
- name: string;
568
- image_url: string;
569
- link_url: string;
570
- is_active: boolean;
571
- }
572
- interface ServiceFullDetail {
573
- service_id: string;
574
- category_id: string;
575
- name: string;
576
- description: string;
577
- duration_minutes: number;
578
- priority_score: number;
579
- is_featured: boolean;
580
- created_at: string;
581
- updated_at: string;
582
- service_category: ServiceCategoryInfo;
583
- images: ServiceImageResponse[];
584
- banners: BannerResponse[];
585
- }
586
- type CreateServiceImage = {
587
- alt_text: string;
588
- display_order: number;
589
- image_url: string;
590
- is_primary: boolean;
591
- };
592
- type CreateService = {
593
- banner_id: string;
594
- category_id: string;
595
- description: string;
596
- duration: number;
597
- is_featured: boolean;
598
- name: string;
599
- priority: number;
600
- service_images: CreateServiceImage[];
601
- };
602
- type UpdateServiceImageManual = {
603
- alt_text?: string;
604
- display_order?: number;
605
- image_url?: string;
606
- is_primary?: boolean;
607
- };
608
- type UpdateServiceManual = {
609
- banner_id?: string;
610
- category_id?: string;
611
- description?: string;
612
- duration?: number;
613
- is_featured?: boolean;
614
- name?: string;
615
- priority?: number;
616
- service_images?: UpdateServiceImageManual[];
617
- };
618
- type BranchServicePrice = {
619
- branch_id: string;
620
- service_id: string;
621
- service_name: string;
622
- is_visible: boolean;
623
- max_capacity: number;
624
- price_for_member: number;
625
- price_for_non_member: number;
626
- };
627
- type CreateBranchServicePriceItem = {
628
- service_id: string;
629
- is_visible: boolean;
630
- max_capacity: number;
631
- price_for_member: number;
632
- price_for_non_member: number;
633
- };
634
- type UpdateBranchServicePrice = {
635
- is_visible?: boolean;
636
- max_capacity?: number;
637
- price_for_member?: number;
638
- price_for_non_member?: number;
639
- };
640
- type PaginatedServiceRequest = PaginationRequest & {
641
- category?: string;
642
- };
643
- type ServicesSummary = {
644
- total: number;
645
- actives: number;
646
- featured: number;
647
- };
648
- type ServicePublicItem = ServiceFullDetail & {
649
- lowest_price_member: number;
650
- lowest_price_no_member: number;
651
- base_currency: string;
652
- ref_lowest_price_member: string;
653
- ref_lowest_price_no_member: string;
654
- ref_base_currency: string;
655
- };
656
- type PublicPaginationService = PaginationRequest & {
657
- currency: string;
658
- category: string;
659
- price: number;
660
- sortby: string;
661
- };
662
-
663
678
  type EquipmentCategory = 'Cardio' | 'Strength' | 'FreeWeight' | 'Functional' | 'Accessory';
664
679
  type Equipment = {
665
680
  equipment_id: string;
@@ -955,7 +970,8 @@ type PaymentDetail = {
955
970
 
956
971
  type CheckIn = {
957
972
  branch_id: string;
958
- qr_jwt: string;
973
+ qr_jwt?: string;
974
+ user_id?: string;
959
975
  };
960
976
  type CheckInResponse = {
961
977
  access_type: string;
@@ -1230,6 +1246,7 @@ declare class InstructorService {
1230
1246
  deleteInstructor(instructorId: string, jwt: string): Promise<void>;
1231
1247
  addSpecialty(instructorId: string, specialty: Specialty[], jwt: string): Promise<void>;
1232
1248
  removeSpecialty(instructorId: string, specialtyId: string, jwt: string): Promise<void>;
1249
+ getAssignedClients(instructorId: string, jwt: string, { page, limit, sort, search }?: PaginationRequest): Promise<PaginatedTotal<AssignedClientResponse[]>>;
1233
1250
  addBranchInstructor(branchId: string, instructorIDs: string[], jwt: string): Promise<void>;
1234
1251
  removeBranchInstructor(branchId: string, instructorId: string, jwt: string): Promise<void>;
1235
1252
  getBranchInstructors(branchId: string, { search, identity_doc }: PaginatedInstructor, jwt: string): Promise<DataResponse<BranchInstructorInfo[]>>;
@@ -1299,6 +1316,7 @@ declare class ProductsService {
1299
1316
  createService(data: CreateService, jwt: string): Promise<void>;
1300
1317
  getServices(jwt: string, { page, limit, sort, search, category, }: PaginatedServiceRequest): Promise<PaginatedTotal<ServiceFullDetail[]>>;
1301
1318
  getSummary(jwt: string): Promise<DataResponse<ServicesSummary>>;
1319
+ getClientBalances(jwt: string, userId?: string): Promise<DataResponse<ClientBalance[]>>;
1302
1320
  getServiceByID(serviceId: string, jwt: string): Promise<DataResponse<ServiceFullDetail>>;
1303
1321
  updateService(serviceId: string, data: UpdateServiceManual, jwt: string): Promise<void>;
1304
1322
  deleteService(serviceId: string, jwt: string): Promise<void>;
@@ -1380,6 +1398,7 @@ declare class AccessService {
1380
1398
  private client;
1381
1399
  constructor(client: Client);
1382
1400
  checkIn(jwt: string, data: CheckIn): Promise<CheckInResponse>;
1401
+ checkInManual(jwt: string, data: CheckIn): Promise<CheckInResponse>;
1383
1402
  getClientAttendanceHistory(jwt: string, userId: string, start?: string, end?: string, { page, limit, sort }?: PaginationRequest): Promise<PaginatedTotal<AttendanceHistory[]>>;
1384
1403
  getClientServiceUsage(jwt: string, userId: string, start?: string, end?: string, { page, limit, sort }?: PaginationRequest): Promise<PaginatedTotal<ServiceUsage[]>>;
1385
1404
  getClassAttendanceHistory(jwt: string, classId: string, start?: string, end?: string, status?: 'Attended' | 'NoShow' | 'Cancelled'): Promise<DataResponse<AttendanceHistory[]>>;
@@ -1535,4 +1554,4 @@ declare class VitalFit {
1535
1554
  version(): string;
1536
1555
  }
1537
1556
 
1538
- export { APIError, type AddPaymentToInvoicePayload, type AddPaymentToInvoiceResponse, type AddToWishlistRequest, type AttendanceHistory, type AuditLog, type BankTransferConfig, type Banner, type BannerResponse, type BaseModel, type BillingMatrix, type BillingMatrixRow, type BlockUserRequest, type BookClassRequest, type BookingParticipant, type BranchClassInfo, type BranchDetails, type BranchEquipmentInventory, type BranchInfo, type BranchInstructorInfo, type BranchPaymentMethod, type BranchPaymentMethodInfo, type BranchPaymentVisibility, type BranchPerformance, type BranchScheduleResponse, type BranchServicePrice, type BranchStaff, type BranchStatusCount, type BroadcastRequest, type CancellationReason, type ChartData, type CheckIn, type CheckInResponse, type ClassBookingCount, type ClassCapacityStats, type ClassScheduleItem, type ClientBookingResponse, type ClientInvoice, type ClientMembership, type ClientMembershipDetail, type ClientMembershipItem, type ClientMembershipUser, type ClientProfile, type CohortRetention, type CreateBanner, type CreateBranchEquipment, type CreateBranchRequest, type CreateBranchServicePriceItem, type CreateCancellationReason, type CreateClassPayload, type CreateEquipment, type CreateFiscalDocumentRequest, type CreateInvoiceItem, type CreateInvoicePayload, type CreateInvoiceResponse, type CreateMembershipType, type CreatePackagePayload, type CreatePaymentMethod, type CreatePromotion, type CreateRole, type CreateService, type CreateServiceImage, type DataResponse, type Equipment, type EquipmentCategory, type EquipmentInfo, type EquipmentStatus, type ExchangeRateResponse, type FinancialSummary, type FinancialSummaryItem, type FiscalDocument, type GetUserResponse, type GlobalSalesStats, type GlobalStat, type HeatmapPoint, type Instructor, type InstructorData, type InstructorDataList, type InstructorsSummary, type InvoiceDetail, type InvoiceItemDetail, type InvoiceList, type InvoicePaymentDetail, type KPICard, type LoginRequest, type LoginResponse, type MedicalProfile, type MembershipType, type MembershipTypeDetail, type MembershipsSummary, type NotificationResponse, type Oauth, type OperatingHour, type PackageDetail, type PackageItemDetail, type PackageItemInput, type PackageListItem, type PackagePublicItem, type PaginatedBranch, type PaginatedEquipmentRequest, type PaginatedInstructor, type PaginatedServiceRequest, type PaginatedTotal, type Pagination, type PaginationBranchRequest, type PaginationRequest, type PaginationWithStatus, type PagoMovilConfig, type PaymentConfiguration, type PaymentDetail, type PaymentMethod, type PaymentMethodTypes, type Permission, type Policy, type Promotion, type PublicMembershipResponse, type PublicPaginatedPackage, type PublicPaginationService, type QrToken, type RandomBanner, type RecentAttendanceItem, type RenewTokenRequest, type Role, type RoleResponse, type ServiceCategoryInfo, type ServiceFullDetail, type ServiceImageResponse, type ServicePublicItem, type ServiceUsage, type ServicesSummary, type SignUpRequest, type Specialty, type StackedChartData, type Staff, type TaxRate, type TopBranch, type TotalSalesStats, type UUIDModel, type UnreadCountResponse, type UpdateBanner, type UpdateBranchEquipmentDetails, type UpdateBranchPaymentMethod, type UpdateBranchRequest, type UpdateBranchServicePrice, type UpdateClassPayload, type UpdateClientMembershipRequest, type UpdateEquipment, type UpdateMembershipType, type UpdateOperatingHour, type UpdatePackagePayload, type UpdateServiceImageManual, type UpdateServiceManual, type UpdateUserRequest, type UpdateUserStaffRequest, type User, type UserApiResponse, UserGender, type UserPaginationOptions, type UserSession, VitalFit, type WishlistItemResponse, type ZelleConfig, isAPIError, mainCurrencies, type updatePolicy };
1557
+ export { APIError, type AddPaymentToInvoicePayload, type AddPaymentToInvoiceResponse, type AddToWishlistRequest, type AssignedClientResponse, type AttendanceHistory, type AuditLog, type BankTransferConfig, type Banner, type BannerResponse, type BaseModel, type BillingMatrix, type BillingMatrixRow, type BlockUserRequest, type BookClassRequest, type BookingParticipant, type BranchClassInfo, type BranchDetails, type BranchEquipmentInventory, type BranchInfo, type BranchInstructorInfo, type BranchPaymentMethod, type BranchPaymentMethodInfo, type BranchPaymentVisibility, type BranchPerformance, type BranchScheduleResponse, type BranchServicePrice, type BranchStaff, type BranchStatusCount, type BroadcastRequest, type CancellationReason, type ChartData, type CheckIn, type CheckInResponse, type ClassBookingCount, type ClassCapacityStats, type ClassScheduleItem, type ClientBalance, type ClientBookingResponse, type ClientInvoice, type ClientMembership, type ClientMembershipDetail, type ClientMembershipItem, type ClientMembershipUser, type ClientProfile, type CohortRetention, type CreateBanner, type CreateBranchEquipment, type CreateBranchRequest, type CreateBranchServicePriceItem, type CreateCancellationReason, type CreateClassPayload, type CreateEquipment, type CreateFiscalDocumentRequest, type CreateInvoiceItem, type CreateInvoicePayload, type CreateInvoiceResponse, type CreateMembershipType, type CreatePackagePayload, type CreatePaymentMethod, type CreatePromotion, type CreateRole, type CreateService, type CreateServiceImage, type DataResponse, type Equipment, type EquipmentCategory, type EquipmentInfo, type EquipmentStatus, type ExchangeRateResponse, type FinancialSummary, type FinancialSummaryItem, type FiscalDocument, type GetUserResponse, type GlobalSalesStats, type GlobalStat, type HeatmapPoint, type Instructor, type InstructorData, type InstructorDataList, type InstructorsSummary, type InvoiceDetail, type InvoiceItemDetail, type InvoiceList, type InvoicePaymentDetail, type KPICard, type LoginRequest, type LoginResponse, type MedicalProfile, type MembershipType, type MembershipTypeDetail, type MembershipsSummary, type NotificationResponse, type Oauth, type OperatingHour, type PackageDetail, type PackageItemDetail, type PackageItemInput, type PackageListItem, type PackagePublicItem, type PaginatedBranch, type PaginatedEquipmentRequest, type PaginatedInstructor, type PaginatedServiceRequest, type PaginatedTotal, type Pagination, type PaginationBranchRequest, type PaginationRequest, type PaginationWithStatus, type PagoMovilConfig, type PaymentConfiguration, type PaymentDetail, type PaymentMethod, type PaymentMethodTypes, type Permission, type Policy, type Promotion, type PublicMembershipResponse, type PublicPaginatedPackage, type PublicPaginationService, type QrToken, type RandomBanner, type RecentAttendanceItem, type RenewTokenRequest, type Role, type RoleResponse, type ServiceCategoryInfo, type ServiceFullDetail, type ServiceImageResponse, type ServicePublicItem, type ServiceUsage, type ServicesSummary, type SignUpRequest, type Specialty, type StackedChartData, type Staff, type TaxRate, type TopBranch, type TotalSalesStats, type UUIDModel, type UnreadCountResponse, type UpdateBanner, type UpdateBranchEquipmentDetails, type UpdateBranchPaymentMethod, type UpdateBranchRequest, type UpdateBranchServicePrice, type UpdateClassPayload, type UpdateClientMembershipRequest, type UpdateEquipment, type UpdateMembershipType, type UpdateOperatingHour, type UpdatePackagePayload, type UpdateServiceImageManual, type UpdateServiceManual, type UpdateUserRequest, type UpdateUserStaffRequest, type User, type UserApiResponse, UserGender, type UserPaginationOptions, type UserSession, VitalFit, type WishlistItemResponse, type ZelleConfig, isAPIError, mainCurrencies, type updatePolicy };
package/dist/index.js CHANGED
@@ -697,6 +697,7 @@ var InstructorService = class {
697
697
  this.deleteInstructor = this.deleteInstructor.bind(this);
698
698
  this.addSpecialty = this.addSpecialty.bind(this);
699
699
  this.removeSpecialty = this.removeSpecialty.bind(this);
700
+ this.getAssignedClients = this.getAssignedClients.bind(this);
700
701
  this.addBranchInstructor = this.addBranchInstructor.bind(this);
701
702
  this.removeBranchInstructor = this.removeBranchInstructor.bind(this);
702
703
  this.getBranchInstructors = this.getBranchInstructors.bind(this);
@@ -763,6 +764,19 @@ var InstructorService = class {
763
764
  jwt
764
765
  });
765
766
  }
767
+ async getAssignedClients(instructorId, jwt, { page = 1, limit = 10, sort = "desc", search } = {}) {
768
+ const response = await this.client.get({
769
+ url: `/instructor/${instructorId}/clients`,
770
+ jwt,
771
+ params: {
772
+ page,
773
+ limit,
774
+ sort,
775
+ search
776
+ }
777
+ });
778
+ return response;
779
+ }
766
780
  async addBranchInstructor(branchId, instructorIDs, jwt) {
767
781
  await this.client.post({
768
782
  url: `/branches/${branchId}/instructor`,
@@ -1211,6 +1225,7 @@ var ProductsService = class {
1211
1225
  this.createService = this.createService.bind(this);
1212
1226
  this.getServices = this.getServices.bind(this);
1213
1227
  this.getSummary = this.getSummary.bind(this);
1228
+ this.getClientBalances = this.getClientBalances.bind(this);
1214
1229
  this.getServiceByID = this.getServiceByID.bind(this);
1215
1230
  this.updateService = this.updateService.bind(this);
1216
1231
  this.deleteService = this.deleteService.bind(this);
@@ -1255,6 +1270,16 @@ var ProductsService = class {
1255
1270
  });
1256
1271
  return response;
1257
1272
  }
1273
+ async getClientBalances(jwt, userId) {
1274
+ const response = await this.client.get({
1275
+ url: "/services/balances",
1276
+ jwt,
1277
+ params: {
1278
+ user_id: userId
1279
+ }
1280
+ });
1281
+ return response;
1282
+ }
1258
1283
  async getServiceByID(serviceId, jwt) {
1259
1284
  const response = await this.client.get({
1260
1285
  url: `/services/${serviceId}`,
@@ -1751,6 +1776,7 @@ var AccessService = class {
1751
1776
  constructor(client) {
1752
1777
  this.client = client;
1753
1778
  this.checkIn = this.checkIn.bind(this);
1779
+ this.checkInManual = this.checkInManual.bind(this);
1754
1780
  this.getClientAttendanceHistory = this.getClientAttendanceHistory.bind(this);
1755
1781
  this.getClientServiceUsage = this.getClientServiceUsage.bind(this);
1756
1782
  this.getClassAttendanceHistory = this.getClassAttendanceHistory.bind(this);
@@ -1763,6 +1789,14 @@ var AccessService = class {
1763
1789
  });
1764
1790
  return response;
1765
1791
  }
1792
+ async checkInManual(jwt, data) {
1793
+ const response = await this.client.post({
1794
+ url: "/access/check-in/manual",
1795
+ jwt,
1796
+ data
1797
+ });
1798
+ return response;
1799
+ }
1766
1800
  async getClientAttendanceHistory(jwt, userId, start, end, { page = 1, limit = 10, sort = "desc" } = {}) {
1767
1801
  const response = await this.client.get({
1768
1802
  url: `/clients/${userId}/attendance-history`,
@@ -2703,7 +2737,7 @@ var VitalFit = class _VitalFit {
2703
2737
  return _VitalFit.instance;
2704
2738
  }
2705
2739
  version() {
2706
- return "0.3.8";
2740
+ return "0.3.9";
2707
2741
  }
2708
2742
  };
2709
2743
  export {