@explorins/pers-sdk 2.1.42 → 2.2.0-alpha.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (41) hide show
  1. package/dist/booking/api/booking-api.d.ts +71 -0
  2. package/dist/booking/api/booking-api.d.ts.map +1 -0
  3. package/dist/booking/index.d.ts +9 -0
  4. package/dist/booking/index.d.ts.map +1 -0
  5. package/dist/booking/services/booking-service.d.ts +79 -0
  6. package/dist/booking/services/booking-service.d.ts.map +1 -0
  7. package/dist/chunks/{pers-sdk-DxYmXQcW.js → pers-sdk-C01Z2nmP.js} +923 -4
  8. package/dist/chunks/pers-sdk-C01Z2nmP.js.map +1 -0
  9. package/dist/chunks/{pers-sdk-DeFxjuRB.cjs → pers-sdk-DQ6uC3h0.cjs} +925 -2
  10. package/dist/chunks/pers-sdk-DQ6uC3h0.cjs.map +1 -0
  11. package/dist/core/events/event-types.d.ts +5 -1
  12. package/dist/core/events/event-types.d.ts.map +1 -1
  13. package/dist/core/pers-api-client.d.ts.map +1 -1
  14. package/dist/core/pers-config.d.ts +30 -0
  15. package/dist/core/pers-config.d.ts.map +1 -1
  16. package/dist/core.cjs +3 -1
  17. package/dist/core.cjs.map +1 -1
  18. package/dist/core.js +1 -1
  19. package/dist/custom-field/api/custom-field-api.d.ts +58 -0
  20. package/dist/custom-field/api/custom-field-api.d.ts.map +1 -0
  21. package/dist/custom-field/index.d.ts +2 -0
  22. package/dist/custom-field/index.d.ts.map +1 -0
  23. package/dist/index.cjs +5 -1
  24. package/dist/index.cjs.map +1 -1
  25. package/dist/index.d.ts +1 -0
  26. package/dist/index.d.ts.map +1 -1
  27. package/dist/index.js +1 -1
  28. package/dist/managers/booking-manager.d.ts +188 -0
  29. package/dist/managers/booking-manager.d.ts.map +1 -0
  30. package/dist/managers/custom-field-definition-manager.d.ts +317 -0
  31. package/dist/managers/custom-field-definition-manager.d.ts.map +1 -0
  32. package/dist/managers/index.d.ts +2 -0
  33. package/dist/managers/index.d.ts.map +1 -1
  34. package/dist/node.cjs +1 -1
  35. package/dist/node.js +1 -1
  36. package/dist/package.json +2 -2
  37. package/dist/pers-sdk.d.ts +65 -1
  38. package/dist/pers-sdk.d.ts.map +1 -1
  39. package/package.json +2 -2
  40. package/dist/chunks/pers-sdk-DeFxjuRB.cjs.map +0 -1
  41. package/dist/chunks/pers-sdk-DxYmXQcW.js.map +0 -1
@@ -0,0 +1,188 @@
1
+ import { PersApiClient } from '../core/pers-api-client';
2
+ import { PersEventEmitter } from '../core/events';
3
+ import { BookingService, type BookingQueryOptions, type BookingValidationOptions } from '../booking';
4
+ import type { BookingDTO, CreateBookingDTO, UpdateBookingDTO } from '@explorins/pers-shared';
5
+ export type { BookingQueryOptions, BookingValidationOptions } from '../booking';
6
+ /**
7
+ * Booking Manager - High-level interface for booking operations
8
+ *
9
+ * Provides a simplified API for managing bookings (hotel stays, reservations, etc.)
10
+ * Used for tracking user stays and eligibility checks on redemptions.
11
+ *
12
+ * @group Managers
13
+ * @category Booking Management
14
+ *
15
+ * @example List Bookings
16
+ * ```typescript
17
+ * // Get all bookings
18
+ * const allBookings = await sdk.bookings.getAll();
19
+ *
20
+ * // Filter by user
21
+ * const userBookings = await sdk.bookings.getAll({ userId: 'user-123' });
22
+ *
23
+ * // Filter by status
24
+ * const activeBookings = await sdk.bookings.getAll({ status: 'active' });
25
+ * ```
26
+ *
27
+ * @example Create Booking
28
+ * ```typescript
29
+ * const booking = await sdk.bookings.create({
30
+ * userId: 'user-123',
31
+ * locationName: 'Grand Hotel',
32
+ * checkInDate: '2026-06-01',
33
+ * checkOutDate: '2026-06-05',
34
+ * guests: 2
35
+ * });
36
+ * ```
37
+ *
38
+ * @example Check Eligibility
39
+ * ```typescript
40
+ * // Check if user has valid (active or future) booking
41
+ * const hasBooking = await sdk.bookings.hasValidBooking('user-123');
42
+ * if (hasBooking) {
43
+ * // User is eligible for booking-required redemption
44
+ * }
45
+ * ```
46
+ */
47
+ export declare class BookingManager {
48
+ private apiClient;
49
+ private events?;
50
+ private bookingService;
51
+ constructor(apiClient: PersApiClient, events?: PersEventEmitter | undefined);
52
+ /**
53
+ * Get all bookings with optional filters
54
+ *
55
+ * @param options - Filter options (userId, businessId, status)
56
+ * @returns Promise resolving to array of bookings
57
+ *
58
+ * @example Basic Usage
59
+ * ```typescript
60
+ * // All bookings
61
+ * const bookings = await sdk.bookings.getAll();
62
+ *
63
+ * // Filter by user
64
+ * const userBookings = await sdk.bookings.getAll({ userId: 'user-123' });
65
+ *
66
+ * // Filter by status
67
+ * const activeBookings = await sdk.bookings.getAll({ status: 'active' });
68
+ * const futureBookings = await sdk.bookings.getAll({ status: 'future' });
69
+ * const pastBookings = await sdk.bookings.getAll({ status: 'past' });
70
+ * ```
71
+ */
72
+ getAll(options?: BookingQueryOptions): Promise<BookingDTO[]>;
73
+ /**
74
+ * Get bookings for a specific user
75
+ *
76
+ * Convenience method for filtering bookings by user ID.
77
+ *
78
+ * @param userId - User ID to filter by
79
+ * @param status - Optional status filter
80
+ * @returns Promise resolving to user's bookings
81
+ */
82
+ getByUser(userId: string, status?: BookingQueryOptions['status']): Promise<BookingDTO[]>;
83
+ /**
84
+ * Get bookings for a specific business
85
+ *
86
+ * Convenience method for filtering bookings by business ID.
87
+ *
88
+ * @param businessId - Business ID to filter by
89
+ * @param status - Optional status filter
90
+ * @returns Promise resolving to business's bookings
91
+ */
92
+ getByBusiness(businessId: string, status?: BookingQueryOptions['status']): Promise<BookingDTO[]>;
93
+ /**
94
+ * Get a single booking by ID
95
+ *
96
+ * @param id - Booking UUID
97
+ * @returns Promise resolving to booking data
98
+ * @throws {PersApiError} When booking not found
99
+ */
100
+ getById(id: string): Promise<BookingDTO>;
101
+ /**
102
+ * Create a new booking
103
+ *
104
+ * Creates a booking for a user at a specific location. Used for tracking
105
+ * hotel stays, reservations, etc. for eligibility checks.
106
+ *
107
+ * @param data - Booking creation data
108
+ * @returns Promise resolving to created booking
109
+ * @throws {Error} When check-out date is not after check-in date
110
+ *
111
+ * @example Create Hotel Booking
112
+ * ```typescript
113
+ * const booking = await sdk.bookings.create({
114
+ * userId: 'user-123',
115
+ * locationName: 'Grand Hotel',
116
+ * locationType: 'hotel',
117
+ * checkInDate: '2026-06-01',
118
+ * checkOutDate: '2026-06-05',
119
+ * confirmationNumber: 'CONF123',
120
+ * guests: 2,
121
+ * notes: 'Ocean view room'
122
+ * });
123
+ * ```
124
+ */
125
+ create(data: CreateBookingDTO): Promise<BookingDTO>;
126
+ /**
127
+ * Update an existing booking
128
+ *
129
+ * @param id - Booking UUID
130
+ * @param data - Booking update data (partial update supported)
131
+ * @returns Promise resolving to updated booking
132
+ * @throws {PersApiError} When booking not found
133
+ * @throws {Error} When check-out date is not after check-in date
134
+ *
135
+ * @example Update Booking Dates
136
+ * ```typescript
137
+ * const updated = await sdk.bookings.update('booking-123', {
138
+ * checkInDate: '2026-06-02',
139
+ * checkOutDate: '2026-06-07'
140
+ * });
141
+ * ```
142
+ */
143
+ update(id: string, data: UpdateBookingDTO): Promise<BookingDTO>;
144
+ /**
145
+ * Delete a booking
146
+ *
147
+ * @param id - Booking UUID
148
+ * @returns Promise resolving to success status
149
+ * @throws {PersApiError} When booking not found
150
+ */
151
+ delete(id: string): Promise<{
152
+ success: boolean;
153
+ }>;
154
+ /**
155
+ * Check if a user has a valid (active or future) booking
156
+ *
157
+ * Useful for eligibility checks on redemptions that require a valid booking.
158
+ *
159
+ * @param userId - User ID to check
160
+ * @param options - Validation options (status filter, business filter)
161
+ * @returns Promise resolving to true if user has valid booking
162
+ *
163
+ * @example Eligibility Check
164
+ * ```typescript
165
+ * const hasBooking = await sdk.bookings.hasValidBooking('user-123');
166
+ *
167
+ * if (!hasBooking) {
168
+ * console.log('User must have an active or upcoming booking');
169
+ * }
170
+ *
171
+ * // Check for active booking only
172
+ * const hasActive = await sdk.bookings.hasValidBooking('user-123', { status: 'active' });
173
+ *
174
+ * // Check for booking at specific business
175
+ * const hasHotelBooking = await sdk.bookings.hasValidBooking('user-123', {
176
+ * businessId: 'hotel-123'
177
+ * });
178
+ * ```
179
+ */
180
+ hasValidBooking(userId: string, options?: BookingValidationOptions): Promise<boolean>;
181
+ /**
182
+ * Get the booking service for advanced operations
183
+ *
184
+ * @returns BookingService instance with full API access
185
+ */
186
+ getBookingService(): BookingService;
187
+ }
188
+ //# sourceMappingURL=booking-manager.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"booking-manager.d.ts","sourceRoot":"","sources":["../../src/managers/booking-manager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AACxD,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,EAAc,cAAc,EAAE,KAAK,mBAAmB,EAAE,KAAK,wBAAwB,EAAE,MAAM,YAAY,CAAC;AACjH,OAAO,KAAK,EACV,UAAU,EACV,gBAAgB,EAChB,gBAAgB,EACjB,MAAM,wBAAwB,CAAC;AAGhC,YAAY,EAAE,mBAAmB,EAAE,wBAAwB,EAAE,MAAM,YAAY,CAAC;AAEhF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAwCG;AACH,qBAAa,cAAc;IAIvB,OAAO,CAAC,SAAS;IACjB,OAAO,CAAC,MAAM,CAAC;IAJjB,OAAO,CAAC,cAAc,CAAiB;gBAG7B,SAAS,EAAE,aAAa,EACxB,MAAM,CAAC,8BAAkB;IAMnC;;;;;;;;;;;;;;;;;;;OAmBG;IACG,MAAM,CAAC,OAAO,CAAC,EAAE,mBAAmB,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;IAIlE;;;;;;;;OAQG;IACG,SAAS,CAAC,MAAM,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,mBAAmB,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;IAI9F;;;;;;;;OAQG;IACG,aAAa,CAAC,UAAU,EAAE,MAAM,EAAE,MAAM,CAAC,EAAE,mBAAmB,CAAC,QAAQ,CAAC,GAAG,OAAO,CAAC,UAAU,EAAE,CAAC;IAItG;;;;;;OAMG;IACG,OAAO,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,CAAC;IAI9C;;;;;;;;;;;;;;;;;;;;;;;OAuBG;IACG,MAAM,CAAC,IAAI,EAAE,gBAAgB,GAAG,OAAO,CAAC,UAAU,CAAC;IASzD;;;;;;;;;;;;;;;;OAgBG;IACG,MAAM,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,gBAAgB,GAAG,OAAO,CAAC,UAAU,CAAC;IASrE;;;;;;OAMG;IACG,MAAM,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC;QAAE,OAAO,EAAE,OAAO,CAAA;KAAE,CAAC;IASvD;;;;;;;;;;;;;;;;;;;;;;;;;OAyBG;IACG,eAAe,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,wBAAwB,GAAG,OAAO,CAAC,OAAO,CAAC;IAI3F;;;;OAIG;IACH,iBAAiB,IAAI,cAAc;CAGpC"}
@@ -0,0 +1,317 @@
1
+ import { PersApiClient } from '../core/pers-api-client';
2
+ import { PersEventEmitter } from '../core/events';
3
+ import { CustomFieldDefinitionDTO, CreateCustomFieldDefinitionDTO, UpdateCustomFieldDefinitionDTO, CustomFieldEntityType, CustomFieldSelectOption, type FieldDefinition, type ValidationErrorDetail } from '@explorins/pers-shared';
4
+ export type { CustomFieldDefinitionDTO, CreateCustomFieldDefinitionDTO, UpdateCustomFieldDefinitionDTO, CustomFieldEntityType, CustomFieldSelectOption, FieldDefinition, ValidationErrorDetail, };
5
+ /**
6
+ * Options for querying custom field definitions
7
+ */
8
+ export interface CustomFieldQueryOptions {
9
+ /** Filter by entity type (default: 'user') */
10
+ entityType?: CustomFieldEntityType;
11
+ }
12
+ /**
13
+ * Custom Field Definition Manager - Manage tenant-specific custom fields
14
+ *
15
+ * Provides CRUD operations for custom field definitions that extend the built-in
16
+ * user profile fields. Custom fields are defined per-tenant and can be used for
17
+ * additional user data collection, redemption requirements, and form validation.
18
+ *
19
+ * @group Managers
20
+ * @category Custom Fields
21
+ *
22
+ * @example Basic Operations
23
+ * ```typescript
24
+ * // List all user custom fields
25
+ * const fields = await sdk.customFields.getDefinitions();
26
+ *
27
+ * // Create a new custom field
28
+ * const field = await sdk.customFields.createDefinition({
29
+ * key: 'employee_id',
30
+ * label: 'Employee ID',
31
+ * fieldType: 'text',
32
+ * validation: { required: true, pattern: '^E[0-9]{5}$' }
33
+ * });
34
+ *
35
+ * // Update a field
36
+ * await sdk.customFields.updateDefinition(field.id, {
37
+ * label: 'Company Employee ID'
38
+ * });
39
+ *
40
+ * // Delete a field
41
+ * await sdk.customFields.deleteDefinition(field.id);
42
+ * ```
43
+ *
44
+ * @example Validation
45
+ * ```typescript
46
+ * // Validate user custom data against definitions
47
+ * const definitions = await sdk.customFields.getDefinitions();
48
+ * const errors = sdk.customFields.validateUserData(
49
+ * { employee_id: 'INVALID' },
50
+ * definitions
51
+ * );
52
+ * if (errors.length > 0) {
53
+ * console.log('Validation errors:', errors);
54
+ * }
55
+ * ```
56
+ */
57
+ export declare class CustomFieldDefinitionManager {
58
+ private events?;
59
+ private readonly api;
60
+ constructor(apiClient: PersApiClient, events?: PersEventEmitter | undefined);
61
+ /**
62
+ * List all custom field definitions for the tenant
63
+ *
64
+ * Retrieves all custom field definitions, optionally filtered by entity type.
65
+ * Results are sorted by sortOrder (ascending).
66
+ *
67
+ * @param options - Query options including entity type filter
68
+ * @returns Array of custom field definitions
69
+ *
70
+ * @example List All User Fields
71
+ * ```typescript
72
+ * const fields = await sdk.customFields.getDefinitions();
73
+ * console.log(`Found ${fields.length} custom fields`);
74
+ *
75
+ * fields.forEach(field => {
76
+ * console.log(`${field.key}: ${field.label} (${field.fieldType})`);
77
+ * });
78
+ * ```
79
+ *
80
+ * @example Filter by Entity Type
81
+ * ```typescript
82
+ * // Get only business custom fields
83
+ * const businessFields = await sdk.customFields.getDefinitions({
84
+ * entityType: 'business'
85
+ * });
86
+ * ```
87
+ */
88
+ getDefinitions(options?: CustomFieldQueryOptions): Promise<CustomFieldDefinitionDTO[]>;
89
+ /**
90
+ * Get a single custom field definition by ID
91
+ *
92
+ * @param id - The UUID of the custom field definition
93
+ * @returns The custom field definition
94
+ * @throws {PersApiError} When definition not found (404)
95
+ *
96
+ * @example
97
+ * ```typescript
98
+ * try {
99
+ * const field = await sdk.customFields.getDefinition('uuid-here');
100
+ * console.log('Field:', field.label);
101
+ * } catch (error) {
102
+ * if (error.statusCode === 404) {
103
+ * console.log('Field not found');
104
+ * }
105
+ * }
106
+ * ```
107
+ */
108
+ getDefinition(id: string): Promise<CustomFieldDefinitionDTO>;
109
+ /**
110
+ * Create a new custom field definition
111
+ *
112
+ * Creates a new custom field for the tenant. The field key must be unique
113
+ * within the tenant and entity type combination.
114
+ *
115
+ * @param data - The field definition data
116
+ * @returns The created custom field definition
117
+ * @throws {PersApiError} When key already exists (409) or validation fails (400)
118
+ *
119
+ * @example Text Field with Pattern
120
+ * ```typescript
121
+ * const employeeIdField = await sdk.customFields.createDefinition({
122
+ * key: 'employee_id',
123
+ * label: 'Employee ID',
124
+ * description: 'Your company employee ID (E + 5 digits)',
125
+ * fieldType: 'text',
126
+ * validation: {
127
+ * required: true,
128
+ * pattern: '^E[0-9]{5}$',
129
+ * patternMessage: 'Must be E followed by 5 digits'
130
+ * },
131
+ * sortOrder: 1
132
+ * });
133
+ * ```
134
+ *
135
+ * @example Date Field with Comparison
136
+ * ```typescript
137
+ * const checkOutField = await sdk.customFields.createDefinition({
138
+ * key: 'check_out',
139
+ * label: 'Check-out Date',
140
+ * fieldType: 'date',
141
+ * validation: {
142
+ * required: true,
143
+ * comparisons: [
144
+ * { field: 'check_in', operator: '>', message: 'Must be after check-in' }
145
+ * ]
146
+ * },
147
+ * sortOrder: 2
148
+ * });
149
+ * ```
150
+ *
151
+ * @example Select Field with Static Options
152
+ * ```typescript
153
+ * const departmentField = await sdk.customFields.createDefinition({
154
+ * key: 'department',
155
+ * label: 'Department',
156
+ * fieldType: 'select',
157
+ * selectOptions: [
158
+ * { value: 'engineering', label: 'Engineering' },
159
+ * { value: 'sales', label: 'Sales' },
160
+ * { value: 'hr', label: 'Human Resources' }
161
+ * ],
162
+ * validation: { required: true }
163
+ * });
164
+ * ```
165
+ *
166
+ * @example Select Field with Dynamic Options
167
+ * ```typescript
168
+ * const hotelField = await sdk.customFields.createDefinition({
169
+ * key: 'preferred_hotel',
170
+ * label: 'Preferred Hotel',
171
+ * fieldType: 'select',
172
+ * selectOptionsSource: {
173
+ * entity: 'business',
174
+ * valueField: 'id',
175
+ * labelField: 'name',
176
+ * filter: { tags: ['hotel'], isActive: true }
177
+ * },
178
+ * validation: { required: true }
179
+ * });
180
+ * ```
181
+ */
182
+ createDefinition(data: CreateCustomFieldDefinitionDTO): Promise<CustomFieldDefinitionDTO>;
183
+ /**
184
+ * Update an existing custom field definition
185
+ *
186
+ * Updates a custom field definition. Note that key and entityType cannot
187
+ * be changed after creation.
188
+ *
189
+ * @param id - The UUID of the custom field definition to update
190
+ * @param data - The fields to update (partial update supported)
191
+ * @returns The updated custom field definition
192
+ * @throws {PersApiError} When definition not found (404) or validation fails (400)
193
+ *
194
+ * @example Update Label and Validation
195
+ * ```typescript
196
+ * const updated = await sdk.customFields.updateDefinition('uuid-here', {
197
+ * label: 'Employee ID (Required)',
198
+ * validation: {
199
+ * required: true,
200
+ * minLength: 6,
201
+ * maxLength: 6
202
+ * }
203
+ * });
204
+ * ```
205
+ *
206
+ * @example Update Sort Order
207
+ * ```typescript
208
+ * await sdk.customFields.updateDefinition('uuid-here', {
209
+ * sortOrder: 5
210
+ * });
211
+ * ```
212
+ */
213
+ updateDefinition(id: string, data: UpdateCustomFieldDefinitionDTO): Promise<CustomFieldDefinitionDTO>;
214
+ /**
215
+ * Delete a custom field definition (soft delete)
216
+ *
217
+ * Soft deletes a custom field definition. Existing user data in customData
218
+ * is preserved, but the field will no longer appear in forms or validation.
219
+ *
220
+ * ⚠️ Consider the impact on existing user data before deleting.
221
+ *
222
+ * @param id - The UUID of the custom field definition to delete
223
+ * @throws {PersApiError} When definition not found (404)
224
+ *
225
+ * @example
226
+ * ```typescript
227
+ * try {
228
+ * await sdk.customFields.deleteDefinition('uuid-here');
229
+ * console.log('Field deleted');
230
+ * } catch (error) {
231
+ * console.log('Failed to delete:', error.message);
232
+ * }
233
+ * ```
234
+ */
235
+ deleteDefinition(id: string): Promise<void>;
236
+ /**
237
+ * Resolve dynamic select options for a field
238
+ *
239
+ * For fields with selectOptionsSource (dynamic options from entities),
240
+ * this resolves the actual options by querying the source entity.
241
+ *
242
+ * @param id - The UUID of the custom field definition
243
+ * @returns Array of select options
244
+ *
245
+ * @example
246
+ * ```typescript
247
+ * const field = await sdk.customFields.getDefinition('hotel-field-id');
248
+ *
249
+ * if (field.selectOptionsSource) {
250
+ * // Options come from entity - need to resolve
251
+ * const options = await sdk.customFields.resolveSelectOptions(field.id);
252
+ * console.log('Available hotels:', options);
253
+ * } else {
254
+ * // Static options
255
+ * console.log('Options:', field.selectOptions);
256
+ * }
257
+ * ```
258
+ */
259
+ resolveSelectOptions(id: string): Promise<CustomFieldSelectOption[]>;
260
+ /**
261
+ * Validate user custom data against field definitions
262
+ *
263
+ * Client-side validation using the same rules as the backend. Use this
264
+ * to validate form data before submission.
265
+ *
266
+ * @param data - User's custom data (key-value pairs)
267
+ * @param definitions - Custom field definitions to validate against
268
+ * @returns Array of validation errors (empty if valid)
269
+ *
270
+ * @example Form Validation
271
+ * ```typescript
272
+ * const definitions = await sdk.customFields.getDefinitions();
273
+ * const formData = {
274
+ * employee_id: 'E123', // Missing a digit
275
+ * department: 'engineering'
276
+ * };
277
+ *
278
+ * const errors = sdk.customFields.validateUserData(formData, definitions);
279
+ * if (errors.length > 0) {
280
+ * errors.forEach(err => {
281
+ * console.log(`${err.field}: ${err.message}`);
282
+ * });
283
+ * return; // Don't submit
284
+ * }
285
+ *
286
+ * // No errors, safe to submit
287
+ * await sdk.users.updateCurrentUser({ customData: formData });
288
+ * ```
289
+ */
290
+ validateUserData(data: Record<string, unknown>, definitions: CustomFieldDefinitionDTO[]): ValidationErrorDetail[];
291
+ /**
292
+ * Validate a single field value
293
+ *
294
+ * Validates a single value against a field's rules. Useful for
295
+ * real-time validation as the user types.
296
+ *
297
+ * @param value - The value to validate
298
+ * @param definition - The field definition
299
+ * @returns Validation error or null if valid
300
+ *
301
+ * @example Real-time Validation
302
+ * ```typescript
303
+ * const employeeIdField = definitions.find(d => d.key === 'employee_id');
304
+ *
305
+ * const handleBlur = (value: string) => {
306
+ * const error = sdk.customFields.validateFieldValue(value, employeeIdField);
307
+ * if (error) {
308
+ * setFieldError('employee_id', error.message);
309
+ * } else {
310
+ * clearFieldError('employee_id');
311
+ * }
312
+ * };
313
+ * ```
314
+ */
315
+ validateFieldValue(value: unknown, definition: CustomFieldDefinitionDTO): ValidationErrorDetail | null;
316
+ }
317
+ //# sourceMappingURL=custom-field-definition-manager.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"custom-field-definition-manager.d.ts","sourceRoot":"","sources":["../../src/managers/custom-field-definition-manager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AACxD,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAElD,OAAO,EACL,wBAAwB,EACxB,8BAA8B,EAC9B,8BAA8B,EAC9B,qBAAqB,EACrB,uBAAuB,EAGvB,KAAK,eAAe,EACpB,KAAK,qBAAqB,EAC3B,MAAM,wBAAwB,CAAC;AAGhC,YAAY,EACV,wBAAwB,EACxB,8BAA8B,EAC9B,8BAA8B,EAC9B,qBAAqB,EACrB,uBAAuB,EACvB,eAAe,EACf,qBAAqB,GACtB,CAAC;AAEF;;GAEG;AACH,MAAM,WAAW,uBAAuB;IACtC,8CAA8C;IAC9C,UAAU,CAAC,EAAE,qBAAqB,CAAC;C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,UAAU,EAAE,wBAAwB,GACnC,qBAAqB,GAAG,IAAI;CAchC"}
@@ -22,4 +22,6 @@ export { DonationManager } from './donation-manager';
22
22
  export { TriggerSourceManager } from './trigger-source-manager';
23
23
  export { WebhookManager } from './webhook-manager';
24
24
  export { WalletEventsManager, type WalletEventsConfig } from './events-manager';
25
+ export { CustomFieldDefinitionManager, type CustomFieldQueryOptions } from './custom-field-definition-manager';
26
+ export { BookingManager, type BookingQueryOptions, type BookingValidationOptions } from './booking-manager';
25
27
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/managers/index.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,YAAY,EAAE,mBAAmB,EAAE,iBAAiB,EAAE,MAAM,gBAAgB,CAAC;AAC7E,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,iBAAiB,EAAE,MAAM,uBAAuB,CAAC;AAC1D,OAAO,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;AAC/C,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,EAAE,iBAAiB,EAAE,MAAM,sBAAsB,CAAC;AACzD,OAAO,EAAE,kBAAkB,EAAE,MAAM,uBAAuB,CAAC;AAC3D,OAAO,EAAE,eAAe,EAAE,MAAM,oBAAoB,CAAC;AACrD,OAAO,EAAE,WAAW,EAAE,MAAM,gBAAgB,CAAC;AAC7C,OAAO,EAAE,aAAa,EAAE,KAAK,aAAa,EAAE,MAAM,kBAAkB,CAAC;AACrE,OAAO,EAAE,aAAa,EAAE,MAAM,mBAAmB,CAAC;AAClD,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AACvD,OAAO,EAAE,eAAe,EAAE,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,KAAK,kBAAkB,EAAE,MAAM,kBAAkB,CAAC;AAChF,OAAO,EAAE,4BAA4B,EAAE,KAAK,uBAAuB,EAAE,MAAM,mCAAmC,CAAC;AAC/G,OAAO,EAAE,cAAc,EAAE,KAAK,mBAAmB,EAAE,KAAK,wBAAwB,EAAE,MAAM,mBAAmB,CAAC"}
package/dist/node.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var persSdk = require('./chunks/pers-sdk-DeFxjuRB.cjs');
3
+ var persSdk = require('./chunks/pers-sdk-DQ6uC3h0.cjs');
4
4
  var persShared = require('@explorins/pers-shared');
5
5
  var nodeHttpClient = require('./chunks/node-http-client-D_avaa5F.cjs');
6
6
  require('./chunks/index-C4K-jkRO.cjs');
package/dist/node.js CHANGED
@@ -1,4 +1,4 @@
1
- import { j as StaticJwtAuthProvider, P as PersSDK } from './chunks/pers-sdk-DxYmXQcW.js';
1
+ import { j as StaticJwtAuthProvider, P as PersSDK } from './chunks/pers-sdk-C01Z2nmP.js';
2
2
  import { AccountOwnerType } from '@explorins/pers-shared';
3
3
  export { AccountOwnerType } from '@explorins/pers-shared';
4
4
  import { N as NodeHttpClientAdapter } from './chunks/node-http-client-DloDLfm9.js';
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@explorins/pers-sdk",
3
- "version": "2.1.42",
3
+ "version": "2.2.0-alpha.2",
4
4
  "description": "Platform-agnostic SDK for PERS (Phygital Experience Rewards System) - Core business logic and API integration",
5
5
  "type": "module",
6
6
  "main": "./dist/index.cjs",
@@ -133,7 +133,7 @@
133
133
  },
134
134
  "dependencies": {
135
135
  "@explorins/pers-sdk": "^2.1.32",
136
- "@explorins/pers-shared": "^2.1.154",
136
+ "@explorins/pers-shared": "^2.1.173",
137
137
  "@explorins/web3-ts": "^0.3.88",
138
138
  "@explorins/web3-types": "^1.2.0",
139
139
  "ethers": "^6.15.0"
@@ -170,7 +170,7 @@ import { PersConfig } from './core/pers-config';
170
170
  import { PersApiClient } from './core/pers-api-client';
171
171
  import { PersEventEmitter } from './core/events';
172
172
  import { UserDTO } from '@explorins/pers-shared';
173
- import { AuthManager, UserManager, UserStatusManager, TokenManager, BusinessManager, CampaignManager, RedemptionManager, TransactionManager, PurchaseManager, FileManager, TenantManager, ApiKeyManager, AnalyticsManager, DonationManager, TriggerSourceManager, WebhookManager, WalletEventsManager } from './managers';
173
+ import { AuthManager, UserManager, UserStatusManager, TokenManager, BusinessManager, CampaignManager, RedemptionManager, TransactionManager, PurchaseManager, FileManager, TenantManager, ApiKeyManager, AnalyticsManager, DonationManager, TriggerSourceManager, WebhookManager, WalletEventsManager, CustomFieldDefinitionManager, BookingManager } from './managers';
174
174
  import type { WalletEventsConfig } from './managers';
175
175
  /**
176
176
  * PERS SDK - Main SDK class with domain managers
@@ -249,6 +249,8 @@ export declare class PersSDK {
249
249
  private _triggerSources?;
250
250
  private _webhooks?;
251
251
  private _walletEvents?;
252
+ private _customFields?;
253
+ private _bookings?;
252
254
  private walletEventsConfig?;
253
255
  /**
254
256
  * Creates a new PERS SDK instance
@@ -645,6 +647,68 @@ export declare class PersSDK {
645
647
  * @see {@link WebhookManager} for detailed documentation
646
648
  */
647
649
  get webhooks(): WebhookManager;
650
+ /**
651
+ * Custom Field Definition Manager - Manage tenant-specific custom fields
652
+ *
653
+ * Provides CRUD operations for custom field definitions that extend the built-in
654
+ * user profile fields. Custom fields are tenant-specific and support validation.
655
+ *
656
+ * @returns CustomFieldDefinitionManager instance
657
+ *
658
+ * @example Basic Operations
659
+ * ```typescript
660
+ * // List all custom fields
661
+ * const fields = await sdk.customFields.getDefinitions();
662
+ *
663
+ * // Create a new field
664
+ * const field = await sdk.customFields.createDefinition({
665
+ * key: 'employee_id',
666
+ * label: 'Employee ID',
667
+ * fieldType: 'text',
668
+ * validation: { required: true }
669
+ * });
670
+ *
671
+ * // Validate user data
672
+ * const errors = sdk.customFields.validateUserData(formData, fields.data);
673
+ * ```
674
+ */
675
+ get customFields(): CustomFieldDefinitionManager;
676
+ /**
677
+ * Booking manager - High-level booking operations
678
+ *
679
+ * Provides methods for managing user bookings (hotel stays, reservations, etc.)
680
+ * Used for eligibility checks on redemptions that require valid bookings.
681
+ *
682
+ * @returns BookingManager instance
683
+ *
684
+ * @example List User Bookings
685
+ * ```typescript
686
+ * // Get all bookings for a user
687
+ * const bookings = await sdk.bookings.getByUser('user-123');
688
+ *
689
+ * // Filter by status
690
+ * const activeBookings = await sdk.bookings.getAll({ status: 'active' });
691
+ * ```
692
+ *
693
+ * @example Create Booking
694
+ * ```typescript
695
+ * const booking = await sdk.bookings.create({
696
+ * userId: 'user-123',
697
+ * locationName: 'Grand Hotel',
698
+ * checkInDate: '2026-06-01',
699
+ * checkOutDate: '2026-06-05'
700
+ * });
701
+ * ```
702
+ *
703
+ * @example Eligibility Check
704
+ * ```typescript
705
+ * const hasBooking = await sdk.bookings.hasValidBooking('user-123');
706
+ * if (hasBooking) {
707
+ * // User is eligible for booking-required redemption
708
+ * }
709
+ * ```
710
+ */
711
+ get bookings(): BookingManager;
648
712
  /**
649
713
  * Wallet Events Manager - Real-time blockchain events for user's wallets
650
714
  *
@@ -1 +1 @@
1
- {"version":3,"file":"pers-sdk.d.ts","sourceRoot":"","sources":["../src/pers-sdk.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA8JG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,iCAAiC,CAAC;AAC7D,OAAO,EAAE,UAAU,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AACvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,eAAe,C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