@explorins/pers-sdk 2.1.2 → 2.1.4

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 (108) hide show
  1. package/dist/analytics/api/analytics-api.d.ts +175 -1
  2. package/dist/analytics/api/analytics-api.d.ts.map +1 -1
  3. package/dist/analytics/models/index.d.ts +2 -5
  4. package/dist/analytics/models/index.d.ts.map +1 -1
  5. package/dist/analytics/services/analytics-service.d.ts +32 -1
  6. package/dist/analytics/services/analytics-service.d.ts.map +1 -1
  7. package/dist/analytics.cjs +9 -44
  8. package/dist/analytics.cjs.map +1 -1
  9. package/dist/analytics.js +2 -45
  10. package/dist/analytics.js.map +1 -1
  11. package/dist/campaign/api/campaign-api.d.ts +59 -4
  12. package/dist/campaign/api/campaign-api.d.ts.map +1 -1
  13. package/dist/campaign/services/campaign-service.d.ts +49 -7
  14. package/dist/campaign/services/campaign-service.d.ts.map +1 -1
  15. package/dist/campaign.cjs +150 -14
  16. package/dist/campaign.cjs.map +1 -1
  17. package/dist/campaign.js +150 -14
  18. package/dist/campaign.js.map +1 -1
  19. package/dist/chunks/analytics-service-B9IfG6ox.js +271 -0
  20. package/dist/chunks/analytics-service-B9IfG6ox.js.map +1 -0
  21. package/dist/chunks/analytics-service-DwkeBB08.cjs +274 -0
  22. package/dist/chunks/analytics-service-DwkeBB08.cjs.map +1 -0
  23. package/dist/chunks/{pers-sdk-DnLw822h.js → pers-sdk-CAM0iQyK.js} +1203 -267
  24. package/dist/chunks/pers-sdk-CAM0iQyK.js.map +1 -0
  25. package/dist/chunks/{pers-sdk-D5lE9ZFW.cjs → pers-sdk-Di_R6AiT.cjs} +1207 -268
  26. package/dist/chunks/pers-sdk-Di_R6AiT.cjs.map +1 -0
  27. package/dist/chunks/{redemption-service-D-hBqh42.js → redemption-service-CQtTLdic.js} +32 -10
  28. package/dist/chunks/redemption-service-CQtTLdic.js.map +1 -0
  29. package/dist/chunks/{redemption-service-rMB6T2W5.cjs → redemption-service-DsH7sRdv.cjs} +32 -10
  30. package/dist/chunks/redemption-service-DsH7sRdv.cjs.map +1 -0
  31. package/dist/chunks/{transaction-request.builder-C1vVVFto.js → transaction-request.builder-C8ahJYwi.js} +122 -70
  32. package/dist/chunks/transaction-request.builder-C8ahJYwi.js.map +1 -0
  33. package/dist/chunks/{transaction-request.builder-BpgtuMMq.cjs → transaction-request.builder-CkYd5bl6.cjs} +122 -70
  34. package/dist/chunks/transaction-request.builder-CkYd5bl6.cjs.map +1 -0
  35. package/dist/core/auth/auth-provider.interface.d.ts +1 -0
  36. package/dist/core/auth/auth-provider.interface.d.ts.map +1 -1
  37. package/dist/core/auth/default-auth-provider.d.ts +2 -0
  38. package/dist/core/auth/default-auth-provider.d.ts.map +1 -1
  39. package/dist/core/auth/refresh-manager.d.ts +2 -0
  40. package/dist/core/auth/refresh-manager.d.ts.map +1 -1
  41. package/dist/core/auth/services/auth-service.d.ts.map +1 -1
  42. package/dist/core/auth/token-storage.d.ts +2 -1
  43. package/dist/core/auth/token-storage.d.ts.map +1 -1
  44. package/dist/core/pers-api-client.d.ts.map +1 -1
  45. package/dist/core/pers-config.d.ts +0 -18
  46. package/dist/core/pers-config.d.ts.map +1 -1
  47. package/dist/core.cjs +5 -4
  48. package/dist/core.cjs.map +1 -1
  49. package/dist/core.js +4 -4
  50. package/dist/index.cjs +13 -6
  51. package/dist/index.cjs.map +1 -1
  52. package/dist/index.d.ts +1 -0
  53. package/dist/index.d.ts.map +1 -1
  54. package/dist/index.js +5 -5
  55. package/dist/managers/analytics-manager.d.ts +165 -2
  56. package/dist/managers/analytics-manager.d.ts.map +1 -1
  57. package/dist/managers/campaign-manager.d.ts +180 -30
  58. package/dist/managers/campaign-manager.d.ts.map +1 -1
  59. package/dist/managers/index.d.ts +1 -0
  60. package/dist/managers/index.d.ts.map +1 -1
  61. package/dist/managers/redemption-manager.d.ts +52 -2
  62. package/dist/managers/redemption-manager.d.ts.map +1 -1
  63. package/dist/managers/transaction-manager.d.ts +66 -131
  64. package/dist/managers/transaction-manager.d.ts.map +1 -1
  65. package/dist/managers/trigger-source-manager.d.ts +194 -0
  66. package/dist/managers/trigger-source-manager.d.ts.map +1 -0
  67. package/dist/managers/user-manager.d.ts +38 -7
  68. package/dist/managers/user-manager.d.ts.map +1 -1
  69. package/dist/node.cjs +4 -4
  70. package/dist/node.js +4 -4
  71. package/dist/package.json +2 -2
  72. package/dist/pers-sdk.d.ts +68 -23
  73. package/dist/pers-sdk.d.ts.map +1 -1
  74. package/dist/redemption/api/redemption-api.d.ts +8 -4
  75. package/dist/redemption/api/redemption-api.d.ts.map +1 -1
  76. package/dist/redemption/services/redemption-service.d.ts +7 -3
  77. package/dist/redemption/services/redemption-service.d.ts.map +1 -1
  78. package/dist/redemption.cjs +1 -1
  79. package/dist/redemption.js +1 -1
  80. package/dist/transaction/api/transaction-api.d.ts +37 -42
  81. package/dist/transaction/api/transaction-api.d.ts.map +1 -1
  82. package/dist/transaction/models/index.d.ts +21 -0
  83. package/dist/transaction/models/index.d.ts.map +1 -1
  84. package/dist/transaction/services/transaction-service.d.ts +10 -15
  85. package/dist/transaction/services/transaction-service.d.ts.map +1 -1
  86. package/dist/transaction.cjs +1 -1
  87. package/dist/transaction.js +1 -1
  88. package/dist/trigger-source/api/trigger-source-api.d.ts +86 -0
  89. package/dist/trigger-source/api/trigger-source-api.d.ts.map +1 -0
  90. package/dist/trigger-source/index.d.ts +9 -0
  91. package/dist/trigger-source/index.d.ts.map +1 -0
  92. package/dist/trigger-source/services/trigger-source-service.d.ts +42 -0
  93. package/dist/trigger-source/services/trigger-source-service.d.ts.map +1 -0
  94. package/dist/user/api/user-api.d.ts +26 -1
  95. package/dist/user/api/user-api.d.ts.map +1 -1
  96. package/dist/user/services/user-service.d.ts +3 -1
  97. package/dist/user/services/user-service.d.ts.map +1 -1
  98. package/dist/user.cjs +34 -4
  99. package/dist/user.cjs.map +1 -1
  100. package/dist/user.js +34 -4
  101. package/dist/user.js.map +1 -1
  102. package/package.json +2 -2
  103. package/dist/chunks/pers-sdk-D5lE9ZFW.cjs.map +0 -1
  104. package/dist/chunks/pers-sdk-DnLw822h.js.map +0 -1
  105. package/dist/chunks/redemption-service-D-hBqh42.js.map +0 -1
  106. package/dist/chunks/redemption-service-rMB6T2W5.cjs.map +0 -1
  107. package/dist/chunks/transaction-request.builder-BpgtuMMq.cjs.map +0 -1
  108. package/dist/chunks/transaction-request.builder-C1vVVFto.js.map +0 -1
@@ -1,9 +1,8 @@
1
1
  import { PersApiClient } from '../core/pers-api-client';
2
2
  import { PersEventEmitter } from '../core/events';
3
- import { TransactionService } from '../transaction';
4
- import { PaginatedResponseDTO, TransactionAnalyticsRequestDTO, TransactionAnalyticsResponseDTO, TransactionPaginationRequestDTO, TransactionRequestResponseDTO, TransactionRole } from '@explorins/pers-shared';
3
+ import { TransactionService, TransactionQueryOptions } from '../transaction';
4
+ import { PaginatedResponseDTO, TransactionAnalyticsRequestDTO, TransactionAnalyticsResponseDTO, TransactionPaginationRequestDTO, TransactionRequestResponseDTO, TransactionIncludeRelation } from '@explorins/pers-shared';
5
5
  import { AccountSelectorDTO, TransactionDTO, TransactionRequestDTO, TransactionSubmissionRequestDTO } from '../shared/interfaces/pers-shared-lib.interfaces';
6
- import { PaginationOptions } from '../shared/utils/pagination-utils';
7
6
  /**
8
7
  * Transaction Manager - Clean, high-level interface for transaction operations
9
8
  *
@@ -50,8 +49,8 @@ import { PaginationOptions } from '../shared/utils/pagination-utils';
50
49
  *
51
50
  * @example Administrative Reporting
52
51
  * ```typescript
53
- * // Admin: Get all tenant transactions for analysis
54
- * const allTransactions = await sdk.transactions.getTenantTransactions();
52
+ * // Admin: Get paginated transactions for analysis
53
+ * const allTransactions = await sdk.transactions.getPaginatedTransactions({ page: 1, limit: 100 });
55
54
  *
56
55
  * // Export transaction data
57
56
  * const csvBlob = await sdk.transactions.exportTransactionsCSV();
@@ -72,13 +71,18 @@ export declare class TransactionManager {
72
71
  * Provides complete transaction audit trail and verification data.
73
72
  *
74
73
  * @param transactionId - Unique transaction identifier
74
+ * @param include - Optional relations to include (sender, recipient, business) for enriched entity data
75
75
  * @returns Promise resolving to complete transaction data
76
76
  * @throws {PersApiError} When transaction with specified ID is not found or access denied
77
77
  *
78
78
  * @example
79
79
  * ```typescript
80
80
  * try {
81
- * const transaction = await sdk.transactions.getTransactionById('txn-abc123');
81
+ * // Get transaction with enriched sender/recipient data
82
+ * const transaction = await sdk.transactions.getTransactionById(
83
+ * 'txn-abc123',
84
+ * ['sender', 'recipient', 'business']
85
+ * );
82
86
  *
83
87
  * console.log('Transaction Details:');
84
88
  * console.log('ID:', transaction.id);
@@ -91,16 +95,19 @@ export declare class TransactionManager {
91
95
  * console.log('Description:', transaction.description);
92
96
  * }
93
97
  *
94
- * if (transaction.business) {
95
- * console.log('Business:', transaction.business.displayName);
98
+ * // Access enriched sender data
99
+ * if (transaction.included?.sender) {
100
+ * console.log('Sender:', transaction.included.sender);
96
101
  * }
97
102
  *
98
- * // Show token movements
99
- * if (transaction.tokenTransfers?.length) {
100
- * console.log('\nToken Transfers:');
101
- * transaction.tokenTransfers.forEach(transfer => {
102
- * console.log(`${transfer.amount} ${transfer.token.symbol} ${transfer.direction}`);
103
- * });
103
+ * // Access enriched recipient data
104
+ * if (transaction.included?.recipient) {
105
+ * console.log('Recipient:', transaction.included.recipient);
106
+ * }
107
+ *
108
+ * // Access enriched business data
109
+ * if (transaction.included?.engagedBusiness) {
110
+ * console.log('Business:', transaction.included.engagedBusiness.displayName);
104
111
  * }
105
112
  *
106
113
  * // Show blockchain confirmation
@@ -113,7 +120,7 @@ export declare class TransactionManager {
113
120
  * }
114
121
  * ```
115
122
  */
116
- getTransactionById(transactionId: string): Promise<TransactionDTO>;
123
+ getTransactionById(transactionId: string, include?: TransactionIncludeRelation[]): Promise<TransactionDTO>;
117
124
  /**
118
125
  * Create a new transaction
119
126
  *
@@ -197,147 +204,61 @@ export declare class TransactionManager {
197
204
  /**
198
205
  * Get user's transaction history
199
206
  *
200
- * Retrieves transaction history for the authenticated user, filtered by
201
- * transaction role. Provides chronological view of all user's loyalty
207
+ * Retrieves transaction history for the authenticated user with comprehensive
208
+ * filtering options. Provides chronological view of all user's loyalty
202
209
  * activities including purchases, rewards, redemptions, and transfers.
210
+ * Optionally enrich with related entities (sender, recipient, business).
203
211
  *
204
- * @param role - Optional role filter (TransactionRole.SENDER, TransactionRole.RECIPIENT). If undefined, returns all user transactions
205
- * @param limit - Maximum number of transactions to return (default: 1000)
206
- * @returns Promise resolving to array of user's transactions
212
+ * @param options - Query options including filters, pagination, and include relations
213
+ * @returns Promise resolving to paginated transaction data with optional included entities
207
214
  *
208
215
  * @example All Transactions
209
216
  * ```typescript
210
- * const allTransactions = await sdk.transactions.getUserTransactionHistory('ALL');
217
+ * const result = await sdk.transactions.getUserTransactionHistory();
211
218
  *
212
- * console.log(` Transaction History (${allTransactions.length} transactions):`);
219
+ * console.log(`Transaction History (${result.data.length} of ${result.pagination.total} transactions)`);
213
220
  *
214
- * allTransactions.forEach((transaction, index) => {
221
+ * result.data.forEach((transaction, index) => {
215
222
  * const date = new Date(transaction.createdAt).toLocaleDateString();
216
223
  * console.log(`\n${index + 1}. ${transaction.type} - ${date}`);
217
224
  * console.log(` ${transaction.description || 'No description'}`);
218
225
  * console.log(` Status: ${transaction.status}`);
219
- *
220
- * if (transaction.amount && transaction.currency) {
221
- * console.log(` Amount: ${transaction.amount} ${transaction.currency}`);
222
- * }
223
- *
224
- * if (transaction.business) {
225
- * console.log(` Business: ${transaction.business.displayName}`);
226
- * }
227
226
  * });
228
227
  * ```
229
228
  *
230
- * @example Filtered by Type
229
+ * @example Filter by Role and Status
231
230
  * ```typescript
232
- * // Get only purchase transactions
233
- * const purchases = await sdk.transactions.getUserTransactionHistory('PURCHASE');
234
- *
235
- * let totalSpent = 0;
236
- * let totalRewards = 0;
237
- *
238
- * purchases.forEach(purchase => {
239
- * if (purchase.amount) {
240
- * totalSpent += purchase.amount;
241
- * }
242
- *
243
- * if (purchase.tokensEarned?.length) {
244
- * purchase.tokensEarned.forEach(reward => {
245
- * totalRewards += reward.amount;
246
- * });
247
- * }
231
+ * // Get only completed sent transactions
232
+ * const sent = await sdk.transactions.getUserTransactionHistory({
233
+ * role: TransactionRole.SENDER,
234
+ * status: TransactionStatus.COMPLETED,
235
+ * include: ['recipient', 'business'],
236
+ * page: 1,
237
+ * limit: 50
248
238
  * });
249
239
  *
250
- * console.log('Purchase Summary:');
251
- * console.log(`Total purchases: ${purchases.length}`);
252
- * console.log(`Total spent: $${totalSpent.toFixed(2)}`);
253
- * console.log(`Total rewards earned: ${totalRewards} points`);
254
- * ```
255
- *
256
- * @example Recent Activity
257
- * ```typescript
258
- * const recentTransactions = await sdk.transactions.getUserTransactionHistory('ALL');
259
- *
260
- * // Filter to last 30 days
261
- * const thirtyDaysAgo = new Date(Date.now() - 30 * 24 * 60 * 60 * 1000);
262
- * const recentActivity = recentTransactions.filter(t =>
263
- * new Date(t.createdAt) > thirtyDaysAgo
264
- * );
265
- *
266
- * console.log(`Recent Activity (${recentActivity.length} transactions in last 30 days):`);
267
- *
268
- * // Group by type
269
- * const activityByType = recentActivity.reduce((acc, t) => {
270
- * acc[t.type] = (acc[t.type] || 0) + 1;
271
- * return acc;
272
- * }, {});
273
- *
274
- * Object.entries(activityByType).forEach(([type, count]) => {
275
- * console.log(`${type}: ${count} transactions`);
240
+ * sent.data.forEach(tx => {
241
+ * console.log(`Sent to: ${tx.included?.recipient?.displayName || tx.recipientAddress}`);
276
242
  * });
277
243
  * ```
278
- */
279
- getUserTransactionHistory(role?: TransactionRole, options?: PaginationOptions): Promise<PaginatedResponseDTO<TransactionDTO>>;
280
- /**
281
- * Admin: Get all tenant transactions
282
- *
283
- * Retrieves all transactions across the entire tenant/organization for
284
- * comprehensive reporting and analysis. This operation requires administrator
285
- * privileges and provides system-wide transaction visibility.
286
244
  *
287
- * @param limit - Maximum number of transactions to return (default: 1000)
288
- * @returns Promise resolving to array of all tenant transactions
289
- * @throws {PersApiError} When not authenticated as administrator
290
- *
291
- * @example
245
+ * @example Filter by Trigger Process (Campaign/Redemption)
292
246
  * ```typescript
293
- * // Admin operation - comprehensive transaction analysis
294
- * const allTransactions = await sdk.transactions.getTenantTransactions();
295
- *
296
- * console.log(`Tenant Transaction Overview:`);
297
- * console.log(`Total transactions: ${allTransactions.length}`);
298
- *
299
- * // Analyze by status
300
- * const statusCounts = allTransactions.reduce((acc, t) => {
301
- * acc[t.status] = (acc[t.status] || 0) + 1;
302
- * return acc;
303
- * }, {});
304
- *
305
- * console.log('\nBy status:');
306
- * Object.entries(statusCounts).forEach(([status, count]) => {
307
- * console.log(`${status}: ${count} transactions`);
247
+ * // Get all transactions triggered by a specific campaign claim
248
+ * const claimTxs = await sdk.transactions.getUserTransactionHistory({
249
+ * triggerProcessId: 'claim-abc123',
250
+ * include: ['sender', 'recipient', 'business']
308
251
  * });
309
252
  *
310
- * // Analyze by type
311
- * const typeCounts = allTransactions.reduce((acc, t) => {
312
- * acc[t.type] = (acc[t.type] || 0) + 1;
313
- * return acc;
314
- * }, {});
315
- *
316
- * console.log('\nBy type:');
317
- * Object.entries(typeCounts).forEach(([type, count]) => {
318
- * console.log(`${type}: ${count} transactions`);
253
+ * claimTxs.data.forEach(tx => {
254
+ * console.log('Transaction from claim:', tx.id);
255
+ * if (tx.included?.engagedBusiness) {
256
+ * console.log('Business:', tx.included.engagedBusiness.displayName);
257
+ * }
319
258
  * });
320
- *
321
- * // Calculate volume metrics
322
- * const totalVolume = allTransactions.reduce((sum, t) =>
323
- * sum + (t.amount || 0), 0
324
- * );
325
- *
326
- * const avgTransactionSize = totalVolume / allTransactions.length;
327
- *
328
- * console.log('\nVolume metrics:');
329
- * console.log(`Total volume: $${totalVolume.toFixed(2)}`);
330
- * console.log(`Average transaction: $${avgTransactionSize.toFixed(2)}`);
331
- *
332
- * // Recent activity analysis
333
- * const last24Hours = allTransactions.filter(t =>
334
- * new Date(t.createdAt) > new Date(Date.now() - 24 * 60 * 60 * 1000)
335
- * );
336
- *
337
- * console.log(`\n⏰ Last 24 hours: ${last24Hours.length} transactions`);
338
259
  * ```
339
260
  */
340
- getTenantTransactions(options?: PaginationOptions): Promise<PaginatedResponseDTO<TransactionDTO>>;
261
+ getUserTransactionHistory(options?: TransactionQueryOptions): Promise<PaginatedResponseDTO<TransactionDTO>>;
341
262
  /**
342
263
  * Admin: Get paginated transactions
343
264
  *
@@ -400,8 +321,22 @@ export declare class TransactionManager {
400
321
  * console.log(`$${transaction.amount} - ${transaction.business?.displayName}`);
401
322
  * });
402
323
  * ```
324
+ *
325
+ * @example With Included Relations
326
+ * ```typescript
327
+ * // Include sender and recipient entities
328
+ * const result = await sdk.transactions.getPaginatedTransactions(
329
+ * { page: 1, limit: 50 },
330
+ * ['sender', 'recipient', 'business']
331
+ * );
332
+ *
333
+ * result.data.forEach(tx => {
334
+ * if (tx.included?.sender) console.log('From:', tx.included.sender);
335
+ * if (tx.included?.recipient) console.log('To:', tx.included.recipient);
336
+ * });
337
+ * ```
403
338
  */
404
- getPaginatedTransactions(params: TransactionPaginationRequestDTO): Promise<PaginatedResponseDTO<TransactionDTO>>;
339
+ getPaginatedTransactions(params: TransactionPaginationRequestDTO, include?: TransactionIncludeRelation[]): Promise<PaginatedResponseDTO<TransactionDTO>>;
405
340
  /**
406
341
  * Admin: Export transactions as CSV
407
342
  *
@@ -1 +1 @@
1
- {"version":3,"file":"transaction-manager.d.ts","sourceRoot":"","sources":["../../src/managers/transaction-manager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AACxD,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,EAAkB,kBAAkB,EAAE,MAAM,gBAAgB,CAAC;AACpE,OAAO,EAAE,oBAAoB,EAAE,8BAA8B,EAAE,+BAA+B,EAAE,+BAA+B,EAAE,6BAA6B,EAAE,eAAe,EAAE,MAAM,wBAAwB,CAAC;AAChN,OAAO,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AM,GAAG,OAAO,CAAC,6BAA6B,CAAC;IAI/F;;;;;;;;OAQG;IACG,8BAA8B,CAAC,OAAO,EAAE,qBAAqB,GAAG,OAAO,CAAC,6BAA6B,CAAC;IAI5G;;;;;;;OAOG;IACG,uBAAuB,CAAC,YAAY,EAAE,+BAA+B,GAAG,OAAO,CAAC,6BAA6B,CAAC;IAapH;;;;;;;OAOG;IACG,yBAAyB,CAAC,eAAe,EAAE,kBAAkB,GAAG,OAAO,CAAC,oBAAoB,CAAC,cAAc,CAAC,CAAC;IAInH;;;;;;;OAOG;IACG,4BAA4B,CAAC,eAAe,EAAE,kBAAkB,GAAG,OAAO,CAAC,oBAAoB,CAAC,cAAc,CAAC,CAAC;IAItH;;;;;;;;OAQG;IACG,uBAAuB,CAAC,gBAAgB,EAAE,8BAA8B,GAAG,OAAO,CAAC,+BAA+B,CAAC;IAIzH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OAkCG;IACH,qBAAqB,IAAI,kBAAkB;CAG5C"}
@@ -0,0 +1,194 @@
1
+ import { PaginatedResponseDTO, SortOrder, TriggerSourceDTO, TriggerSourceCreateRequestDTO, TriggerSourceType } from '@explorins/pers-shared';
2
+ import { PersApiClient } from '../core/pers-api-client';
3
+ import { PersEventEmitter } from '../core/events';
4
+ import { TriggerSourceService } from '../trigger-source';
5
+ /**
6
+ * TriggerSource Manager - Clean, high-level interface for trigger source operations
7
+ *
8
+ * Manages trigger sources which are physical or digital activation points for campaigns:
9
+ * - QR_CODE: Scannable QR codes
10
+ * - NFC_TAG: NFC tap points
11
+ * - GPS_GEOFENCE: Location-based triggers
12
+ * - API_WEBHOOK: External system integration
13
+ * - TRANSACTION: Purchase/payment based triggers
14
+ *
15
+ * Trigger sources are independent entities that can be created, managed, and then
16
+ * assigned to campaigns. This separation allows reuse and flexible campaign configuration.
17
+ *
18
+ * @group Managers
19
+ * @category TriggerSource Management
20
+ *
21
+ * @example Basic TriggerSource Operations
22
+ * ```typescript
23
+ * // Get all QR code trigger sources
24
+ * const qrSources = await sdk.triggerSources.getAll({ type: 'QR_CODE' });
25
+ *
26
+ * // Create a new QR code trigger source
27
+ * const source = await sdk.triggerSources.create({
28
+ * type: 'QR_CODE',
29
+ * name: 'Store Entrance QR',
30
+ * businessId: 'business-123'
31
+ * });
32
+ *
33
+ * // Assign to campaign (via CampaignManager)
34
+ * await sdk.campaigns.assignTriggerSource('campaign-456', source.id);
35
+ * ```
36
+ */
37
+ export declare class TriggerSourceManager {
38
+ private apiClient;
39
+ private events?;
40
+ private triggerSourceService;
41
+ constructor(apiClient: PersApiClient, events?: PersEventEmitter | undefined);
42
+ /**
43
+ * Get trigger sources with optional filters and pagination
44
+ *
45
+ * Retrieves trigger sources (QR codes, NFC tags, GPS geofences, webhooks, etc.)
46
+ * that can be used to activate campaigns. Supports filtering by type, business,
47
+ * campaign association, and active status.
48
+ *
49
+ * @param options - Filter and pagination options
50
+ * @returns Promise resolving to paginated trigger sources
51
+ *
52
+ * @example
53
+ * ```typescript
54
+ * // Get all QR code trigger sources
55
+ * const qrSources = await sdk.triggerSources.getAll({ type: 'QR_CODE' });
56
+ *
57
+ * // Get trigger sources for a specific business
58
+ * const businessSources = await sdk.triggerSources.getAll({
59
+ * businessId: 'business-123',
60
+ * active: true,
61
+ * page: 1,
62
+ * limit: 20
63
+ * });
64
+ *
65
+ * // Get trigger sources assigned to a campaign
66
+ * const campaignSources = await sdk.triggerSources.getAll({
67
+ * campaignId: 'campaign-456'
68
+ * });
69
+ * ```
70
+ */
71
+ getAll(options?: {
72
+ type?: TriggerSourceType;
73
+ businessId?: string;
74
+ campaignId?: string;
75
+ active?: boolean;
76
+ page?: number;
77
+ limit?: number;
78
+ sortBy?: 'name' | 'createdAt' | 'type';
79
+ sortOrder?: SortOrder;
80
+ }): Promise<PaginatedResponseDTO<TriggerSourceDTO>>;
81
+ /**
82
+ * Get trigger source by ID
83
+ *
84
+ * Retrieves detailed information for a specific trigger source including
85
+ * its type, location, metadata, and usage analytics.
86
+ *
87
+ * @param triggerSourceId - UUID of the trigger source
88
+ * @returns Promise resolving to trigger source details
89
+ * @throws {PersApiError} When trigger source with specified ID is not found
90
+ *
91
+ * @example
92
+ * ```typescript
93
+ * const source = await sdk.triggerSources.getById('source-123');
94
+ *
95
+ * console.log('Trigger Source:', source.name);
96
+ * console.log('Type:', source.type);
97
+ * console.log('Active:', source.isActive);
98
+ *
99
+ * if (source.coordsLatitude && source.coordsLongitude) {
100
+ * console.log('Location:', source.coordsLatitude, source.coordsLongitude);
101
+ * }
102
+ * ```
103
+ */
104
+ getById(triggerSourceId: string): Promise<TriggerSourceDTO>;
105
+ /**
106
+ * Admin: Create a new trigger source
107
+ *
108
+ * Creates a new trigger source (QR code, NFC tag, GPS geofence, webhook, or
109
+ * transaction-based trigger) that can be assigned to campaigns. Requires
110
+ * administrator privileges.
111
+ *
112
+ * @param triggerSource - Trigger source creation data
113
+ * @returns Promise resolving to created trigger source
114
+ * @throws {PersApiError} When not authenticated as admin or validation fails
115
+ *
116
+ * @example
117
+ * ```typescript
118
+ * // Create a QR code trigger source
119
+ * const qrSource = await sdk.triggerSources.create({
120
+ * type: 'QR_CODE',
121
+ * name: 'Store Entrance QR',
122
+ * description: 'QR code at main entrance',
123
+ * businessId: 'business-123',
124
+ * coordsLatitude: 47.6062,
125
+ * coordsLongitude: -122.3321
126
+ * });
127
+ *
128
+ * // Create an NFC tag trigger source
129
+ * const nfcSource = await sdk.triggerSources.create({
130
+ * type: 'NFC_TAG',
131
+ * name: 'Product Display NFC',
132
+ * metadata: { productId: 'SKU-12345' }
133
+ * });
134
+ *
135
+ * // Create a GPS geofence trigger source
136
+ * const geoSource = await sdk.triggerSources.create({
137
+ * type: 'GPS_GEOFENCE',
138
+ * name: 'Store Area',
139
+ * coordsLatitude: 47.6062,
140
+ * coordsLongitude: -122.3321,
141
+ * metadata: { radiusMeters: 100 }
142
+ * });
143
+ * ```
144
+ */
145
+ create(triggerSource: TriggerSourceCreateRequestDTO): Promise<TriggerSourceDTO>;
146
+ /**
147
+ * Admin: Update a trigger source
148
+ *
149
+ * Updates an existing trigger source's configuration. All fields are optional;
150
+ * only provided fields will be updated. Requires administrator privileges.
151
+ *
152
+ * @param triggerSourceId - UUID of the trigger source to update
153
+ * @param triggerSource - Updated trigger source data (partial)
154
+ * @returns Promise resolving to updated trigger source
155
+ * @throws {PersApiError} When not authenticated as admin or trigger source not found
156
+ *
157
+ * @example
158
+ * ```typescript
159
+ * // Update trigger source name and location
160
+ * const updated = await sdk.triggerSources.update('source-123', {
161
+ * name: 'Updated Store Entrance QR',
162
+ * description: 'New description',
163
+ * coordsLatitude: 47.6063,
164
+ * coordsLongitude: -122.3322
165
+ * });
166
+ * ```
167
+ */
168
+ update(triggerSourceId: string, triggerSource: Partial<TriggerSourceCreateRequestDTO>): Promise<TriggerSourceDTO>;
169
+ /**
170
+ * Admin: Delete a trigger source
171
+ *
172
+ * Soft deletes a trigger source, making it inactive. The trigger source will
173
+ * be removed from any campaigns it was assigned to. Requires administrator
174
+ * privileges.
175
+ *
176
+ * @param triggerSourceId - UUID of the trigger source to delete
177
+ * @returns Promise resolving to success status
178
+ * @throws {PersApiError} When not authenticated as admin or trigger source not found
179
+ *
180
+ * @example
181
+ * ```typescript
182
+ * const success = await sdk.triggerSources.delete('source-123');
183
+ * console.log('Trigger source deleted:', success);
184
+ * ```
185
+ */
186
+ delete(triggerSourceId: string): Promise<boolean>;
187
+ /**
188
+ * Get the full trigger source service for advanced operations
189
+ *
190
+ * @returns TriggerSourceService instance with full API access
191
+ */
192
+ getTriggerSourceService(): TriggerSourceService;
193
+ }
194
+ //# sourceMappingURL=trigger-source-manager.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"trigger-source-manager.d.ts","sourceRoot":"","sources":["../../src/managers/trigger-source-manager.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,oBAAoB,EACpB,SAAS,EACT,gBAAgB,EAChB,6BAA6B,EAC7B,iBAAiB,EAClB,MAAM,wBAAwB,C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;;;;;;OAgBG;IACG,MAAM,CAAC,eAAe,EAAE,MAAM,GAAG,OAAO,CAAC,OAAO,CAAC;IAavD;;;;OAIG;IACH,uBAAuB,IAAI,oBAAoB;CAGhD"}
@@ -184,25 +184,56 @@ export declare class UserManager {
184
184
  * requires administrator privileges and returns full user profiles including
185
185
  * private information.
186
186
  *
187
- * @returns Promise resolving to array of all users with complete data
187
+ * @param options - Pagination and sorting options
188
+ * @param options.page - Page number (1-based, default: 1)
189
+ * @param options.limit - Items per page (default: 50)
190
+ * @param options.sortBy - Sort by field. Supported fields:
191
+ * - 'id', 'email', 'identifierEmail', 'firstName', 'lastName'
192
+ * - 'externalId', 'accountAddress', 'isActive'
193
+ * - 'createdAt', 'updatedAt'
194
+ * - Default: 'createdAt'
195
+ * @param options.sortOrder - Sort order: SortOrder.ASC or SortOrder.DESC (default: DESC)
196
+ * @param search - Optional search query to filter users
197
+ * @returns Promise resolving to paginated users with complete data
188
198
  * @throws {PersApiError} When not authenticated as admin
189
199
  *
190
- * @example
200
+ * @example Basic Usage
191
201
  * ```typescript
192
202
  * // Admin operation - requires admin authentication
193
203
  * try {
194
- * const allUsers = await sdk.users.getAllUsers();
195
- * console.log(`Total users: ${allUsers.length}`);
204
+ * const result = await sdk.users.getAllUsers();
205
+ * console.log(`Total users: ${result.pagination.total}`);
196
206
  *
197
- * allUsers.forEach(user => {
198
- * console.log(`${user.name} - ${user.email} - Active: ${user.isActive}`);
207
+ * result.data.forEach(user => {
208
+ * console.log(`${user.firstName} - ${user.email} - Active: ${user.isActive}`);
199
209
  * });
200
210
  * } catch (error) {
201
211
  * console.log('Admin access required');
202
212
  * }
203
213
  * ```
214
+ *
215
+ * @example With Sorting
216
+ * ```typescript
217
+ * import { SortOrder } from '@explorins/pers-sdk';
218
+ *
219
+ * // Get users sorted by email ascending
220
+ * const result = await sdk.users.getAllUsers({
221
+ * page: 1,
222
+ * limit: 20,
223
+ * sortBy: 'email',
224
+ * sortOrder: SortOrder.ASC
225
+ * });
226
+ *
227
+ * // Get users sorted by creation date (newest first)
228
+ * const recent = await sdk.users.getAllUsers({
229
+ * page: 1,
230
+ * limit: 10,
231
+ * sortBy: 'createdAt',
232
+ * sortOrder: SortOrder.DESC
233
+ * });
234
+ * ```
204
235
  */
205
- getAllUsers(options?: PaginationOptions): Promise<PaginatedResponseDTO<UserDTO>>;
236
+ getAllUsers(options?: PaginationOptions, search?: string): Promise<PaginatedResponseDTO<UserDTO>>;
206
237
  /**
207
238
  * Business/Admin: Create or update a user
208
239
  *
@@ -1 +1 @@
1
- {"version":3,"file":"user-manager.d.ts","sourceRoot":"","sources":["../../src/managers/user-manager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,yBAAyB,CAAC;AACxD,OAAO,EAAE,gBAAgB,EAAE,MAAM,gBAAgB,CAAC;AAClD,OAAO,EAAW,WAAW,EAAE,MAAM,SAAS,CAAC;AAC/C,OAAO,EAAE,oBAAoB,EAAE,MAAM,gBAAgB,CAAC;AACtD,OAAO,KAAK,EAAE,OAAO,EAAE,oBAAoB,EAAE,MAAM,iDAAiD,CAAC;AACrG,OAAO,EAAE,oBAAoB,EAAE,MAAM,wBAAwB,CAAC;AAC9D,OAAO,EAAE,iBAAiB,EAAE,MAAM,kCAAkC,CAAC;AAErE;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkDG;AACH,qBAAa,WAAW;IAIpB,OAAO,CAAC,SAAS;IACjB,OAAO,CAAC,MAAM,CAAC;IAJjB,OAAO,CAAC,WAAW,CAAc;gBAGvB,SAAS,EAAE,aAAa,EACxB,MAAM,CAAC,8BAAkB;IAMnC;;;;;;;;;;;;;;;;;;;;OAoBG;IACG,cAAc,IAAI,OAAO,CAAC,OAAO,CAAC;IAIxC;;;;;;;;;;;;;;;;;;;;;;;;;;OA0BG;IACG,iBAAiB,CAAC,QAAQ,EAAE,oBAAoB,GAAG,OAAO,CAAC,OAAO,CAAC;IAazE;;;;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IAIvG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;OA8BG;IACG,kBAAkB,CAAC,QAAQ,EAAE,oBAAoB,GAAG,OAAO,CAAC,OAAO,CAAC;IAI1E;;;;;;;;;;;;;;;;;;;;OAoBG;IACG,mBAAmB,CAAC,KAAK,EAAE,oBAAoB,EAAE,GAAG,OAAO,CAAC,OAAO,EAAE,CAAC;IAI5E;;;;;;;;;;;;;;;;;;;;;;;;OAwBG;IACG,UAAU,CAAC,MAAM,EAAE,MAAM,EAAE,QAAQ,EAAE,oBAAoB,GAAG,OAAO,CAAC,OAAO,CAAC;IAIlF;;;;;;;;;;;;;;;;;;;;;;;;;;OA0BG;IACG,gBAAgB,CAAC,IAAI,EAAE,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC;IAIvD;;;;;;;;;;;;;;;OAeG;IACH,cAAc,IAAI,WAAW;CAI9B"}
package/dist/node.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var persSdk = require('./chunks/pers-sdk-D5lE9ZFW.cjs');
3
+ var persSdk = require('./chunks/pers-sdk-Di_R6AiT.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-B-g2JPVK.cjs');
@@ -10,11 +10,11 @@ require('./user-status.cjs');
10
10
  require('./chunks/token-service-BlbXrxnS.cjs');
11
11
  require('./chunks/business-membership-service-8KC_qRj7.cjs');
12
12
  require('./campaign.cjs');
13
- require('./chunks/redemption-service-rMB6T2W5.cjs');
14
- require('./chunks/transaction-request.builder-BpgtuMMq.cjs');
13
+ require('./chunks/redemption-service-DsH7sRdv.cjs');
14
+ require('./chunks/transaction-request.builder-CkYd5bl6.cjs');
15
15
  require('./chunks/payment-service-Bkw7ZXev.cjs');
16
16
  require('./chunks/tenant-service-fj-pkXTw.cjs');
17
- require('./analytics.cjs');
17
+ require('./chunks/analytics-service-DwkeBB08.cjs');
18
18
  require('./donation.cjs');
19
19
 
20
20
  /**
package/dist/node.js CHANGED
@@ -1,4 +1,4 @@
1
- import { j as StaticJwtAuthProvider, P as PersSDK } from './chunks/pers-sdk-DnLw822h.js';
1
+ import { j as StaticJwtAuthProvider, P as PersSDK } from './chunks/pers-sdk-CAM0iQyK.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';
@@ -9,11 +9,11 @@ import './user-status.js';
9
9
  import './chunks/token-service-Bfj6C0yz.js';
10
10
  import './chunks/business-membership-service-D6vaVQTR.js';
11
11
  import './campaign.js';
12
- import './chunks/redemption-service-D-hBqh42.js';
13
- import './chunks/transaction-request.builder-C1vVVFto.js';
12
+ import './chunks/redemption-service-CQtTLdic.js';
13
+ import './chunks/transaction-request.builder-C8ahJYwi.js';
14
14
  import './chunks/payment-service-IvM6rryM.js';
15
15
  import './chunks/tenant-service-CsRA3O2V.js';
16
- import './analytics.js';
16
+ import './chunks/analytics-service-B9IfG6ox.js';
17
17
  import './donation.js';
18
18
 
19
19
  /**
package/dist/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@explorins/pers-sdk",
3
- "version": "2.1.2",
3
+ "version": "2.1.4",
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",
@@ -127,7 +127,7 @@
127
127
  "publish-with-docs": "npm run clean && npm run build && npm run docs && npm version patch && npm publish"
128
128
  },
129
129
  "dependencies": {
130
- "@explorins/pers-shared": "^2.1.75",
130
+ "@explorins/pers-shared": "^2.1.92",
131
131
  "@explorins/web3-ts": "^0.3.77",
132
132
  "ethers": "^6.15.0"
133
133
  },