@saasicat/nest 0.27.0 → 1.0.0-rc.1

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 (103) hide show
  1. package/README.md +1 -1
  2. package/dist/.build-stamp +1 -0
  3. package/dist/_entries.cjs +460 -460
  4. package/dist/admin/index.d.cts +6 -6
  5. package/dist/admin/index.d.ts +6 -6
  6. package/dist/admin/index.js +3 -3
  7. package/dist/{admin-audit.service-9IqXMlZm.d.cts → admin-audit.service-4P3Djdxk.d.cts} +1 -1
  8. package/dist/{admin-audit.service-9IqXMlZm.d.ts → admin-audit.service-4P3Djdxk.d.ts} +1 -1
  9. package/dist/{admin-resources.module-DGgGSdzN.d.cts → admin-resources.module-CpvzcfCc.d.cts} +2 -2
  10. package/dist/{admin-resources.module-BY5r_1MG.d.ts → admin-resources.module-DF5_Q7RD.d.ts} +2 -2
  11. package/dist/{admin-stats.service-HUZIU448.d.cts → admin-stats.service-DfKupywR.d.cts} +3 -3
  12. package/dist/{admin-stats.service-Db2exT_d.d.ts → admin-stats.service-TYiSUwIR.d.ts} +3 -3
  13. package/dist/{aggregation-DP5zfKbU.d.ts → aggregation-B3CD0v_d.d.cts} +2 -2
  14. package/dist/{aggregation-mZ7WZROK.d.cts → aggregation-BFzW07DE.d.ts} +2 -2
  15. package/dist/billing/index.d.cts +13 -13
  16. package/dist/billing/index.d.ts +13 -13
  17. package/dist/billing/index.js +15 -15
  18. package/dist/catalog/index.d.cts +17 -5
  19. package/dist/catalog/index.d.ts +17 -5
  20. package/dist/catalog/index.js +12 -10
  21. package/dist/{catalog.module-D-_pQDNA.d.cts → catalog.module-BDDO6iwq.d.cts} +1 -1
  22. package/dist/{catalog.module-CQr1FpkI.d.ts → catalog.module-BTnMsE6u.d.ts} +1 -1
  23. package/dist/checkout-offer/index.d.cts +3 -3
  24. package/dist/checkout-offer/index.d.ts +3 -3
  25. package/dist/checkout-offer/index.js +2 -2
  26. package/dist/{checkout-offer.module-Ca3_TieR.d.ts → checkout-offer.module-CMtiQJTT.d.ts} +1 -1
  27. package/dist/{checkout-offer.module-DmlpPevf.d.cts → checkout-offer.module-CVpWrzbe.d.cts} +1 -1
  28. package/dist/{checkout-offer.service-BX51dljL.d.ts → checkout-offer.service-BLOv2HOo.d.cts} +1 -1
  29. package/dist/{checkout-offer.service-BX51dljL.d.cts → checkout-offer.service-BLOv2HOo.d.ts} +1 -1
  30. package/dist/{chunk-EBJJNTW6.js → chunk-57V6ZTI6.js} +1 -1
  31. package/dist/{chunk-37HEKVDH.js → chunk-7TVZI3KY.js} +11 -11
  32. package/dist/chunk-AOQJEYOL.js +20 -0
  33. package/dist/{chunk-3E6ONOMG.js → chunk-AU3OOREM.js} +2 -2
  34. package/dist/{chunk-H4DOTO7S.js → chunk-BGS4CWV2.js} +5 -5
  35. package/dist/{chunk-YYUXKLXK.js → chunk-I7GTA3RX.js} +2 -2
  36. package/dist/{chunk-7ZPFQXHM.js → chunk-IQTQLQD3.js} +5 -5
  37. package/dist/{chunk-CJFAOD7K.js → chunk-KFT5AIIH.js} +2 -2
  38. package/dist/{chunk-XTVAFJ3P.js → chunk-L23MLBEC.js} +7 -7
  39. package/dist/{chunk-SN5UOC43.js → chunk-LTT736P3.js} +15 -15
  40. package/dist/{chunk-WPUVJRIN.js → chunk-N3L3AICU.js} +11 -11
  41. package/dist/{chunk-MJ32VNZD.js → chunk-NARZ2WWK.js} +22 -22
  42. package/dist/{chunk-E56W4U2P.js → chunk-O2J2HDXA.js} +4 -4
  43. package/dist/{chunk-WKVBNTYC.js → chunk-OUDSQ3PU.js} +6 -6
  44. package/dist/{chunk-F4B2NJUZ.js → chunk-PK6C5R7B.js} +15 -15
  45. package/dist/{chunk-L4SUWH5B.js → chunk-QUZU2M33.js} +2 -2
  46. package/dist/{chunk-NYLON2VC.js → chunk-VBRYPU7V.js} +2 -2
  47. package/dist/{chunk-2JTISFUZ.js → chunk-VG2NU3CG.js} +11 -11
  48. package/dist/{chunk-7X5MSAIL.js → chunk-VNADKD5U.js} +23 -23
  49. package/dist/{chunk-UHD6FJBQ.js → chunk-W6YEIY4R.js} +46 -46
  50. package/dist/{chunk-5ZXBXYXU.js → chunk-WXYJHZCN.js} +3 -3
  51. package/dist/{chunk-6WL6VQ7Z.js → chunk-XBYAFEOR.js} +2 -2
  52. package/dist/{chunk-EHKMPP6J.js → chunk-XMA4XYC5.js} +40 -40
  53. package/dist/{chunk-B6IWLV7R.js → chunk-YZPVQUIW.js} +8 -8
  54. package/dist/{define-saasicat-CFxut1VR.d.cts → define-saasicat-B5RmWiD2.d.cts} +8 -8
  55. package/dist/{define-saasicat-3ois8t8s.d.ts → define-saasicat-DN-dRObd.d.ts} +8 -8
  56. package/dist/discovery/index.d.cts +4 -4
  57. package/dist/discovery/index.d.ts +4 -4
  58. package/dist/discovery/index.js +7 -7
  59. package/dist/{discovery.scanner-DLgEvuoy.d.cts → discovery.scanner-9cMqF95o.d.cts} +1 -1
  60. package/dist/{discovery.scanner-DLgEvuoy.d.ts → discovery.scanner-9cMqF95o.d.ts} +1 -1
  61. package/dist/{enforce-quota.interceptor-N80KC34N.d.cts → enforce-quota.interceptor-CnieZsdB.d.cts} +3 -3
  62. package/dist/{enforce-quota.interceptor-CYDNvAQz.d.ts → enforce-quota.interceptor-Cseo35Ki.d.ts} +3 -3
  63. package/dist/entitlement/index.d.cts +4 -4
  64. package/dist/entitlement/index.d.ts +4 -4
  65. package/dist/entitlement/index.js +8 -8
  66. package/dist/index.d.cts +23 -23
  67. package/dist/index.d.ts +23 -23
  68. package/dist/index.js +137 -136
  69. package/dist/{module-options-klrPnWGF.d.cts → module-options-CjeSSaBf.d.cts} +35 -35
  70. package/dist/{module-options-ByJL7FZm.d.ts → module-options-DtcJqwjv.d.ts} +35 -35
  71. package/dist/{plan-resolution-CFCoUkrE.d.cts → plan-resolution-Cgo_TR1H.d.cts} +1 -1
  72. package/dist/{plan-resolution-CFCoUkrE.d.ts → plan-resolution-Cgo_TR1H.d.ts} +1 -1
  73. package/dist/{plan-versions.service-B-YoE4SZ.d.ts → plan-versions.service-DChhbK6h.d.ts} +2 -2
  74. package/dist/{plan-versions.service-_saKzb50.d.cts → plan-versions.service-TPEtbN0r.d.cts} +2 -2
  75. package/dist/platform/index.d.cts +29 -29
  76. package/dist/platform/index.d.ts +29 -29
  77. package/dist/platform/index.js +32 -33
  78. package/dist/promo/index.d.cts +4 -4
  79. package/dist/promo/index.d.ts +4 -4
  80. package/dist/promo/index.js +4 -4
  81. package/dist/{module-BE17XFLg.d.ts → promo.module-BUKcUWDf.d.ts} +2 -2
  82. package/dist/{module-CHMIyWlf.d.cts → promo.module-BY2YHHLn.d.cts} +2 -2
  83. package/dist/{service-D48clObR.d.cts → promo.service-2qFgqF-a.d.cts} +1 -1
  84. package/dist/{service-D48clObR.d.ts → promo.service-2qFgqF-a.d.ts} +1 -1
  85. package/dist/registration/index.d.cts +3 -3
  86. package/dist/registration/index.d.ts +3 -3
  87. package/dist/registration/index.js +2 -2
  88. package/dist/subscription-contract/index.d.cts +3 -3
  89. package/dist/subscription-contract/index.d.ts +3 -3
  90. package/dist/subscription-contract/index.js +3 -3
  91. package/dist/{subscription-contract.module-B2uNvUJL.d.cts → subscription-contract.module-CEK8HS5-.d.cts} +1 -1
  92. package/dist/{subscription-contract.module-edyhBr4n.d.ts → subscription-contract.module-fDFdQ0jm.d.ts} +1 -1
  93. package/dist/{subscription-contract.service--cm47ZJJ.d.cts → subscription-contract.service-hD87MKyg.d.cts} +1 -1
  94. package/dist/{subscription-contract.service--cm47ZJJ.d.ts → subscription-contract.service-hD87MKyg.d.ts} +1 -1
  95. package/dist/{tenant-billing.controller-CAMMdfn1.d.cts → tenant-billing.controller-B6UTheK_.d.cts} +5 -5
  96. package/dist/{tenant-billing.controller-CYYK0CpT.d.ts → tenant-billing.controller-DpgHCT9r.d.ts} +5 -5
  97. package/dist/{tenant-billing.module-BxJS6fX4.d.cts → tenant-billing.module-BznC3XtW.d.cts} +1 -1
  98. package/dist/{tenant-billing.module-B0stLoJn.d.ts → tenant-billing.module-wUbsQSFG.d.ts} +1 -1
  99. package/dist/testing/index.d.cts +19 -19
  100. package/dist/testing/index.d.ts +19 -19
  101. package/dist/testing/index.js +33 -33
  102. package/package.json +5 -5
  103. package/dist/chunk-L4KTQ6CL.js +0 -20
package/dist/index.js CHANGED
@@ -1,4 +1,6 @@
1
- import "./chunk-HWGIMNWR.js";
1
+ import {
2
+ defineSaaSiCat
3
+ } from "./chunk-OYNHOY45.js";
2
4
  import {
3
5
  ACTIVATION_ORCHESTRATOR_TOKEN,
4
6
  BaseIpRateLimitGuard,
@@ -37,83 +39,20 @@ import {
37
39
  resolveModel,
38
40
  slugify,
39
41
  verifyOtpCode
40
- } from "./chunk-MJ32VNZD.js";
42
+ } from "./chunk-NARZ2WWK.js";
41
43
  import "./chunk-2SLTRKXC.js";
42
- import "./chunk-UF53DWWR.js";
43
- import {
44
- CatalogBundleUpsellResolver,
45
- ConfiguratorCatalogBuilder,
46
- FEATURE_GUARD_CONFIG_TOKEN,
47
- FeatureGuard,
48
- LimitExceededFilter,
49
- PLAN_CATALOG_IMPORT_SINK_TOKEN,
50
- PlanCatalogImportDto,
51
- PlanCatalogImporterModule,
52
- PlanCatalogImporterService,
53
- PlanCatalogValidationError,
54
- PublishValidationError,
55
- UPSELL_OFFER_CURRENCY_TOKEN,
56
- UPSELL_OFFER_RESOLVER_TOKEN,
57
- assertBaseVersionFresh,
58
- assertChangeNote,
59
- assertDraftPublishable,
60
- assertOptimisticLockHeld,
61
- buildPlanCatalogImporterController,
62
- clearPendingPlanVersionFields,
63
- computeCarriedTrialEndsAt,
64
- computeNextPeriod,
65
- decideRenewal,
66
- loadPlanCatalogFromFile,
67
- loadPlanCatalogFromString
68
- } from "./chunk-2JTISFUZ.js";
69
- import {
70
- formatPreflightReport,
71
- formatSeedGateReport,
72
- preflightExitCode,
73
- runPreflight,
74
- runSeedGateFromFile,
75
- seedGateExitCode,
76
- validateSeedAgainstSnapshot
77
- } from "./chunk-7ZPFQXHM.js";
78
- import "./chunk-DBZGV3HC.js";
79
- import {
80
- DefinesQuota,
81
- EnforceQuota,
82
- ImplementsCapability,
83
- RequiresCapability,
84
- runHeadlessDiscoveryScan
85
- } from "./chunk-YYUXKLXK.js";
86
- import {
87
- DiscoverySnapshotNotFoundError,
88
- loadDiscoverySnapshotFromFile
89
- } from "./chunk-74SCJ4HF.js";
90
- import "./chunk-2FR6ZL7R.js";
91
- import {
92
- defineSaaSiCat
93
- } from "./chunk-OYNHOY45.js";
94
44
  import {
95
45
  SETUP_CONFIG_TOKEN,
96
46
  SETUP_PROVISIONING_PORT_TOKEN,
97
- SaasPlatformModule,
47
+ SaaSiCatModule,
98
48
  SetupController,
99
49
  SetupModule,
100
50
  SetupService
101
- } from "./chunk-EHKMPP6J.js";
102
- import {
103
- CreatePromoCodeDto,
104
- PreviewPromoCodeDto,
105
- PromoCodeExpirer,
106
- PromoCodePublicController,
107
- PromoCodeRateLimitGuard,
108
- PromoCodesModule,
109
- UpdatePromoCodeDto,
110
- buildPromoCodeAdminController,
111
- hashIp,
112
- ipFingerprint
113
- } from "./chunk-B6IWLV7R.js";
51
+ } from "./chunk-XMA4XYC5.js";
114
52
  import {
115
53
  SubscriptionContractModule
116
- } from "./chunk-3E6ONOMG.js";
54
+ } from "./chunk-AU3OOREM.js";
55
+ import "./chunk-UF53DWWR.js";
117
56
  import {
118
57
  ADMIN_MANIFEST_CONFIG,
119
58
  ADMIN_RESOURCES_PORT_TOKEN,
@@ -140,8 +79,35 @@ import {
140
79
  SuperAdminGuard,
141
80
  SuspendTenantDto,
142
81
  buildAdminStatsController
143
- } from "./chunk-SN5UOC43.js";
82
+ } from "./chunk-LTT736P3.js";
144
83
  import {
84
+ CatalogBundleUpsellResolver,
85
+ ConfiguratorCatalogBuilder,
86
+ FEATURE_GUARD_CONFIG_TOKEN,
87
+ FeatureGuard,
88
+ LimitExceededFilter,
89
+ PLAN_CATALOG_IMPORT_SINK_TOKEN,
90
+ PlanCatalogImportDto,
91
+ PlanCatalogImporterModule,
92
+ PlanCatalogImporterService,
93
+ PlanCatalogValidationError,
94
+ PublishValidationError,
95
+ UPSELL_OFFER_CURRENCY_TOKEN,
96
+ UPSELL_OFFER_RESOLVER_TOKEN,
97
+ assertBaseVersionFresh,
98
+ assertChangeNote,
99
+ assertDraftPublishable,
100
+ assertOptimisticLockHeld,
101
+ buildPlanCatalogImporterController,
102
+ clearPendingPlanVersionFields,
103
+ computeCarriedTrialEndsAt,
104
+ computeNextPeriod,
105
+ decideRenewal,
106
+ loadPlanCatalogFromFile,
107
+ loadPlanCatalogFromString
108
+ } from "./chunk-VG2NU3CG.js";
109
+ import {
110
+ BILLING_FEATURE_UI_REGISTRY_TOKEN,
145
111
  CONTRACT_FREEZE_PORT_TOKEN,
146
112
  CONTRACT_FREEZE_PROJECT_KEY_TOKEN,
147
113
  CONTRACT_FREEZE_SOURCE_PORT_TOKEN,
@@ -150,7 +116,6 @@ import {
150
116
  CompleteOnboardingSubscriptionDto,
151
117
  ComposedTenantAuthGuard,
152
118
  FEATURE_GUARD_MARKER,
153
- FEATURE_UI_REGISTRY_TOKEN,
154
119
  PUBLIC_CATALOG_BUNDLE_REPOSITORY_TOKEN,
155
120
  PUBLIC_CATALOG_MARKETING_REPOSITORY_TOKEN,
156
121
  PUBLIC_CATALOG_PROJECT_KEY_TOKEN,
@@ -179,29 +144,22 @@ import {
179
144
  periodEndWithMinLead,
180
145
  resolveBundleCancelEffectiveAt,
181
146
  resolveBundlePriceNet
182
- } from "./chunk-UHD6FJBQ.js";
183
- import {
184
- PROMO_CODE_REDEMPTION_REPOSITORY_TOKEN,
185
- PROMO_CODE_REPOSITORY_TOKEN,
186
- PROMO_CODE_VALIDATION_LOG_REPOSITORY_TOKEN,
187
- PROMO_FIRST_TIME_CUSTOMER_CHECK_TOKEN,
188
- PROMO_REVENUE_DEDUCTION_AGGREGATOR_TOKEN,
189
- PROMO_SERVICE_CONFIG_TOKEN,
190
- PROMO_SUBSCRIPTION_LOOKUP_TOKEN,
191
- PROMO_TRANSACTION_RUNNER_TOKEN,
192
- PromoCodesService,
193
- addCycles,
194
- buildLabel,
195
- computeDiscountGross,
196
- computeDiscountedGross,
197
- computeRegularStartsAt
198
- } from "./chunk-37HEKVDH.js";
147
+ } from "./chunk-W6YEIY4R.js";
199
148
  import {
200
149
  SubscriptionContractService,
201
150
  contractLineItemToInvoiceLineItem,
202
151
  sortContractLineItemsForInvoice,
203
152
  subscriptionContractToInvoiceSnapshot
204
- } from "./chunk-CJFAOD7K.js";
153
+ } from "./chunk-KFT5AIIH.js";
154
+ import {
155
+ formatPreflightReport,
156
+ formatSeedGateReport,
157
+ preflightExitCode,
158
+ runPreflight,
159
+ runSeedGateFromFile,
160
+ seedGateExitCode,
161
+ validateSeedAgainstSnapshot
162
+ } from "./chunk-IQTQLQD3.js";
205
163
  import {
206
164
  ADVISORY_STRICT_MODE_CODES,
207
165
  BundlesService,
@@ -250,7 +208,7 @@ import {
250
208
  quotaApprovalSignature,
251
209
  validateBundleDraft,
252
210
  validatePlanDraft
253
- } from "./chunk-7X5MSAIL.js";
211
+ } from "./chunk-VNADKD5U.js";
254
212
  import {
255
213
  AUDIT_CONTEXT_RESOLVER_TOKEN,
256
214
  PENDING_PLAN_QUERY_PORT_TOKEN,
@@ -264,13 +222,8 @@ import {
264
222
  USER_ID_RESOLVER_TOKEN,
265
223
  classifyBundleVersionDiff,
266
224
  classifyPlanDiff
267
- } from "./chunk-WPUVJRIN.js";
268
- import {
269
- AUDIT_PORT_TOKEN,
270
- AdminAuditService,
271
- MFA_PORT_TOKEN,
272
- RLS_BYPASS_PORT_TOKEN
273
- } from "./chunk-E56W4U2P.js";
225
+ } from "./chunk-N3L3AICU.js";
226
+ import "./chunk-DBZGV3HC.js";
274
227
  import {
275
228
  CHECKOUT_OFFER_REPOSITORY_TOKEN,
276
229
  CheckoutOfferModule,
@@ -278,26 +231,33 @@ import {
278
231
  CreateCheckoutOfferDto,
279
232
  UpdateCheckoutOfferDto,
280
233
  buildCheckoutOfferController
281
- } from "./chunk-XTVAFJ3P.js";
234
+ } from "./chunk-L23MLBEC.js";
282
235
  import "./chunk-BSK6YBLI.js";
283
236
  import {
284
- SAASICAT_PUBLIC_ROUTE_KEY,
285
- SaaSiCatPublicRoute,
286
- isSaaSiCatPublicRoute
287
- } from "./chunk-YSC46BGM.js";
237
+ DefinesQuota,
238
+ EnforceQuota,
239
+ ImplementsCapability,
240
+ RequiresCapability,
241
+ runHeadlessDiscoveryScan
242
+ } from "./chunk-I7GTA3RX.js";
288
243
  import {
289
244
  DiscoveryModule,
290
245
  buildDiscoveryController
291
- } from "./chunk-6WL6VQ7Z.js";
246
+ } from "./chunk-XBYAFEOR.js";
247
+ import {
248
+ DiscoverySnapshotNotFoundError,
249
+ loadDiscoverySnapshotFromFile
250
+ } from "./chunk-74SCJ4HF.js";
292
251
  import {
293
252
  DISCOVERY_APP_INFO_TOKEN,
294
253
  DISCOVERY_SNAPSHOT_PATH_TOKEN,
295
254
  DiscoveryScanner,
296
255
  computeSnapshotHash
297
- } from "./chunk-5ZXBXYXU.js";
256
+ } from "./chunk-WXYJHZCN.js";
257
+ import "./chunk-2FR6ZL7R.js";
298
258
  import {
299
259
  EntitlementModule
300
- } from "./chunk-H4DOTO7S.js";
260
+ } from "./chunk-BGS4CWV2.js";
301
261
  import {
302
262
  EntitlementService,
303
263
  LimitExceededError,
@@ -320,7 +280,74 @@ import {
320
280
  mergeSubscriptionBundlesIntoLimits,
321
281
  resolveEntitlementPlan,
322
282
  toEffectiveLimitsSnapshot
323
- } from "./chunk-F4B2NJUZ.js";
283
+ } from "./chunk-PK6C5R7B.js";
284
+ import {
285
+ SUBSCRIPTION_CONTRACT_REPOSITORY_TOKEN
286
+ } from "./chunk-VBRYPU7V.js";
287
+ import {
288
+ ENTITLEMENT_RESOLUTION_CONFIG_TOKEN,
289
+ ENTITLEMENT_SERVICE_TOKEN,
290
+ PLAN_VERSION_REPOSITORY_TOKEN,
291
+ SUBSCRIPTION_REPOSITORY_TOKEN,
292
+ TRANSACTION_RUNNER_TOKEN
293
+ } from "./chunk-OUDSQ3PU.js";
294
+ import {
295
+ BUNDLE_REPOSITORY_TOKEN,
296
+ CATALOG_ENTRY_REPOSITORY_TOKEN,
297
+ CATALOG_FEATURE_UI_REGISTRY_TOKEN,
298
+ CATALOG_SERVICE_CONFIG_TOKEN,
299
+ MARKETING_PROJECTION_REPOSITORY_TOKEN,
300
+ MARKETING_SETTINGS_REPOSITORY_TOKEN,
301
+ PLAN_REPOSITORY_TOKEN,
302
+ PROMOTION_REPOSITORY_TOKEN
303
+ } from "./chunk-AOQJEYOL.js";
304
+ import {
305
+ DEFINES_QUOTA_KEY,
306
+ DISCOVERY_SNAPSHOT_TOKEN,
307
+ ENFORCE_QUOTA_KEY,
308
+ IMPLEMENTS_CAPABILITY_KEY,
309
+ REQUIRES_CAPABILITY_KEY
310
+ } from "./chunk-QUZU2M33.js";
311
+ import "./chunk-HWGIMNWR.js";
312
+ import {
313
+ CreatePromoCodeDto,
314
+ PreviewPromoCodeDto,
315
+ PromoCodeExpirer,
316
+ PromoCodePublicController,
317
+ PromoCodeRateLimitGuard,
318
+ PromoCodesModule,
319
+ UpdatePromoCodeDto,
320
+ buildPromoCodeAdminController,
321
+ hashIp,
322
+ ipFingerprint
323
+ } from "./chunk-YZPVQUIW.js";
324
+ import {
325
+ PROMO_CODE_REDEMPTION_REPOSITORY_TOKEN,
326
+ PROMO_CODE_REPOSITORY_TOKEN,
327
+ PROMO_CODE_VALIDATION_LOG_REPOSITORY_TOKEN,
328
+ PROMO_FIRST_TIME_CUSTOMER_CHECK_TOKEN,
329
+ PROMO_REVENUE_DEDUCTION_AGGREGATOR_TOKEN,
330
+ PROMO_SERVICE_CONFIG_TOKEN,
331
+ PROMO_SUBSCRIPTION_LOOKUP_TOKEN,
332
+ PROMO_TRANSACTION_RUNNER_TOKEN,
333
+ PromoCodesService,
334
+ addCycles,
335
+ buildLabel,
336
+ computeDiscountGross,
337
+ computeDiscountedGross,
338
+ computeRegularStartsAt
339
+ } from "./chunk-7TVZI3KY.js";
340
+ import {
341
+ AUDIT_PORT_TOKEN,
342
+ AdminAuditService,
343
+ MFA_PORT_TOKEN,
344
+ RLS_BYPASS_PORT_TOKEN
345
+ } from "./chunk-O2J2HDXA.js";
346
+ import {
347
+ SAASICAT_PUBLIC_ROUTE_KEY,
348
+ SaaSiCatPublicRoute,
349
+ isSaaSiCatPublicRoute
350
+ } from "./chunk-YSC46BGM.js";
324
351
  import {
325
352
  PLAN_CATALOG_READ_SINK_TOKEN,
326
353
  PLAN_CATALOG_TOKEN,
@@ -339,38 +366,12 @@ import {
339
366
  isFeaturePlannedOnly,
340
367
  round2
341
368
  } from "./chunk-DQKCK7DX.js";
342
- import {
343
- SUBSCRIPTION_CONTRACT_REPOSITORY_TOKEN
344
- } from "./chunk-NYLON2VC.js";
345
369
  import {
346
370
  codedError
347
- } from "./chunk-EBJJNTW6.js";
348
- import {
349
- ENTITLEMENT_RESOLUTION_CONFIG_TOKEN,
350
- ENTITLEMENT_SERVICE_TOKEN,
351
- PLAN_VERSION_REPOSITORY_TOKEN,
352
- SUBSCRIPTION_REPOSITORY_TOKEN,
353
- TRANSACTION_RUNNER_TOKEN
354
- } from "./chunk-WKVBNTYC.js";
355
- import {
356
- BUNDLE_REPOSITORY_TOKEN,
357
- CATALOG_ENTRY_REPOSITORY_TOKEN,
358
- CATALOG_SERVICE_CONFIG_TOKEN,
359
- MARKETING_PROJECTION_REPOSITORY_TOKEN,
360
- MARKETING_SETTINGS_REPOSITORY_TOKEN,
361
- PLAN_REPOSITORY_TOKEN,
362
- PROMOTION_REPOSITORY_TOKEN
363
- } from "./chunk-L4KTQ6CL.js";
371
+ } from "./chunk-57V6ZTI6.js";
364
372
  import {
365
373
  asProvider
366
374
  } from "./chunk-SABTXESR.js";
367
- import {
368
- DEFINES_QUOTA_KEY,
369
- DISCOVERY_SNAPSHOT_TOKEN,
370
- ENFORCE_QUOTA_KEY,
371
- IMPLEMENTS_CAPABILITY_KEY,
372
- REQUIRES_CAPABILITY_KEY
373
- } from "./chunk-L4SUWH5B.js";
374
375
  import "./chunk-SHUYVCID.js";
375
376
  export {
376
377
  ACTIVATION_ORCHESTRATOR_TOKEN,
@@ -392,10 +393,12 @@ export {
392
393
  AdminStatsController,
393
394
  AdminStatsModule,
394
395
  AdminStatsService,
396
+ BILLING_FEATURE_UI_REGISTRY_TOKEN,
395
397
  BUNDLE_REPOSITORY_TOKEN,
396
398
  BaseIpRateLimitGuard,
397
399
  BundlesService,
398
400
  CATALOG_ENTRY_REPOSITORY_TOKEN,
401
+ CATALOG_FEATURE_UI_REGISTRY_TOKEN,
399
402
  CATALOG_SERVICE_CONFIG_TOKEN,
400
403
  CHECKOUT_OFFER_REPOSITORY_TOKEN,
401
404
  CONTRACT_FREEZE_PORT_TOKEN,
@@ -437,7 +440,6 @@ export {
437
440
  EntitlementService,
438
441
  FEATURE_GUARD_CONFIG_TOKEN,
439
442
  FEATURE_GUARD_MARKER,
440
- FEATURE_UI_REGISTRY_TOKEN,
441
443
  FeatureGuard,
442
444
  IMPLEMENTS_CAPABILITY_KEY,
443
445
  ImplementsCapability,
@@ -539,9 +541,8 @@ export {
539
541
  SUBSCRIPTION_STATS_PORT_TOKEN,
540
542
  SUBSCRIPTION_USAGE_PORT_TOKEN,
541
543
  SUBSCRIPTION_WRITE_PORT_TOKEN,
542
- SaasPlatformModule as SaaSiCatModule,
544
+ SaaSiCatModule,
543
545
  SaaSiCatPublicRoute,
544
- SaasPlatformModule,
545
546
  SaveRegistrationConfigDto,
546
547
  SaveRegistrationConfigSelectionDto,
547
548
  SelectRegistrationPlanDto,
@@ -1,14 +1,14 @@
1
1
  import { Type, DynamicModule, ForwardReference, Provider, CanActivate, FactoryProvider } from '@nestjs/common';
2
- import { SuperAdminProvisioningPort, PlanCatalog, SaasicatPersistenceAdapter, MfaPort, AuditPort, RlsBypassPort, PlanCatalogReadSink, SubscriptionRepository, PlanVersionRepository, TransactionRunner, QuotaProvider, FeatureUiRegistry, SubscriptionUsagePort, UsageSnapshotPort, TenantSubscriptionWritePort, AdminResourcesPort, FirstTimeCustomerCheck } from '@saasicat/types';
2
+ import { SuperAdminProvisioningPort, MfaPort, AuditPort, RlsBypassPort, PlanCatalogReadSink, SubscriptionRepository, PlanVersionRepository, TransactionRunner, AdminResourcesPort, FeatureUiRegistry, PlanCatalog, SaaSiCatPersistenceAdapter, QuotaProvider, SubscriptionUsagePort, UsageSnapshotPort, TenantSubscriptionWritePort, FirstTimeCustomerCheck } from '@saasicat/core';
3
3
  import { P as ProviderSpec } from './di-CcNeq9v-.cjs';
4
- import { b as AdminManifestConfig, d as AdminResourcesModuleOptions, g as AdminStatsModuleOptions } from './admin-resources.module-DGgGSdzN.cjs';
5
- import { t as TenantBillingModuleOptions, p as SubscriptionBundleModuleOptions, n as SubscriptionBundleControllerOptions } from './tenant-billing.module-BxJS6fX4.cjs';
6
- import { b as CatalogModuleOptions } from './catalog.module-D-_pQDNA.cjs';
7
- import { b as DiscoveryAppInfo } from './discovery.scanner-DLgEvuoy.cjs';
8
- import { E as EntitlementResolutionConfig } from './plan-resolution-CFCoUkrE.cjs';
9
- import { a as PromoCodesModuleOptions } from './module-CHMIyWlf.cjs';
10
- import { b as CheckoutOfferModuleOptions } from './checkout-offer.module-DmlpPevf.cjs';
11
- import { a as SubscriptionContractModuleOptions } from './subscription-contract.module-B2uNvUJL.cjs';
4
+ import { d as AdminResourcesModuleOptions, g as AdminStatsModuleOptions, b as AdminManifestConfig } from './admin-resources.module-CpvzcfCc.cjs';
5
+ import { t as TenantBillingModuleOptions, p as SubscriptionBundleModuleOptions, n as SubscriptionBundleControllerOptions } from './tenant-billing.module-BznC3XtW.cjs';
6
+ import { b as CatalogModuleOptions } from './catalog.module-BDDO6iwq.cjs';
7
+ import { b as DiscoveryAppInfo } from './discovery.scanner-9cMqF95o.cjs';
8
+ import { E as EntitlementResolutionConfig } from './plan-resolution-Cgo_TR1H.cjs';
9
+ import { a as PromoCodesModuleOptions } from './promo.module-BY2YHHLn.cjs';
10
+ import { b as CheckoutOfferModuleOptions } from './checkout-offer.module-CVpWrzbe.cjs';
11
+ import { a as SubscriptionContractModuleOptions } from './subscription-contract.module-CEK8HS5-.cjs';
12
12
 
13
13
  interface SetupModuleOptions {
14
14
  /**
@@ -46,7 +46,7 @@ interface PlanResolverPort {
46
46
  * for local development and for apps that do not yet have a contract concept.
47
47
  *
48
48
  * The quickstart path uses this implicitly when `adapters.planResolver` is
49
- * not set and `defaultPlanId` was provided in SaasPlatformModule.forRoot().
49
+ * not set and `defaultPlanId` was provided in SaaSiCatModule.forRoot().
50
50
  */
51
51
  declare class StaticPlanResolver implements PlanResolverPort {
52
52
  private readonly planId;
@@ -78,7 +78,7 @@ declare function buildTenantManifestController(options: TenantManifestController
78
78
  * when wiring adapters without a bundle. The module validates that each port
79
79
  * ends up provided by exactly one of the two paths.
80
80
  */
81
- interface SaasPlatformAdapters {
81
+ interface SaaSiCatAdapters {
82
82
  mfa?: ProviderSpec<MfaPort>;
83
83
  audit?: ProviderSpec<AuditPort>;
84
84
  rlsBypass?: ProviderSpec<RlsBypassPort>;
@@ -105,7 +105,7 @@ interface SaasPlatformAdapters {
105
105
  transactionRunner?: ProviderSpec<TransactionRunner>;
106
106
  }
107
107
  type PlatformImports = Array<Type<unknown> | DynamicModule | Promise<DynamicModule> | ForwardReference>;
108
- interface SaasPlatformCatalogOptions extends Pick<CatalogModuleOptions, 'strictModeCheckMode' | 'autoSyncDiscoveryAtBoot' | 'marketedOnlyFeatures' | 'publicMarketingCatalog' | 'extraProviders'> {
108
+ interface SaaSiCatCatalogOptions extends Pick<CatalogModuleOptions, 'strictModeCheckMode' | 'autoSyncDiscoveryAtBoot' | 'marketedOnlyFeatures' | 'publicMarketingCatalog' | 'extraProviders'> {
109
109
  /** Labels/icons used by discovery review and the public catalog. */
110
110
  featureUiRegistry: FeatureUiRegistry;
111
111
  /** Mount the SuperAdmin catalog controllers. Default `true`. */
@@ -115,31 +115,31 @@ interface SaasPlatformCatalogOptions extends Pick<CatalogModuleOptions, 'strictM
115
115
  /** Override the top-level module imports for catalog adapter factories. */
116
116
  imports?: PlatformImports;
117
117
  }
118
- type SaasPlatformTenantAuthGuards = Array<Type<CanActivate>> | ProviderSpec<ReadonlyArray<CanActivate>>;
119
- interface SaasPlatformTenantBillingOptions extends Omit<TenantBillingModuleOptions, 'authGuards' | 'subscriptionUsagePort' | 'usageSnapshotPort' | 'subscriptionWritePort' | 'global'> {
118
+ type SaaSiCatTenantAuthGuards = Array<Type<CanActivate>> | ProviderSpec<ReadonlyArray<CanActivate>>;
119
+ interface SaaSiCatTenantBillingOptions extends Omit<TenantBillingModuleOptions, 'authGuards' | 'subscriptionUsagePort' | 'usageSnapshotPort' | 'subscriptionWritePort' | 'global'> {
120
120
  /**
121
121
  * Tenant guards as classes (the common path) or as a custom provider
122
122
  * factory. Guard classes are resolved from `imports`.
123
123
  */
124
- authGuards: SaasPlatformTenantAuthGuards;
124
+ authGuards: SaaSiCatTenantAuthGuards;
125
125
  /** Optional overrides; otherwise the persistence bundle supplies them. */
126
126
  subscriptionUsagePort?: ProviderSpec<SubscriptionUsagePort>;
127
127
  usageSnapshotPort?: ProviderSpec<UsageSnapshotPort>;
128
128
  subscriptionWritePort?: ProviderSpec<TenantSubscriptionWritePort>;
129
129
  }
130
- interface SaasPlatformSubscriptionBundlesOptions extends Omit<SubscriptionBundleModuleOptions, 'subscriptionBundleRepository' | 'bundleRepository' | 'controller' | 'imports' | 'extraProviders' | 'global'> {
130
+ interface SaaSiCatSubscriptionBundlesOptions extends Omit<SubscriptionBundleModuleOptions, 'subscriptionBundleRepository' | 'bundleRepository' | 'controller' | 'imports' | 'extraProviders' | 'global'> {
131
131
  /** Default mounts the tenant controller and reuses tenant-billing auth. */
132
132
  controller?: false | Omit<SubscriptionBundleControllerOptions, 'authGuards' | 'subscriptionUsagePort'>;
133
133
  imports?: PlatformImports;
134
134
  extraProviders?: Provider[];
135
135
  }
136
- interface SaasPlatformAdminResourcesOptions extends Omit<AdminResourcesModuleOptions, 'resources' | 'guards' | 'global'> {
136
+ interface SaaSiCatAdminResourcesOptions extends Omit<AdminResourcesModuleOptions, 'resources' | 'guards' | 'global'> {
137
137
  /** Override the default controller guards + `SuperAdminGuard` chain. */
138
138
  guards?: Array<Type<CanActivate>>;
139
139
  /** Custom schema override; the persistence bundle supplies the default. */
140
140
  resources?: ProviderSpec<AdminResourcesPort>;
141
141
  }
142
- interface SaasPlatformPromoCodesOptions extends Omit<PromoCodesModuleOptions, 'promoCodeRepository' | 'redemptionRepository' | 'validationLogRepository' | 'subscriptionLookup' | 'revenueAggregator' | 'transactionRunner' | 'firstTimeCustomerCheck' | 'adminController' | 'global'> {
142
+ interface SaaSiCatPromoCodesOptions extends Omit<PromoCodesModuleOptions, 'promoCodeRepository' | 'redemptionRepository' | 'validationLogRepository' | 'subscriptionLookup' | 'revenueAggregator' | 'transactionRunner' | 'firstTimeCustomerCheck' | 'adminController' | 'global'> {
143
143
  /**
144
144
  * Required when the public preview/redeem flow is enabled. Admin-only
145
145
  * setups do not need an app-specific customer-history check.
@@ -158,24 +158,24 @@ interface SaasPlatformPromoCodesOptions extends Omit<PromoCodesModuleOptions, 'p
158
158
  adminController?: false;
159
159
  }
160
160
  /** First-run setup, deriving the provisioning adapter from persistence by default. */
161
- interface SaasPlatformSetupOptions extends Omit<SetupModuleOptions, 'provisioningPort' | 'global'> {
161
+ interface SaaSiCatSetupOptions extends Omit<SetupModuleOptions, 'provisioningPort' | 'global'> {
162
162
  provisioningPort?: SetupModuleOptions['provisioningPort'];
163
163
  }
164
164
  /** Admin dashboard statistics; the audit port can come from persistence. */
165
- interface SaasPlatformAdminStatsOptions extends Omit<AdminStatsModuleOptions, 'auditStatsPort' | 'global'> {
165
+ interface SaaSiCatAdminStatsOptions extends Omit<AdminStatsModuleOptions, 'auditStatsPort' | 'global'> {
166
166
  auditStatsPort?: AdminStatsModuleOptions['auditStatsPort'];
167
167
  }
168
168
  /**
169
169
  * Public checkout-offer flow. Catalog repositories default to the persistence
170
170
  * bundle, while the app still supplies its checkout-offer repository.
171
171
  */
172
- interface SaasPlatformCheckoutOfferOptions extends Omit<CheckoutOfferModuleOptions, 'bundleRepository' | 'planRepository' | 'catalogEntryRepository' | 'global'> {
172
+ interface SaaSiCatCheckoutOfferOptions extends Omit<CheckoutOfferModuleOptions, 'bundleRepository' | 'planRepository' | 'catalogEntryRepository' | 'global'> {
173
173
  bundleRepository?: CheckoutOfferModuleOptions['bundleRepository'];
174
174
  planRepository?: CheckoutOfferModuleOptions['planRepository'];
175
175
  catalogEntryRepository?: CheckoutOfferModuleOptions['catalogEntryRepository'];
176
176
  }
177
177
  /** Subscription-contract service, deriving its repository from persistence by default. */
178
- interface SaasPlatformSubscriptionContractOptions extends Omit<SubscriptionContractModuleOptions, 'subscriptionContractRepository' | 'global'> {
178
+ interface SaaSiCatSubscriptionContractOptions extends Omit<SubscriptionContractModuleOptions, 'subscriptionContractRepository' | 'global'> {
179
179
  subscriptionContractRepository?: SubscriptionContractModuleOptions['subscriptionContractRepository'];
180
180
  }
181
181
  /**
@@ -195,7 +195,7 @@ interface SaasPlatformSubscriptionContractOptions extends Omit<SubscriptionContr
195
195
  * Everything else — an operator creating tenants through the SuperAdmin UI, a
196
196
  * CLI, or your own onboarding form — is composed here.
197
197
  */
198
- interface SaasPlatformModuleOptions {
198
+ interface SaaSiCatModuleOptions {
199
199
  /**
200
200
  * Plan catalog. Either as an already-loaded object (quickstart, comes
201
201
  * directly from `loadPlanCatalogFromFile('config/saas.yaml')`) or via DB
@@ -224,12 +224,12 @@ interface SaasPlatformModuleOptions {
224
224
  * `capabilities` are validated fail-fast against the enabled feature set
225
225
  * (e.g. `entitlement: true` requires transactions + pessimistic locking).
226
226
  */
227
- persistence?: SaasicatPersistenceAdapter;
227
+ persistence?: SaaSiCatPersistenceAdapter;
228
228
  /**
229
229
  * Individual adapter bindings. Optional when `persistence` provides the
230
230
  * respective port; explicit entries take precedence over the bundle.
231
231
  */
232
- adapters?: SaasPlatformAdapters;
232
+ adapters?: SaaSiCatAdapters;
233
233
  /**
234
234
  * Class-level guards for the platform controllers (`GET /admin/discovery`
235
235
  * and `GET /admin/manifest`). REQUIRED — otherwise the platform throws at
@@ -316,43 +316,43 @@ interface SaasPlatformModuleOptions {
316
316
  * Standard DB-backed catalog stack. Repositories are taken from
317
317
  * `persistence.catalog`; no consumer forwarding module is needed.
318
318
  */
319
- catalog?: false | SaasPlatformCatalogOptions;
319
+ catalog?: false | SaaSiCatCatalogOptions;
320
320
  /**
321
321
  * Standard tenant self-service stack. Subscription read/write adapters
322
322
  * come from `persistence.tenantBilling`; usage is derived from
323
323
  * `quotaProviders` unless explicitly overridden.
324
324
  */
325
- tenantBilling?: false | SaasPlatformTenantBillingOptions;
325
+ tenantBilling?: false | SaaSiCatTenantBillingOptions;
326
326
  /**
327
327
  * Add-on bundle service and tenant controller. `true` uses defaults and
328
328
  * reuses tenant-billing auth/usage; an object customizes policy.
329
329
  */
330
- subscriptionBundles?: false | true | SaasPlatformSubscriptionBundlesOptions;
330
+ subscriptionBundles?: false | true | SaaSiCatSubscriptionBundlesOptions;
331
331
  /**
332
332
  * Standard SuperAdmin Tenant/User/Audit/Subscription endpoints. `true`
333
333
  * uses `persistence.adminResources` and the standard guard chain.
334
334
  */
335
- adminResources?: false | true | SaasPlatformAdminResourcesOptions;
335
+ adminResources?: false | true | SaaSiCatAdminResourcesOptions;
336
336
  /**
337
337
  * Promo-code domain and SuperAdmin CRUD. `true` enables the admin API
338
338
  * without the public preview endpoint; pass an object to enable preview.
339
339
  */
340
- promoCodes?: false | true | SaasPlatformPromoCodesOptions;
340
+ promoCodes?: false | true | SaaSiCatPromoCodesOptions;
341
341
  /**
342
342
  * First-run SuperAdmin setup. `true` uses
343
343
  * `persistence.core.superAdminProvisioning`; an object customizes it or
344
344
  * supplies an app-specific provisioning adapter.
345
345
  */
346
- setup?: false | true | SaasPlatformSetupOptions;
346
+ setup?: false | true | SaaSiCatSetupOptions;
347
347
  /** SuperAdmin dashboard statistics with app-specific subscription/promo ports. */
348
- adminStats?: false | SaasPlatformAdminStatsOptions;
348
+ adminStats?: false | SaaSiCatAdminStatsOptions;
349
349
  /** Public checkout-offer flow; catalog repositories reuse `persistence.catalog`. */
350
- checkoutOffer?: false | SaasPlatformCheckoutOfferOptions;
350
+ checkoutOffer?: false | SaaSiCatCheckoutOfferOptions;
351
351
  /**
352
352
  * Subscription-contract service. `true` reuses
353
353
  * `persistence.entitlement.subscriptionContractRepository`.
354
354
  */
355
- subscriptionContract?: false | true | SaasPlatformSubscriptionContractOptions;
355
+ subscriptionContract?: false | true | SaaSiCatSubscriptionContractOptions;
356
356
  /**
357
357
  * Enable the tenant manifest — the app UI gets a filtered manifest per
358
358
  * tenant with features, quotas and visible navigation. Requires that
@@ -403,4 +403,4 @@ interface SaasPlatformModuleOptions {
403
403
  enforcementChainCheck?: boolean;
404
404
  }
405
405
 
406
- export { PLAN_RESOLVER_PORT_TOKEN as P, type SaasPlatformAdapters as S, type TenantManifestControllerOptions as T, type SaasPlatformAdminResourcesOptions as a, type SaasPlatformAdminStatsOptions as b, type SaasPlatformCatalogOptions as c, type SaasPlatformCheckoutOfferOptions as d, type SaasPlatformModuleOptions as e, type SaasPlatformPromoCodesOptions as f, type SaasPlatformSetupOptions as g, type SaasPlatformSubscriptionBundlesOptions as h, type SaasPlatformSubscriptionContractOptions as i, type SaasPlatformTenantAuthGuards as j, type SaasPlatformTenantBillingOptions as k, SetupModule as l, type SetupModuleOptions as m, StaticPlanResolver as n, type PlanResolverPort as o, buildTenantManifestController as p };
406
+ export { PLAN_RESOLVER_PORT_TOKEN as P, type SaaSiCatAdapters as S, type TenantManifestControllerOptions as T, type SaaSiCatAdminResourcesOptions as a, type SaaSiCatAdminStatsOptions as b, type SaaSiCatCatalogOptions as c, type SaaSiCatCheckoutOfferOptions as d, type SaaSiCatModuleOptions as e, type SaaSiCatPromoCodesOptions as f, type SaaSiCatSetupOptions as g, type SaaSiCatSubscriptionBundlesOptions as h, type SaaSiCatSubscriptionContractOptions as i, type SaaSiCatTenantAuthGuards as j, type SaaSiCatTenantBillingOptions as k, SetupModule as l, type SetupModuleOptions as m, StaticPlanResolver as n, type PlanResolverPort as o, buildTenantManifestController as p };