@wildo-ai/saas-models 1.1.8 → 1.1.10

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 (951) hide show
  1. package/dist/esm/_inspect.d.ts.map +1 -1
  2. package/dist/esm/_inspect.js.map +1 -1
  3. package/dist/esm/applications/application-metadata.shared.resources-config.schemas.d.ts.map +1 -1
  4. package/dist/esm/applications/application-metadata.shared.resources-config.schemas.js.map +1 -1
  5. package/dist/esm/applications/application-subject.shared.schemas.d.ts.map +1 -1
  6. package/dist/esm/applications/application-subject.shared.schemas.js.map +1 -1
  7. package/dist/esm/applications/application-versions.shared.resources-config.schemas.d.ts.map +1 -1
  8. package/dist/esm/applications/application-versions.shared.resources-config.schemas.js.map +1 -1
  9. package/dist/esm/applications/applications-context.schemas.d.ts +68 -2
  10. package/dist/esm/applications/applications-context.schemas.d.ts.map +1 -1
  11. package/dist/esm/applications/applications-context.schemas.js.map +1 -1
  12. package/dist/esm/applications/applications.shared.resources-config.schemas.d.ts.map +1 -1
  13. package/dist/esm/applications/applications.shared.resources-config.schemas.js.map +1 -1
  14. package/dist/esm/applications/applications.shared.schemas.d.ts.map +1 -1
  15. package/dist/esm/applications/applications.shared.schemas.js.map +1 -1
  16. package/dist/esm/billing/billing-account.shared.resources-config.schemas.d.ts.map +1 -1
  17. package/dist/esm/billing/billing-account.shared.resources-config.schemas.js.map +1 -1
  18. package/dist/esm/billing/billing-account.shared.schemas.d.ts.map +1 -1
  19. package/dist/esm/billing/billing-account.shared.schemas.js.map +1 -1
  20. package/dist/esm/billing/billing-configuration.shared.schemas.d.ts.map +1 -1
  21. package/dist/esm/billing/billing-configuration.shared.schemas.js.map +1 -1
  22. package/dist/esm/billing/billing-enums.shared.schemas.d.ts.map +1 -1
  23. package/dist/esm/billing/billing-enums.shared.schemas.js.map +1 -1
  24. package/dist/esm/billing/billing-types.shared.schemas.d.ts.map +1 -1
  25. package/dist/esm/billing/billing-types.shared.schemas.js.map +1 -1
  26. package/dist/esm/billing/credit-pool.shared.resources-config.schemas.d.ts.map +1 -1
  27. package/dist/esm/billing/credit-pool.shared.resources-config.schemas.js.map +1 -1
  28. package/dist/esm/billing/credit-pool.shared.schemas.d.ts.map +1 -1
  29. package/dist/esm/billing/credit-pool.shared.schemas.js.map +1 -1
  30. package/dist/esm/billing/invoice-ref.shared.resources-config.schemas.d.ts.map +1 -1
  31. package/dist/esm/billing/invoice-ref.shared.resources-config.schemas.js.map +1 -1
  32. package/dist/esm/billing/invoice-ref.shared.schemas.d.ts.map +1 -1
  33. package/dist/esm/billing/invoice-ref.shared.schemas.js.map +1 -1
  34. package/dist/esm/billing/price.shared.resources-config.schemas.d.ts.map +1 -1
  35. package/dist/esm/billing/price.shared.resources-config.schemas.js.map +1 -1
  36. package/dist/esm/billing/price.shared.schemas.d.ts.map +1 -1
  37. package/dist/esm/billing/price.shared.schemas.js.map +1 -1
  38. package/dist/esm/billing/product-behavior-policy.shared.schemas.d.ts.map +1 -1
  39. package/dist/esm/billing/product-behavior-policy.shared.schemas.js.map +1 -1
  40. package/dist/esm/billing/product-definition.shared.schemas.d.ts.map +1 -1
  41. package/dist/esm/billing/product-definition.shared.schemas.js.map +1 -1
  42. package/dist/esm/billing/product.shared.resources-config.schemas.d.ts.map +1 -1
  43. package/dist/esm/billing/product.shared.resources-config.schemas.js.map +1 -1
  44. package/dist/esm/billing/product.shared.schemas.d.ts.map +1 -1
  45. package/dist/esm/billing/product.shared.schemas.js.map +1 -1
  46. package/dist/esm/billing/promotions.shared.resources-config.schemas.d.ts.map +1 -1
  47. package/dist/esm/billing/promotions.shared.resources-config.schemas.js.map +1 -1
  48. package/dist/esm/billing/promotions.shared.schemas.d.ts.map +1 -1
  49. package/dist/esm/billing/promotions.shared.schemas.js.map +1 -1
  50. package/dist/esm/billing/public-pricing-catalog.shared.atoms.d.ts.map +1 -1
  51. package/dist/esm/billing/public-pricing-catalog.shared.atoms.js.map +1 -1
  52. package/dist/esm/billing/public-pricing-catalog.shared.d.ts.map +1 -1
  53. package/dist/esm/billing/public-pricing-catalog.shared.js.map +1 -1
  54. package/dist/esm/billing/referral-reward.shared.schemas.d.ts.map +1 -1
  55. package/dist/esm/billing/referral-reward.shared.schemas.js.map +1 -1
  56. package/dist/esm/billing/referral.shared.resources-config.schemas.d.ts.map +1 -1
  57. package/dist/esm/billing/referral.shared.resources-config.schemas.js.map +1 -1
  58. package/dist/esm/billing/referral.shared.schemas.d.ts.map +1 -1
  59. package/dist/esm/billing/referral.shared.schemas.js.map +1 -1
  60. package/dist/esm/billing/subscription.shared.resources-config.schemas.d.ts.map +1 -1
  61. package/dist/esm/billing/subscription.shared.resources-config.schemas.js.map +1 -1
  62. package/dist/esm/billing/subscription.shared.schemas.d.ts.map +1 -1
  63. package/dist/esm/billing/subscription.shared.schemas.js.map +1 -1
  64. package/dist/esm/billing/usage-flush-evidence.shared.schemas.d.ts.map +1 -1
  65. package/dist/esm/billing/usage-flush-evidence.shared.schemas.js.map +1 -1
  66. package/dist/esm/billing/usage-record.shared.resources-config.schemas.d.ts.map +1 -1
  67. package/dist/esm/billing/usage-record.shared.resources-config.schemas.js.map +1 -1
  68. package/dist/esm/billing/usage-record.shared.schemas.d.ts.map +1 -1
  69. package/dist/esm/billing/usage-record.shared.schemas.js.map +1 -1
  70. package/dist/esm/charts/aggregation-query.shared.schemas.d.ts.map +1 -1
  71. package/dist/esm/charts/aggregation-query.shared.schemas.js.map +1 -1
  72. package/dist/esm/charts/aggregation.shared.definitions.d.ts.map +1 -1
  73. package/dist/esm/charts/aggregation.shared.definitions.js.map +1 -1
  74. package/dist/esm/charts/chart-definition-builder.shared.d.ts.map +1 -1
  75. package/dist/esm/charts/chart-definition-builder.shared.js.map +1 -1
  76. package/dist/esm/companion/artifact-placement.shared.definitions.d.ts.map +1 -1
  77. package/dist/esm/companion/artifact-placement.shared.definitions.js.map +1 -1
  78. package/dist/esm/companion/provider-discovery.shared.schemas.d.ts +13 -0
  79. package/dist/esm/companion/provider-discovery.shared.schemas.d.ts.map +1 -1
  80. package/dist/esm/companion/provider-discovery.shared.schemas.js +13 -0
  81. package/dist/esm/companion/provider-discovery.shared.schemas.js.map +1 -1
  82. package/dist/esm/companion/shared-library-companion.shared.definitions.d.ts.map +1 -1
  83. package/dist/esm/companion/shared-library-companion.shared.definitions.js.map +1 -1
  84. package/dist/esm/companion-exports.d.ts.map +1 -1
  85. package/dist/esm/companion-exports.js.map +1 -1
  86. package/dist/esm/compliance/audit-trails/application-audit-logs.shared.resources-config.schemas.d.ts +1 -1
  87. package/dist/esm/compliance/audit-trails/application-audit-logs.shared.resources-config.schemas.d.ts.map +1 -1
  88. package/dist/esm/compliance/audit-trails/application-audit-logs.shared.resources-config.schemas.js +5 -2
  89. package/dist/esm/compliance/audit-trails/application-audit-logs.shared.resources-config.schemas.js.map +1 -1
  90. package/dist/esm/compliance/audit-trails/audit-actor.shared.schemas.d.ts.map +1 -1
  91. package/dist/esm/compliance/audit-trails/audit-actor.shared.schemas.js.map +1 -1
  92. package/dist/esm/compliance/audit-trails/audit-event-classification.shared.d.ts +28 -0
  93. package/dist/esm/compliance/audit-trails/audit-event-classification.shared.d.ts.map +1 -0
  94. package/dist/esm/compliance/audit-trails/audit-event-classification.shared.js +30 -0
  95. package/dist/esm/compliance/audit-trails/audit-event-classification.shared.js.map +1 -0
  96. package/dist/esm/compliance/audit-trails/audit-export-projection.shared.schemas.d.ts.map +1 -1
  97. package/dist/esm/compliance/audit-trails/audit-export-projection.shared.schemas.js.map +1 -1
  98. package/dist/esm/compliance/audit-trails/audit-log-sink.shared.schemas.d.ts.map +1 -1
  99. package/dist/esm/compliance/audit-trails/audit-log-sink.shared.schemas.js.map +1 -1
  100. package/dist/esm/compliance/audit-trails/audit-logs.shared.resources-config.schemas.d.ts +1 -1
  101. package/dist/esm/compliance/audit-trails/audit-logs.shared.resources-config.schemas.d.ts.map +1 -1
  102. package/dist/esm/compliance/audit-trails/audit-logs.shared.resources-config.schemas.js +2 -1
  103. package/dist/esm/compliance/audit-trails/audit-logs.shared.resources-config.schemas.js.map +1 -1
  104. package/dist/esm/compliance/audit-trails/audit-trail-config.shared.schemas.d.ts +20 -0
  105. package/dist/esm/compliance/audit-trails/audit-trail-config.shared.schemas.d.ts.map +1 -1
  106. package/dist/esm/compliance/audit-trails/audit-trail-config.shared.schemas.js +40 -0
  107. package/dist/esm/compliance/audit-trails/audit-trail-config.shared.schemas.js.map +1 -1
  108. package/dist/esm/compliance/audit-trails/auditable-events.shared.schema.d.ts +1 -14
  109. package/dist/esm/compliance/audit-trails/auditable-events.shared.schema.d.ts.map +1 -1
  110. package/dist/esm/compliance/audit-trails/auditable-events.shared.schema.js +1 -16
  111. package/dist/esm/compliance/audit-trails/auditable-events.shared.schema.js.map +1 -1
  112. package/dist/esm/compliance/audit-trails/security-audit-event-envelope.shared.schema.d.ts +17 -4
  113. package/dist/esm/compliance/audit-trails/security-audit-event-envelope.shared.schema.d.ts.map +1 -1
  114. package/dist/esm/compliance/audit-trails/security-audit-event-envelope.shared.schema.js +25 -5
  115. package/dist/esm/compliance/audit-trails/security-audit-event-envelope.shared.schema.js.map +1 -1
  116. package/dist/esm/compliance/data-classification/data-classification.shared.schemas.d.ts.map +1 -1
  117. package/dist/esm/compliance/data-classification/data-classification.shared.schemas.js.map +1 -1
  118. package/dist/esm/compliance/documents/governed-document-interactions.shared.schemas.d.ts.map +1 -1
  119. package/dist/esm/compliance/documents/governed-document-interactions.shared.schemas.js.map +1 -1
  120. package/dist/esm/compliance/documents/governed-documents.shared.schemas.d.ts +0 -50
  121. package/dist/esm/compliance/documents/governed-documents.shared.schemas.d.ts.map +1 -1
  122. package/dist/esm/compliance/documents/governed-documents.shared.schemas.js +4 -51
  123. package/dist/esm/compliance/documents/governed-documents.shared.schemas.js.map +1 -1
  124. package/dist/esm/compliance/documents/public-governed-documents.shared.d.ts +67 -0
  125. package/dist/esm/compliance/documents/public-governed-documents.shared.d.ts.map +1 -0
  126. package/dist/esm/compliance/documents/public-governed-documents.shared.js +69 -0
  127. package/dist/esm/compliance/documents/public-governed-documents.shared.js.map +1 -0
  128. package/dist/esm/compliance/documents/user-governed-document-acceptances.shared.resources-config.schemas.d.ts.map +1 -1
  129. package/dist/esm/compliance/documents/user-governed-document-acceptances.shared.resources-config.schemas.js.map +1 -1
  130. package/dist/esm/compliance/documents/user-governed-document-acceptances.shared.schemas.d.ts.map +1 -1
  131. package/dist/esm/compliance/documents/user-governed-document-acceptances.shared.schemas.js.map +1 -1
  132. package/dist/esm/compliance/privacy/ai-use-posture.shared.schemas.d.ts.map +1 -1
  133. package/dist/esm/compliance/privacy/ai-use-posture.shared.schemas.js.map +1 -1
  134. package/dist/esm/compliance/privacy/capability-consent-purposes.shared.utils.d.ts.map +1 -1
  135. package/dist/esm/compliance/privacy/capability-consent-purposes.shared.utils.js.map +1 -1
  136. package/dist/esm/compliance/privacy/client-storage.shared.schemas.d.ts.map +1 -1
  137. package/dist/esm/compliance/privacy/client-storage.shared.schemas.js.map +1 -1
  138. package/dist/esm/compliance/privacy/consent-gate-vocabulary.shared.schemas.d.ts.map +1 -1
  139. package/dist/esm/compliance/privacy/consent-gate-vocabulary.shared.schemas.js.map +1 -1
  140. package/dist/esm/compliance/privacy/consent-purposes.shared.d.ts.map +1 -1
  141. package/dist/esm/compliance/privacy/consent-purposes.shared.js.map +1 -1
  142. package/dist/esm/compliance/privacy/data-subject-rights.shared.schemas.d.ts.map +1 -1
  143. package/dist/esm/compliance/privacy/data-subject-rights.shared.schemas.js +1 -1
  144. package/dist/esm/compliance/privacy/data-subject-rights.shared.schemas.js.map +1 -1
  145. package/dist/esm/compliance/privacy/impersonalization-scrub.shared.utils.d.ts.map +1 -1
  146. package/dist/esm/compliance/privacy/impersonalization-scrub.shared.utils.js.map +1 -1
  147. package/dist/esm/compliance/privacy/impersonalization.shared.schemas.d.ts.map +1 -1
  148. package/dist/esm/compliance/privacy/impersonalization.shared.schemas.js.map +1 -1
  149. package/dist/esm/compliance/privacy/jurisdiction-containment.shared.d.ts +32 -0
  150. package/dist/esm/compliance/privacy/jurisdiction-containment.shared.d.ts.map +1 -0
  151. package/dist/esm/compliance/privacy/jurisdiction-containment.shared.js +46 -0
  152. package/dist/esm/compliance/privacy/jurisdiction-containment.shared.js.map +1 -0
  153. package/dist/esm/compliance/privacy/legal-hold-subject-attribution.shared.utils.d.ts.map +1 -1
  154. package/dist/esm/compliance/privacy/legal-hold-subject-attribution.shared.utils.js.map +1 -1
  155. package/dist/esm/compliance/privacy/legal-holds.shared.resources-config.schemas.d.ts.map +1 -1
  156. package/dist/esm/compliance/privacy/legal-holds.shared.resources-config.schemas.js.map +1 -1
  157. package/dist/esm/compliance/privacy/legal-holds.shared.schemas.d.ts.map +1 -1
  158. package/dist/esm/compliance/privacy/legal-holds.shared.schemas.js.map +1 -1
  159. package/dist/esm/compliance/privacy/legal-notice-obligation.shared.d.ts +47 -0
  160. package/dist/esm/compliance/privacy/legal-notice-obligation.shared.d.ts.map +1 -0
  161. package/dist/esm/compliance/privacy/legal-notice-obligation.shared.js +54 -0
  162. package/dist/esm/compliance/privacy/legal-notice-obligation.shared.js.map +1 -0
  163. package/dist/esm/compliance/privacy/legal-notice.shared.d.ts +105 -0
  164. package/dist/esm/compliance/privacy/legal-notice.shared.d.ts.map +1 -0
  165. package/dist/esm/compliance/privacy/legal-notice.shared.js +112 -0
  166. package/dist/esm/compliance/privacy/legal-notice.shared.js.map +1 -0
  167. package/dist/esm/compliance/privacy/operating-jurisdictions.shared.schemas.d.ts +1 -27
  168. package/dist/esm/compliance/privacy/operating-jurisdictions.shared.schemas.d.ts.map +1 -1
  169. package/dist/esm/compliance/privacy/operating-jurisdictions.shared.schemas.js +2 -41
  170. package/dist/esm/compliance/privacy/operating-jurisdictions.shared.schemas.js.map +1 -1
  171. package/dist/esm/compliance/privacy/operator-compliance-identity.shared.schemas.d.ts +83 -1
  172. package/dist/esm/compliance/privacy/operator-compliance-identity.shared.schemas.d.ts.map +1 -1
  173. package/dist/esm/compliance/privacy/operator-compliance-identity.shared.schemas.js +97 -0
  174. package/dist/esm/compliance/privacy/operator-compliance-identity.shared.schemas.js.map +1 -1
  175. package/dist/esm/compliance/privacy/personal-data-category.shared.schemas.d.ts.map +1 -1
  176. package/dist/esm/compliance/privacy/personal-data-category.shared.schemas.js.map +1 -1
  177. package/dist/esm/compliance/privacy/personal-data-declaration.shared.utils.d.ts.map +1 -1
  178. package/dist/esm/compliance/privacy/personal-data-declaration.shared.utils.js.map +1 -1
  179. package/dist/esm/compliance/privacy/privacy.shared.schemas.d.ts.map +1 -1
  180. package/dist/esm/compliance/privacy/privacy.shared.schemas.js.map +1 -1
  181. package/dist/esm/compliance/privacy/provider-capability-disclosure.shared.schemas.d.ts.map +1 -1
  182. package/dist/esm/compliance/privacy/provider-capability-disclosure.shared.schemas.js.map +1 -1
  183. package/dist/esm/compliance/privacy/purpose-ref.shared.schemas.d.ts.map +1 -1
  184. package/dist/esm/compliance/privacy/purpose-ref.shared.schemas.js.map +1 -1
  185. package/dist/esm/compliance/privacy/redaction.shared.schemas.d.ts.map +1 -1
  186. package/dist/esm/compliance/privacy/redaction.shared.schemas.js.map +1 -1
  187. package/dist/esm/compliance/privacy/retention-binding.shared.utils.d.ts.map +1 -1
  188. package/dist/esm/compliance/privacy/retention-binding.shared.utils.js.map +1 -1
  189. package/dist/esm/compliance/privacy/retention-enforcement-records.shared.resources-config.schemas.d.ts.map +1 -1
  190. package/dist/esm/compliance/privacy/retention-enforcement-records.shared.resources-config.schemas.js.map +1 -1
  191. package/dist/esm/compliance/privacy/retention-enforcement-records.shared.schemas.d.ts +8 -8
  192. package/dist/esm/compliance/privacy/retention-enforcement-records.shared.schemas.d.ts.map +1 -1
  193. package/dist/esm/compliance/privacy/retention-enforcement-records.shared.schemas.js.map +1 -1
  194. package/dist/esm/compliance/privacy/retention-schedule.shared.schemas.d.ts.map +1 -1
  195. package/dist/esm/compliance/privacy/retention-schedule.shared.schemas.js.map +1 -1
  196. package/dist/esm/compliance/privacy/retention-scope-deleted.shared.utils.d.ts.map +1 -1
  197. package/dist/esm/compliance/privacy/retention-scope-deleted.shared.utils.js.map +1 -1
  198. package/dist/esm/compliance/privacy/sharing.shared.schemas.d.ts.map +1 -1
  199. package/dist/esm/compliance/privacy/sharing.shared.schemas.js.map +1 -1
  200. package/dist/esm/compliance/privacy/subject-data-recipients.shared.schemas.d.ts.map +1 -1
  201. package/dist/esm/compliance/privacy/subject-data-recipients.shared.schemas.js.map +1 -1
  202. package/dist/esm/compliance/privacy/subject-erasure-lane-evidence.shared.schemas.d.ts.map +1 -1
  203. package/dist/esm/compliance/privacy/subject-erasure-lane-evidence.shared.schemas.js.map +1 -1
  204. package/dist/esm/compliance/privacy/subject-erasure.shared.schemas.d.ts.map +1 -1
  205. package/dist/esm/compliance/privacy/subject-erasure.shared.schemas.js.map +1 -1
  206. package/dist/esm/compliance/privacy/subject-export-render.shared.utils.d.ts.map +1 -1
  207. package/dist/esm/compliance/privacy/subject-export-render.shared.utils.js.map +1 -1
  208. package/dist/esm/compliance/privacy/subject-export.shared.schemas.d.ts.map +1 -1
  209. package/dist/esm/compliance/privacy/subject-export.shared.schemas.js.map +1 -1
  210. package/dist/esm/compliance/review-cadence.shared.schemas.d.ts.map +1 -1
  211. package/dist/esm/compliance/review-cadence.shared.schemas.js.map +1 -1
  212. package/dist/esm/compliance/risk-posture.shared.schemas.d.ts +15 -3
  213. package/dist/esm/compliance/risk-posture.shared.schemas.d.ts.map +1 -1
  214. package/dist/esm/compliance/risk-posture.shared.schemas.js +14 -2
  215. package/dist/esm/compliance/risk-posture.shared.schemas.js.map +1 -1
  216. package/dist/esm/config/analytics-value-moments.shared.schemas.d.ts.map +1 -1
  217. package/dist/esm/config/analytics-value-moments.shared.schemas.js.map +1 -1
  218. package/dist/esm/config/app-configuration-shared.shared.schemas.d.ts +63 -1
  219. package/dist/esm/config/app-configuration-shared.shared.schemas.d.ts.map +1 -1
  220. package/dist/esm/config/app-configuration-shared.shared.schemas.js +11 -0
  221. package/dist/esm/config/app-configuration-shared.shared.schemas.js.map +1 -1
  222. package/dist/esm/config/app-frontend-type.shared.schemas.d.ts.map +1 -1
  223. package/dist/esm/config/app-frontend-type.shared.schemas.js.map +1 -1
  224. package/dist/esm/config/auth-config-resolution.shared.utils.d.ts.map +1 -1
  225. package/dist/esm/config/auth-config-resolution.shared.utils.js.map +1 -1
  226. package/dist/esm/config/brand-assets.shared.schemas.d.ts.map +1 -1
  227. package/dist/esm/config/brand-assets.shared.schemas.js.map +1 -1
  228. package/dist/esm/config/configuration-validation.shared.schemas.d.ts.map +1 -1
  229. package/dist/esm/config/configuration-validation.shared.schemas.js.map +1 -1
  230. package/dist/esm/config/entity-identity-config.shared.schemas.d.ts.map +1 -1
  231. package/dist/esm/config/entity-identity-config.shared.schemas.js.map +1 -1
  232. package/dist/esm/config/frontend/chart-definition.shared.schemas.d.ts +16 -16
  233. package/dist/esm/config/frontend/chart-definition.shared.schemas.d.ts.map +1 -1
  234. package/dist/esm/config/frontend/chart-definition.shared.schemas.js.map +1 -1
  235. package/dist/esm/config/frontend/chart-registration-alignment.shared.d.ts.map +1 -1
  236. package/dist/esm/config/frontend/chart-registration-alignment.shared.js.map +1 -1
  237. package/dist/esm/config/frontend/navigation.shared.schemas.d.ts.map +1 -1
  238. package/dist/esm/config/frontend/navigation.shared.schemas.js.map +1 -1
  239. package/dist/esm/config/frontend/onboarding.shared.schemas.d.ts.map +1 -1
  240. package/dist/esm/config/frontend/onboarding.shared.schemas.js.map +1 -1
  241. package/dist/esm/config/postgresql.shared.schemas.d.ts.map +1 -1
  242. package/dist/esm/config/postgresql.shared.schemas.js.map +1 -1
  243. package/dist/esm/config/registration-acquisition-policy.shared.utils.d.ts.map +1 -1
  244. package/dist/esm/config/registration-acquisition-policy.shared.utils.js.map +1 -1
  245. package/dist/esm/config-authoring.entry.d.ts.map +1 -1
  246. package/dist/esm/config-authoring.entry.js.map +1 -1
  247. package/dist/esm/crdt/crdt-merge.shared.utils.d.ts.map +1 -1
  248. package/dist/esm/crdt/crdt-merge.shared.utils.js.map +1 -1
  249. package/dist/esm/data-seeding/data-seeding-config.shared.schemas.d.ts.map +1 -1
  250. package/dist/esm/data-seeding/data-seeding-config.shared.schemas.js.map +1 -1
  251. package/dist/esm/errors/caught-error-description.shared.utils.d.ts +5 -1
  252. package/dist/esm/errors/caught-error-description.shared.utils.d.ts.map +1 -1
  253. package/dist/esm/errors/caught-error-description.shared.utils.js +48 -4
  254. package/dist/esm/errors/caught-error-description.shared.utils.js.map +1 -1
  255. package/dist/esm/errors/errors.custom-message-ref.shared.definitions.d.ts.map +1 -1
  256. package/dist/esm/errors/errors.custom-message-ref.shared.definitions.js.map +1 -1
  257. package/dist/esm/errors/errors.shared.definitions.d.ts.map +1 -1
  258. package/dist/esm/errors/errors.shared.definitions.js.map +1 -1
  259. package/dist/esm/errors/errors.shared.schemas.d.ts.map +1 -1
  260. package/dist/esm/errors/errors.shared.schemas.js.map +1 -1
  261. package/dist/esm/errors/errors.shared.utils.d.ts.map +1 -1
  262. package/dist/esm/errors/errors.shared.utils.js.map +1 -1
  263. package/dist/esm/errors/resource-access-forbidden.shared.error.d.ts.map +1 -1
  264. package/dist/esm/errors/resource-access-forbidden.shared.error.js.map +1 -1
  265. package/dist/esm/errors/thrown-value-description.shared.utils.d.ts.map +1 -1
  266. package/dist/esm/errors/thrown-value-description.shared.utils.js.map +1 -1
  267. package/dist/esm/errors/zod-issue-formatting.shared.utils.d.ts.map +1 -1
  268. package/dist/esm/errors/zod-issue-formatting.shared.utils.js.map +1 -1
  269. package/dist/esm/exports/tabular-csv.shared.utils.d.ts.map +1 -1
  270. package/dist/esm/exports/tabular-csv.shared.utils.js.map +1 -1
  271. package/dist/esm/external-data/external-data-pipeline-description.shared.d.ts.map +1 -1
  272. package/dist/esm/external-data/external-data-pipeline-description.shared.js.map +1 -1
  273. package/dist/esm/external-data/external-data-pipeline-pass-mode.shared.d.ts.map +1 -1
  274. package/dist/esm/external-data/external-data-pipeline-pass-mode.shared.js.map +1 -1
  275. package/dist/esm/external-data/external-data-pipeline.shared.schemas.d.ts.map +1 -1
  276. package/dist/esm/external-data/external-data-pipeline.shared.schemas.js.map +1 -1
  277. package/dist/esm/external-data/external-data-provenance.shared.d.ts.map +1 -1
  278. package/dist/esm/external-data/external-data-provenance.shared.js.map +1 -1
  279. package/dist/esm/external-data.exports.d.ts.map +1 -1
  280. package/dist/esm/external-data.exports.js.map +1 -1
  281. package/dist/esm/external-providers/compose-provider-registry.shared.d.ts.map +1 -1
  282. package/dist/esm/external-providers/compose-provider-registry.shared.js.map +1 -1
  283. package/dist/esm/external-providers/engine-capabilities.shared.schemas.d.ts.map +1 -1
  284. package/dist/esm/external-providers/engine-capabilities.shared.schemas.js.map +1 -1
  285. package/dist/esm/external-providers/engine-capability-resolution-mode.shared.d.ts.map +1 -1
  286. package/dist/esm/external-providers/engine-capability-resolution-mode.shared.js.map +1 -1
  287. package/dist/esm/external-providers/engine-capability-surface.shared.d.ts.map +1 -1
  288. package/dist/esm/external-providers/engine-capability-surface.shared.js.map +1 -1
  289. package/dist/esm/external-providers/external-providers.shared.schemas.d.ts.map +1 -1
  290. package/dist/esm/external-providers/external-providers.shared.schemas.js.map +1 -1
  291. package/dist/esm/external-providers/frontend-bootstrap.shared.schemas.d.ts +34 -1
  292. package/dist/esm/external-providers/frontend-bootstrap.shared.schemas.d.ts.map +1 -1
  293. package/dist/esm/external-providers/frontend-bootstrap.shared.schemas.js.map +1 -1
  294. package/dist/esm/external-providers/frontend-capability-public-config.shared.schemas.d.ts.map +1 -1
  295. package/dist/esm/external-providers/frontend-capability-public-config.shared.schemas.js.map +1 -1
  296. package/dist/esm/external-providers/frontend-capability-runtime.shared.types.d.ts.map +1 -1
  297. package/dist/esm/external-providers/frontend-capability-runtime.shared.types.js.map +1 -1
  298. package/dist/esm/external-providers/frontend-provider-entry.shared.schemas.d.ts.map +1 -1
  299. package/dist/esm/external-providers/frontend-provider-entry.shared.schemas.js.map +1 -1
  300. package/dist/esm/external-providers/frontend-provider-public-config.shared.d.ts.map +1 -1
  301. package/dist/esm/external-providers/frontend-provider-public-config.shared.js.map +1 -1
  302. package/dist/esm/external-providers/model-cost-accounting-config.shared.schemas.d.ts.map +1 -1
  303. package/dist/esm/external-providers/model-cost-accounting-config.shared.schemas.js.map +1 -1
  304. package/dist/esm/external-providers/provider-address-lookup-contract.shared.types.d.ts.map +1 -1
  305. package/dist/esm/external-providers/provider-address-lookup-contract.shared.types.js.map +1 -1
  306. package/dist/esm/external-providers/provider-augmentation-opt-ins.shared.schemas.d.ts.map +1 -1
  307. package/dist/esm/external-providers/provider-augmentation-opt-ins.shared.schemas.js.map +1 -1
  308. package/dist/esm/external-providers/provider-authentication-assurance.shared.schemas.d.ts.map +1 -1
  309. package/dist/esm/external-providers/provider-authentication-assurance.shared.schemas.js.map +1 -1
  310. package/dist/esm/external-providers/provider-browser-operations.shared.schemas.d.ts.map +1 -1
  311. package/dist/esm/external-providers/provider-browser-operations.shared.schemas.js.map +1 -1
  312. package/dist/esm/external-providers/provider-capability.shared.schemas.d.ts.map +1 -1
  313. package/dist/esm/external-providers/provider-capability.shared.schemas.js.map +1 -1
  314. package/dist/esm/external-providers/provider-compliance-profile.shared.schemas.d.ts.map +1 -1
  315. package/dist/esm/external-providers/provider-compliance-profile.shared.schemas.js.map +1 -1
  316. package/dist/esm/external-providers/provider-frontend-component-contract.shared.types.d.ts.map +1 -1
  317. package/dist/esm/external-providers/provider-frontend-component-contract.shared.types.js.map +1 -1
  318. package/dist/esm/external-providers/provider-frontend-surface.shared.schemas.d.ts.map +1 -1
  319. package/dist/esm/external-providers/provider-frontend-surface.shared.schemas.js.map +1 -1
  320. package/dist/esm/external-providers/provider-metadata.shared.schemas.d.ts.map +1 -1
  321. package/dist/esm/external-providers/provider-metadata.shared.schemas.js.map +1 -1
  322. package/dist/esm/external-providers/provider-package-allow-list.shared.schemas.d.ts.map +1 -1
  323. package/dist/esm/external-providers/provider-package-allow-list.shared.schemas.js.map +1 -1
  324. package/dist/esm/external-providers/provider-protocol.shared.schemas.d.ts.map +1 -1
  325. package/dist/esm/external-providers/provider-protocol.shared.schemas.js.map +1 -1
  326. package/dist/esm/external-providers/provider-scope-reauthorization.shared.schemas.d.ts.map +1 -1
  327. package/dist/esm/external-providers/provider-scope-reauthorization.shared.schemas.js.map +1 -1
  328. package/dist/esm/external-providers/provider-shared-connections.shared.schemas.d.ts.map +1 -1
  329. package/dist/esm/external-providers/provider-shared-connections.shared.schemas.js.map +1 -1
  330. package/dist/esm/external-providers/provider-tier-rule.shared.utils.d.ts.map +1 -1
  331. package/dist/esm/external-providers/provider-tier-rule.shared.utils.js.map +1 -1
  332. package/dist/esm/external-providers/provider-usage-cost.shared.d.ts.map +1 -1
  333. package/dist/esm/external-providers/provider-usage-cost.shared.js.map +1 -1
  334. package/dist/esm/external-providers/provider-usage-pricing.example.d.ts.map +1 -1
  335. package/dist/esm/external-providers/provider-usage-pricing.example.js.map +1 -1
  336. package/dist/esm/external-providers/provider-usage-pricing.shared.schemas.d.ts.map +1 -1
  337. package/dist/esm/external-providers/provider-usage-pricing.shared.schemas.js.map +1 -1
  338. package/dist/esm/features/application-features.shared.resources-config.schemas.d.ts.map +1 -1
  339. package/dist/esm/features/application-features.shared.resources-config.schemas.js.map +1 -1
  340. package/dist/esm/features/connected-feature.example.d.ts.map +1 -1
  341. package/dist/esm/features/connected-feature.example.js.map +1 -1
  342. package/dist/esm/features/core-feature-definitions.shared.d.ts.map +1 -1
  343. package/dist/esm/features/core-feature-definitions.shared.js.map +1 -1
  344. package/dist/esm/features/feature-builders.shared.d.ts.map +1 -1
  345. package/dist/esm/features/feature-builders.shared.js.map +1 -1
  346. package/dist/esm/features/feature-definition.shared.schemas.d.ts.map +1 -1
  347. package/dist/esm/features/feature-definition.shared.schemas.js.map +1 -1
  348. package/dist/esm/features/feature-registry.shared.d.ts.map +1 -1
  349. package/dist/esm/features/feature-registry.shared.js.map +1 -1
  350. package/dist/esm/features/feature-resolution.shared.schemas.d.ts.map +1 -1
  351. package/dist/esm/features/feature-resolution.shared.schemas.js.map +1 -1
  352. package/dist/esm/features/scope-features.shared.schemas.d.ts.map +1 -1
  353. package/dist/esm/features/scope-features.shared.schemas.js.map +1 -1
  354. package/dist/esm/features/user-features.shared.resources-config.schemas.d.ts.map +1 -1
  355. package/dist/esm/features/user-features.shared.resources-config.schemas.js.map +1 -1
  356. package/dist/esm/files/file-remote-reference-link.shared.schemas.d.ts.map +1 -1
  357. package/dist/esm/files/file-remote-reference-link.shared.schemas.js.map +1 -1
  358. package/dist/esm/files/file-upload-grant.shared.schemas.d.ts.map +1 -1
  359. package/dist/esm/files/file-upload-grant.shared.schemas.js.map +1 -1
  360. package/dist/esm/files/files.shared.resources-config.schemas.d.ts.map +1 -1
  361. package/dist/esm/files/files.shared.resources-config.schemas.js.map +1 -1
  362. package/dist/esm/files/files.shared.schemas.d.ts.map +1 -1
  363. package/dist/esm/files/files.shared.schemas.js.map +1 -1
  364. package/dist/esm/files/files.shared.utils.d.ts.map +1 -1
  365. package/dist/esm/files/files.shared.utils.js.map +1 -1
  366. package/dist/esm/flows-actors/a2a-push-delivery-log.shared.resources-config.schemas.d.ts.map +1 -1
  367. package/dist/esm/flows-actors/a2a-push-delivery-log.shared.resources-config.schemas.js.map +1 -1
  368. package/dist/esm/flows-actors/a2a-push-delivery-log.shared.schemas.d.ts.map +1 -1
  369. package/dist/esm/flows-actors/a2a-push-delivery-log.shared.schemas.js.map +1 -1
  370. package/dist/esm/flows-actors/a2a-token-budget-state.shared.resources-config.schemas.d.ts.map +1 -1
  371. package/dist/esm/flows-actors/a2a-token-budget-state.shared.resources-config.schemas.js.map +1 -1
  372. package/dist/esm/flows-actors/a2a-token-budget-state.shared.schemas.d.ts.map +1 -1
  373. package/dist/esm/flows-actors/a2a-token-budget-state.shared.schemas.js.map +1 -1
  374. package/dist/esm/flows-actors/actors.shared.schemas.d.ts.map +1 -1
  375. package/dist/esm/flows-actors/actors.shared.schemas.js.map +1 -1
  376. package/dist/esm/flows-actors/agent-traceability.shared.schemas.d.ts.map +1 -1
  377. package/dist/esm/flows-actors/agent-traceability.shared.schemas.js.map +1 -1
  378. package/dist/esm/flows-actors/agent-work-decisions.shared.resources-config.schemas.d.ts.map +1 -1
  379. package/dist/esm/flows-actors/agent-work-decisions.shared.resources-config.schemas.js.map +1 -1
  380. package/dist/esm/flows-actors/agent-work-decisions.shared.schemas.d.ts.map +1 -1
  381. package/dist/esm/flows-actors/agent-work-decisions.shared.schemas.js.map +1 -1
  382. package/dist/esm/flows-actors/agents.shared.schemas.d.ts.map +1 -1
  383. package/dist/esm/flows-actors/agents.shared.schemas.js.map +1 -1
  384. package/dist/esm/flows-actors/autonomous-agents.shared.schemas.d.ts.map +1 -1
  385. package/dist/esm/flows-actors/autonomous-agents.shared.schemas.js.map +1 -1
  386. package/dist/esm/flows-actors/deliberation.shared.schemas.d.ts +2 -1
  387. package/dist/esm/flows-actors/deliberation.shared.schemas.d.ts.map +1 -1
  388. package/dist/esm/flows-actors/deliberation.shared.schemas.js +2 -1
  389. package/dist/esm/flows-actors/deliberation.shared.schemas.js.map +1 -1
  390. package/dist/esm/flows-actors/execution-plan-readiness.shared.utils.d.ts.map +1 -1
  391. package/dist/esm/flows-actors/execution-plan-readiness.shared.utils.js.map +1 -1
  392. package/dist/esm/flows-actors/flows-actors-execution.shared.resources-config.schemas.d.ts.map +1 -1
  393. package/dist/esm/flows-actors/flows-actors-execution.shared.resources-config.schemas.js.map +1 -1
  394. package/dist/esm/flows-actors/flows-actors-execution.shared.schemas.d.ts.map +1 -1
  395. package/dist/esm/flows-actors/flows-actors-execution.shared.schemas.js.map +1 -1
  396. package/dist/esm/flows-actors/flows-actors-task.shared.resources-config.schemas.d.ts.map +1 -1
  397. package/dist/esm/flows-actors/flows-actors-task.shared.resources-config.schemas.js.map +1 -1
  398. package/dist/esm/flows-actors/flows-actors-task.shared.schemas.d.ts.map +1 -1
  399. package/dist/esm/flows-actors/flows-actors-task.shared.schemas.js.map +1 -1
  400. package/dist/esm/flows-actors/flows-actors.commons.shared.schemas.d.ts.map +1 -1
  401. package/dist/esm/flows-actors/flows-actors.commons.shared.schemas.js.map +1 -1
  402. package/dist/esm/flows-actors/flows-actors.configuration.shared.schemas.d.ts.map +1 -1
  403. package/dist/esm/flows-actors/flows-actors.configuration.shared.schemas.js.map +1 -1
  404. package/dist/esm/flows-actors/flows-actors.frontend.shared.schemas.d.ts.map +1 -1
  405. package/dist/esm/flows-actors/flows-actors.frontend.shared.schemas.js.map +1 -1
  406. package/dist/esm/flows-actors/flows-actors.io.shared.schemas.d.ts.map +1 -1
  407. package/dist/esm/flows-actors/flows-actors.io.shared.schemas.js.map +1 -1
  408. package/dist/esm/flows-actors/flows-actors.system.shared.definitions.d.ts.map +1 -1
  409. package/dist/esm/flows-actors/flows-actors.system.shared.definitions.js.map +1 -1
  410. package/dist/esm/flows-actors/flows-actors.system.shared.schemas.d.ts.map +1 -1
  411. package/dist/esm/flows-actors/flows-actors.system.shared.schemas.js.map +1 -1
  412. package/dist/esm/flows-actors/flows.shared.schemas.d.ts.map +1 -1
  413. package/dist/esm/flows-actors/flows.shared.schemas.js.map +1 -1
  414. package/dist/esm/flows-actors/human-decision.shared.schemas.d.ts.map +1 -1
  415. package/dist/esm/flows-actors/human-decision.shared.schemas.js.map +1 -1
  416. package/dist/esm/flows-actors/mcp-servers.shared.schemas.d.ts.map +1 -1
  417. package/dist/esm/flows-actors/mcp-servers.shared.schemas.js.map +1 -1
  418. package/dist/esm/flows-actors/model-call-attributions.shared.resources-config.schemas.d.ts.map +1 -1
  419. package/dist/esm/flows-actors/model-call-attributions.shared.resources-config.schemas.js.map +1 -1
  420. package/dist/esm/flows-actors/model-call-attributions.shared.schemas.d.ts.map +1 -1
  421. package/dist/esm/flows-actors/model-call-attributions.shared.schemas.js.map +1 -1
  422. package/dist/esm/flows-actors/model-cost-period-aggregates.shared.resources-config.schemas.d.ts.map +1 -1
  423. package/dist/esm/flows-actors/model-cost-period-aggregates.shared.resources-config.schemas.js.map +1 -1
  424. package/dist/esm/flows-actors/model-cost-period-aggregates.shared.schemas.d.ts.map +1 -1
  425. package/dist/esm/flows-actors/model-cost-period-aggregates.shared.schemas.js.map +1 -1
  426. package/dist/esm/flows-actors/model-cost-summary.shared.schemas.d.ts.map +1 -1
  427. package/dist/esm/flows-actors/model-cost-summary.shared.schemas.js.map +1 -1
  428. package/dist/esm/flows-actors/prompt-ir.shared.schemas.d.ts.map +1 -1
  429. package/dist/esm/flows-actors/prompt-ir.shared.schemas.js.map +1 -1
  430. package/dist/esm/flows-actors/provider-call-records.shared.resources-config.schemas.d.ts.map +1 -1
  431. package/dist/esm/flows-actors/provider-call-records.shared.resources-config.schemas.js.map +1 -1
  432. package/dist/esm/flows-actors/provider-call-records.shared.schemas.d.ts.map +1 -1
  433. package/dist/esm/flows-actors/provider-call-records.shared.schemas.js.map +1 -1
  434. package/dist/esm/flows-actors/review-deadlines.shared.schemas.d.ts.map +1 -1
  435. package/dist/esm/flows-actors/review-deadlines.shared.schemas.js.map +1 -1
  436. package/dist/esm/flows-actors/tasks.actors.shared.schemas.d.ts.map +1 -1
  437. package/dist/esm/flows-actors/tasks.actors.shared.schemas.js.map +1 -1
  438. package/dist/esm/flows-actors/work-attribution.shared.schemas.d.ts.map +1 -1
  439. package/dist/esm/flows-actors/work-attribution.shared.schemas.js.map +1 -1
  440. package/dist/esm/frontend-definitions/frontend-notification-custom-message-ref.definitions.d.ts.map +1 -1
  441. package/dist/esm/frontend-definitions/frontend-notification-custom-message-ref.definitions.js.map +1 -1
  442. package/dist/esm/frontend-definitions/settings-destination-ref.definitions.d.ts.map +1 -1
  443. package/dist/esm/frontend-definitions/settings-destination-ref.definitions.js.map +1 -1
  444. package/dist/esm/guidance/guidance-flow.shared.schemas.d.ts.map +1 -1
  445. package/dist/esm/guidance/guidance-flow.shared.schemas.js.map +1 -1
  446. package/dist/esm/guidance/guidance-state.shared.resources-config.schemas.d.ts.map +1 -1
  447. package/dist/esm/guidance/guidance-state.shared.resources-config.schemas.js.map +1 -1
  448. package/dist/esm/guidance/guidance-state.shared.schemas.d.ts.map +1 -1
  449. package/dist/esm/guidance/guidance-state.shared.schemas.js.map +1 -1
  450. package/dist/esm/guidance/guidance-state.shared.utils.d.ts.map +1 -1
  451. package/dist/esm/guidance/guidance-state.shared.utils.js.map +1 -1
  452. package/dist/esm/guidance/lifecycle-config.shared.schemas.d.ts +2 -2
  453. package/dist/esm/guidance/lifecycle-config.shared.schemas.d.ts.map +1 -1
  454. package/dist/esm/guidance/lifecycle-config.shared.schemas.js.map +1 -1
  455. package/dist/esm/guidance/lifecycle-state.shared.resources-config.schemas.d.ts.map +1 -1
  456. package/dist/esm/guidance/lifecycle-state.shared.resources-config.schemas.js.map +1 -1
  457. package/dist/esm/guidance/lifecycle-state.shared.schemas.d.ts.map +1 -1
  458. package/dist/esm/guidance/lifecycle-state.shared.schemas.js.map +1 -1
  459. package/dist/esm/guidance/milestone-builders.shared.d.ts.map +1 -1
  460. package/dist/esm/guidance/milestone-builders.shared.js.map +1 -1
  461. package/dist/esm/guidance/milestone-definition.shared.schemas.d.ts.map +1 -1
  462. package/dist/esm/guidance/milestone-definition.shared.schemas.js.map +1 -1
  463. package/dist/esm/guidance/progression-presentation.shared.schemas.d.ts.map +1 -1
  464. package/dist/esm/guidance/progression-presentation.shared.schemas.js.map +1 -1
  465. package/dist/esm/guidance/progression-state.shared.resources-config.schemas.d.ts.map +1 -1
  466. package/dist/esm/guidance/progression-state.shared.resources-config.schemas.js.map +1 -1
  467. package/dist/esm/guidance/progression-state.shared.schemas.d.ts.map +1 -1
  468. package/dist/esm/guidance/progression-state.shared.schemas.js.map +1 -1
  469. package/dist/esm/http-api-binding/http-api-binding-id.shared.utils.d.ts.map +1 -1
  470. package/dist/esm/http-api-binding/http-api-binding-id.shared.utils.js.map +1 -1
  471. package/dist/esm/http-api-binding/http-api-binding.shared.schemas.d.ts.map +1 -1
  472. package/dist/esm/http-api-binding/http-api-binding.shared.schemas.js.map +1 -1
  473. package/dist/esm/http-api-binding/http-api-erasure-stance.shared.d.ts.map +1 -1
  474. package/dist/esm/http-api-binding/http-api-erasure-stance.shared.js.map +1 -1
  475. package/dist/esm/http-api-binding/http-api-rest-write-operations.shared.schemas.d.ts.map +1 -1
  476. package/dist/esm/http-api-binding/http-api-rest-write-operations.shared.schemas.js.map +1 -1
  477. package/dist/esm/http-api-binding/http-api-transport-dialect.shared.d.ts.map +1 -1
  478. package/dist/esm/http-api-binding/http-api-transport-dialect.shared.js.map +1 -1
  479. package/dist/esm/http-api-binding/read-through-engine-anchors.shared.d.ts.map +1 -1
  480. package/dist/esm/http-api-binding/read-through-engine-anchors.shared.js.map +1 -1
  481. package/dist/esm/i18n/application-config-vocabulary.shared.d.ts.map +1 -1
  482. package/dist/esm/i18n/application-config-vocabulary.shared.js.map +1 -1
  483. package/dist/esm/i18n/engine-open-vocabulary-values.shared.d.ts.map +1 -1
  484. package/dist/esm/i18n/engine-open-vocabulary-values.shared.js.map +1 -1
  485. package/dist/esm/i18n/engine-open-vocabulary.shared.d.ts.map +1 -1
  486. package/dist/esm/i18n/engine-open-vocabulary.shared.js.map +1 -1
  487. package/dist/esm/i18n/interpolate-label-params.shared.utils.d.ts.map +1 -1
  488. package/dist/esm/i18n/interpolate-label-params.shared.utils.js.map +1 -1
  489. package/dist/esm/i18n/labelling.dto.shared.schemas.d.ts.map +1 -1
  490. package/dist/esm/i18n/labelling.dto.shared.schemas.js.map +1 -1
  491. package/dist/esm/inbound/conversation-threads.shared.resources-config.schemas.d.ts.map +1 -1
  492. package/dist/esm/inbound/conversation-threads.shared.resources-config.schemas.js.map +1 -1
  493. package/dist/esm/inbound/conversation-threads.shared.schemas.d.ts.map +1 -1
  494. package/dist/esm/inbound/conversation-threads.shared.schemas.js.map +1 -1
  495. package/dist/esm/inbound/inbound-channels.shared.schemas.d.ts.map +1 -1
  496. package/dist/esm/inbound/inbound-channels.shared.schemas.js.map +1 -1
  497. package/dist/esm/inbound/inbound-delivery.shared.resources-config.schemas.d.ts.map +1 -1
  498. package/dist/esm/inbound/inbound-delivery.shared.resources-config.schemas.js.map +1 -1
  499. package/dist/esm/inbound/inbound-delivery.shared.schemas.d.ts.map +1 -1
  500. package/dist/esm/inbound/inbound-delivery.shared.schemas.js.map +1 -1
  501. package/dist/esm/inbound/inbound-endpoint-env.shared.d.ts.map +1 -1
  502. package/dist/esm/inbound/inbound-endpoint-env.shared.js.map +1 -1
  503. package/dist/esm/index.d.ts +5 -0
  504. package/dist/esm/index.d.ts.map +1 -1
  505. package/dist/esm/index.js +5 -0
  506. package/dist/esm/index.js.map +1 -1
  507. package/dist/esm/meta-workflows/actions.meta-workflows.shared.schemas.d.ts.map +1 -1
  508. package/dist/esm/meta-workflows/actions.meta-workflows.shared.schemas.js.map +1 -1
  509. package/dist/esm/meta-workflows/catalog.meta-workflows.shared.schemas.d.ts.map +1 -1
  510. package/dist/esm/meta-workflows/catalog.meta-workflows.shared.schemas.js.map +1 -1
  511. package/dist/esm/meta-workflows/coding-tasks.meta-workflows.shared.schemas.d.ts.map +1 -1
  512. package/dist/esm/meta-workflows/coding-tasks.meta-workflows.shared.schemas.js.map +1 -1
  513. package/dist/esm/meta-workflows/context-selection.meta-workflows.shared.schemas.d.ts.map +1 -1
  514. package/dist/esm/meta-workflows/context-selection.meta-workflows.shared.schemas.js.map +1 -1
  515. package/dist/esm/meta-workflows/decisions.meta-workflows.shared.schemas.d.ts.map +1 -1
  516. package/dist/esm/meta-workflows/decisions.meta-workflows.shared.schemas.js.map +1 -1
  517. package/dist/esm/meta-workflows/elicitation-depth.meta-workflows.shared.schemas.d.ts +128 -0
  518. package/dist/esm/meta-workflows/elicitation-depth.meta-workflows.shared.schemas.d.ts.map +1 -0
  519. package/dist/esm/meta-workflows/elicitation-depth.meta-workflows.shared.schemas.js +136 -0
  520. package/dist/esm/meta-workflows/elicitation-depth.meta-workflows.shared.schemas.js.map +1 -0
  521. package/dist/esm/meta-workflows/orchestration.meta-workflows.shared.schemas.d.ts +45 -1
  522. package/dist/esm/meta-workflows/orchestration.meta-workflows.shared.schemas.d.ts.map +1 -1
  523. package/dist/esm/meta-workflows/orchestration.meta-workflows.shared.schemas.js +87 -2
  524. package/dist/esm/meta-workflows/orchestration.meta-workflows.shared.schemas.js.map +1 -1
  525. package/dist/esm/meta-workflows/portable-primitives.meta-workflows.shared.schemas.d.ts.map +1 -1
  526. package/dist/esm/meta-workflows/portable-primitives.meta-workflows.shared.schemas.js.map +1 -1
  527. package/dist/esm/meta-workflows.exports.d.ts +1 -0
  528. package/dist/esm/meta-workflows.exports.d.ts.map +1 -1
  529. package/dist/esm/meta-workflows.exports.js +1 -0
  530. package/dist/esm/meta-workflows.exports.js.map +1 -1
  531. package/dist/esm/monitoring/monitoring.shared.schemas.d.ts.map +1 -1
  532. package/dist/esm/monitoring/monitoring.shared.schemas.js.map +1 -1
  533. package/dist/esm/notifications/email/email-context.shared.schemas.d.ts.map +1 -1
  534. package/dist/esm/notifications/email/email-context.shared.schemas.js.map +1 -1
  535. package/dist/esm/notifications/email/email-submission.shared.enums.d.ts.map +1 -1
  536. package/dist/esm/notifications/email/email-submission.shared.enums.js.map +1 -1
  537. package/dist/esm/notifications/email/email-template-registry.shared.schemas.d.ts.map +1 -1
  538. package/dist/esm/notifications/email/email-template-registry.shared.schemas.js.map +1 -1
  539. package/dist/esm/notifications/email/email-template.shared.enums.d.ts.map +1 -1
  540. package/dist/esm/notifications/email/email-template.shared.enums.js.map +1 -1
  541. package/dist/esm/notifications/inbound-email/inbound-email.shared.resources-config.schemas.d.ts.map +1 -1
  542. package/dist/esm/notifications/inbound-email/inbound-email.shared.resources-config.schemas.js.map +1 -1
  543. package/dist/esm/notifications/inbound-email/inbound-email.shared.schemas.d.ts.map +1 -1
  544. package/dist/esm/notifications/inbound-email/inbound-email.shared.schemas.js.map +1 -1
  545. package/dist/esm/notifications/m2m/m2m-webhook-delivery-contract.shared.d.ts.map +1 -1
  546. package/dist/esm/notifications/m2m/m2m-webhook-delivery-contract.shared.js.map +1 -1
  547. package/dist/esm/notifications/m2m/m2m-webhook-delivery-log.shared.resources-config.schemas.d.ts.map +1 -1
  548. package/dist/esm/notifications/m2m/m2m-webhook-delivery-log.shared.resources-config.schemas.js.map +1 -1
  549. package/dist/esm/notifications/m2m/m2m-webhook-delivery-log.shared.schemas.d.ts.map +1 -1
  550. package/dist/esm/notifications/m2m/m2m-webhook-delivery-log.shared.schemas.js.map +1 -1
  551. package/dist/esm/notifications/m2m/webhook-config.shared.resources-config.schemas.d.ts.map +1 -1
  552. package/dist/esm/notifications/m2m/webhook-config.shared.resources-config.schemas.js.map +1 -1
  553. package/dist/esm/notifications/m2m/webhook-config.shared.schemas.d.ts.map +1 -1
  554. package/dist/esm/notifications/m2m/webhook-config.shared.schemas.js.map +1 -1
  555. package/dist/esm/notifications/notification-badges.core.definitions.d.ts.map +1 -1
  556. package/dist/esm/notifications/notification-badges.core.definitions.js.map +1 -1
  557. package/dist/esm/notifications/notification-badges.schemas.d.ts.map +1 -1
  558. package/dist/esm/notifications/notification-badges.schemas.js.map +1 -1
  559. package/dist/esm/notifications/notification-badges.shared.resources-config.schemas.d.ts.map +1 -1
  560. package/dist/esm/notifications/notification-badges.shared.resources-config.schemas.js.map +1 -1
  561. package/dist/esm/notifications/notifications.shared.schemas.d.ts +5 -3
  562. package/dist/esm/notifications/notifications.shared.schemas.d.ts.map +1 -1
  563. package/dist/esm/notifications/notifications.shared.schemas.js +5 -3
  564. package/dist/esm/notifications/notifications.shared.schemas.js.map +1 -1
  565. package/dist/esm/organizations/application-owner-organization.shared.schemas.d.ts.map +1 -1
  566. package/dist/esm/organizations/application-owner-organization.shared.schemas.js.map +1 -1
  567. package/dist/esm/organizations/organization-features.shared.resources-config.schemas.d.ts.map +1 -1
  568. package/dist/esm/organizations/organization-features.shared.resources-config.schemas.js.map +1 -1
  569. package/dist/esm/organizations/organization-features.shared.schemas.d.ts.map +1 -1
  570. package/dist/esm/organizations/organization-features.shared.schemas.js.map +1 -1
  571. package/dist/esm/organizations/organization-members.shared.resources-config.schemas.d.ts.map +1 -1
  572. package/dist/esm/organizations/organization-members.shared.resources-config.schemas.js.map +1 -1
  573. package/dist/esm/organizations/organization-members.shared.schemas.d.ts.map +1 -1
  574. package/dist/esm/organizations/organization-members.shared.schemas.js.map +1 -1
  575. package/dist/esm/organizations/organization-notifications.shared.resources-config.schemas.d.ts.map +1 -1
  576. package/dist/esm/organizations/organization-notifications.shared.resources-config.schemas.js.map +1 -1
  577. package/dist/esm/organizations/organization-notifications.shared.schemas.d.ts.map +1 -1
  578. package/dist/esm/organizations/organization-notifications.shared.schemas.js.map +1 -1
  579. package/dist/esm/organizations/organization-preferences.shared.resources-config.schemas.d.ts.map +1 -1
  580. package/dist/esm/organizations/organization-preferences.shared.resources-config.schemas.js.map +1 -1
  581. package/dist/esm/organizations/organization-preferences.shared.schemas.d.ts.map +1 -1
  582. package/dist/esm/organizations/organization-preferences.shared.schemas.js.map +1 -1
  583. package/dist/esm/organizations/organization-profile.shared.resources-config.schemas.d.ts.map +1 -1
  584. package/dist/esm/organizations/organization-profile.shared.resources-config.schemas.js.map +1 -1
  585. package/dist/esm/organizations/organization-profile.shared.schemas.d.ts.map +1 -1
  586. package/dist/esm/organizations/organization-profile.shared.schemas.js.map +1 -1
  587. package/dist/esm/organizations/organization-unit-inheritance.shared.d.ts.map +1 -1
  588. package/dist/esm/organizations/organization-unit-inheritance.shared.js.map +1 -1
  589. package/dist/esm/organizations/organization-unit-members.shared.resources-config.schemas.d.ts.map +1 -1
  590. package/dist/esm/organizations/organization-unit-members.shared.resources-config.schemas.js.map +1 -1
  591. package/dist/esm/organizations/organization-unit-members.shared.schemas.d.ts.map +1 -1
  592. package/dist/esm/organizations/organization-unit-members.shared.schemas.js.map +1 -1
  593. package/dist/esm/organizations/organization-unit-narrowing-decision.shared.d.ts.map +1 -1
  594. package/dist/esm/organizations/organization-unit-narrowing-decision.shared.js.map +1 -1
  595. package/dist/esm/organizations/organization-unit-narrowing.example.d.ts.map +1 -1
  596. package/dist/esm/organizations/organization-unit-narrowing.example.js.map +1 -1
  597. package/dist/esm/organizations/organization-unit-narrowing.shared.d.ts.map +1 -1
  598. package/dist/esm/organizations/organization-unit-narrowing.shared.js.map +1 -1
  599. package/dist/esm/organizations/organization-units.shared.path.d.ts.map +1 -1
  600. package/dist/esm/organizations/organization-units.shared.path.js.map +1 -1
  601. package/dist/esm/organizations/organization-units.shared.resources-config.schemas.d.ts.map +1 -1
  602. package/dist/esm/organizations/organization-units.shared.resources-config.schemas.js.map +1 -1
  603. package/dist/esm/organizations/organization-units.shared.schemas.d.ts.map +1 -1
  604. package/dist/esm/organizations/organization-units.shared.schemas.js.map +1 -1
  605. package/dist/esm/organizations/organizations.shared.resources-config.schemas.d.ts.map +1 -1
  606. package/dist/esm/organizations/organizations.shared.resources-config.schemas.js.map +1 -1
  607. package/dist/esm/organizations/organizations.shared.schemas.d.ts.map +1 -1
  608. package/dist/esm/organizations/organizations.shared.schemas.js.map +1 -1
  609. package/dist/esm/organizations/service-provider-activity-feed.shared.resources-config.schemas.d.ts.map +1 -1
  610. package/dist/esm/organizations/service-provider-activity-feed.shared.resources-config.schemas.js.map +1 -1
  611. package/dist/esm/organizations/service-provider-activity-feed.shared.schemas.d.ts.map +1 -1
  612. package/dist/esm/organizations/service-provider-activity-feed.shared.schemas.js.map +1 -1
  613. package/dist/esm/organizations/service-provider-capability-grants.shared.resources-config.schemas.d.ts.map +1 -1
  614. package/dist/esm/organizations/service-provider-capability-grants.shared.resources-config.schemas.js.map +1 -1
  615. package/dist/esm/organizations/service-provider-capability-grants.shared.schemas.d.ts.map +1 -1
  616. package/dist/esm/organizations/service-provider-capability-grants.shared.schemas.js.map +1 -1
  617. package/dist/esm/organizations/service-provider-client-controls.shared.schemas.d.ts.map +1 -1
  618. package/dist/esm/organizations/service-provider-client-controls.shared.schemas.js.map +1 -1
  619. package/dist/esm/organizations/service-provider-relationships.shared.resources-config.schemas.d.ts.map +1 -1
  620. package/dist/esm/organizations/service-provider-relationships.shared.resources-config.schemas.js.map +1 -1
  621. package/dist/esm/organizations/service-provider-relationships.shared.schemas.d.ts.map +1 -1
  622. package/dist/esm/organizations/service-provider-relationships.shared.schemas.js.map +1 -1
  623. package/dist/esm/organizations/tenant-teardown-config.shared.schemas.d.ts.map +1 -1
  624. package/dist/esm/organizations/tenant-teardown-config.shared.schemas.js.map +1 -1
  625. package/dist/esm/provider-registration-runtime.exports.d.ts.map +1 -1
  626. package/dist/esm/provider-registration-runtime.exports.js.map +1 -1
  627. package/dist/esm/public-runtime/index.d.ts +13 -0
  628. package/dist/esm/public-runtime/index.d.ts.map +1 -1
  629. package/dist/esm/public-runtime/index.js +13 -0
  630. package/dist/esm/public-runtime/index.js.map +1 -1
  631. package/dist/esm/queue/jobs.shared.resources-config.schemas.d.ts.map +1 -1
  632. package/dist/esm/queue/jobs.shared.resources-config.schemas.js.map +1 -1
  633. package/dist/esm/queue/jobs.shared.schemas.d.ts +71 -2
  634. package/dist/esm/queue/jobs.shared.schemas.d.ts.map +1 -1
  635. package/dist/esm/queue/jobs.shared.schemas.js +85 -2
  636. package/dist/esm/queue/jobs.shared.schemas.js.map +1 -1
  637. package/dist/esm/queue/jobs.shared.utils.d.ts.map +1 -1
  638. package/dist/esm/queue/jobs.shared.utils.js.map +1 -1
  639. package/dist/esm/queue/queues.shared.schemas.d.ts.map +1 -1
  640. package/dist/esm/queue/queues.shared.schemas.js.map +1 -1
  641. package/dist/esm/queue/queues.shared.utils.d.ts.map +1 -1
  642. package/dist/esm/queue/queues.shared.utils.js.map +1 -1
  643. package/dist/esm/queue/rabbitmq-queue-args.shared.d.ts.map +1 -1
  644. package/dist/esm/queue/rabbitmq-queue-args.shared.js.map +1 -1
  645. package/dist/esm/rag/rag-retrieval-health.shared.d.ts.map +1 -1
  646. package/dist/esm/rag/rag-retrieval-health.shared.js.map +1 -1
  647. package/dist/esm/requests/header-keys.shared.d.ts.map +1 -1
  648. package/dist/esm/requests/header-keys.shared.js.map +1 -1
  649. package/dist/esm/requests/http-requests.shared.d.ts.map +1 -1
  650. package/dist/esm/requests/http-requests.shared.js.map +1 -1
  651. package/dist/esm/requests/idempotency-key.shared.d.ts.map +1 -1
  652. package/dist/esm/requests/idempotency-key.shared.js.map +1 -1
  653. package/dist/esm/requests/manual-controllers-routes-documentation.d.ts.map +1 -1
  654. package/dist/esm/requests/manual-controllers-routes-documentation.js.map +1 -1
  655. package/dist/esm/requests/manual-controllers-routes-urls.d.ts.map +1 -1
  656. package/dist/esm/requests/manual-controllers-routes-urls.js.map +1 -1
  657. package/dist/esm/requests/rate-limits.shared.schemas.d.ts.map +1 -1
  658. package/dist/esm/requests/rate-limits.shared.schemas.js.map +1 -1
  659. package/dist/esm/requests/websocket.shared.schemas.d.ts +2 -2
  660. package/dist/esm/requests/websocket.shared.schemas.d.ts.map +1 -1
  661. package/dist/esm/requests/websocket.shared.schemas.js.map +1 -1
  662. package/dist/esm/resources/child-operations.shared.schemas.d.ts.map +1 -1
  663. package/dist/esm/resources/child-operations.shared.schemas.js.map +1 -1
  664. package/dist/esm/resources/collection-query-parameters.shared.d.ts.map +1 -1
  665. package/dist/esm/resources/collection-query-parameters.shared.js.map +1 -1
  666. package/dist/esm/resources/context-policy.shared.schemas.d.ts.map +1 -1
  667. package/dist/esm/resources/context-policy.shared.schemas.js.map +1 -1
  668. package/dist/esm/resources/embedded-resource-mark.shared.utils.d.ts.map +1 -1
  669. package/dist/esm/resources/embedded-resource-mark.shared.utils.js.map +1 -1
  670. package/dist/esm/resources/relationship-display.shared.schemas.d.ts.map +1 -1
  671. package/dist/esm/resources/relationship-display.shared.schemas.js.map +1 -1
  672. package/dist/esm/resources/resource-status-lifecycle.example.d.ts +100 -0
  673. package/dist/esm/resources/resource-status-lifecycle.example.d.ts.map +1 -0
  674. package/dist/esm/resources/resource-status-lifecycle.example.js +156 -0
  675. package/dist/esm/resources/resource-status-lifecycle.example.js.map +1 -0
  676. package/dist/esm/resources/resources-config.shared.factory.d.ts +25 -1
  677. package/dist/esm/resources/resources-config.shared.factory.d.ts.map +1 -1
  678. package/dist/esm/resources/resources-config.shared.factory.js +31 -8
  679. package/dist/esm/resources/resources-config.shared.factory.js.map +1 -1
  680. package/dist/esm/resources/resources-config.shared.schemas.d.ts +33 -0
  681. package/dist/esm/resources/resources-config.shared.schemas.d.ts.map +1 -1
  682. package/dist/esm/resources/resources-config.shared.schemas.js.map +1 -1
  683. package/dist/esm/resources/resources-registry.shared.core.definitions.d.ts.map +1 -1
  684. package/dist/esm/resources/resources-registry.shared.core.definitions.js.map +1 -1
  685. package/dist/esm/resources/resources-relationships.shared.factory.d.ts.map +1 -1
  686. package/dist/esm/resources/resources-relationships.shared.factory.js.map +1 -1
  687. package/dist/esm/resources/resources-serialization.shared.schemas.d.ts.map +1 -1
  688. package/dist/esm/resources/resources-serialization.shared.schemas.js.map +1 -1
  689. package/dist/esm/resources/resources.shared.core.definitions.d.ts.map +1 -1
  690. package/dist/esm/resources/resources.shared.core.definitions.js.map +1 -1
  691. package/dist/esm/resources/resources.shared.schemas.d.ts.map +1 -1
  692. package/dist/esm/resources/resources.shared.schemas.js.map +1 -1
  693. package/dist/esm/resources/resources.shared.utils.d.ts.map +1 -1
  694. package/dist/esm/resources/resources.shared.utils.js.map +1 -1
  695. package/dist/esm/resources/utils/collection-export.shared.utils.d.ts.map +1 -1
  696. package/dist/esm/resources/utils/collection-export.shared.utils.js.map +1 -1
  697. package/dist/esm/resources/utils/composition-cascade-deletability.validation.d.ts.map +1 -1
  698. package/dist/esm/resources/utils/composition-cascade-deletability.validation.js.map +1 -1
  699. package/dist/esm/resources/utils/composition-seedability.validation.d.ts.map +1 -1
  700. package/dist/esm/resources/utils/composition-seedability.validation.js.map +1 -1
  701. package/dist/esm/resources/utils/context-addressed-composition-singleton.shared.utils.d.ts.map +1 -1
  702. package/dist/esm/resources/utils/context-addressed-composition-singleton.shared.utils.js.map +1 -1
  703. package/dist/esm/resources/utils/dependent-lifecycle-classification.validation.d.ts.map +1 -1
  704. package/dist/esm/resources/utils/dependent-lifecycle-classification.validation.js.map +1 -1
  705. package/dist/esm/resources/utils/duplicate-relationship-registration.validation.d.ts.map +1 -1
  706. package/dist/esm/resources/utils/duplicate-relationship-registration.validation.js.map +1 -1
  707. package/dist/esm/resources/utils/field-value-disclosure.utils.d.ts.map +1 -1
  708. package/dist/esm/resources/utils/field-value-disclosure.utils.js.map +1 -1
  709. package/dist/esm/resources/utils/http-api-write-declaration.shared.utils.d.ts.map +1 -1
  710. package/dist/esm/resources/utils/http-api-write-declaration.shared.utils.js.map +1 -1
  711. package/dist/esm/resources/utils/initiator-stamped-field-satisfiability.validation.d.ts.map +1 -1
  712. package/dist/esm/resources/utils/initiator-stamped-field-satisfiability.validation.js.map +1 -1
  713. package/dist/esm/resources/utils/no-subject-data-stance-coherence.shared.utils.d.ts.map +1 -1
  714. package/dist/esm/resources/utils/no-subject-data-stance-coherence.shared.utils.js.map +1 -1
  715. package/dist/esm/resources/utils/persistence-adapter-discrimination.shared.utils.d.ts.map +1 -1
  716. package/dist/esm/resources/utils/persistence-adapter-discrimination.shared.utils.js.map +1 -1
  717. package/dist/esm/resources/utils/populated-file-fields.shared.utils.d.ts.map +1 -1
  718. package/dist/esm/resources/utils/populated-file-fields.shared.utils.js.map +1 -1
  719. package/dist/esm/resources/utils/repository-dto-builder.utils.d.ts.map +1 -1
  720. package/dist/esm/resources/utils/repository-dto-builder.utils.js.map +1 -1
  721. package/dist/esm/resources/utils/request-schema-field-carriage.shared.utils.d.ts.map +1 -1
  722. package/dist/esm/resources/utils/request-schema-field-carriage.shared.utils.js.map +1 -1
  723. package/dist/esm/resources/utils/required-fk-fillability.validation.d.ts.map +1 -1
  724. package/dist/esm/resources/utils/required-fk-fillability.validation.js.map +1 -1
  725. package/dist/esm/resources/utils/resource-operation-type-guards.utils.d.ts.map +1 -1
  726. package/dist/esm/resources/utils/resource-operation-type-guards.utils.js.map +1 -1
  727. package/dist/esm/resources/utils/resource-polymorphism.factory.d.ts.map +1 -1
  728. package/dist/esm/resources/utils/resource-polymorphism.factory.js.map +1 -1
  729. package/dist/esm/resources/utils/resource-polymorphism.relationships.d.ts.map +1 -1
  730. package/dist/esm/resources/utils/resource-polymorphism.relationships.js.map +1 -1
  731. package/dist/esm/resources/utils/resource-polymorphism.schemas.d.ts.map +1 -1
  732. package/dist/esm/resources/utils/resource-polymorphism.schemas.js.map +1 -1
  733. package/dist/esm/resources/utils/resource-polymorphism.utils.d.ts.map +1 -1
  734. package/dist/esm/resources/utils/resource-polymorphism.utils.js.map +1 -1
  735. package/dist/esm/resources/utils/resource-subtree.utils.d.ts.map +1 -1
  736. package/dist/esm/resources/utils/resource-subtree.utils.js.map +1 -1
  737. package/dist/esm/resources/utils/resources-config-context-needs.utils.d.ts.map +1 -1
  738. package/dist/esm/resources/utils/resources-config-context-needs.utils.js.map +1 -1
  739. package/dist/esm/resources/utils/resources-config-naming.utils.d.ts.map +1 -1
  740. package/dist/esm/resources/utils/resources-config-naming.utils.js.map +1 -1
  741. package/dist/esm/resources/utils/resources-config-operations.dtos-builder.utils.d.ts +25 -0
  742. package/dist/esm/resources/utils/resources-config-operations.dtos-builder.utils.d.ts.map +1 -1
  743. package/dist/esm/resources/utils/resources-config-operations.dtos-builder.utils.js +47 -19
  744. package/dist/esm/resources/utils/resources-config-operations.dtos-builder.utils.js.map +1 -1
  745. package/dist/esm/resources/utils/resources-config-operations.path.utils.d.ts.map +1 -1
  746. package/dist/esm/resources/utils/resources-config-operations.path.utils.js.map +1 -1
  747. package/dist/esm/resources/utils/resources-config-operations.urls-builder.utils.d.ts.map +1 -1
  748. package/dist/esm/resources/utils/resources-config-operations.urls-builder.utils.js.map +1 -1
  749. package/dist/esm/resources/utils/resources-config-operations.utils.d.ts.map +1 -1
  750. package/dist/esm/resources/utils/resources-config-operations.utils.js.map +1 -1
  751. package/dist/esm/resources/utils/resources-serialization.utils.d.ts.map +1 -1
  752. package/dist/esm/resources/utils/resources-serialization.utils.js.map +1 -1
  753. package/dist/esm/resources/utils/resources-summary.utils.d.ts.map +1 -1
  754. package/dist/esm/resources/utils/resources-summary.utils.js.map +1 -1
  755. package/dist/esm/resources/utils/schema-family-builder.utils.d.ts.map +1 -1
  756. package/dist/esm/resources/utils/schema-family-builder.utils.js.map +1 -1
  757. package/dist/esm/resources/utils/schema-type-inference.utils.d.ts.map +1 -1
  758. package/dist/esm/resources/utils/schema-type-inference.utils.js.map +1 -1
  759. package/dist/esm/resources/utils/schema-type-utils.d.ts.map +1 -1
  760. package/dist/esm/resources/utils/schema-type-utils.js.map +1 -1
  761. package/dist/esm/resources/utils/schema-variant-resolver.utils.d.ts.map +1 -1
  762. package/dist/esm/resources/utils/schema-variant-resolver.utils.js.map +1 -1
  763. package/dist/esm/resources/utils/shared-persistence-collection.utils.d.ts.map +1 -1
  764. package/dist/esm/resources/utils/shared-persistence-collection.utils.js.map +1 -1
  765. package/dist/esm/resources/utils/templatable-file-fields.shared.utils.d.ts.map +1 -1
  766. package/dist/esm/resources/utils/templatable-file-fields.shared.utils.js.map +1 -1
  767. package/dist/esm/resources/work-unit.shared.schemas.d.ts.map +1 -1
  768. package/dist/esm/resources/work-unit.shared.schemas.js.map +1 -1
  769. package/dist/esm/runtime/domain-module.shared.definitions.d.ts.map +1 -1
  770. package/dist/esm/runtime/domain-module.shared.definitions.js.map +1 -1
  771. package/dist/esm/runtime/execution-context.shared.schemas.d.ts.map +1 -1
  772. package/dist/esm/runtime/execution-context.shared.schemas.js.map +1 -1
  773. package/dist/esm/runtime/runtime.shared.schemas.d.ts.map +1 -1
  774. package/dist/esm/runtime/runtime.shared.schemas.js.map +1 -1
  775. package/dist/esm/security/api-keys/api-keys-application.shared.resources-config.schemas.d.ts.map +1 -1
  776. package/dist/esm/security/api-keys/api-keys-application.shared.resources-config.schemas.js.map +1 -1
  777. package/dist/esm/security/api-keys/api-keys-organization.shared.resources-config.schemas.d.ts.map +1 -1
  778. package/dist/esm/security/api-keys/api-keys-organization.shared.resources-config.schemas.js.map +1 -1
  779. package/dist/esm/security/api-keys/api-keys.shared.schemas.d.ts.map +1 -1
  780. package/dist/esm/security/api-keys/api-keys.shared.schemas.js.map +1 -1
  781. package/dist/esm/security/authentications/anonymous-session/anonymous-session.shared.contract.d.ts.map +1 -1
  782. package/dist/esm/security/authentications/anonymous-session/anonymous-session.shared.contract.js.map +1 -1
  783. package/dist/esm/security/authentications/authentication.shared.dto.schemas.d.ts.map +1 -1
  784. package/dist/esm/security/authentications/authentication.shared.dto.schemas.js.map +1 -1
  785. package/dist/esm/security/authentications/authentication.shared.schemas.d.ts.map +1 -1
  786. package/dist/esm/security/authentications/authentication.shared.schemas.js.map +1 -1
  787. package/dist/esm/security/authentications/authentication.shared.utils.d.ts.map +1 -1
  788. package/dist/esm/security/authentications/authentication.shared.utils.js.map +1 -1
  789. package/dist/esm/security/authentications/consumable-token.shared.schemas.d.ts.map +1 -1
  790. package/dist/esm/security/authentications/consumable-token.shared.schemas.js.map +1 -1
  791. package/dist/esm/security/authentications/cross-frontend-handoff.shared.dto.schemas.d.ts.map +1 -1
  792. package/dist/esm/security/authentications/cross-frontend-handoff.shared.dto.schemas.js.map +1 -1
  793. package/dist/esm/security/authentications/mfa-backup-code-contract.shared.d.ts.map +1 -1
  794. package/dist/esm/security/authentications/mfa-backup-code-contract.shared.js.map +1 -1
  795. package/dist/esm/security/authentications/password-blocklist.shared.utils.d.ts.map +1 -1
  796. package/dist/esm/security/authentications/password-blocklist.shared.utils.js.map +1 -1
  797. package/dist/esm/security/authentications/password-reset.shared.dto.schemas.d.ts.map +1 -1
  798. package/dist/esm/security/authentications/password-reset.shared.dto.schemas.js.map +1 -1
  799. package/dist/esm/security/authentications/registration.shared.dto.schemas.d.ts.map +1 -1
  800. package/dist/esm/security/authentications/registration.shared.dto.schemas.js.map +1 -1
  801. package/dist/esm/security/authentications/same-origin-redirect-path.shared.d.ts.map +1 -1
  802. package/dist/esm/security/authentications/same-origin-redirect-path.shared.js.map +1 -1
  803. package/dist/esm/security/authentications/scim/scim-organization-unit-mapping.shared.d.ts.map +1 -1
  804. package/dist/esm/security/authentications/scim/scim-organization-unit-mapping.shared.js.map +1 -1
  805. package/dist/esm/security/authentications/scim/scim-provisioning-config.shared.resources-config.schemas.d.ts.map +1 -1
  806. package/dist/esm/security/authentications/scim/scim-provisioning-config.shared.resources-config.schemas.js.map +1 -1
  807. package/dist/esm/security/authentications/scim/scim-provisioning-config.shared.schemas.d.ts.map +1 -1
  808. package/dist/esm/security/authentications/scim/scim-provisioning-config.shared.schemas.js.map +1 -1
  809. package/dist/esm/security/authentications/scim/scim-tokens.shared.resources-config.schemas.d.ts.map +1 -1
  810. package/dist/esm/security/authentications/scim/scim-tokens.shared.resources-config.schemas.js.map +1 -1
  811. package/dist/esm/security/authentications/scim/scim-tokens.shared.schemas.d.ts.map +1 -1
  812. package/dist/esm/security/authentications/scim/scim-tokens.shared.schemas.js.map +1 -1
  813. package/dist/esm/security/authentications/service-provider-client-authentication.shared.schemas.d.ts.map +1 -1
  814. package/dist/esm/security/authentications/service-provider-client-authentication.shared.schemas.js.map +1 -1
  815. package/dist/esm/security/authentications/siem/siem-delivery-dlq.shared.resources-config.schemas.d.ts.map +1 -1
  816. package/dist/esm/security/authentications/siem/siem-delivery-dlq.shared.resources-config.schemas.js.map +1 -1
  817. package/dist/esm/security/authentications/siem/siem-delivery-dlq.shared.schemas.d.ts.map +1 -1
  818. package/dist/esm/security/authentications/siem/siem-delivery-dlq.shared.schemas.js.map +1 -1
  819. package/dist/esm/security/authentications/siem/siem-delivery-outbox.shared.resources-config.schemas.d.ts.map +1 -1
  820. package/dist/esm/security/authentications/siem/siem-delivery-outbox.shared.resources-config.schemas.js.map +1 -1
  821. package/dist/esm/security/authentications/siem/siem-delivery-outbox.shared.schemas.d.ts.map +1 -1
  822. package/dist/esm/security/authentications/siem/siem-delivery-outbox.shared.schemas.js.map +1 -1
  823. package/dist/esm/security/authentications/siem/siem-delivery-reliability-contract.shared.d.ts.map +1 -1
  824. package/dist/esm/security/authentications/siem/siem-delivery-reliability-contract.shared.js.map +1 -1
  825. package/dist/esm/security/authentications/siem/siem-export-config.shared.resources-config.schemas.d.ts.map +1 -1
  826. package/dist/esm/security/authentications/siem/siem-export-config.shared.resources-config.schemas.js.map +1 -1
  827. package/dist/esm/security/authentications/siem/siem-export-config.shared.schemas.d.ts.map +1 -1
  828. package/dist/esm/security/authentications/siem/siem-export-config.shared.schemas.js.map +1 -1
  829. package/dist/esm/security/authentications/sso/sso-config.shared.resources-config.schemas.d.ts.map +1 -1
  830. package/dist/esm/security/authentications/sso/sso-config.shared.resources-config.schemas.js.map +1 -1
  831. package/dist/esm/security/authentications/sso/sso-config.shared.schemas.d.ts.map +1 -1
  832. package/dist/esm/security/authentications/sso/sso-config.shared.schemas.js.map +1 -1
  833. package/dist/esm/security/authentications/sso/sso-connection.shared.resources-config.schemas.d.ts.map +1 -1
  834. package/dist/esm/security/authentications/sso/sso-connection.shared.resources-config.schemas.js.map +1 -1
  835. package/dist/esm/security/authentications/sso/sso-connection.shared.schemas.d.ts.map +1 -1
  836. package/dist/esm/security/authentications/sso/sso-connection.shared.schemas.js.map +1 -1
  837. package/dist/esm/security/authorizations/administrative-continuity.shared.schemas.d.ts.map +1 -1
  838. package/dist/esm/security/authorizations/administrative-continuity.shared.schemas.js.map +1 -1
  839. package/dist/esm/security/authorizations/application-access-grants.shared.resources-config.schemas.d.ts.map +1 -1
  840. package/dist/esm/security/authorizations/application-access-grants.shared.resources-config.schemas.js.map +1 -1
  841. package/dist/esm/security/authorizations/application-access-grants.shared.schemas.d.ts.map +1 -1
  842. package/dist/esm/security/authorizations/application-access-grants.shared.schemas.js.map +1 -1
  843. package/dist/esm/security/authorizations/platform-access-grants.shared.resources-config.schemas.d.ts.map +1 -1
  844. package/dist/esm/security/authorizations/platform-access-grants.shared.resources-config.schemas.js.map +1 -1
  845. package/dist/esm/security/authorizations/platform-access-grants.shared.schemas.d.ts.map +1 -1
  846. package/dist/esm/security/authorizations/platform-access-grants.shared.schemas.js.map +1 -1
  847. package/dist/esm/security/authorizations/roles.application-roles.example.d.ts +37 -0
  848. package/dist/esm/security/authorizations/roles.application-roles.example.d.ts.map +1 -0
  849. package/dist/esm/security/authorizations/roles.application-roles.example.js +50 -0
  850. package/dist/esm/security/authorizations/roles.application-roles.example.js.map +1 -0
  851. package/dist/esm/security/authorizations/roles.shared.defaults.d.ts +13 -0
  852. package/dist/esm/security/authorizations/roles.shared.defaults.d.ts.map +1 -1
  853. package/dist/esm/security/authorizations/roles.shared.defaults.js +13 -0
  854. package/dist/esm/security/authorizations/roles.shared.defaults.js.map +1 -1
  855. package/dist/esm/security/authorizations/roles.shared.schemas.d.ts +29 -0
  856. package/dist/esm/security/authorizations/roles.shared.schemas.d.ts.map +1 -1
  857. package/dist/esm/security/authorizations/roles.shared.schemas.js +28 -0
  858. package/dist/esm/security/authorizations/roles.shared.schemas.js.map +1 -1
  859. package/dist/esm/security/authorizations/roles.shared.utils.d.ts.map +1 -1
  860. package/dist/esm/security/authorizations/roles.shared.utils.js.map +1 -1
  861. package/dist/esm/security/connected-accounts/provider-connection-listing.shared.schemas.d.ts.map +1 -1
  862. package/dist/esm/security/connected-accounts/provider-connection-listing.shared.schemas.js.map +1 -1
  863. package/dist/esm/security/connected-accounts/provider-credentials-organization.shared.resources-config.schemas.d.ts.map +1 -1
  864. package/dist/esm/security/connected-accounts/provider-credentials-organization.shared.resources-config.schemas.js.map +1 -1
  865. package/dist/esm/security/connected-accounts/provider-credentials-user.shared.resources-config.schemas.d.ts.map +1 -1
  866. package/dist/esm/security/connected-accounts/provider-credentials-user.shared.resources-config.schemas.js.map +1 -1
  867. package/dist/esm/security/connected-accounts/provider-credentials.shared.schemas.d.ts.map +1 -1
  868. package/dist/esm/security/connected-accounts/provider-credentials.shared.schemas.js.map +1 -1
  869. package/dist/esm/security/credential-rotation-grace.shared.utils.d.ts.map +1 -1
  870. package/dist/esm/security/credential-rotation-grace.shared.utils.js.map +1 -1
  871. package/dist/esm/security/crypto-keys/crypto-keys.shared.schemas.d.ts.map +1 -1
  872. package/dist/esm/security/crypto-keys/crypto-keys.shared.schemas.js.map +1 -1
  873. package/dist/esm/security/oauth-clients/oauth-clients-application.shared.resources-config.schemas.d.ts.map +1 -1
  874. package/dist/esm/security/oauth-clients/oauth-clients-application.shared.resources-config.schemas.js.map +1 -1
  875. package/dist/esm/security/oauth-clients/oauth-clients-organization.shared.resources-config.schemas.d.ts.map +1 -1
  876. package/dist/esm/security/oauth-clients/oauth-clients-organization.shared.resources-config.schemas.js.map +1 -1
  877. package/dist/esm/security/oauth-clients/oauth-clients.shared.schemas.d.ts.map +1 -1
  878. package/dist/esm/security/oauth-clients/oauth-clients.shared.schemas.js.map +1 -1
  879. package/dist/esm/security/oauth-clients/oauth-consent-grants.shared.resources-config.schemas.d.ts.map +1 -1
  880. package/dist/esm/security/oauth-clients/oauth-consent-grants.shared.resources-config.schemas.js.map +1 -1
  881. package/dist/esm/security/oauth-clients/oauth-consent-grants.shared.schemas.d.ts.map +1 -1
  882. package/dist/esm/security/oauth-clients/oauth-consent-grants.shared.schemas.js.map +1 -1
  883. package/dist/esm/security/oauth-clients/oauth-resource-server.shared.schemas.d.ts.map +1 -1
  884. package/dist/esm/security/oauth-clients/oauth-resource-server.shared.schemas.js.map +1 -1
  885. package/dist/esm/security/outbound-target-control.shared.schemas.d.ts.map +1 -1
  886. package/dist/esm/security/outbound-target-control.shared.schemas.js.map +1 -1
  887. package/dist/esm/security/submission-challenge/submission-challenge.shared.d.ts.map +1 -1
  888. package/dist/esm/security/submission-challenge/submission-challenge.shared.js.map +1 -1
  889. package/dist/esm/systems-of-record/system-of-record-actions.shared.schemas.d.ts.map +1 -1
  890. package/dist/esm/systems-of-record/system-of-record-actions.shared.schemas.js.map +1 -1
  891. package/dist/esm/systems-of-record/system-of-record-credential-kind.shared.d.ts.map +1 -1
  892. package/dist/esm/systems-of-record/system-of-record-credential-kind.shared.js.map +1 -1
  893. package/dist/esm/systems-of-record/system-of-record-declaration.shared.schemas.d.ts.map +1 -1
  894. package/dist/esm/systems-of-record/system-of-record-declaration.shared.schemas.js.map +1 -1
  895. package/dist/esm/systems-of-record/system-of-record-env.shared.d.ts.map +1 -1
  896. package/dist/esm/systems-of-record/system-of-record-env.shared.js.map +1 -1
  897. package/dist/esm/systems-of-record/system-of-record-error-codes.shared.d.ts.map +1 -1
  898. package/dist/esm/systems-of-record/system-of-record-error-codes.shared.js.map +1 -1
  899. package/dist/esm/systems-of-record/system-of-record-facet.shared.schemas.d.ts.map +1 -1
  900. package/dist/esm/systems-of-record/system-of-record-facet.shared.schemas.js.map +1 -1
  901. package/dist/esm/systems-of-record/system-of-record-partition-assignments.shared.resources-config.schemas.d.ts.map +1 -1
  902. package/dist/esm/systems-of-record/system-of-record-partition-assignments.shared.resources-config.schemas.js.map +1 -1
  903. package/dist/esm/systems-of-record/system-of-record-partition-assignments.shared.schemas.d.ts.map +1 -1
  904. package/dist/esm/systems-of-record/system-of-record-partition-assignments.shared.schemas.js.map +1 -1
  905. package/dist/esm/testing/resource-config-builders.d.ts.map +1 -1
  906. package/dist/esm/testing/resource-config-builders.js.map +1 -1
  907. package/dist/esm/testing.d.ts.map +1 -1
  908. package/dist/esm/testing.js.map +1 -1
  909. package/dist/esm/users/anonymous-user-marketing-metadata.shared.schemas.d.ts.map +1 -1
  910. package/dist/esm/users/anonymous-user-marketing-metadata.shared.schemas.js.map +1 -1
  911. package/dist/esm/users/anonymous-users.shared.resources-config.schemas.d.ts.map +1 -1
  912. package/dist/esm/users/anonymous-users.shared.resources-config.schemas.js.map +1 -1
  913. package/dist/esm/users/anonymous-users.shared.schema.d.ts.map +1 -1
  914. package/dist/esm/users/anonymous-users.shared.schema.js.map +1 -1
  915. package/dist/esm/users/inbound-contacts.shared.resources-config.schemas.d.ts.map +1 -1
  916. package/dist/esm/users/inbound-contacts.shared.resources-config.schemas.js +2 -0
  917. package/dist/esm/users/inbound-contacts.shared.resources-config.schemas.js.map +1 -1
  918. package/dist/esm/users/inbound-contacts.shared.schemas.d.ts.map +1 -1
  919. package/dist/esm/users/inbound-contacts.shared.schemas.js.map +1 -1
  920. package/dist/esm/users/user-consent-decision.shared.utils.d.ts.map +1 -1
  921. package/dist/esm/users/user-consent-decision.shared.utils.js.map +1 -1
  922. package/dist/esm/users/user-credentials.shared.resources-config.schemas.d.ts.map +1 -1
  923. package/dist/esm/users/user-credentials.shared.resources-config.schemas.js.map +1 -1
  924. package/dist/esm/users/user-credentials.shared.schemas.d.ts.map +1 -1
  925. package/dist/esm/users/user-credentials.shared.schemas.js.map +1 -1
  926. package/dist/esm/users/user-identity-links.shared.resources-config.schemas.d.ts.map +1 -1
  927. package/dist/esm/users/user-identity-links.shared.resources-config.schemas.js.map +1 -1
  928. package/dist/esm/users/user-identity-links.shared.schemas.d.ts.map +1 -1
  929. package/dist/esm/users/user-identity-links.shared.schemas.js.map +1 -1
  930. package/dist/esm/users/user-preferences-reset.shared.utils.d.ts.map +1 -1
  931. package/dist/esm/users/user-preferences-reset.shared.utils.js.map +1 -1
  932. package/dist/esm/users/user-preferences.shared.resources-config.schemas.d.ts.map +1 -1
  933. package/dist/esm/users/user-preferences.shared.resources-config.schemas.js.map +1 -1
  934. package/dist/esm/users/user-profiles.shared.resources-config.schemas.d.ts.map +1 -1
  935. package/dist/esm/users/user-profiles.shared.resources-config.schemas.js.map +1 -1
  936. package/dist/esm/users/user-self-preferences.shared.resources-config.schemas.d.ts.map +1 -1
  937. package/dist/esm/users/user-self-preferences.shared.resources-config.schemas.js.map +1 -1
  938. package/dist/esm/users/user-self-profiles.shared.resources-config.schemas.d.ts.map +1 -1
  939. package/dist/esm/users/user-self-profiles.shared.resources-config.schemas.js.map +1 -1
  940. package/dist/esm/users/user-self.shared.resources-config.schemas.d.ts.map +1 -1
  941. package/dist/esm/users/user-self.shared.resources-config.schemas.js.map +1 -1
  942. package/dist/esm/users/users.shared.resources-config.schemas.d.ts.map +1 -1
  943. package/dist/esm/users/users.shared.resources-config.schemas.js.map +1 -1
  944. package/dist/esm/users/users.shared.schemas.d.ts.map +1 -1
  945. package/dist/esm/users/users.shared.schemas.js.map +1 -1
  946. package/dist/tsconfig.build.tsbuildinfo +1 -1
  947. package/package.json +4 -4
  948. package/dist/esm/__tests__/setup.d.ts +0 -2
  949. package/dist/esm/__tests__/setup.d.ts.map +0 -1
  950. package/dist/esm/__tests__/setup.js +0 -19
  951. package/dist/esm/__tests__/setup.js.map +0 -1
@@ -1 +1 @@
1
- {"version":3,"file":"webhook-config.shared.resources-config.schemas.js","sourceRoot":"","sources":["../../../../../src/notifications/m2m/webhook-config.shared.resources-config.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EACL,qBAAqB,EACrB,gBAAgB,GACjB,MAAM,mDAAmD,CAAC;AAC3D,OAAO,EACL,0BAA0B,EAC1B,4BAA4B,GAC7B,MAAM,0CAA0C,CAAC;AAClD,OAAO,EAAE,uCAAuC,EAAE,MAAM,qDAAqD,CAAC;AAC9G,OAAO,EAAE,wBAAwB,EAAE,MAAM,iDAAiD,CAAC;AAC3F,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,oDAAoD,CAAC;AACpG,OAAO,EAAE,mCAAmC,EAAE,2BAA2B,EAAE,MAAM,iCAAiC,CAAC;AAEnH,gFAAgF;AAChF,oBAAoB;AACpB,gFAAgF;AAEhF,MAAM,CAAN,IAAY,wBAkBX;AAlBD,WAAY,wBAAwB;IAClC;;;;;;;;;;;;;;;OAeG;IACH,0DAA8B,CAAA;AAChC,CAAC,EAlBW,wBAAwB,KAAxB,wBAAwB,QAkBnC;AAED,gFAAgF;AAChF,eAAe;AACf,gFAAgF;AAEhF,MAAM,CAAC,MAAM,oCAAoC,GAAG,CAAC,CAAC,MAAM,CAAC;IAC3D,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAA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AAQ;oBAClD,SAAS,EAAE,IAAI;oBACf,eAAe,EAAE;wBACf,CAAC,gBAAgB,CAAC,aAAa,CAAC,EAAE,CAAC,cAAc,CAAC,SAAS,CAAC;wBAC5D,CAAC,gBAAgB,CAAC,WAAW,CAAC,EAAE,CAAC,cAAc,CAAC,qBAAqB,CAAC;qBACvE;oBACD,SAAS,EAAE,0BAA0B,CAAC,MAAM;oBAC5C,qEAAqE;oBACrE,kEAAkE;oBAClE,qBAAqB,EAAE,qBAAqB,CAAC,MAAM;oBACnD,UAAU,EAAE,oCAAoC;oBAChD,iEAAiE;oBACjE,gEAAgE;oBAChE,oEAAoE;oBACpE,kEAAkE;oBAClE,qCAAqC;oBACrC,iBAAiB,EAAE,qCAAqC;iBACzD;aACF;SACF;KACF;CACF,CACF,CAAC","sourcesContent":["/**\n * M2M Webhook Config Resource Configuration — Polymorphic dual-scope\n *\n * Produces 2 factory functions (ORG + APP) via the polymorphic factory.\n * Spread into the registry factory map:\n * ...webhookConfigPolymorphicFactories\n *\n * Operation set (mirrors SIEM Export Config singleton precedent):\n * - READ (API) : admin reads the config + derived public key\n * - CREATE (REPOSITORY_ONLY) : seeded once per scope; not externally callable\n * - UPDATE (API_CALL) : the administrator's edit door; a PREFIX stamps each endpoint's\n * id and timestamps (see `WEBHOOK_CONFIG_WRITE_VARIANT_TYPE`)\n * - TEST_ENDPOINT (custom) : fires a synthetic delivery to verify URL reachability\n *\n * @see m2m-webhook-organization-delivery.md — Phase 2 / Step 5\n * @see security/authentications/siem/siem-export-config.shared.resources-config.schemas.ts\n */\n\nimport { z } from 'zod';\nimport {\n CoreResourceOperation,\n CoreResourceType,\n} from '../../resources/resources.shared.core.definitions';\nimport {\n ResourceOperationRiskLevel,\n ResourceOperationVariantType,\n} from '../../resources/resources.shared.schemas';\nimport { createPolymorphicResourceConfigurations } from '../../resources/utils/resource-polymorphism.factory';\nimport { ResourceSystemAccessMode } from '../../resources/resources-config.shared.schemas';\nimport { CORE_ORG_ROLES, CORE_APP_ROLES } from '../../security/authorizations/roles.shared.schemas';\nimport { webhookConfigPolymorphicDeclaration, WebhookEndpointProbeOutcome } from './webhook-config.shared.schemas';\n\n// =============================================================================\n// CUSTOM OPERATIONS\n// =============================================================================\n\nexport enum WebhookConfig_Operations {\n /**\n * Synthetic delivery to verify URL reachability + signature\n * verification on the consumer side. Targets a single endpoint\n * (selected by `endpointId` in the request body); does not write to\n * `M2MWebhookDeliveryLog` (test deliveries are excluded from the user\n * event log to keep the log clean).\n *\n * The probe is `resourceOperationLike: UPDATE`, NOT `READ`. It performs no\n * database write, but it DOES have an external side effect — a live signed\n * POST leaves the platform and arrives at a customer-controlled URL. Borrowing\n * READ made this a `GET` whose OpenAPI entry had to declare `x-idempotent: false`,\n * a self-contradiction, and pushed `endpointId` into a query string. Borrowing\n * UPDATE yields a `PUT` on the same custom-op sub-path, matching the\n * `M2MWebhookDeliveryLog.retry` precedent (also a no-DB-write-of-its-own verb\n * that triggers a delivery).\n */\n TEST_ENDPOINT = 'testEndpoint',\n}\n\n// =============================================================================\n// REQUEST DTOs\n// =============================================================================\n\nexport const WebhookConfig_TestEndpointRequestDto = z.object({\n endpointId: z.string().min(1).describe('The id of the configured endpoint to test. A disabled endpoint can be tested too.'),\n});\n\n// =============================================================================\n// RESPONSE DTOs\n// =============================================================================\n\n/**\n * Diagnostic returned synchronously by `testEndpoint`.\n *\n * A transport-level failure at the customer endpoint is a successful PROBE and\n * therefore answers HTTP 200 carrying `outcome: UNREACHABLE` — it is not an API\n * error. API errors are reserved for faults in the request itself (unknown\n * `endpointId`, no config row, rate limit exceeded).\n */\nexport const WebhookConfig_TestEndpointResponseDto = z.object({\n endpointId: z.string().describe('The endpoint that was tested.'),\n /** Destination actually contacted, echoed so the admin can confirm the stored URL. */\n url: z.string().describe('The destination URL that was contacted, as stored on the endpoint.'),\n /**\n * True when that destination is plaintext `http://`, so the signature JWT travelled in the clear.\n *\n * ## Why the exposure is reported HERE (#492)\n *\n * Plaintext endpoints are admitted, deliberately, and the reasoning is recorded on\n * `WebhookEndpointSchema.url`. The cost of admitting them is that the decision becomes invisible:\n * a documented exposure nobody encounters is the same as an undocumented one, and the JSDoc\n * reaches only someone reading the schema.\n *\n * This probe is the one place an admin acts on a SINGLE endpoint and reads a per-endpoint answer,\n * so it is where the exposure can actually be met. It rides beside `outcome` rather than replacing\n * it, because the two say different things: `ACCEPTED` over `http://` is a working endpoint AND a\n * credential on the wire, and collapsing that into a failure would be false.\n *\n * Reported for every outcome, including `NOT_SENT` — the scheme is a property of the stored\n * destination, not of the attempt, and an admin fixing a signing fault should still be told.\n */\n transportIsPlaintext: z\n .boolean()\n .describe('`true` when the destination uses plaintext `http://`, so the signature token travels in the clear. Reported for every outcome.'),\n outcome: z\n .enum(WebhookEndpointProbeOutcome)\n .describe(\n 'The result of the test: `accepted` (the endpoint answered 2xx), `rejected` (it answered with another status), `unreachable` (no HTTP response, including a timeout), or `not_sent` (the request could not be signed, so nothing was sent).',\n ),\n /** HTTP status returned by the endpoint. Absent for `UNREACHABLE` / `NOT_SENT`. */\n responseStatus: z.number().int().optional().describe('The HTTP status the endpoint answered with. Absent when it did not answer or nothing was sent.'),\n /** Truncated response body, to let an admin read the consumer's own error text. */\n responseBodyTruncated: z\n .string()\n .optional()\n .describe(\"The start of the endpoint's response body, cut to 4 KB (UTF-8), so you can read the endpoint's own error text. Absent when the body was empty or there was no response.\"),\n /** Network / timeout / signing failure detail. Absent when the endpoint answered. */\n failureReason: z\n .string()\n .optional()\n .describe('Why no response was received — a network error, a refused destination, the 30-second timeout, or a signing failure. Absent when the endpoint answered.'),\n durationMs: z.number().int().nonnegative().describe('How long the request took, in milliseconds. `0` when nothing was sent.'),\n /**\n * `jti` of the signed probe. Stated so an admin can correlate this attempt with\n * the entry in their own consumer's logs — the same dedup key a real delivery\n * carries.\n */\n signatureJti: z\n .string()\n .describe(\"The unique id of the signed test request — the same delivery-id claim a real delivery carries — so you can find this attempt in the endpoint's own logs.\"),\n attemptedAt: z.date().describe('When the test request was built and sent.'),\n});\n\n// =============================================================================\n// POLYMORPHIC FACTORY\n// =============================================================================\n\n/**\n * The variant type of the webhook config's UPDATE — read by the resource configuration below AND by\n * the UPDATE prefix that stamps each endpoint's id and timestamps (`webhook-config-update.custom-impl`,\n * #1801).\n *\n * One named value because the custom-implementation registry keys a registration on the FULL\n * operation path, variant type included: a hand-restated value that drifted would leave the prefix\n * unbound, and every save would again reset `createdAt` and freeze `updatedAt` while the update\n * itself reported success. Same reason, and same shape, as `SSO_CONFIG_WRITE_VARIANT_TYPE`.\n */\nexport const WEBHOOK_CONFIG_WRITE_VARIANT_TYPE: Readonly<{\n // Exact member, not the enum: a variant is a union DISCRIMINATED by `variantType`.\n [CoreResourceOperation.UPDATE]: ResourceOperationVariantType.API_CALL;\n}> = {\n [CoreResourceOperation.UPDATE]: ResourceOperationVariantType.API_CALL,\n};\n\nexport const webhookConfigPolymorphicFactories = createPolymorphicResourceConfigurations(\n webhookConfigPolymorphicDeclaration,\n {\n isSystemResource: true,\n // Server-internal webhook delivery loads the (org/app) endpoint config via\n // `readAsSystem`, independent of the triggering user's roles — the config\n // governs runtime delivery behaviour, not user-facing data.\n //\n // CREATE joined it on 2026-09-18, matching the three enterprise-config singletons\n // (SSO / SCIM / SIEM) this resource is otherwise shaped like. It said \"READ-only\"\n // because, unlike them, it had no lazy materialiser of its own — not because a default\n // row would be wrong. #1179's seam reads this declaration before materialising a\n // context-addressed singleton on an UPDATE or DELETE the caller never named, so an\n // administrator can start configuring webhooks for a scope that has no row yet.\n //\n // It does NOT make a READ materialise — measured 2026-09-19, that seam is never entered on\n // the read route — so an unconfigured scope still 404s when the settings pane reads it.\n // Making the row exist for an organization that predates the `afterCreate` default seed is\n // a SEEDING question, and is where that defect belongs.\n systemAccessPolicy: {\n read: ResourceSystemAccessMode.ALLOWED,\n create: ResourceSystemAccessMode.ALLOWED,\n },\n customOperation: WebhookConfig_Operations,\n coreOperations: [\n CoreResourceOperation.READ,\n CoreResourceOperation.CREATE,\n CoreResourceOperation.UPDATE,\n CoreResourceOperation.DELETE,\n ],\n operationsConfiguration: {\n [CoreResourceOperation.READ]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.API_CALL,\n isDefault: true,\n polymorphicRole: {\n [CoreResourceType.ORGANIZATIONS]: [CORE_ORG_ROLES.ORG_ADMIN],\n [CoreResourceType.APPLICATION]: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n },\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.CREATE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n polymorphicRole: {\n [CoreResourceType.ORGANIZATIONS]: [CORE_ORG_ROLES.ORG_ADMIN],\n [CoreResourceType.APPLICATION]: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n },\n riskLevel: ResourceOperationRiskLevel.MEDIUM,\n },\n ],\n },\n /*\n * API_CALL — the administrator's edit door, and the only caller of this write.\n *\n * It was REPOSITORY_ONLY, which is route-less, and nothing in the engine called it: the\n * scope's row is seeded by `webhook-config-defaults.seeds.ts` through CREATE, the two\n * registered custom implementations are keyed on READ and on `testEndpoint`, and\n * `WebhookConfigBackendService` never updates. So the declared write had no caller on either\n * side of the boundary — no route for an administrator, no service reaching it internally —\n * and a webhook configuration is nothing BUT settings: whether outbound delivery is on, the\n * endpoints, the event selection, the retry posture.\n *\n * Worse than unreachable, and this is why it moved rather than being deleted: with no\n * addressable literal `update`, the frontend's update resolution fell through to whatever\n * operation borrowed UPDATE semantics — and here that is `testEndpoint`\n * (`resourceOperationLike: UPDATE`, API_CALL). Every writable field on the webhook settings\n * pane was a control that would have FIRED A TEST DELIVERY at the configured endpoint instead\n * of saving. `pickInlineFieldWriteOperation` now refuses a borrowed verb outright, so the\n * mis-wiring is closed whatever this variant says; the door is what makes the pane work.\n *\n * A PREFIX is registered on it (#1801): the endpoints array is written whole, so the prefix\n * matches each incoming endpoint to its stored self by `id`, keeps the stored `createdAt`,\n * advances `updatedAt` only for an endpoint whose settings changed, and assigns an id and both\n * timestamps to a new one. Its variant type is `WEBHOOK_CONFIG_WRITE_VARIANT_TYPE`, which this\n * declaration reads too. Should an internal writer ever need the repository path,\n * `getInternalRepositoryOperationPathDefault` falls back to the URL-bearing default for exactly\n * this shape.\n *\n * CREATE stays REPOSITORY_ONLY beside it: the row is seeded once per scope and is never\n * created self-serve. Admin tier / MEDIUM, unchanged.\n */\n [CoreResourceOperation.UPDATE]: {\n variants: [\n {\n variantType: WEBHOOK_CONFIG_WRITE_VARIANT_TYPE[CoreResourceOperation.UPDATE],\n isDefault: true,\n polymorphicRole: {\n [CoreResourceType.ORGANIZATIONS]: [CORE_ORG_ROLES.ORG_ADMIN],\n [CoreResourceType.APPLICATION]: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n },\n riskLevel: ResourceOperationRiskLevel.MEDIUM,\n },\n ],\n },\n // Internal-only (REPOSITORY_ONLY, no HTTP route): powers the composition\n // onParentDelete cascade so this one-per-scope webhook-config row is physically\n // removed when its owning org/app is deleted. Without a DELETE op the cascade\n // (deleteChildrenImmediate) throws ErrorType.CONFIGURATION on any scope with a\n // config row. Admin tier (ORG_ADMIN / APP super-admin) / HIGH.\n [CoreResourceOperation.DELETE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n polymorphicRole: {\n [CoreResourceType.ORGANIZATIONS]: [CORE_ORG_ROLES.ORG_ADMIN],\n [CoreResourceType.APPLICATION]: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n },\n riskLevel: ResourceOperationRiskLevel.HIGH,\n },\n ],\n },\n [WebhookConfig_Operations.TEST_ENDPOINT]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.API_CALL,\n isDefault: true,\n polymorphicRole: {\n [CoreResourceType.ORGANIZATIONS]: [CORE_ORG_ROLES.ORG_ADMIN],\n [CoreResourceType.APPLICATION]: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n },\n riskLevel: ResourceOperationRiskLevel.MEDIUM,\n // UPDATE-like, not READ-like — see the JSDoc on `TEST_ENDPOINT`. The\n // operation writes nothing, but it emits a live outbound request.\n resourceOperationLike: CoreResourceOperation.UPDATE,\n requestDto: WebhookConfig_TestEndpointRequestDto,\n // Implemented by `createWebhookConfigTestEndpointFactories()` in\n // saas-backend-lib (REPLACE_CORE_OPERATIONS): the core write is\n // replaced by the synthetic delivery, and this diagnostic — NOT the\n // config row — is what the caller receives. Keep this contract in\n // lockstep with that implementation.\n customResponseDto: WebhookConfig_TestEndpointResponseDto,\n },\n ],\n },\n },\n },\n);\n"]}
1
+ {"version":3,"file":"webhook-config.shared.resources-config.schemas.js","sourceRoot":"","sources":["../../../../src/notifications/m2m/webhook-config.shared.resources-config.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EACL,qBAAqB,EACrB,gBAAgB,GACjB,MAAM,mDAAmD,CAAC;AAC3D,OAAO,EACL,0BAA0B,EAC1B,4BAA4B,GAC7B,MAAM,0CAA0C,CAAC;AAClD,OAAO,EAAE,uCAAuC,EAAE,MAAM,qDAAqD,CAAC;AAC9G,OAAO,EAAE,wBAAwB,EAAE,MAAM,iDAAiD,CAAC;AAC3F,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,oDAAoD,CAAC;AACpG,OAAO,EAAE,mCAAmC,EAAE,2BAA2B,EAAE,MAAM,iCAAiC,CAAC;AAEnH,gFAAgF;AAChF,oBAAoB;AACpB,gFAAgF;AAEhF,MAAM,CAAN,IAAY,wBAkBX;AAlBD,WAAY,wBAAwB;IAClC;;;;;;;;;;;;;;;OAeG;IACH,0DAA8B,CAAA;AAChC,CAAC,EAlBW,wBAAwB,KAAxB,wBAAwB,QAkBnC;AAED,gFAAgF;AAChF,eAAe;AACf,gFAAgF;AA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iBAC3C;aACF;SACF;QACD,CAAC,wBAAwB,CAAC,aAAa,CAAC,EAAE;YACxC,QAAQ,EAAE;gBACR;oBACE,WAAW,EAAE,4BAA4B,CAAC,QAAQ;oBAClD,SAAS,EAAE,IAAI;oBACf,eAAe,EAAE;wBACf,CAAC,gBAAgB,CAAC,aAAa,CAAC,EAAE,CAAC,cAAc,CAAC,SAAS,CAAC;wBAC5D,CAAC,gBAAgB,CAAC,WAAW,CAAC,EAAE,CAAC,cAAc,CAAC,qBAAqB,CAAC;qBACvE;oBACD,SAAS,EAAE,0BAA0B,CAAC,MAAM;oBAC5C,qEAAqE;oBACrE,kEAAkE;oBAClE,qBAAqB,EAAE,qBAAqB,CAAC,MAAM;oBACnD,UAAU,EAAE,oCAAoC;oBAChD,iEAAiE;oBACjE,gEAAgE;oBAChE,oEAAoE;oBACpE,kEAAkE;oBAClE,qCAAqC;oBACrC,iBAAiB,EAAE,qCAAqC;iBACzD;aACF;SACF;KACF;CACF,CACF,CAAC","sourcesContent":["/**\n * M2M Webhook Config Resource Configuration — Polymorphic dual-scope\n *\n * Produces 2 factory functions (ORG + APP) via the polymorphic factory.\n * Spread into the registry factory map:\n * ...webhookConfigPolymorphicFactories\n *\n * Operation set (mirrors SIEM Export Config singleton precedent):\n * - READ (API) : admin reads the config + derived public key\n * - CREATE (REPOSITORY_ONLY) : seeded once per scope; not externally callable\n * - UPDATE (API_CALL) : the administrator's edit door; a PREFIX stamps each endpoint's\n * id and timestamps (see `WEBHOOK_CONFIG_WRITE_VARIANT_TYPE`)\n * - TEST_ENDPOINT (custom) : fires a synthetic delivery to verify URL reachability\n *\n * @see m2m-webhook-organization-delivery.md — Phase 2 / Step 5\n * @see security/authentications/siem/siem-export-config.shared.resources-config.schemas.ts\n */\n\nimport { z } from 'zod';\nimport {\n CoreResourceOperation,\n CoreResourceType,\n} from '../../resources/resources.shared.core.definitions';\nimport {\n ResourceOperationRiskLevel,\n ResourceOperationVariantType,\n} from '../../resources/resources.shared.schemas';\nimport { createPolymorphicResourceConfigurations } from '../../resources/utils/resource-polymorphism.factory';\nimport { ResourceSystemAccessMode } from '../../resources/resources-config.shared.schemas';\nimport { CORE_ORG_ROLES, CORE_APP_ROLES } from '../../security/authorizations/roles.shared.schemas';\nimport { webhookConfigPolymorphicDeclaration, WebhookEndpointProbeOutcome } from './webhook-config.shared.schemas';\n\n// =============================================================================\n// CUSTOM OPERATIONS\n// =============================================================================\n\nexport enum WebhookConfig_Operations {\n /**\n * Synthetic delivery to verify URL reachability + signature\n * verification on the consumer side. Targets a single endpoint\n * (selected by `endpointId` in the request body); does not write to\n * `M2MWebhookDeliveryLog` (test deliveries are excluded from the user\n * event log to keep the log clean).\n *\n * The probe is `resourceOperationLike: UPDATE`, NOT `READ`. It performs no\n * database write, but it DOES have an external side effect — a live signed\n * POST leaves the platform and arrives at a customer-controlled URL. Borrowing\n * READ made this a `GET` whose OpenAPI entry had to declare `x-idempotent: false`,\n * a self-contradiction, and pushed `endpointId` into a query string. Borrowing\n * UPDATE yields a `PUT` on the same custom-op sub-path, matching the\n * `M2MWebhookDeliveryLog.retry` precedent (also a no-DB-write-of-its-own verb\n * that triggers a delivery).\n */\n TEST_ENDPOINT = 'testEndpoint',\n}\n\n// =============================================================================\n// REQUEST DTOs\n// =============================================================================\n\nexport const WebhookConfig_TestEndpointRequestDto = z.object({\n endpointId: z.string().min(1).describe('The id of the configured endpoint to test. A disabled endpoint can be tested too.'),\n});\n\n// =============================================================================\n// RESPONSE DTOs\n// =============================================================================\n\n/**\n * Diagnostic returned synchronously by `testEndpoint`.\n *\n * A transport-level failure at the customer endpoint is a successful PROBE and\n * therefore answers HTTP 200 carrying `outcome: UNREACHABLE` — it is not an API\n * error. API errors are reserved for faults in the request itself (unknown\n * `endpointId`, no config row, rate limit exceeded).\n */\nexport const WebhookConfig_TestEndpointResponseDto = z.object({\n endpointId: z.string().describe('The endpoint that was tested.'),\n /** Destination actually contacted, echoed so the admin can confirm the stored URL. */\n url: z.string().describe('The destination URL that was contacted, as stored on the endpoint.'),\n /**\n * True when that destination is plaintext `http://`, so the signature JWT travelled in the clear.\n *\n * ## Why the exposure is reported HERE (#492)\n *\n * Plaintext endpoints are admitted, deliberately, and the reasoning is recorded on\n * `WebhookEndpointSchema.url`. The cost of admitting them is that the decision becomes invisible:\n * a documented exposure nobody encounters is the same as an undocumented one, and the JSDoc\n * reaches only someone reading the schema.\n *\n * This probe is the one place an admin acts on a SINGLE endpoint and reads a per-endpoint answer,\n * so it is where the exposure can actually be met. It rides beside `outcome` rather than replacing\n * it, because the two say different things: `ACCEPTED` over `http://` is a working endpoint AND a\n * credential on the wire, and collapsing that into a failure would be false.\n *\n * Reported for every outcome, including `NOT_SENT` — the scheme is a property of the stored\n * destination, not of the attempt, and an admin fixing a signing fault should still be told.\n */\n transportIsPlaintext: z\n .boolean()\n .describe('`true` when the destination uses plaintext `http://`, so the signature token travels in the clear. Reported for every outcome.'),\n outcome: z\n .enum(WebhookEndpointProbeOutcome)\n .describe(\n 'The result of the test: `accepted` (the endpoint answered 2xx), `rejected` (it answered with another status), `unreachable` (no HTTP response, including a timeout), or `not_sent` (the request could not be signed, so nothing was sent).',\n ),\n /** HTTP status returned by the endpoint. Absent for `UNREACHABLE` / `NOT_SENT`. */\n responseStatus: z.number().int().optional().describe('The HTTP status the endpoint answered with. Absent when it did not answer or nothing was sent.'),\n /** Truncated response body, to let an admin read the consumer's own error text. */\n responseBodyTruncated: z\n .string()\n .optional()\n .describe(\"The start of the endpoint's response body, cut to 4 KB (UTF-8), so you can read the endpoint's own error text. Absent when the body was empty or there was no response.\"),\n /** Network / timeout / signing failure detail. Absent when the endpoint answered. */\n failureReason: z\n .string()\n .optional()\n .describe('Why no response was received — a network error, a refused destination, the 30-second timeout, or a signing failure. Absent when the endpoint answered.'),\n durationMs: z.number().int().nonnegative().describe('How long the request took, in milliseconds. `0` when nothing was sent.'),\n /**\n * `jti` of the signed probe. Stated so an admin can correlate this attempt with\n * the entry in their own consumer's logs — the same dedup key a real delivery\n * carries.\n */\n signatureJti: z\n .string()\n .describe(\"The unique id of the signed test request — the same delivery-id claim a real delivery carries — so you can find this attempt in the endpoint's own logs.\"),\n attemptedAt: z.date().describe('When the test request was built and sent.'),\n});\n\n// =============================================================================\n// POLYMORPHIC FACTORY\n// =============================================================================\n\n/**\n * The variant type of the webhook config's UPDATE — read by the resource configuration below AND by\n * the UPDATE prefix that stamps each endpoint's id and timestamps (`webhook-config-update.custom-impl`,\n * #1801).\n *\n * One named value because the custom-implementation registry keys a registration on the FULL\n * operation path, variant type included: a hand-restated value that drifted would leave the prefix\n * unbound, and every save would again reset `createdAt` and freeze `updatedAt` while the update\n * itself reported success. Same reason, and same shape, as `SSO_CONFIG_WRITE_VARIANT_TYPE`.\n */\nexport const WEBHOOK_CONFIG_WRITE_VARIANT_TYPE: Readonly<{\n // Exact member, not the enum: a variant is a union DISCRIMINATED by `variantType`.\n [CoreResourceOperation.UPDATE]: ResourceOperationVariantType.API_CALL;\n}> = {\n [CoreResourceOperation.UPDATE]: ResourceOperationVariantType.API_CALL,\n};\n\nexport const webhookConfigPolymorphicFactories = createPolymorphicResourceConfigurations(\n webhookConfigPolymorphicDeclaration,\n {\n isSystemResource: true,\n // Server-internal webhook delivery loads the (org/app) endpoint config via\n // `readAsSystem`, independent of the triggering user's roles — the config\n // governs runtime delivery behaviour, not user-facing data.\n //\n // CREATE joined it on 2026-09-18, matching the three enterprise-config singletons\n // (SSO / SCIM / SIEM) this resource is otherwise shaped like. It said \"READ-only\"\n // because, unlike them, it had no lazy materialiser of its own — not because a default\n // row would be wrong. #1179's seam reads this declaration before materialising a\n // context-addressed singleton on an UPDATE or DELETE the caller never named, so an\n // administrator can start configuring webhooks for a scope that has no row yet.\n //\n // It does NOT make a READ materialise — measured 2026-09-19, that seam is never entered on\n // the read route — so an unconfigured scope still 404s when the settings pane reads it.\n // Making the row exist for an organization that predates the `afterCreate` default seed is\n // a SEEDING question, and is where that defect belongs.\n systemAccessPolicy: {\n read: ResourceSystemAccessMode.ALLOWED,\n create: ResourceSystemAccessMode.ALLOWED,\n },\n customOperation: WebhookConfig_Operations,\n coreOperations: [\n CoreResourceOperation.READ,\n CoreResourceOperation.CREATE,\n CoreResourceOperation.UPDATE,\n CoreResourceOperation.DELETE,\n ],\n operationsConfiguration: {\n [CoreResourceOperation.READ]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.API_CALL,\n isDefault: true,\n polymorphicRole: {\n [CoreResourceType.ORGANIZATIONS]: [CORE_ORG_ROLES.ORG_ADMIN],\n [CoreResourceType.APPLICATION]: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n },\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.CREATE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n polymorphicRole: {\n [CoreResourceType.ORGANIZATIONS]: [CORE_ORG_ROLES.ORG_ADMIN],\n [CoreResourceType.APPLICATION]: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n },\n riskLevel: ResourceOperationRiskLevel.MEDIUM,\n },\n ],\n },\n /*\n * API_CALL — the administrator's edit door, and the only caller of this write.\n *\n * It was REPOSITORY_ONLY, which is route-less, and nothing in the engine called it: the\n * scope's row is seeded by `webhook-config-defaults.seeds.ts` through CREATE, the two\n * registered custom implementations are keyed on READ and on `testEndpoint`, and\n * `WebhookConfigBackendService` never updates. So the declared write had no caller on either\n * side of the boundary — no route for an administrator, no service reaching it internally —\n * and a webhook configuration is nothing BUT settings: whether outbound delivery is on, the\n * endpoints, the event selection, the retry posture.\n *\n * Worse than unreachable, and this is why it moved rather than being deleted: with no\n * addressable literal `update`, the frontend's update resolution fell through to whatever\n * operation borrowed UPDATE semantics — and here that is `testEndpoint`\n * (`resourceOperationLike: UPDATE`, API_CALL). Every writable field on the webhook settings\n * pane was a control that would have FIRED A TEST DELIVERY at the configured endpoint instead\n * of saving. `pickInlineFieldWriteOperation` now refuses a borrowed verb outright, so the\n * mis-wiring is closed whatever this variant says; the door is what makes the pane work.\n *\n * A PREFIX is registered on it (#1801): the endpoints array is written whole, so the prefix\n * matches each incoming endpoint to its stored self by `id`, keeps the stored `createdAt`,\n * advances `updatedAt` only for an endpoint whose settings changed, and assigns an id and both\n * timestamps to a new one. Its variant type is `WEBHOOK_CONFIG_WRITE_VARIANT_TYPE`, which this\n * declaration reads too. Should an internal writer ever need the repository path,\n * `getInternalRepositoryOperationPathDefault` falls back to the URL-bearing default for exactly\n * this shape.\n *\n * CREATE stays REPOSITORY_ONLY beside it: the row is seeded once per scope and is never\n * created self-serve. Admin tier / MEDIUM, unchanged.\n */\n [CoreResourceOperation.UPDATE]: {\n variants: [\n {\n variantType: WEBHOOK_CONFIG_WRITE_VARIANT_TYPE[CoreResourceOperation.UPDATE],\n isDefault: true,\n polymorphicRole: {\n [CoreResourceType.ORGANIZATIONS]: [CORE_ORG_ROLES.ORG_ADMIN],\n [CoreResourceType.APPLICATION]: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n },\n riskLevel: ResourceOperationRiskLevel.MEDIUM,\n },\n ],\n },\n // Internal-only (REPOSITORY_ONLY, no HTTP route): powers the composition\n // onParentDelete cascade so this one-per-scope webhook-config row is physically\n // removed when its owning org/app is deleted. Without a DELETE op the cascade\n // (deleteChildrenImmediate) throws ErrorType.CONFIGURATION on any scope with a\n // config row. Admin tier (ORG_ADMIN / APP super-admin) / HIGH.\n [CoreResourceOperation.DELETE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n polymorphicRole: {\n [CoreResourceType.ORGANIZATIONS]: [CORE_ORG_ROLES.ORG_ADMIN],\n [CoreResourceType.APPLICATION]: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n },\n riskLevel: ResourceOperationRiskLevel.HIGH,\n },\n ],\n },\n [WebhookConfig_Operations.TEST_ENDPOINT]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.API_CALL,\n isDefault: true,\n polymorphicRole: {\n [CoreResourceType.ORGANIZATIONS]: [CORE_ORG_ROLES.ORG_ADMIN],\n [CoreResourceType.APPLICATION]: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n },\n riskLevel: ResourceOperationRiskLevel.MEDIUM,\n // UPDATE-like, not READ-like — see the JSDoc on `TEST_ENDPOINT`. The\n // operation writes nothing, but it emits a live outbound request.\n resourceOperationLike: CoreResourceOperation.UPDATE,\n requestDto: WebhookConfig_TestEndpointRequestDto,\n // Implemented by `createWebhookConfigTestEndpointFactories()` in\n // saas-backend-lib (REPLACE_CORE_OPERATIONS): the core write is\n // replaced by the synthetic delivery, and this diagnostic — NOT the\n // config row — is what the caller receives. Keep this contract in\n // lockstep with that implementation.\n customResponseDto: WebhookConfig_TestEndpointResponseDto,\n },\n ],\n },\n },\n },\n);\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"webhook-config.shared.schemas.d.ts","sourceRoot":"","sources":["../../../../../src/notifications/m2m/webhook-config.shared.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,OAAO,EAEL,KAAK,4BAA4B,EAClC,MAAM,qDAAqD,CAAC;AAM7D;;;;;;;;;;;;GAYG;AACH,oBAAY,2BAA2B;IACrC;;;;;OAKG;IACH,QAAQ,aAAa;IACrB,iFAAiF;IACjF,QAAQ,aAAa;IACrB,sFAAsF;IACtF,WAAW,gBAAgB;IAC3B;;;;;OAKG;IACH,QAAQ,aAAa;CACtB;AAMD;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,0BAA0B,EAAE,4BAA4B,EAWpE,CAAC;AAMF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,qBAAqB;;;;;;;iBAoEhC,CAAC;AAEH;;;;GAIG;AACH,eAAO,MAAM,oCAAoC,2CAA+G,CAAC;AAEjK,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAEpE;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,mCAAmC,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAMxE;AAED;;;;;;;GAOG;AACH,wBAAgB,8BAA8B,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAMlE;AAMD,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;iBA2ClC,CAAC;AAEH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAMxE;;;;;;;;GAQG;AACH,eAAO,MAAM,mCAAmC;;;;;;;;;;;;;;kBAM9C,CAAC"}
1
+ {"version":3,"file":"webhook-config.shared.schemas.d.ts","sourceRoot":"","sources":["../../../../src/notifications/m2m/webhook-config.shared.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,OAAO,EAEL,KAAK,4BAA4B,EAClC,MAAM,qDAAqD,CAAC;AAM7D;;;;;;;;;;;;GAYG;AACH,oBAAY,2BAA2B;IACrC;;;;;OAKG;IACH,QAAQ,aAAa;IACrB,iFAAiF;IACjF,QAAQ,aAAa;IACrB,sFAAsF;IACtF,WAAW,gBAAgB;IAC3B;;;;;OAKG;IACH,QAAQ,aAAa;CACtB;AAMD;;;;;;;;;;;;;;;;;GAiBG;AACH,eAAO,MAAM,0BAA0B,EAAE,4BAA4B,EAWpE,CAAC;AAMF;;;;;;;;;;GAUG;AACH,eAAO,MAAM,qBAAqB;;;;;;;iBAoEhC,CAAC;AAEH;;;;GAIG;AACH,eAAO,MAAM,oCAAoC,2CAA+G,CAAC;AAEjK,MAAM,MAAM,eAAe,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,qBAAqB,CAAC,CAAC;AAEpE;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,wBAAgB,mCAAmC,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAMxE;AAED;;;;;;;GAOG;AACH,wBAAgB,8BAA8B,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAMlE;AAMD,eAAO,MAAM,uBAAuB;;;;;;;;;;;;;;iBA2ClC,CAAC;AAEH,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,uBAAuB,CAAC,CAAC;AAMxE;;;;;;;;GAQG;AACH,eAAO,MAAM,mCAAmC;;;;;;;;;;;;;;kBAM9C,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"webhook-config.shared.schemas.js","sourceRoot":"","sources":["../../../../../src/notifications/m2m/webhook-config.shared.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EACL,gBAAgB,EAChB,kCAAkC,GACnC,MAAM,mDAAmD,CAAC;AAC3D,OAAO,EACL,yBAAyB,GAE1B,MAAM,qDAAqD,CAAC;AAE7D,gFAAgF;AAChF,4BAA4B;AAC5B,gFAAgF;AAEhF;;;;;;;;;;;;GAYG;AACH,MAAM,CAAN,IAAY,2BAmBX;AAnBD,WAAY,2BAA2B;IACrC;;;;;OAKG;IACH,oDAAqB,CAAA;IACrB,iFAAiF;IACjF,oDAAqB,CAAA;IACrB,sFAAsF;IACtF,0DAA2B,CAAA;IAC3B;;;;;OAKG;IACH,oDAAqB,CAAA;AACvB,CAAC,EAnBW,2BAA2B,KAA3B,2BAA2B,QAmBtC;AAED,gFAAgF;AAChF,6BAA6B;AAC7B,gFAAgF;AAEhF;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,CAAC,MAAM,0BAA0B,GAAmC;IACxE;QACE,kBAAkB,EAAE,gBAAgB,CAAC,aAAa;QAClD,qBAAqB,EAAE,kCAAkC,CAAC,gBAAgB,CAAC,aAAa,CAAC;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EAAE,CAAC;gBAC1B,GAAG,CAAC,QAAQ,CAAC,EAAE,IAAI,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC,KAAK,EAAE,IAAI,CAAC,EAAE,OAAO,EAAE,+BAA+B,QAAQ,CAAC,EAAE,oCAAoC,EAAE,CAAC,CAAC;YACjJ,CAAC;YACD,IAAI,CAAC,GAAG,CAAC,QAAQ,CAAC,EAAE,CAAC,CAAC;QACxB,CAAC,CAAC,CAAC;IACL,CAAC,CAAC;SACD,OAAO,CAAC,EAAE,CAAC;IAEd;;;;;;;OAOG;IACH,uBAAuB,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,iBAAiB,EAAE,CAAC,iBAAiB,EAAE;IAEtF,SAAS,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC,OAAO,CAAC,GAAG,EAAE,CAAC,IAAI,IAAI,EAAE,CAAC,CAAC,iBAAiB,EAAE,CAAC,iBAAiB,EAAE;IACrF,SAAS,EAAE,CAAC,CAAC,IAAI,EAAE,CAAC,OAAO,CAAC,GAAG,EAAE,CAAC,IAAI,IAAI,EAAE,CAAC,CAAC,iBAAiB,EAAE,CAAC,iBAAiB,EAAE;CACtF,CAAC,CAAC;AAIH,gFAAgF;AAChF,0BAA0B;AAC1B,gFAAgF;AAEhF;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,mCAAmC,GAAG,yBAAyB,CAAC;IAC3E,gBAAgB,EAAE,eAAe;IACjC,mBAAmB,EAAE,iBAAiB;IACtC,WAAW,EAAE,gBAAgB;IAC7B,UAAU,EAAE,uBAAuB;IACnC,QAAQ,EAAE,0BAA0B;CACrC,CAAC,CAAC","sourcesContent":["/**\n * M2M Webhook Config Schema (Shared) — Polymorphic dual-scope\n *\n * Configures outbound webhook delivery for M2M notifications fired by\n * resource operations carrying a `WEBHOOK_ORGANIZATION` or\n * `WEBHOOK_APPLICATION` channel in their spec. Holds:\n * - a master `enabled` switch\n * - an array of admin-managed endpoints (URL + description + per-endpoint enabled flag)\n * - a derived `applicationPublicKeyPem` (READ-only, populated by a\n * postfix hook from `JwtPrivateKeys.APPLICATION_WEBHOOK` so external\n * consumers can verify our JWT-signed deliveries)\n *\n * Scope FK (`organizationId` / `applicationId`) is injected by the\n * polymorphism engine — NOT declared on the base schema.\n *\n * @see m2m-webhook-organization-delivery.md — Phase 2 / Step 3\n * @see security/authentications/siem/siem-export-config.shared.schemas.ts\n * for the dual-scope polymorphic precedent this mirrors.\n */\n\nimport { z } from 'zod';\nimport {\n CoreResourceType,\n coreResourceShared_FieldIdentifier,\n} from '../../resources/resources.shared.core.definitions';\nimport {\n declarePolymorphicSchemas,\n type PolymorphicVariantDefinition,\n} from '../../resources/utils/resource-polymorphism.schemas';\n\n// =============================================================================\n// ENDPOINT PROBE VOCABULARY\n// =============================================================================\n\n/**\n * Verdict of a single synthetic delivery fired by `webhookConfig.testEndpoint`.\n * A probe that cannot fail is worse than no probe, so every terminal state an\n * outbound attempt can reach is named here rather than collapsed into a boolean.\n *\n * The transport verdict and the HTTP status are deliberately SEPARATE axes:\n * `REJECTED` still carries a response status, because \"the endpoint answered 403\"\n * and \"the endpoint never answered\" are different problems with different fixes.\n *\n * Declared in this light schema module (not alongside the operation DTO) so the\n * audit-event vocabulary can name the same enum without pulling the resource-config\n * factory graph into `auditable-events.shared.schema.ts`.\n */\nexport enum WebhookEndpointProbeOutcome {\n /**\n * The endpoint answered with 2xx. This is the only outcome that evidences\n * consumer-side signature verification: the platform cannot observe the\n * consumer's verification step directly, so a 2xx from an endpoint that\n * verifies before responding is the available proof.\n */\n ACCEPTED = 'accepted',\n /** The endpoint answered, but not with 2xx. Reachable; it refused or errored. */\n REJECTED = 'rejected',\n /** No HTTP response at all — DNS/TLS/connection failure, or the attempt timed out. */\n UNREACHABLE = 'unreachable',\n /**\n * Nothing left the platform. The payload could not be signed, which is an\n * operator-side key/configuration fault, not a statement about the endpoint.\n * Reported distinctly so an admin never reads a local misconfiguration as a\n * broken customer endpoint.\n */\n NOT_SENT = 'not_sent',\n}\n\n// =============================================================================\n// SHARED VARIANT DEFINITIONS\n// =============================================================================\n\n/**\n * The 2 M2M webhook scope variants — shared by `WebhookConfig` and\n * `M2MWebhookDeliveryLog`. Centralised here so both polymorphic\n * declarations stay in lock-step.\n *\n * Notes:\n * - We deliberately define a domain-local constant (mirroring\n * `BILLING_SCOPE_VARIANTS` in the billing domain) instead of reusing\n * `AUTH_SCOPE_VARIANTS` from `authentications/`. The variant *shape*\n * is identical — `(ORGANIZATIONS, APPLICATION)` with `isPrimaryScope:\n * true` — but the auth constant is documented as \"shared across all\n * AUTH polymorphic resources\" and webhooks are notification resources,\n * not auth resources. Keeping a domain-local constant prevents the\n * semantic drift the framework-mindset rule warns about.\n * - Both variants are primary scopes: there is no \"child of an\n * organization unit\" or \"child of a user\" variant — webhooks are a\n * tenant-level concern, not an entity-attached one.\n */\nexport const M2M_WEBHOOK_SCOPE_VARIANTS: PolymorphicVariantDefinition[] = [\n {\n parentResourceType: CoreResourceType.ORGANIZATIONS,\n parentFieldIdentifier: coreResourceShared_FieldIdentifier[CoreResourceType.ORGANIZATIONS],\n isPrimaryScope: true,\n },\n {\n parentResourceType: CoreResourceType.APPLICATION,\n parentFieldIdentifier: coreResourceShared_FieldIdentifier[CoreResourceType.APPLICATION],\n isPrimaryScope: true,\n },\n];\n\n// =============================================================================\n// ENDPOINT SUB-SCHEMA\n// =============================================================================\n\n/**\n * A single admin-configured webhook destination.\n *\n * v1 deliberately keeps endpoint config minimal (URL + description +\n * enabled flag) — per user direction: \"as a first implementation, we\n * need just an url and a description, not more.\" Per-endpoint secrets\n * are NOT used: signing happens with a single per-application JWT\n * private key (`JwtPrivateKeys.APPLICATION_WEBHOOK`) and consumers\n * verify with the matching public key surfaced via the parent config's\n * derived `applicationPublicKeyPem` field.\n */\nexport const WebhookEndpointSchema = z.object({\n /**\n * Stable per-endpoint identifier. Used as the `endpointId` FK on every delivery log row, and the\n * key the UPDATE path matches an incoming endpoint to its stored self by (#1801).\n *\n * ASSIGNED BY THE SERVER when an endpoint is saved without one — which is how a new endpoint\n * arrives from the settings pane, whose array editor seeds a new item's string fields with `''`.\n * That is why blank is admitted here rather than refused: `min(1)` made the settings pane unable\n * to add an endpoint at all, and an id is not something an administrator should have to invent.\n * A caller that supplies its own id keeps it. Duplicate ids are refused on `endpoints` below.\n */\n id: z\n .string()\n .max(128)\n .isNotEditable()\n .describe('Identifies the endpoint. Delivery-log entries and endpoint tests name the endpoint by this id. Assigned by the server when a new endpoint is saved without one; an existing endpoint keeps its id.'),\n /**\n * Destination URL receiving POST deliveries.\n *\n * ## `http://` IS ACCEPTED, AND WHAT THAT COSTS YOU (#492, decided 2026-09-08)\n *\n * Every delivery carries a **signature JWT in the request**. That JWT is a credential: it is what\n * proves to your endpoint that the delivery came from this application. Over plaintext it is\n * readable by anyone on the network path between us and you, and replayable against your endpoint\n * until it expires — so an observer of one delivery can forge the next one.\n *\n * **Use `https://`.** Plaintext is admitted because refusing it would break endpoints already\n * configured under a framework that accepted them, not because it is safe. That is a commercial\n * accommodation, deliberately taken, and it is not an assessment that `http://` is fine here.\n *\n * The sibling agent push-notification caller requires HTTPS unconditionally, and the same argument\n * applies to this field; the two differ only in whether anyone has already authored against them.\n *\n * Note the URL is also SSRF-guarded at delivery time — a destination resolving to a private or\n * link-local address is refused regardless of scheme, because a signed POST to an instance-metadata\n * service is a read primitive rather than a delivery.\n */\n url: z\n .url()\n .describe(\n 'Where deliveries are sent, as a signed POST. Use `https://`: over `http://` the signature token travels in the clear. A destination that resolves to a private or link-local address is refused when a delivery is sent (outside production, loopback is allowed).',\n ),\n /** Free-form admin label (visible in the management UI). */\n description: z.string().max(500).default('').describe('A label for the endpoint, shown to administrators. At most 500 characters; empty by default.'),\n /** Per-endpoint master switch — disabled endpoints are skipped by the dispatcher. */\n enabled: z.boolean().default(true).describe('When `false`, deliveries skip this endpoint. It can still be tested. Defaults to `true`.'),\n /**\n * When this endpoint was added. SERVER-STAMPED (#1801): the UPDATE path keeps the stored value for\n * an endpoint it recognises by `id` and stamps the save instant for a new one, whatever the request\n * carries — the array is written whole, so a client that omitted or edited this field would\n * otherwise reset or rewrite it.\n *\n * Why not `.excludeFromCreate().excludeFromUpdate()`: those strip TOP-LEVEL request fields only\n * (`applyUpdateOmissionsToSchema` does not descend into array items), so on an item they would\n * read as protection and enforce nothing. `.isNotEditable()` is what the item editor honours; the\n * server stamp is what makes the value true.\n */\n createdAt: z\n .date()\n .default(() => new Date())\n .isNotEditable()\n .describe('When the endpoint was added. Set by the server; a value sent by the client is ignored.'),\n /** When any setting of this endpoint last changed. SERVER-STAMPED, see {@link createdAt}. */\n updatedAt: z\n .date()\n .default(() => new Date())\n .isNotEditable()\n .describe('When the endpoint\\'s URL, description or switch last changed. Set by the server; a value sent by the client is ignored. Saving other endpoints does not change it.'),\n});\n\n/**\n * The endpoint fields a CLIENT authors — every field except the identity and the two server-stamped\n * timestamps. The UPDATE path compares these to decide whether an endpoint changed, so a field added\n * to {@link WebhookEndpointSchema} tomorrow counts as a change without anyone remembering to list it.\n */\nexport const WEBHOOK_ENDPOINT_SERVER_OWNED_FIELDS = ['id', 'createdAt', 'updatedAt'] as const satisfies readonly (keyof z.infer<typeof WebhookEndpointSchema>)[];\n\nexport type WebhookEndpoint = z.infer<typeof WebhookEndpointSchema>;\n\n/**\n * Whether a destination is reached over PLAINTEXT HTTP, so the signature JWT travels in the clear.\n *\n * ## One definition, because two would eventually disagree (#492)\n *\n * Plaintext is ADMITTED here — a deliberate commercial accommodation recorded on\n * {@link WebhookEndpointSchema.url} — which is exactly why the condition needs a single named home\n * rather than an inline `startsWith('http://')` at each surface that wants to say something about\n * it. A refusal can live in one place because it stops the request; a TOLERATED condition is\n * observed by several, and those several must agree.\n *\n * Read by the UPDATE path (which logs a warning naming the destination host when a plaintext endpoint\n * is saved) and by the endpoint probe (which reports it to the admin who pressed \"test\"). Both are\n * listed here so the next reader can tell whether adding a third is joining a mechanism or starting\n * a second one.\n *\n * Scheme comparison, not a `startsWith`: `WHATWG` lowercases the scheme during parsing, so\n * `HTTP://example.test` and `http://example.test` are the same destination and a prefix test would\n * disagree with the URL the delivery actually opens. An unparseable value answers `false` — it is\n * not a plaintext destination, it is not a destination at all, and `z.url()` refuses it upstream.\n */\nexport function webhookEndpointTransportIsPlaintext(url: string): boolean {\n try {\n return new URL(url).protocol === 'http:';\n } catch {\n return false;\n }\n}\n\n/**\n * The host of a webhook destination, for an audit row or a log line — never the full URL.\n *\n * Mirrors `AuditableEvent_Webhook_EndpointTestDispatchedEventDataSchema.destinationHost` and the\n * reasoning recorded there: paths and query strings on customer endpoints routinely embed\n * per-tenant tokens, and these rows are replicated to the organisation's SIEM and to the immutable\n * store. The host answers \"which of my endpoints\" without carrying a credential into a log.\n */\nexport function webhookEndpointDestinationHost(url: string): string {\n try {\n return new URL(url).host;\n } catch {\n return 'unparseable';\n }\n}\n\n// =============================================================================\n// BASE CONFIG SCHEMA (polymorphism injects the scope FK at variant time)\n// =============================================================================\n\nexport const WebhookConfigBaseSchema = z.object({\n _id: z.string().min(1).isPrimaryKey().isSummaryField(),\n\n /** Master kill-switch — when `false`, the dispatcher short-circuits with no deliveries. */\n enabled: z.boolean().default(false).isSummaryField(),\n\n /**\n * Admin-managed list of destinations. Empty array = no deliveries even when `enabled: true`.\n *\n * Ids must be unique: the UPDATE path matches endpoints by id to carry their timestamps forward,\n * delivery-log rows name their endpoint by id, and `testEndpoint` selects one by id — a duplicate\n * would make all three pick an arbitrary one of the two. Blank ids are exempt, because the server\n * assigns them on save (see `WebhookEndpointSchema.id`).\n */\n // The refinement sits on the ARRAY, before `.default([])`: the request-DTO builder rebuilds a\n // default-wrapped field from its inner type, so a check on the wrapper never reached a request and a\n // PUT with two `\"same\"` ids was accepted (#1801 review M1).\n endpoints: z\n .array(WebhookEndpointSchema)\n .superRefine((endpoints, ctx) => {\n const seen = new Set<string>();\n endpoints.forEach((endpoint, index) => {\n if (!endpoint.id) return;\n if (seen.has(endpoint.id)) {\n ctx.addIssue({ code: 'custom', path: [index, 'id'], message: `Two endpoints share the id \"${endpoint.id}\". Each endpoint needs its own id.` });\n }\n seen.add(endpoint.id);\n });\n })\n .default([]),\n\n /**\n * Derived field — populated by `postfixCoreOperations[READ]` from\n * `appConfig.jwtConfig.config.publicKey[JwtPrivateKeys.APPLICATION_WEBHOOK]`.\n * Excluded from CREATE/UPDATE so clients cannot set it; the value is\n * regenerated on every read from the canonical app config so key\n * rotation is reflected immediately. Phase 3 wires the postfix hook\n * (Step 9 of the plan).\n */\n applicationPublicKeyPem: z.string().optional().excludeFromCreate().excludeFromUpdate(),\n\n createdAt: z.date().default(() => new Date()).excludeFromCreate().excludeFromUpdate(),\n updatedAt: z.date().default(() => new Date()).excludeFromCreate().excludeFromUpdate(),\n});\n\nexport type WebhookConfigBase = z.infer<typeof WebhookConfigBaseSchema>;\n\n// =============================================================================\n// POLYMORPHIC DECLARATION\n// =============================================================================\n\n/**\n * Yields two `CoreResourceType` variants:\n * - `organizationWebhookConfig` (FK: `organizationId`)\n * - `applicationWebhookConfig` (FK: `applicationId`)\n *\n * Both are singletons per scope (cardinality ONE) — wired in\n * `resources-registry.shared.core.definitions.ts` via\n * `createPolymorphicScopeRelationships(...)`.\n */\nexport const webhookConfigPolymorphicDeclaration = declarePolymorphicSchemas({\n baseResourceType: 'webhookConfig',\n baseFieldIdentifier: 'webhookConfigId',\n baseEnumKey: 'WEBHOOK_CONFIG',\n baseSchema: WebhookConfigBaseSchema,\n variants: M2M_WEBHOOK_SCOPE_VARIANTS,\n});\n"]}
1
+ {"version":3,"file":"webhook-config.shared.schemas.js","sourceRoot":"","sources":["../../../../src/notifications/m2m/webhook-config.shared.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EACL,gBAAgB,EAChB,kCAAkC,GACnC,MAAM,mDAAmD,CAAC;AAC3D,OAAO,EACL,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O,CAAC,GAAG,EAAE,CAAC,IAAI,IAAI,EAAE,CAAC,CAAC,iBAAiB,EAAE,CAAC,iBAAiB,EAAE;CACtF,CAAC,CAAC;AAIH,gFAAgF;AAChF,0BAA0B;AAC1B,gFAAgF;AAEhF;;;;;;;;GAQG;AACH,MAAM,CAAC,MAAM,mCAAmC,GAAG,yBAAyB,CAAC;IAC3E,gBAAgB,EAAE,eAAe;IACjC,mBAAmB,EAAE,iBAAiB;IACtC,WAAW,EAAE,gBAAgB;IAC7B,UAAU,EAAE,uBAAuB;IACnC,QAAQ,EAAE,0BAA0B;CACrC,CAAC,CAAC","sourcesContent":["/**\n * M2M Webhook Config Schema (Shared) — Polymorphic dual-scope\n *\n * Configures outbound webhook delivery for M2M notifications fired by\n * resource operations carrying a `WEBHOOK_ORGANIZATION` or\n * `WEBHOOK_APPLICATION` channel in their spec. Holds:\n * - a master `enabled` switch\n * - an array of admin-managed endpoints (URL + description + per-endpoint enabled flag)\n * - a derived `applicationPublicKeyPem` (READ-only, populated by a\n * postfix hook from `JwtPrivateKeys.APPLICATION_WEBHOOK` so external\n * consumers can verify our JWT-signed deliveries)\n *\n * Scope FK (`organizationId` / `applicationId`) is injected by the\n * polymorphism engine — NOT declared on the base schema.\n *\n * @see m2m-webhook-organization-delivery.md — Phase 2 / Step 3\n * @see security/authentications/siem/siem-export-config.shared.schemas.ts\n * for the dual-scope polymorphic precedent this mirrors.\n */\n\nimport { z } from 'zod';\nimport {\n CoreResourceType,\n coreResourceShared_FieldIdentifier,\n} from '../../resources/resources.shared.core.definitions';\nimport {\n declarePolymorphicSchemas,\n type PolymorphicVariantDefinition,\n} from '../../resources/utils/resource-polymorphism.schemas';\n\n// =============================================================================\n// ENDPOINT PROBE VOCABULARY\n// =============================================================================\n\n/**\n * Verdict of a single synthetic delivery fired by `webhookConfig.testEndpoint`.\n * A probe that cannot fail is worse than no probe, so every terminal state an\n * outbound attempt can reach is named here rather than collapsed into a boolean.\n *\n * The transport verdict and the HTTP status are deliberately SEPARATE axes:\n * `REJECTED` still carries a response status, because \"the endpoint answered 403\"\n * and \"the endpoint never answered\" are different problems with different fixes.\n *\n * Declared in this light schema module (not alongside the operation DTO) so the\n * audit-event vocabulary can name the same enum without pulling the resource-config\n * factory graph into `auditable-events.shared.schema.ts`.\n */\nexport enum WebhookEndpointProbeOutcome {\n /**\n * The endpoint answered with 2xx. This is the only outcome that evidences\n * consumer-side signature verification: the platform cannot observe the\n * consumer's verification step directly, so a 2xx from an endpoint that\n * verifies before responding is the available proof.\n */\n ACCEPTED = 'accepted',\n /** The endpoint answered, but not with 2xx. Reachable; it refused or errored. */\n REJECTED = 'rejected',\n /** No HTTP response at all — DNS/TLS/connection failure, or the attempt timed out. */\n UNREACHABLE = 'unreachable',\n /**\n * Nothing left the platform. The payload could not be signed, which is an\n * operator-side key/configuration fault, not a statement about the endpoint.\n * Reported distinctly so an admin never reads a local misconfiguration as a\n * broken customer endpoint.\n */\n NOT_SENT = 'not_sent',\n}\n\n// =============================================================================\n// SHARED VARIANT DEFINITIONS\n// =============================================================================\n\n/**\n * The 2 M2M webhook scope variants — shared by `WebhookConfig` and\n * `M2MWebhookDeliveryLog`. Centralised here so both polymorphic\n * declarations stay in lock-step.\n *\n * Notes:\n * - We deliberately define a domain-local constant (mirroring\n * `BILLING_SCOPE_VARIANTS` in the billing domain) instead of reusing\n * `AUTH_SCOPE_VARIANTS` from `authentications/`. The variant *shape*\n * is identical — `(ORGANIZATIONS, APPLICATION)` with `isPrimaryScope:\n * true` — but the auth constant is documented as \"shared across all\n * AUTH polymorphic resources\" and webhooks are notification resources,\n * not auth resources. Keeping a domain-local constant prevents the\n * semantic drift the framework-mindset rule warns about.\n * - Both variants are primary scopes: there is no \"child of an\n * organization unit\" or \"child of a user\" variant — webhooks are a\n * tenant-level concern, not an entity-attached one.\n */\nexport const M2M_WEBHOOK_SCOPE_VARIANTS: PolymorphicVariantDefinition[] = [\n {\n parentResourceType: CoreResourceType.ORGANIZATIONS,\n parentFieldIdentifier: coreResourceShared_FieldIdentifier[CoreResourceType.ORGANIZATIONS],\n isPrimaryScope: true,\n },\n {\n parentResourceType: CoreResourceType.APPLICATION,\n parentFieldIdentifier: coreResourceShared_FieldIdentifier[CoreResourceType.APPLICATION],\n isPrimaryScope: true,\n },\n];\n\n// =============================================================================\n// ENDPOINT SUB-SCHEMA\n// =============================================================================\n\n/**\n * A single admin-configured webhook destination.\n *\n * v1 deliberately keeps endpoint config minimal (URL + description +\n * enabled flag) — per user direction: \"as a first implementation, we\n * need just an url and a description, not more.\" Per-endpoint secrets\n * are NOT used: signing happens with a single per-application JWT\n * private key (`JwtPrivateKeys.APPLICATION_WEBHOOK`) and consumers\n * verify with the matching public key surfaced via the parent config's\n * derived `applicationPublicKeyPem` field.\n */\nexport const WebhookEndpointSchema = z.object({\n /**\n * Stable per-endpoint identifier. Used as the `endpointId` FK on every delivery log row, and the\n * key the UPDATE path matches an incoming endpoint to its stored self by (#1801).\n *\n * ASSIGNED BY THE SERVER when an endpoint is saved without one — which is how a new endpoint\n * arrives from the settings pane, whose array editor seeds a new item's string fields with `''`.\n * That is why blank is admitted here rather than refused: `min(1)` made the settings pane unable\n * to add an endpoint at all, and an id is not something an administrator should have to invent.\n * A caller that supplies its own id keeps it. Duplicate ids are refused on `endpoints` below.\n */\n id: z\n .string()\n .max(128)\n .isNotEditable()\n .describe('Identifies the endpoint. Delivery-log entries and endpoint tests name the endpoint by this id. Assigned by the server when a new endpoint is saved without one; an existing endpoint keeps its id.'),\n /**\n * Destination URL receiving POST deliveries.\n *\n * ## `http://` IS ACCEPTED, AND WHAT THAT COSTS YOU (#492, decided 2026-09-08)\n *\n * Every delivery carries a **signature JWT in the request**. That JWT is a credential: it is what\n * proves to your endpoint that the delivery came from this application. Over plaintext it is\n * readable by anyone on the network path between us and you, and replayable against your endpoint\n * until it expires — so an observer of one delivery can forge the next one.\n *\n * **Use `https://`.** Plaintext is admitted because refusing it would break endpoints already\n * configured under a framework that accepted them, not because it is safe. That is a commercial\n * accommodation, deliberately taken, and it is not an assessment that `http://` is fine here.\n *\n * The sibling agent push-notification caller requires HTTPS unconditionally, and the same argument\n * applies to this field; the two differ only in whether anyone has already authored against them.\n *\n * Note the URL is also SSRF-guarded at delivery time — a destination resolving to a private or\n * link-local address is refused regardless of scheme, because a signed POST to an instance-metadata\n * service is a read primitive rather than a delivery.\n */\n url: z\n .url()\n .describe(\n 'Where deliveries are sent, as a signed POST. Use `https://`: over `http://` the signature token travels in the clear. A destination that resolves to a private or link-local address is refused when a delivery is sent (outside production, loopback is allowed).',\n ),\n /** Free-form admin label (visible in the management UI). */\n description: z.string().max(500).default('').describe('A label for the endpoint, shown to administrators. At most 500 characters; empty by default.'),\n /** Per-endpoint master switch — disabled endpoints are skipped by the dispatcher. */\n enabled: z.boolean().default(true).describe('When `false`, deliveries skip this endpoint. It can still be tested. Defaults to `true`.'),\n /**\n * When this endpoint was added. SERVER-STAMPED (#1801): the UPDATE path keeps the stored value for\n * an endpoint it recognises by `id` and stamps the save instant for a new one, whatever the request\n * carries — the array is written whole, so a client that omitted or edited this field would\n * otherwise reset or rewrite it.\n *\n * Why not `.excludeFromCreate().excludeFromUpdate()`: those strip TOP-LEVEL request fields only\n * (`applyUpdateOmissionsToSchema` does not descend into array items), so on an item they would\n * read as protection and enforce nothing. `.isNotEditable()` is what the item editor honours; the\n * server stamp is what makes the value true.\n */\n createdAt: z\n .date()\n .default(() => new Date())\n .isNotEditable()\n .describe('When the endpoint was added. Set by the server; a value sent by the client is ignored.'),\n /** When any setting of this endpoint last changed. SERVER-STAMPED, see {@link createdAt}. */\n updatedAt: z\n .date()\n .default(() => new Date())\n .isNotEditable()\n .describe('When the endpoint\\'s URL, description or switch last changed. Set by the server; a value sent by the client is ignored. Saving other endpoints does not change it.'),\n});\n\n/**\n * The endpoint fields a CLIENT authors — every field except the identity and the two server-stamped\n * timestamps. The UPDATE path compares these to decide whether an endpoint changed, so a field added\n * to {@link WebhookEndpointSchema} tomorrow counts as a change without anyone remembering to list it.\n */\nexport const WEBHOOK_ENDPOINT_SERVER_OWNED_FIELDS = ['id', 'createdAt', 'updatedAt'] as const satisfies readonly (keyof z.infer<typeof WebhookEndpointSchema>)[];\n\nexport type WebhookEndpoint = z.infer<typeof WebhookEndpointSchema>;\n\n/**\n * Whether a destination is reached over PLAINTEXT HTTP, so the signature JWT travels in the clear.\n *\n * ## One definition, because two would eventually disagree (#492)\n *\n * Plaintext is ADMITTED here — a deliberate commercial accommodation recorded on\n * {@link WebhookEndpointSchema.url} — which is exactly why the condition needs a single named home\n * rather than an inline `startsWith('http://')` at each surface that wants to say something about\n * it. A refusal can live in one place because it stops the request; a TOLERATED condition is\n * observed by several, and those several must agree.\n *\n * Read by the UPDATE path (which logs a warning naming the destination host when a plaintext endpoint\n * is saved) and by the endpoint probe (which reports it to the admin who pressed \"test\"). Both are\n * listed here so the next reader can tell whether adding a third is joining a mechanism or starting\n * a second one.\n *\n * Scheme comparison, not a `startsWith`: `WHATWG` lowercases the scheme during parsing, so\n * `HTTP://example.test` and `http://example.test` are the same destination and a prefix test would\n * disagree with the URL the delivery actually opens. An unparseable value answers `false` — it is\n * not a plaintext destination, it is not a destination at all, and `z.url()` refuses it upstream.\n */\nexport function webhookEndpointTransportIsPlaintext(url: string): boolean {\n try {\n return new URL(url).protocol === 'http:';\n } catch {\n return false;\n }\n}\n\n/**\n * The host of a webhook destination, for an audit row or a log line — never the full URL.\n *\n * Mirrors `AuditableEvent_Webhook_EndpointTestDispatchedEventDataSchema.destinationHost` and the\n * reasoning recorded there: paths and query strings on customer endpoints routinely embed\n * per-tenant tokens, and these rows are replicated to the organisation's SIEM and to the immutable\n * store. The host answers \"which of my endpoints\" without carrying a credential into a log.\n */\nexport function webhookEndpointDestinationHost(url: string): string {\n try {\n return new URL(url).host;\n } catch {\n return 'unparseable';\n }\n}\n\n// =============================================================================\n// BASE CONFIG SCHEMA (polymorphism injects the scope FK at variant time)\n// =============================================================================\n\nexport const WebhookConfigBaseSchema = z.object({\n _id: z.string().min(1).isPrimaryKey().isSummaryField(),\n\n /** Master kill-switch — when `false`, the dispatcher short-circuits with no deliveries. */\n enabled: z.boolean().default(false).isSummaryField(),\n\n /**\n * Admin-managed list of destinations. Empty array = no deliveries even when `enabled: true`.\n *\n * Ids must be unique: the UPDATE path matches endpoints by id to carry their timestamps forward,\n * delivery-log rows name their endpoint by id, and `testEndpoint` selects one by id — a duplicate\n * would make all three pick an arbitrary one of the two. Blank ids are exempt, because the server\n * assigns them on save (see `WebhookEndpointSchema.id`).\n */\n // The refinement sits on the ARRAY, before `.default([])`: the request-DTO builder rebuilds a\n // default-wrapped field from its inner type, so a check on the wrapper never reached a request and a\n // PUT with two `\"same\"` ids was accepted (#1801 review M1).\n endpoints: z\n .array(WebhookEndpointSchema)\n .superRefine((endpoints, ctx) => {\n const seen = new Set<string>();\n endpoints.forEach((endpoint, index) => {\n if (!endpoint.id) return;\n if (seen.has(endpoint.id)) {\n ctx.addIssue({ code: 'custom', path: [index, 'id'], message: `Two endpoints share the id \"${endpoint.id}\". Each endpoint needs its own id.` });\n }\n seen.add(endpoint.id);\n });\n })\n .default([]),\n\n /**\n * Derived field — populated by `postfixCoreOperations[READ]` from\n * `appConfig.jwtConfig.config.publicKey[JwtPrivateKeys.APPLICATION_WEBHOOK]`.\n * Excluded from CREATE/UPDATE so clients cannot set it; the value is\n * regenerated on every read from the canonical app config so key\n * rotation is reflected immediately. Phase 3 wires the postfix hook\n * (Step 9 of the plan).\n */\n applicationPublicKeyPem: z.string().optional().excludeFromCreate().excludeFromUpdate(),\n\n createdAt: z.date().default(() => new Date()).excludeFromCreate().excludeFromUpdate(),\n updatedAt: z.date().default(() => new Date()).excludeFromCreate().excludeFromUpdate(),\n});\n\nexport type WebhookConfigBase = z.infer<typeof WebhookConfigBaseSchema>;\n\n// =============================================================================\n// POLYMORPHIC DECLARATION\n// =============================================================================\n\n/**\n * Yields two `CoreResourceType` variants:\n * - `organizationWebhookConfig` (FK: `organizationId`)\n * - `applicationWebhookConfig` (FK: `applicationId`)\n *\n * Both are singletons per scope (cardinality ONE) — wired in\n * `resources-registry.shared.core.definitions.ts` via\n * `createPolymorphicScopeRelationships(...)`.\n */\nexport const webhookConfigPolymorphicDeclaration = declarePolymorphicSchemas({\n baseResourceType: 'webhookConfig',\n baseFieldIdentifier: 'webhookConfigId',\n baseEnumKey: 'WEBHOOK_CONFIG',\n baseSchema: WebhookConfigBaseSchema,\n variants: M2M_WEBHOOK_SCOPE_VARIANTS,\n});\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"notification-badges.core.definitions.d.ts","sourceRoot":"","sources":["../../../../src/notifications/notification-badges.core.definitions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,2BAA2B,EAAE,MAAM,+BAA+B,CAAC;AAE5E;;;;;;;;;;GAUG;AACH,eAAO,MAAM,gCAAgC,EAAE,2BAA2B,EAAO,CAAC"}
1
+ {"version":3,"file":"notification-badges.core.definitions.d.ts","sourceRoot":"","sources":["../../../src/notifications/notification-badges.core.definitions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,2BAA2B,EAAE,MAAM,+BAA+B,CAAC;AAE5E;;;;;;;;;;GAUG;AACH,eAAO,MAAM,gCAAgC,EAAE,2BAA2B,EAAO,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"notification-badges.core.definitions.js","sourceRoot":"","sources":["../../../../src/notifications/notification-badges.core.definitions.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;GAUG;AACH,MAAM,CAAC,MAAM,gCAAgC,GAAkC,EAAE,CAAC","sourcesContent":["import { NotificationBadgeDefinition } from \"./notification-badges.schemas\";\n\n/**\n * Canonical (framework-shipped) notification badge definitions.\n *\n * Intentionally empty: the two aspirational placeholders (`new messages` /\n * `unpaid invoices`) were removed because nothing produced them.\n *\n * This is a statement about FRAMEWORK-shipped definitions only. Badge surfacing itself works: a\n * navigation item carries `notificationBadgeRef` and the sidebar renders the badge, and applications\n * declare their own definitions. A framework definition returns here only once the framework also\n * ships its producer, carrying a typed `source` (EVENT_COUNTER | DERIVED_QUERY) + `display`.\n */\nexport const coreNotificationBadgeDefinitions: NotificationBadgeDefinition[] = [];\n"]}
1
+ {"version":3,"file":"notification-badges.core.definitions.js","sourceRoot":"","sources":["../../../src/notifications/notification-badges.core.definitions.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;GAUG;AACH,MAAM,CAAC,MAAM,gCAAgC,GAAkC,EAAE,CAAC","sourcesContent":["import { NotificationBadgeDefinition } from \"./notification-badges.schemas\";\n\n/**\n * Canonical (framework-shipped) notification badge definitions.\n *\n * Intentionally empty: the two aspirational placeholders (`new messages` /\n * `unpaid invoices`) were removed because nothing produced them.\n *\n * This is a statement about FRAMEWORK-shipped definitions only. Badge surfacing itself works: a\n * navigation item carries `notificationBadgeRef` and the sidebar renders the badge, and applications\n * declare their own definitions. A framework definition returns here only once the framework also\n * ships its producer, carrying a typed `source` (EVENT_COUNTER | DERIVED_QUERY) + `display`.\n */\nexport const coreNotificationBadgeDefinitions: NotificationBadgeDefinition[] = [];\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"notification-badges.schemas.d.ts","sourceRoot":"","sources":["../../../../src/notifications/notification-badges.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,OAAO,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAC;AACvE,OAAO,EAAE,oBAAoB,EAAE,MAAM,uCAAuC,CAAC;AAG7E;;;;;;;GAOG;AACH,eAAO,MAAM,gCAAgC,MAAM,CAAC;AAEpD,iFAAiF;AACjF,eAAO,MAAM,qCAAqC,QAAY,CAAC;AAE/D;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,iCAAiC,aAKxC,CAAC;AAEP;;;;;;;;;;;;;;GAcG;AACH,eAAO,MAAM,uBAAuB;;;EAGlC,CAAC;AAEH;;;;;;;;;;;;;;;;;;;;GAoBG;AACH,oBAAY,0BAA0B;IAClC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GAAG,IAAI,CAM/F;AAED;;;GAGG;AACH,wBAAgB,iCAAiC,CAAC,SAAS,EAAE,MAAM,GAAG,oBAAoB,GAAG,IAAI,CAGhG;AAED,wEAAwE;AACxE,wBAAgB,iCAAiC,CAAC,KAAK,EAAE,MAAM,GAAG,KAAK,IAAI,iBAAiB,CAE3F;AAMD;;;GAGG;AACH,oBAAY,2CAA2C;IACnD;;;;;OAKG;IACH,wBAAwB,6BAA6B;IACrD;;;;OAIG;IACH,iCAAiC,sCAAsC;IACvE,8EAA8E;IAC9E,wBAAwB,6BAA6B;IACrD;;;;;OAKG;IACH,8BAA8B,mCAAmC;CACpE;AAED,qGAAqG;AACrG,MAAM,WAAW,qCAAqC;IAClD,MAAM,EAAE,2CAA2C,CAAC;IACpD,2FAA2F;IAC3F,QAAQ,EAAE,MAAM,CAAC;IACjB,kGAAkG;IAClG,UAAU,CAAC,EAAE,2BAA2B,CAAC;IACzC,sEAAsE;IACtE,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,sEAAsE;IACtE,mBAAmB,CAAC,EAAE,MAAM,CAAC;CAChC;AAED,gHAAgH;AAChH,MAAM,WAAW,yCAAyC;IACtD,YAAY,EAAE,MAAM,CAAC;IACrB,mBAAmB,EAAE,MAAM,CAAC;IAC5B,QAAQ,EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,6CAA6C,CACzD,WAAW,EAAE,SAAS,2BAA2B,EAAE,EACnD,cAAc,GAAE,SAAS,yCAAyC,EAAO,GAC1E,qCAAqC,EAAE,CAiDzC;AAED;;;;;GAKG;AACH,wBAAgB,qCAAqC,CACjD,WAAW,EAAE,SAAS,2BAA2B,EAAE,GACpD,WAAW,CAAC,oBAAoB,EAAE,2BAA2B,CAAC,CAOhE"}
1
+ {"version":3,"file":"notification-badges.schemas.d.ts","sourceRoot":"","sources":["../../../src/notifications/notification-badges.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,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EAAE,MAAM,CAAC;CACpB;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,6CAA6C,CACzD,WAAW,EAAE,SAAS,2BAA2B,EAAE,EACnD,cAAc,GAAE,SAAS,yCAAyC,EAAO,GAC1E,qCAAqC,EAAE,CAiDzC;AAED;;;;;GAKG;AACH,wBAAgB,qCAAqC,CACjD,WAAW,EAAE,SAAS,2BAA2B,EAAE,GACpD,WAAW,CAAC,oBAAoB,EAAE,2BAA2B,CAAC,CAOhE"}
@@ -1 +1 @@
1
- {"version":3,"file":"notification-badges.schemas.js","sourceRoot":"","sources":["../../../../src/notifications/notification-badges.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAE7D,iBAAiB,CAAC,CAAC,CAAC,CAAC;AAErB,OAAO,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAC;AACvE,OAAO,EAAE,oBAAoB,EAAE,MAAM,uCAAuC,CAAC;AAG7E;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,gCAAgC,GAAG,GAAG,CAAC;AAEpD,iFAAiF;AACjF,MAAM,CAAC,MAAM,qCAAqC,GAAG,SAAS,CAAC;AAE/D;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,CAAC,MAAM,iCAAiC,GAAG,CAAC;KAC7C,MAAM,EAAE;KACR,GAAG,CAAC,CAAC,EAAE,EAAE,KAAK,EAAE,2CAA2C,EAAE,CAAC;KAC9D,KAAK,CAAC,qCAAqC,EAAE;IAC1C,KAAK,EAAE,mDAAmD,gCAAgC,qEAAqE;CAClK,CAAC,CAAC;AAEP;;;;;;;;;;;;;;GAcG;AACH,MAAM,CAAC,MAAM,uBAAuB,GAAG,CAAC,CAAC,IAAI,CAAC;IAC1C,oBAAoB,CAAC,SAAS;IAC9B,oBAAoB,CAAC,aAAa;CACrC,CAAC,CAAC;AAEH;;;;;;;;;;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C,YAAY;gBAC/B,mBAAmB,EAAE,IAAI,CAAC,mBAAmB;aAChD,CAAC,CAAC;YACH,SAAS;QACb,CAAC;QACD,IAAI,eAAe,CAAC,GAAG,CAAC,IAAI,CAAC,QAAQ,CAAC,KAAK,2BAA2B,CAAC,aAAa,EAAE,CAAC;YACnF,UAAU,CAAC,IAAI,CAAC;gBACZ,MAAM,EAAE,2CAA2C,CAAC,8BAA8B;gBAClF,QAAQ,EAAE,IAAI,CAAC,QAAQ;gBACvB,YAAY,EAAE,IAAI,CAAC,YAAY;gBAC/B,mBAAmB,EAAE,IAAI,CAAC,mBAAmB;aAChD,CAAC,CAAC;QACP,CAAC;IACL,CAAC;IAED,OAAO,UAAU,CAAC;AACtB,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,qCAAqC,CACjD,WAAmD;IAEnD,MAAM,KAAK,GAAG,IAAI,GAAG,EAAqD,CAAC;IAC3E,KAAK,MAAM,UAAU,IAAI,WAAW,EAAE,CAAC;QACnC,MAAM,GAAG,GAAG,4BAA4B,CAAC,UAAU,CAAC,CAAC;QACrD,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC;YAAE,KAAK,CAAC,GAAG,CAAC,GAAG,EAAE,UAAU,CAAC,CAAC;IACpD,CAAC;IACD,OAAO,KAAK,CAAC;AACjB,CAAC","sourcesContent":["import { z } from \"zod\";\nimport { initZodDecorators } from '@wildo-ai/zod-decorators';\n\ninitZodDecorators(z);\n\nimport { IndicatorVariant } from '@wildo-ai/presets-components-models';\nimport { ResourcePrimaryScope } from \"../resources/resources.shared.schemas\";\n\n\n/**\n * The one character that separates the parts of a badge KEY and a badge REFERENCE.\n *\n * Both formats are positional, so the separator may not appear inside a part or the parse is\n * ambiguous. `NotificationBadgeIdentifierSchema` refuses it in an identifier for exactly that\n * reason, and `collectNotificationBadgeDeclarationViolations` re-states the refusal at boot,\n * because a declaration object is authored in TypeScript and never `.parse()`d.\n */\nexport const NOTIFICATION_BADGE_KEY_SEPARATOR = ':';\n\n/** Any string that does not contain {@link NOTIFICATION_BADGE_KEY_SEPARATOR}. */\nexport const NOTIFICATION_BADGE_IDENTIFIER_PATTERN = /^[^:]+$/;\n\n/**\n * Notification badge identifier.\n *\n * The identifier is an open string because no canonical (core) identifier ships: the two\n * aspirational placeholders (`new messages` / `unpaid invoices`) were removed because nothing\n * produced them.\n *\n * The SURFACING is not missing. A navigation item declares `notificationBadgeRef` and the sidebar\n * and the menubar render it, and an application declares its own badges, so the open string is what an application\n * uses today. What is still absent is a FRAMEWORK-shipped identifier with a framework producer\n * behind it; when one lands, core identifiers come back as a `CoreNotificationBadgeIdentifiers`\n * enum unioned in here.\n *\n * Open, but not unconstrained: an identifier may not contain\n * {@link NOTIFICATION_BADGE_KEY_SEPARATOR}, because it is the LAST part of a badge key and of a\n * badge reference and both are positional. A definition object is authored in TypeScript and never\n * `.parse()`d, so this constraint is also re-stated as a boot check — see\n * {@link collectNotificationBadgeDeclarationViolations}.\n */\nexport const NotificationBadgeIdentifierSchema = z\n .string()\n .min(1, { error: 'Notification badge identifier is required' })\n .regex(NOTIFICATION_BADGE_IDENTIFIER_PATTERN, {\n error: `Notification badge identifier must not contain \"${NOTIFICATION_BADGE_KEY_SEPARATOR}\" — that character separates the parts of a badge key and reference`,\n });\n\n/**\n * Notification badge scope. Tightened to USER_SELF | ORGANIZATIONS only.\n *\n * The APPLICATION variant was dropped in the polymorphism refactor\n * (`.cursor/plans/notification-badges-polymorphism-refactor.md`):\n * - No canonical badges were ever declared at APPLICATION scope (see\n * `notification-badges.core.definitions.ts`).\n * - The two surviving variants (USER + ORG) each own their own resource type\n * and MongoDB collection. Allowing APPLICATION here would let consumers\n * write a payload that no resource configuration / collection accepts.\n *\n * `WS_BadgeUpdatePayload` semantics are unchanged — the dispatcher in\n * `NotificationBadgeBackendService.emitBadgeUpdate` still routes USER badges to\n * `sendToUser` and ORG badges to `sendToOrganization`.\n */\nexport const NotificationScopeSchema = z.enum([\n ResourcePrimaryScope.USER_SELF,\n ResourcePrimaryScope.ORGANIZATIONS,\n]);\n\n/**\n * @wildo_source:part:start saas.models.notifications.badge-vocabularies facet:layer:shared facet:audience:app-developer\n *\n * The four vocabularies a badge definition picks from: how its count is CALCULATED, how it is\n * PRESENTED, whether it draws attention, and — for a stored counter — what an operation does to it.\n *\n * ⚠️ **Choosing the source kind wrongly produces a number that DRIFTS.** Reach for `EVENT_COUNTER`\n * only when the count is a fact the badge itself owns (\"unread messages\": arrive → increment, seen →\n * reset). For any quantity derived from data an operation could change by another route — incomplete\n * todos, unpaid invoices — use `DERIVED_QUERY`, which recomputes a live aggregate. A stored counter\n * on a derived quantity is right on the day it is written and wrong thereafter.\n *\n * An `EVENT_COUNTER` badge additionally needs `notificationBadgeOperations` declared on the\n * operations that move it; a `DERIVED_QUERY` badge needs none, because the recompute hangs off the\n * source resource's own mutations.\n *\n * `FRONTEND_PRODUCED` is for a count the FRONTEND already holds and the backend cannot compute — a\n * quantity derived from rows that are not a repository collection (a projection, a live read the\n * browser keeps current). The surface that owns the data publishes it with\n * `usePublishNotificationBadgeCount`; nothing is stored and nothing is recomputed server-side.\n */\nexport enum NotificationBadgeOperation {\n INCREMENT = 'increment',\n DECREMENT = 'decrement',\n SET = 'set',\n RESET = 'reset',\n}\n\n/**\n * How a badge's count is CALCULATED — the load-bearing distinction (R1).\n *\n * - `EVENT_COUNTER`: a stored counter mutated imperatively on domain events\n * (arrive → increment, seen → reset). Correct for \"unread messages\" style\n * badges. The count lives in the badge document.\n * - `DERIVED_QUERY`: the count is a LIVE aggregate over a resource collection\n * (`count(resourceType where filter, scoped)`), recomputed on that resource's\n * mutations. Correct for \"incomplete todos\" / \"unpaid invoices\" — quantities\n * derived from data that would DRIFT if tracked with a stored counter.\n * - `FRONTEND_PRODUCED`: the count is PUBLISHED by the frontend surface that already holds the\n * data it counts (`usePublishNotificationBadgeCount`), onto the same badge store a backend push\n * feeds. The backend neither stores nor recomputes it and skips it when seeding a connection.\n * Correct only where the backend cannot run the count — the rows are a projection rather than a\n * repository collection — so a `DERIVED_QUERY` over repository rows is never replaced by this.\n * The producer must be mounted wherever the navigation showing the badge is: for a menubar or\n * sidebar badge, a shell companion (`ApplicationMainProviderOptions.shellCompanions`), which the\n * signed-in shell mounts on every page. A late-mounting badge reads the last published count.\n */\nexport enum NotificationBadgeSourceKind {\n EVENT_COUNTER = 'event_counter',\n DERIVED_QUERY = 'derived_query',\n FRONTEND_PRODUCED = 'frontend_produced',\n}\n\n/** How the badge is presented. `NONE` = suppressed even when the count is > 0. */\nexport enum NotificationBadgeDisplayMode {\n /** A colored signal dot (\"≥ 1\"), no number. */\n DOT = 'dot',\n /** The numeric count (truncated at the display cap). */\n COUNT = 'count',\n /** Rendered as nothing (count still computed/available). */\n NONE = 'none',\n}\n\n/**\n * WHETHER / WHEN a badge draws attention. The LOOK of the pulse is theme-owned\n * (`UIBehaviorRecipe.motion.attention`), so a definition only declares intent.\n */\nexport enum NotificationBadgePulse {\n NONE = 'none',\n /** Transitional — pulse briefly when the count rises (recommended). */\n ON_INCREASE = 'on_increase',\n /** Persistent — pulse while the count is > 0. */\n WHILE_ACTIVE = 'while_active',\n}\n/** @wildo_source:part:end saas.models.notifications.badge-vocabularies */\n\n/** EVENT_COUNTER source — no extra config; the stored counter is the truth. */\nexport const NotificationBadgeEventCounterSourceSchema = z.object({\n kind: z.literal(NotificationBadgeSourceKind.EVENT_COUNTER),\n});\n\n/**\n * DERIVED_QUERY source — the count is `count(resourceType where filter)` with the\n * scope bound via `scopeField` (the FK field on the counted resource that equals\n * the badge's `scopeId`, e.g. `userId` for a USER_SELF badge). Recomputed by the\n * backend on any mutation of `resourceType` (see backend R5).\n */\nexport const NotificationBadgeDerivedQuerySourceSchema = z.object({\n kind: z.literal(NotificationBadgeSourceKind.DERIVED_QUERY),\n resourceType: z.string().min(1, { error: 'Derived-badge resourceType is required' }),\n filter: z.record(z.string(), z.unknown()),\n scopeField: z.string().min(1, { error: 'Derived-badge scopeField is required' }),\n});\n\n/**\n * FRONTEND_PRODUCED source — no extra config: the publishing surface names the badge by its key and\n * supplies the count, so there is nothing for a declaration to say about how it is computed.\n */\nexport const NotificationBadgeFrontendProducedSourceSchema = z.object({\n kind: z.literal(NotificationBadgeSourceKind.FRONTEND_PRODUCED),\n});\n\n/** Discriminated union over the calculation kinds. */\nexport const NotificationBadgeSourceSchema = z.discriminatedUnion('kind', [\n NotificationBadgeEventCounterSourceSchema,\n NotificationBadgeDerivedQuerySourceSchema,\n NotificationBadgeFrontendProducedSourceSchema,\n]);\n\n/**\n * Presentation declaration. `tone` reuses the design-system `IndicatorVariant`\n * (single source — the `Badge` component maps the same enum). `pulse` is a\n * trigger only; the theme owns the animation.\n */\nexport const NotificationBadgeDisplaySchema = z.object({\n mode: z.enum(NotificationBadgeDisplayMode).default(NotificationBadgeDisplayMode.COUNT),\n tone: z.enum(IndicatorVariant).default(IndicatorVariant.NEUTRAL),\n pulse: z.enum(NotificationBadgePulse).default(NotificationBadgePulse.NONE),\n});\n\n/**\n * Badge IDENTITY — the (identifier, scope) tuple shared by the declaration and\n * the persisted document. Kept separate so the stored badge doc does NOT absorb\n * declaration-only fields (`source` / `display`).\n */\nconst NotificationBadgeIdentitySchema = z.object({\n identifier: NotificationBadgeIdentifierSchema,\n scope: NotificationScopeSchema,\n});\n\n/**\n * Badge DEFINITION — the declaration app/framework authors register: identity +\n * how the count is calculated (`source`) + how it is presented (`display`).\n */\nexport const NotificationBadgeDefinitionSchema = NotificationBadgeIdentitySchema.extend({\n source: NotificationBadgeSourceSchema,\n display: NotificationBadgeDisplaySchema,\n});\n\nconst NotificationBadgeBaseSchema = NotificationBadgeIdentitySchema.extend({\n // A compact badge without its application-defined identifier is not interpretable: callers\n // could see a number but not what the number counts. Override the identity field here (rather\n // than decorating NotificationBadgeIdentitySchema) so persisted API rows gain summary metadata\n // while application-authored badge definitions remain a plain declaration schema.\n identifier: NotificationBadgeIdentifierSchema.isSummaryField(),\n // `isPrimaryKey` (composite: excludeFromCreate + isHidden + isUnique + isDBIndexed) —\n // the server generates `_id`, so it must NOT be required on the create DTO. Using bare\n // `.isDBIndexed()` here left `_id` create-required, which failed the dispatcher-driven\n // badge materialization (`buildNewBadge` supplies no `_id`).\n _id: z.string().min(1, { error: 'Notification badge ID is required' }).isPrimaryKey(),\n count: z.number().min(0, { error: 'Notification badge count must be greater than or equal to 0' }).isSummaryField(),\n createdAt: z.date().default(() => new Date()).isDBIndexed(),\n updatedAt: z.date().default(() => new Date()).isDBIndexed().isSummaryField(),\n});\n\nexport const NotificationBadgeOrganizationSchema = NotificationBadgeBaseSchema.extend({\n scope: z.literal(ResourcePrimaryScope.ORGANIZATIONS).describe('Always `organizations`: this count is shared by every member of the organization.'),\n organizationId: z.string().min(1, { error: 'Organization ID is required' }).isDBIndexed().isForeignKey(),\n});\n\nexport const NotificationBadgeUserSelfSchema = NotificationBadgeBaseSchema.extend({\n scope: z.literal(ResourcePrimaryScope.USER_SELF).describe('Always `user_self`: this count belongs to one user and only that user can read it.'),\n userId: z.string().min(1, { error: 'User ID is required' }).isDBIndexed().isForeignKey(),\n});\n\n/**\n * Discriminated union over the two surviving badge scopes (USER_SELF / ORGANIZATIONS).\n * The APPLICATION variant was dropped — see `NotificationScopeSchema` JSDoc above.\n */\nexport const NotificationBadgeSchema = z.discriminatedUnion('scope', [\n NotificationBadgeOrganizationSchema,\n NotificationBadgeUserSelfSchema,\n]);\n\nexport type NotificationBadgeDefinition = z.infer<typeof NotificationBadgeDefinitionSchema>;\nexport type NotificationBadgeIdentifier = z.infer<typeof NotificationBadgeIdentifierSchema>;\nexport type NotificationScope = z.infer<typeof NotificationScopeSchema>;\nexport type NotificationBadge = z.infer<typeof NotificationBadgeSchema>;\nexport type NotificationBadgeSource = z.infer<typeof NotificationBadgeSourceSchema>;\nexport type NotificationBadgeDerivedQuerySource = z.infer<typeof NotificationBadgeDerivedQuerySourceSchema>;\nexport type NotificationBadgeDisplay = z.infer<typeof NotificationBadgeDisplaySchema>;\n\n\n// ════════════════════════════════════════════════════════════════\n// Badge IDENTITY — the one place the key and reference formats live\n// ════════════════════════════════════════════════════════════════\n\n/**\n * A badge KEY: `<scope>:<identifier>` — the DEFINITION's identity, and the only thing that may be\n * used to look a definition up.\n *\n * ## Why the identifier alone is not an identity\n *\n * A definition is `(scope, identifier)`. Nothing ever stopped two definitions declaring the same\n * `identifier` at different scopes, and until this type existed every lookup matched on the\n * identifier alone — so the second definition was unreachable and silently shared the first's\n * count. The key makes both reachable and makes the collision that DOES matter (two definitions at\n * one scope and identifier) something a boot check can refuse.\n *\n * ## Why `scopeId` is NOT in the key\n *\n * `scopeId` says WHOSE badge — a user id, an organization id. It is per-viewer instance data that a\n * navigation declaration cannot possibly carry, and a browser session only ever receives pushes for\n * its own scope ids (the backend routes USER badges to that user's socket and ORG badges to that\n * organization's room). So the key is what a DECLARATION can name, and the reference below is what\n * an INSTANCE is addressed by.\n */\nexport type NotificationBadgeKey = string;\n\n/**\n * A badge REFERENCE: `<scope>:<scopeId>:<identifier>` — one badge ROW, on the wire.\n *\n * Carried by `WS_BadgeUpdatePayload.badgeReference` because emission needs the scopeId to route.\n * The browser reduces it to a {@link NotificationBadgeKey} on arrival via\n * {@link notificationBadgeKeyFromReference}, which is what makes the store's key and the navigation\n * item's lookup the same key rather than two conventions that agree by luck.\n */\nexport type NotificationBadgeReference = string;\n\n/** Build the DEFINITION-identity key from its parts. */\nexport function buildNotificationBadgeKey(\n scope: NotificationScope,\n identifier: NotificationBadgeIdentifier,\n): NotificationBadgeKey {\n return `${scope}${NOTIFICATION_BADGE_KEY_SEPARATOR}${identifier}`;\n}\n\n/**\n * The key of a definition (or of anything else carrying a badge identity, such as a persisted row).\n *\n * Takes the identity fields rather than the whole definition so a `NotificationBadge` row and a\n * `NotificationBadgeDefinition` resolve through the SAME function — a second copy for the row shape\n * is how the two come to disagree.\n */\nexport function notificationBadgeIdentityKey(\n identity: Pick<NotificationBadgeDefinition, 'scope' | 'identifier'>,\n): NotificationBadgeKey {\n return buildNotificationBadgeKey(identity.scope, identity.identifier);\n}\n\n/**\n * Parse a key, returning `null` when it is not a well-formed key at a SUPPORTED scope.\n *\n * The scope check is not cosmetic: the APPLICATION variant was dropped in the polymorphism refactor\n * and no resource type backs it, so `application:foo` must fail here rather than reach a dispatch\n * that has no repository for it.\n */\nexport function parseNotificationBadgeKey(\n key: string,\n): { scope: NotificationScope; identifier: NotificationBadgeIdentifier } | null {\n const parts = key.split(NOTIFICATION_BADGE_KEY_SEPARATOR);\n if (parts.length !== 2) return null;\n const [scope, identifier] = parts;\n if (!isSupportedNotificationBadgeScope(scope) || identifier.length === 0) return null;\n return { scope, identifier };\n}\n\n/** Build the INSTANCE address carried on the wire. */\nexport function buildNotificationBadgeReference(\n scope: NotificationScope,\n scopeId: string,\n identifier: NotificationBadgeIdentifier,\n): NotificationBadgeReference {\n return `${scope}${NOTIFICATION_BADGE_KEY_SEPARATOR}${scopeId}${NOTIFICATION_BADGE_KEY_SEPARATOR}${identifier}`;\n}\n\n/** Parse a wire reference, returning `null` for a malformed one or an unsupported scope. */\nexport function parseNotificationBadgeReference(\n reference: string,\n): { scope: NotificationScope; scopeId: string; identifier: NotificationBadgeIdentifier } | null {\n const parts = reference.split(NOTIFICATION_BADGE_KEY_SEPARATOR);\n if (parts.length !== 3) return null;\n const [scope, scopeId, identifier] = parts;\n if (!isSupportedNotificationBadgeScope(scope) || scopeId.length === 0 || identifier.length === 0) return null;\n return { scope, scopeId, identifier };\n}\n\n/**\n * Reduce a wire reference to the DEFINITION key it addresses — the one hop the browser badge store\n * takes, so that what it keys on is what a navigation item resolves against.\n */\nexport function notificationBadgeKeyFromReference(reference: string): NotificationBadgeKey | null {\n const parsed = parseNotificationBadgeReference(reference);\n return parsed ? buildNotificationBadgeKey(parsed.scope, parsed.identifier) : null;\n}\n\n/** Whether a raw string names one of the two surviving badge scopes. */\nexport function isSupportedNotificationBadgeScope(scope: string): scope is NotificationScope {\n return scope === ResourcePrimaryScope.USER_SELF || scope === ResourcePrimaryScope.ORGANIZATIONS;\n}\n\n// ════════════════════════════════════════════════════════════════\n// Declaration coherence — checked at CONFIGURATION time\n// ════════════════════════════════════════════════════════════════\n\n/**\n * Why a badge declaration is refused. A closed vocabulary with a named runtime source, so a\n * diagnostic can be branched on and each member can carry its own explanation.\n */\nexport enum NotificationBadgeDeclarationViolationReason {\n /**\n * Two definitions declare the same `(scope, identifier)`. Every lookup resolves the FIRST, so\n * the second is unreachable while silently sharing the first's count — the shape that made\n * identifier-only lookup unsafe in the first place. Two definitions at DIFFERENT scopes are\n * fine and are exactly what the key makes reachable.\n */\n DUPLICATE_DEFINITION_KEY = 'duplicate_definition_key',\n /**\n * An identifier contains the key separator, which would make its key and every reference built\n * from it parse into the wrong parts. Refused rather than escaped: a positional format with an\n * escaping rule is a format two implementations will eventually disagree about.\n */\n IDENTIFIER_CONTAINS_KEY_SEPARATOR = 'identifier_contains_key_separator',\n /** An operation declares a `badgeRef` that names no registered definition. */\n OPERATION_REF_UNRESOLVED = 'operation_ref_unresolved',\n /**\n * An operation declares a counter move (increment, reset, …) on a badge whose count is NOT a\n * stored counter — a `DERIVED_QUERY` recomputes its own and a `FRONTEND_PRODUCED` is published by\n * the browser. The move would write a stored row nothing renders, and a backend push of that row\n * would overwrite the real count. Only an `EVENT_COUNTER` is moved by operations.\n */\n OPERATION_MOVES_UNSTORED_COUNT = 'operation_moves_unstored_count',\n}\n\n/** One refused declaration, carrying enough to name the author's own file without re-deriving it. */\nexport interface NotificationBadgeDeclarationViolation {\n reason: NotificationBadgeDeclarationViolationReason;\n /** The badge key at issue — the definition's, or the unresolved `badgeRef` as authored. */\n badgeKey: string;\n /** Present when the violation belongs to a definition rather than to an operation declaration. */\n identifier?: NotificationBadgeIdentifier;\n /** Present when the violation belongs to an operation declaration. */\n resourceType?: string;\n /** Present when the violation belongs to an operation declaration. */\n operationIdentifier?: string;\n}\n\n/** Where an operation declared a badge reference — one row per authored `notificationBadgeOperations` entry. */\nexport interface NotificationBadgeOperationDeclarationSite {\n resourceType: string;\n operationIdentifier: string;\n badgeRef: string;\n}\n\n/**\n * The whole declaration-coherence check, as a pure function over what an application declared.\n *\n * Pure and shared on purpose: the backend registry runs it as a fail-closed boot gate and the\n * frontend launcher verifier reports it in development, and a second implementation is how the two\n * come to disagree about what a valid declaration is.\n *\n * It answers the question `derive-before-you-ask.md` asks — who owes this, and what says so. The\n * population is exactly the registered definitions plus every authored\n * `notificationBadgeOperations` entry; nothing is inferred and nothing is sampled.\n */\nexport function collectNotificationBadgeDeclarationViolations(\n definitions: readonly NotificationBadgeDefinition[],\n operationSites: readonly NotificationBadgeOperationDeclarationSite[] = [],\n): NotificationBadgeDeclarationViolation[] {\n const violations: NotificationBadgeDeclarationViolation[] = [];\n const seenKeys = new Set<NotificationBadgeKey>();\n const sourceKindByKey = new Map<NotificationBadgeKey, NotificationBadgeSourceKind>();\n\n for (const definition of definitions) {\n if (!NOTIFICATION_BADGE_IDENTIFIER_PATTERN.test(definition.identifier)) {\n violations.push({\n reason: NotificationBadgeDeclarationViolationReason.IDENTIFIER_CONTAINS_KEY_SEPARATOR,\n badgeKey: notificationBadgeIdentityKey(definition),\n identifier: definition.identifier,\n });\n // Still recorded below, so a malformed identifier declared twice is reported as both.\n }\n\n const key = notificationBadgeIdentityKey(definition);\n if (seenKeys.has(key)) {\n violations.push({\n reason: NotificationBadgeDeclarationViolationReason.DUPLICATE_DEFINITION_KEY,\n badgeKey: key,\n identifier: definition.identifier,\n });\n continue;\n }\n seenKeys.add(key);\n sourceKindByKey.set(key, definition.source.kind);\n }\n\n for (const site of operationSites) {\n if (!seenKeys.has(site.badgeRef)) {\n violations.push({\n reason: NotificationBadgeDeclarationViolationReason.OPERATION_REF_UNRESOLVED,\n badgeKey: site.badgeRef,\n resourceType: site.resourceType,\n operationIdentifier: site.operationIdentifier,\n });\n continue;\n }\n if (sourceKindByKey.get(site.badgeRef) !== NotificationBadgeSourceKind.EVENT_COUNTER) {\n violations.push({\n reason: NotificationBadgeDeclarationViolationReason.OPERATION_MOVES_UNSTORED_COUNT,\n badgeKey: site.badgeRef,\n resourceType: site.resourceType,\n operationIdentifier: site.operationIdentifier,\n });\n }\n }\n\n return violations;\n}\n\n/**\n * Index the registered definitions by key, so a dispatch resolves in one lookup rather than a scan.\n *\n * Built from the SAME key function the boot check uses, so a definition the boot check accepted is\n * a definition this map can serve.\n */\nexport function buildNotificationBadgeDefinitionIndex(\n definitions: readonly NotificationBadgeDefinition[],\n): ReadonlyMap<NotificationBadgeKey, NotificationBadgeDefinition> {\n const index = new Map<NotificationBadgeKey, NotificationBadgeDefinition>();\n for (const definition of definitions) {\n const key = notificationBadgeIdentityKey(definition);\n if (!index.has(key)) index.set(key, definition);\n }\n return index;\n}\n"]}
1
+ {"version":3,"file":"notification-badges.schemas.js","sourceRoot":"","sources":["../../../src/notifications/notification-badges.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,iBAAiB,EAAE,MAAM,0BAA0B,CAAC;AAE7D,iBAAiB,CAAC,CAAC,CAAC,CAAC;AAErB,OAAO,EAAE,gBAAgB,EAAE,MAAM,qCAAqC,CAAC;AACvE,OAAO,EAAE,oBAAoB,EAAE,MAAM,uCAAuC,CAAC;AAG7E;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,gCAAgC,GAAG,GAAG,CAAC;AAEpD,iFAAiF;AACjF,MAAM,CAAC,MAAM,qCAAqC,GAAG,SAAS,CAAC;AAE/D;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,CAAC,MAAM,iCAAiC,GAAG,CAAC;KAC7C,MAAM,EAAE;KACR,GAAG,CAAC,CAAC,EAAE,EAAE,KAAK,EAAE,2CAA2C,EAAE,CAAC;KAC9D,KAAK,CAAC,qCAAqC,EAAE;IAC1C,KAAK,EAAE,mDAAmD,gCAAgC,qEAAqE;CAClK,CAAC,CAAC;AAEP;;;;;;;;;;;;;;GAcG;AACH,MAAM,CAAC,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AAU,CAAC,IAAI,CAAC;gBACZ,MAAM,EAAE,2CAA2C,CAAC,wBAAwB;gBAC5E,QAAQ,EAAE,IAAI,CAAC,QAAQ;gBACvB,YAAY,EAAE,IAAI,CAAC,YAAY;gBAC/B,mBAAmB,EAAE,IAAI,CAAC,mBAAmB;aAChD,CAAC,CAAC;YACH,SAAS;QACb,CAAC;QACD,IAAI,eAAe,CAAC,GAAG,CAAC,IAAI,CAAC,QAAQ,CAAC,KAAK,2BAA2B,CAAC,aAAa,EAAE,CAAC;YACnF,UAAU,CAAC,IAAI,CAAC;gBACZ,MAAM,EAAE,2CAA2C,CAAC,8BAA8B;gBAClF,QAAQ,EAAE,IAAI,CAAC,QAAQ;gBACvB,YAAY,EAAE,IAAI,CAAC,YAAY;gBAC/B,mBAAmB,EAAE,IAAI,CAAC,mBAAmB;aAChD,CAAC,CAAC;QACP,CAAC;IACL,CAAC;IAED,OAAO,UAAU,CAAC;AACtB,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,qCAAqC,CACjD,WAAmD;IAEnD,MAAM,KAAK,GAAG,IAAI,GAAG,EAAqD,CAAC;IAC3E,KAAK,MAAM,UAAU,IAAI,WAAW,EAAE,CAAC;QACnC,MAAM,GAAG,GAAG,4BAA4B,CAAC,UAAU,CAAC,CAAC;QACrD,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC,GAAG,CAAC;YAAE,KAAK,CAAC,GAAG,CAAC,GAAG,EAAE,UAAU,CAAC,CAAC;IACpD,CAAC;IACD,OAAO,KAAK,CAAC;AACjB,CAAC","sourcesContent":["import { z } from \"zod\";\nimport { initZodDecorators } from '@wildo-ai/zod-decorators';\n\ninitZodDecorators(z);\n\nimport { IndicatorVariant } from '@wildo-ai/presets-components-models';\nimport { ResourcePrimaryScope } from \"../resources/resources.shared.schemas\";\n\n\n/**\n * The one character that separates the parts of a badge KEY and a badge REFERENCE.\n *\n * Both formats are positional, so the separator may not appear inside a part or the parse is\n * ambiguous. `NotificationBadgeIdentifierSchema` refuses it in an identifier for exactly that\n * reason, and `collectNotificationBadgeDeclarationViolations` re-states the refusal at boot,\n * because a declaration object is authored in TypeScript and never `.parse()`d.\n */\nexport const NOTIFICATION_BADGE_KEY_SEPARATOR = ':';\n\n/** Any string that does not contain {@link NOTIFICATION_BADGE_KEY_SEPARATOR}. */\nexport const NOTIFICATION_BADGE_IDENTIFIER_PATTERN = /^[^:]+$/;\n\n/**\n * Notification badge identifier.\n *\n * The identifier is an open string because no canonical (core) identifier ships: the two\n * aspirational placeholders (`new messages` / `unpaid invoices`) were removed because nothing\n * produced them.\n *\n * The SURFACING is not missing. A navigation item declares `notificationBadgeRef` and the sidebar\n * and the menubar render it, and an application declares its own badges, so the open string is what an application\n * uses today. What is still absent is a FRAMEWORK-shipped identifier with a framework producer\n * behind it; when one lands, core identifiers come back as a `CoreNotificationBadgeIdentifiers`\n * enum unioned in here.\n *\n * Open, but not unconstrained: an identifier may not contain\n * {@link NOTIFICATION_BADGE_KEY_SEPARATOR}, because it is the LAST part of a badge key and of a\n * badge reference and both are positional. A definition object is authored in TypeScript and never\n * `.parse()`d, so this constraint is also re-stated as a boot check — see\n * {@link collectNotificationBadgeDeclarationViolations}.\n */\nexport const NotificationBadgeIdentifierSchema = z\n .string()\n .min(1, { error: 'Notification badge identifier is required' })\n .regex(NOTIFICATION_BADGE_IDENTIFIER_PATTERN, {\n error: `Notification badge identifier must not contain \"${NOTIFICATION_BADGE_KEY_SEPARATOR}\" — that character separates the parts of a badge key and reference`,\n });\n\n/**\n * Notification badge scope. Tightened to USER_SELF | ORGANIZATIONS only.\n *\n * The APPLICATION variant was dropped in the polymorphism refactor\n * (`.cursor/plans/notification-badges-polymorphism-refactor.md`):\n * - No canonical badges were ever declared at APPLICATION scope (see\n * `notification-badges.core.definitions.ts`).\n * - The two surviving variants (USER + ORG) each own their own resource type\n * and MongoDB collection. Allowing APPLICATION here would let consumers\n * write a payload that no resource configuration / collection accepts.\n *\n * `WS_BadgeUpdatePayload` semantics are unchanged — the dispatcher in\n * `NotificationBadgeBackendService.emitBadgeUpdate` still routes USER badges to\n * `sendToUser` and ORG badges to `sendToOrganization`.\n */\nexport const NotificationScopeSchema = z.enum([\n ResourcePrimaryScope.USER_SELF,\n ResourcePrimaryScope.ORGANIZATIONS,\n]);\n\n/**\n * @wildo_source:part:start saas.models.notifications.badge-vocabularies facet:layer:shared facet:audience:app-developer\n *\n * The four vocabularies a badge definition picks from: how its count is CALCULATED, how it is\n * PRESENTED, whether it draws attention, and — for a stored counter — what an operation does to it.\n *\n * ⚠️ **Choosing the source kind wrongly produces a number that DRIFTS.** Reach for `EVENT_COUNTER`\n * only when the count is a fact the badge itself owns (\"unread messages\": arrive → increment, seen →\n * reset). For any quantity derived from data an operation could change by another route — incomplete\n * todos, unpaid invoices — use `DERIVED_QUERY`, which recomputes a live aggregate. A stored counter\n * on a derived quantity is right on the day it is written and wrong thereafter.\n *\n * An `EVENT_COUNTER` badge additionally needs `notificationBadgeOperations` declared on the\n * operations that move it; a `DERIVED_QUERY` badge needs none, because the recompute hangs off the\n * source resource's own mutations.\n *\n * `FRONTEND_PRODUCED` is for a count the FRONTEND already holds and the backend cannot compute — a\n * quantity derived from rows that are not a repository collection (a projection, a live read the\n * browser keeps current). The surface that owns the data publishes it with\n * `usePublishNotificationBadgeCount`; nothing is stored and nothing is recomputed server-side.\n */\nexport enum NotificationBadgeOperation {\n INCREMENT = 'increment',\n DECREMENT = 'decrement',\n SET = 'set',\n RESET = 'reset',\n}\n\n/**\n * How a badge's count is CALCULATED — the load-bearing distinction (R1).\n *\n * - `EVENT_COUNTER`: a stored counter mutated imperatively on domain events\n * (arrive → increment, seen → reset). Correct for \"unread messages\" style\n * badges. The count lives in the badge document.\n * - `DERIVED_QUERY`: the count is a LIVE aggregate over a resource collection\n * (`count(resourceType where filter, scoped)`), recomputed on that resource's\n * mutations. Correct for \"incomplete todos\" / \"unpaid invoices\" — quantities\n * derived from data that would DRIFT if tracked with a stored counter.\n * - `FRONTEND_PRODUCED`: the count is PUBLISHED by the frontend surface that already holds the\n * data it counts (`usePublishNotificationBadgeCount`), onto the same badge store a backend push\n * feeds. The backend neither stores nor recomputes it and skips it when seeding a connection.\n * Correct only where the backend cannot run the count — the rows are a projection rather than a\n * repository collection — so a `DERIVED_QUERY` over repository rows is never replaced by this.\n * The producer must be mounted wherever the navigation showing the badge is: for a menubar or\n * sidebar badge, a shell companion (`ApplicationMainProviderOptions.shellCompanions`), which the\n * signed-in shell mounts on every page. A late-mounting badge reads the last published count.\n */\nexport enum NotificationBadgeSourceKind {\n EVENT_COUNTER = 'event_counter',\n DERIVED_QUERY = 'derived_query',\n FRONTEND_PRODUCED = 'frontend_produced',\n}\n\n/** How the badge is presented. `NONE` = suppressed even when the count is > 0. */\nexport enum NotificationBadgeDisplayMode {\n /** A colored signal dot (\"≥ 1\"), no number. */\n DOT = 'dot',\n /** The numeric count (truncated at the display cap). */\n COUNT = 'count',\n /** Rendered as nothing (count still computed/available). */\n NONE = 'none',\n}\n\n/**\n * WHETHER / WHEN a badge draws attention. The LOOK of the pulse is theme-owned\n * (`UIBehaviorRecipe.motion.attention`), so a definition only declares intent.\n */\nexport enum NotificationBadgePulse {\n NONE = 'none',\n /** Transitional — pulse briefly when the count rises (recommended). */\n ON_INCREASE = 'on_increase',\n /** Persistent — pulse while the count is > 0. */\n WHILE_ACTIVE = 'while_active',\n}\n/** @wildo_source:part:end saas.models.notifications.badge-vocabularies */\n\n/** EVENT_COUNTER source — no extra config; the stored counter is the truth. */\nexport const NotificationBadgeEventCounterSourceSchema = z.object({\n kind: z.literal(NotificationBadgeSourceKind.EVENT_COUNTER),\n});\n\n/**\n * DERIVED_QUERY source — the count is `count(resourceType where filter)` with the\n * scope bound via `scopeField` (the FK field on the counted resource that equals\n * the badge's `scopeId`, e.g. `userId` for a USER_SELF badge). Recomputed by the\n * backend on any mutation of `resourceType` (see backend R5).\n */\nexport const NotificationBadgeDerivedQuerySourceSchema = z.object({\n kind: z.literal(NotificationBadgeSourceKind.DERIVED_QUERY),\n resourceType: z.string().min(1, { error: 'Derived-badge resourceType is required' }),\n filter: z.record(z.string(), z.unknown()),\n scopeField: z.string().min(1, { error: 'Derived-badge scopeField is required' }),\n});\n\n/**\n * FRONTEND_PRODUCED source — no extra config: the publishing surface names the badge by its key and\n * supplies the count, so there is nothing for a declaration to say about how it is computed.\n */\nexport const NotificationBadgeFrontendProducedSourceSchema = z.object({\n kind: z.literal(NotificationBadgeSourceKind.FRONTEND_PRODUCED),\n});\n\n/** Discriminated union over the calculation kinds. */\nexport const NotificationBadgeSourceSchema = z.discriminatedUnion('kind', [\n NotificationBadgeEventCounterSourceSchema,\n NotificationBadgeDerivedQuerySourceSchema,\n NotificationBadgeFrontendProducedSourceSchema,\n]);\n\n/**\n * Presentation declaration. `tone` reuses the design-system `IndicatorVariant`\n * (single source — the `Badge` component maps the same enum). `pulse` is a\n * trigger only; the theme owns the animation.\n */\nexport const NotificationBadgeDisplaySchema = z.object({\n mode: z.enum(NotificationBadgeDisplayMode).default(NotificationBadgeDisplayMode.COUNT),\n tone: z.enum(IndicatorVariant).default(IndicatorVariant.NEUTRAL),\n pulse: z.enum(NotificationBadgePulse).default(NotificationBadgePulse.NONE),\n});\n\n/**\n * Badge IDENTITY — the (identifier, scope) tuple shared by the declaration and\n * the persisted document. Kept separate so the stored badge doc does NOT absorb\n * declaration-only fields (`source` / `display`).\n */\nconst NotificationBadgeIdentitySchema = z.object({\n identifier: NotificationBadgeIdentifierSchema,\n scope: NotificationScopeSchema,\n});\n\n/**\n * Badge DEFINITION — the declaration app/framework authors register: identity +\n * how the count is calculated (`source`) + how it is presented (`display`).\n */\nexport const NotificationBadgeDefinitionSchema = NotificationBadgeIdentitySchema.extend({\n source: NotificationBadgeSourceSchema,\n display: NotificationBadgeDisplaySchema,\n});\n\nconst NotificationBadgeBaseSchema = NotificationBadgeIdentitySchema.extend({\n // A compact badge without its application-defined identifier is not interpretable: callers\n // could see a number but not what the number counts. Override the identity field here (rather\n // than decorating NotificationBadgeIdentitySchema) so persisted API rows gain summary metadata\n // while application-authored badge definitions remain a plain declaration schema.\n identifier: NotificationBadgeIdentifierSchema.isSummaryField(),\n // `isPrimaryKey` (composite: excludeFromCreate + isHidden + isUnique + isDBIndexed) —\n // the server generates `_id`, so it must NOT be required on the create DTO. Using bare\n // `.isDBIndexed()` here left `_id` create-required, which failed the dispatcher-driven\n // badge materialization (`buildNewBadge` supplies no `_id`).\n _id: z.string().min(1, { error: 'Notification badge ID is required' }).isPrimaryKey(),\n count: z.number().min(0, { error: 'Notification badge count must be greater than or equal to 0' }).isSummaryField(),\n createdAt: z.date().default(() => new Date()).isDBIndexed(),\n updatedAt: z.date().default(() => new Date()).isDBIndexed().isSummaryField(),\n});\n\nexport const NotificationBadgeOrganizationSchema = NotificationBadgeBaseSchema.extend({\n scope: z.literal(ResourcePrimaryScope.ORGANIZATIONS).describe('Always `organizations`: this count is shared by every member of the organization.'),\n organizationId: z.string().min(1, { error: 'Organization ID is required' }).isDBIndexed().isForeignKey(),\n});\n\nexport const NotificationBadgeUserSelfSchema = NotificationBadgeBaseSchema.extend({\n scope: z.literal(ResourcePrimaryScope.USER_SELF).describe('Always `user_self`: this count belongs to one user and only that user can read it.'),\n userId: z.string().min(1, { error: 'User ID is required' }).isDBIndexed().isForeignKey(),\n});\n\n/**\n * Discriminated union over the two surviving badge scopes (USER_SELF / ORGANIZATIONS).\n * The APPLICATION variant was dropped — see `NotificationScopeSchema` JSDoc above.\n */\nexport const NotificationBadgeSchema = z.discriminatedUnion('scope', [\n NotificationBadgeOrganizationSchema,\n NotificationBadgeUserSelfSchema,\n]);\n\nexport type NotificationBadgeDefinition = z.infer<typeof NotificationBadgeDefinitionSchema>;\nexport type NotificationBadgeIdentifier = z.infer<typeof NotificationBadgeIdentifierSchema>;\nexport type NotificationScope = z.infer<typeof NotificationScopeSchema>;\nexport type NotificationBadge = z.infer<typeof NotificationBadgeSchema>;\nexport type NotificationBadgeSource = z.infer<typeof NotificationBadgeSourceSchema>;\nexport type NotificationBadgeDerivedQuerySource = z.infer<typeof NotificationBadgeDerivedQuerySourceSchema>;\nexport type NotificationBadgeDisplay = z.infer<typeof NotificationBadgeDisplaySchema>;\n\n\n// ════════════════════════════════════════════════════════════════\n// Badge IDENTITY — the one place the key and reference formats live\n// ════════════════════════════════════════════════════════════════\n\n/**\n * A badge KEY: `<scope>:<identifier>` — the DEFINITION's identity, and the only thing that may be\n * used to look a definition up.\n *\n * ## Why the identifier alone is not an identity\n *\n * A definition is `(scope, identifier)`. Nothing ever stopped two definitions declaring the same\n * `identifier` at different scopes, and until this type existed every lookup matched on the\n * identifier alone — so the second definition was unreachable and silently shared the first's\n * count. The key makes both reachable and makes the collision that DOES matter (two definitions at\n * one scope and identifier) something a boot check can refuse.\n *\n * ## Why `scopeId` is NOT in the key\n *\n * `scopeId` says WHOSE badge — a user id, an organization id. It is per-viewer instance data that a\n * navigation declaration cannot possibly carry, and a browser session only ever receives pushes for\n * its own scope ids (the backend routes USER badges to that user's socket and ORG badges to that\n * organization's room). So the key is what a DECLARATION can name, and the reference below is what\n * an INSTANCE is addressed by.\n */\nexport type NotificationBadgeKey = string;\n\n/**\n * A badge REFERENCE: `<scope>:<scopeId>:<identifier>` — one badge ROW, on the wire.\n *\n * Carried by `WS_BadgeUpdatePayload.badgeReference` because emission needs the scopeId to route.\n * The browser reduces it to a {@link NotificationBadgeKey} on arrival via\n * {@link notificationBadgeKeyFromReference}, which is what makes the store's key and the navigation\n * item's lookup the same key rather than two conventions that agree by luck.\n */\nexport type NotificationBadgeReference = string;\n\n/** Build the DEFINITION-identity key from its parts. */\nexport function buildNotificationBadgeKey(\n scope: NotificationScope,\n identifier: NotificationBadgeIdentifier,\n): NotificationBadgeKey {\n return `${scope}${NOTIFICATION_BADGE_KEY_SEPARATOR}${identifier}`;\n}\n\n/**\n * The key of a definition (or of anything else carrying a badge identity, such as a persisted row).\n *\n * Takes the identity fields rather than the whole definition so a `NotificationBadge` row and a\n * `NotificationBadgeDefinition` resolve through the SAME function — a second copy for the row shape\n * is how the two come to disagree.\n */\nexport function notificationBadgeIdentityKey(\n identity: Pick<NotificationBadgeDefinition, 'scope' | 'identifier'>,\n): NotificationBadgeKey {\n return buildNotificationBadgeKey(identity.scope, identity.identifier);\n}\n\n/**\n * Parse a key, returning `null` when it is not a well-formed key at a SUPPORTED scope.\n *\n * The scope check is not cosmetic: the APPLICATION variant was dropped in the polymorphism refactor\n * and no resource type backs it, so `application:foo` must fail here rather than reach a dispatch\n * that has no repository for it.\n */\nexport function parseNotificationBadgeKey(\n key: string,\n): { scope: NotificationScope; identifier: NotificationBadgeIdentifier } | null {\n const parts = key.split(NOTIFICATION_BADGE_KEY_SEPARATOR);\n if (parts.length !== 2) return null;\n const [scope, identifier] = parts;\n if (!isSupportedNotificationBadgeScope(scope) || identifier.length === 0) return null;\n return { scope, identifier };\n}\n\n/** Build the INSTANCE address carried on the wire. */\nexport function buildNotificationBadgeReference(\n scope: NotificationScope,\n scopeId: string,\n identifier: NotificationBadgeIdentifier,\n): NotificationBadgeReference {\n return `${scope}${NOTIFICATION_BADGE_KEY_SEPARATOR}${scopeId}${NOTIFICATION_BADGE_KEY_SEPARATOR}${identifier}`;\n}\n\n/** Parse a wire reference, returning `null` for a malformed one or an unsupported scope. */\nexport function parseNotificationBadgeReference(\n reference: string,\n): { scope: NotificationScope; scopeId: string; identifier: NotificationBadgeIdentifier } | null {\n const parts = reference.split(NOTIFICATION_BADGE_KEY_SEPARATOR);\n if (parts.length !== 3) return null;\n const [scope, scopeId, identifier] = parts;\n if (!isSupportedNotificationBadgeScope(scope) || scopeId.length === 0 || identifier.length === 0) return null;\n return { scope, scopeId, identifier };\n}\n\n/**\n * Reduce a wire reference to the DEFINITION key it addresses — the one hop the browser badge store\n * takes, so that what it keys on is what a navigation item resolves against.\n */\nexport function notificationBadgeKeyFromReference(reference: string): NotificationBadgeKey | null {\n const parsed = parseNotificationBadgeReference(reference);\n return parsed ? buildNotificationBadgeKey(parsed.scope, parsed.identifier) : null;\n}\n\n/** Whether a raw string names one of the two surviving badge scopes. */\nexport function isSupportedNotificationBadgeScope(scope: string): scope is NotificationScope {\n return scope === ResourcePrimaryScope.USER_SELF || scope === ResourcePrimaryScope.ORGANIZATIONS;\n}\n\n// ════════════════════════════════════════════════════════════════\n// Declaration coherence — checked at CONFIGURATION time\n// ════════════════════════════════════════════════════════════════\n\n/**\n * Why a badge declaration is refused. A closed vocabulary with a named runtime source, so a\n * diagnostic can be branched on and each member can carry its own explanation.\n */\nexport enum NotificationBadgeDeclarationViolationReason {\n /**\n * Two definitions declare the same `(scope, identifier)`. Every lookup resolves the FIRST, so\n * the second is unreachable while silently sharing the first's count — the shape that made\n * identifier-only lookup unsafe in the first place. Two definitions at DIFFERENT scopes are\n * fine and are exactly what the key makes reachable.\n */\n DUPLICATE_DEFINITION_KEY = 'duplicate_definition_key',\n /**\n * An identifier contains the key separator, which would make its key and every reference built\n * from it parse into the wrong parts. Refused rather than escaped: a positional format with an\n * escaping rule is a format two implementations will eventually disagree about.\n */\n IDENTIFIER_CONTAINS_KEY_SEPARATOR = 'identifier_contains_key_separator',\n /** An operation declares a `badgeRef` that names no registered definition. */\n OPERATION_REF_UNRESOLVED = 'operation_ref_unresolved',\n /**\n * An operation declares a counter move (increment, reset, …) on a badge whose count is NOT a\n * stored counter — a `DERIVED_QUERY` recomputes its own and a `FRONTEND_PRODUCED` is published by\n * the browser. The move would write a stored row nothing renders, and a backend push of that row\n * would overwrite the real count. Only an `EVENT_COUNTER` is moved by operations.\n */\n OPERATION_MOVES_UNSTORED_COUNT = 'operation_moves_unstored_count',\n}\n\n/** One refused declaration, carrying enough to name the author's own file without re-deriving it. */\nexport interface NotificationBadgeDeclarationViolation {\n reason: NotificationBadgeDeclarationViolationReason;\n /** The badge key at issue — the definition's, or the unresolved `badgeRef` as authored. */\n badgeKey: string;\n /** Present when the violation belongs to a definition rather than to an operation declaration. */\n identifier?: NotificationBadgeIdentifier;\n /** Present when the violation belongs to an operation declaration. */\n resourceType?: string;\n /** Present when the violation belongs to an operation declaration. */\n operationIdentifier?: string;\n}\n\n/** Where an operation declared a badge reference — one row per authored `notificationBadgeOperations` entry. */\nexport interface NotificationBadgeOperationDeclarationSite {\n resourceType: string;\n operationIdentifier: string;\n badgeRef: string;\n}\n\n/**\n * The whole declaration-coherence check, as a pure function over what an application declared.\n *\n * Pure and shared on purpose: the backend registry runs it as a fail-closed boot gate and the\n * frontend launcher verifier reports it in development, and a second implementation is how the two\n * come to disagree about what a valid declaration is.\n *\n * It answers the question `derive-before-you-ask.md` asks — who owes this, and what says so. The\n * population is exactly the registered definitions plus every authored\n * `notificationBadgeOperations` entry; nothing is inferred and nothing is sampled.\n */\nexport function collectNotificationBadgeDeclarationViolations(\n definitions: readonly NotificationBadgeDefinition[],\n operationSites: readonly NotificationBadgeOperationDeclarationSite[] = [],\n): NotificationBadgeDeclarationViolation[] {\n const violations: NotificationBadgeDeclarationViolation[] = [];\n const seenKeys = new Set<NotificationBadgeKey>();\n const sourceKindByKey = new Map<NotificationBadgeKey, NotificationBadgeSourceKind>();\n\n for (const definition of definitions) {\n if (!NOTIFICATION_BADGE_IDENTIFIER_PATTERN.test(definition.identifier)) {\n violations.push({\n reason: NotificationBadgeDeclarationViolationReason.IDENTIFIER_CONTAINS_KEY_SEPARATOR,\n badgeKey: notificationBadgeIdentityKey(definition),\n identifier: definition.identifier,\n });\n // Still recorded below, so a malformed identifier declared twice is reported as both.\n }\n\n const key = notificationBadgeIdentityKey(definition);\n if (seenKeys.has(key)) {\n violations.push({\n reason: NotificationBadgeDeclarationViolationReason.DUPLICATE_DEFINITION_KEY,\n badgeKey: key,\n identifier: definition.identifier,\n });\n continue;\n }\n seenKeys.add(key);\n sourceKindByKey.set(key, definition.source.kind);\n }\n\n for (const site of operationSites) {\n if (!seenKeys.has(site.badgeRef)) {\n violations.push({\n reason: NotificationBadgeDeclarationViolationReason.OPERATION_REF_UNRESOLVED,\n badgeKey: site.badgeRef,\n resourceType: site.resourceType,\n operationIdentifier: site.operationIdentifier,\n });\n continue;\n }\n if (sourceKindByKey.get(site.badgeRef) !== NotificationBadgeSourceKind.EVENT_COUNTER) {\n violations.push({\n reason: NotificationBadgeDeclarationViolationReason.OPERATION_MOVES_UNSTORED_COUNT,\n badgeKey: site.badgeRef,\n resourceType: site.resourceType,\n operationIdentifier: site.operationIdentifier,\n });\n }\n }\n\n return violations;\n}\n\n/**\n * Index the registered definitions by key, so a dispatch resolves in one lookup rather than a scan.\n *\n * Built from the SAME key function the boot check uses, so a definition the boot check accepted is\n * a definition this map can serve.\n */\nexport function buildNotificationBadgeDefinitionIndex(\n definitions: readonly NotificationBadgeDefinition[],\n): ReadonlyMap<NotificationBadgeKey, NotificationBadgeDefinition> {\n const index = new Map<NotificationBadgeKey, NotificationBadgeDefinition>();\n for (const definition of definitions) {\n const key = notificationBadgeIdentityKey(definition);\n if (!index.has(key)) index.set(key, definition);\n }\n return index;\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"notification-badges.shared.resources-config.schemas.d.ts","sourceRoot":"","sources":["../../../../src/notifications/notification-badges.shared.resources-config.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AAEH,OAAO,EACL,+BAA+B,EAC/B,mCAAmC,EACpC,MAAM,+BAA+B,CAAC;AAEvC,OAAO,EACL,qBAAqB,EAGtB,MAAM,gDAAgD,CAAC;AACxD,OAAO,EAGL,oBAAoB,EACrB,MAAM,uCAAuC,CAAC;AAC/C,OAAO,EAAE,qBAAqB,EAAE,MAAM,8CAA8C,CAAC;AAOrF,KAAK,oCAAoC,GACrC,qBAAqB,CAAC,IAAI,GAC1B,qBAAqB,CAAC,IAAI,GAC1B,qBAAqB,CAAC,MAAM,GAC5B,qBAAqB,CAAC,MAAM,GAC5B,qBAAqB,CAAC,MAAM,CAAC;AAEjC,eAAO,MAAM,iEAAiE,GAC5E,wBAAwB,oBAAoB,EAAE,KAC7C,qBAAqB,CACtB,SAAS,EACT,oCAAoC,EACpC,OAAO,+BAA+B,CA0GtC,CAAC;AAIH,KAAK,4CAA4C,GAC7C,qBAAqB,CAAC,IAAI,GAC1B,qBAAqB,CAAC,IAAI,GAC1B,qBAAqB,CAAC,MAAM,GAC5B,qBAAqB,CAAC,MAAM,GAC5B,qBAAqB,CAAC,MAAM,CAAC;AAEjC,eAAO,MAAM,yEAAyE,GACpF,wBAAwB,oBAAoB,EAAE,KAC7C,qBAAqB,CACtB,SAAS,EACT,4CAA4C,EAC5C,OAAO,mCAAmC,CAoF1C,CAAC"}
1
+ {"version":3,"file":"notification-badges.shared.resources-config.schemas.d.ts","sourceRoot":"","sources":["../../../src/notifications/notification-badges.shared.resources-config.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AAEH,OAAO,EACL,+BAA+B,EAC/B,mCAAmC,EACpC,MAAM,+BAA+B,CAAC;AAEvC,OAAO,EACL,qBAAqB,EAGtB,MAAM,gDAAgD,CAAC;AACxD,OAAO,EAGL,oBAAoB,EACrB,MAAM,uCAAuC,CAAC;AAC/C,OAAO,EAAE,qBAAqB,EAAE,MAAM,8CAA8C,CAAC;AAOrF,KAAK,oCAAoC,GACrC,qBAAqB,CAAC,IAAI,GAC1B,qBAAqB,CAAC,IAAI,GAC1B,qBAAqB,CAAC,MAAM,GAC5B,qBAAqB,CAAC,MAAM,GAC5B,qBAAqB,CAAC,MAAM,CAAC;AAEjC,eAAO,MAAM,iEAAiE,GAC5E,wBAAwB,oBAAoB,EAAE,KAC7C,qBAAqB,CACtB,SAAS,EACT,oCAAoC,EACpC,OAAO,+BAA+B,CA0GtC,CAAC;AAIH,KAAK,4CAA4C,GAC7C,qBAAqB,CAAC,IAAI,GAC1B,qBAAqB,CAAC,IAAI,GAC1B,qBAAqB,CAAC,MAAM,GAC5B,qBAAqB,CAAC,MAAM,GAC5B,qBAAqB,CAAC,MAAM,CAAC;AAEjC,eAAO,MAAM,yEAAyE,GACpF,wBAAwB,oBAAoB,EAAE,KAC7C,qBAAqB,CACtB,SAAS,EACT,4CAA4C,EAC5C,OAAO,mCAAmC,CAoF1C,CAAC"}
@@ -1 +1 @@
1
- {"version":3,"file":"notification-badges.shared.resources-config.schemas.js","sourceRoot":"","sources":["../../../../src/notifications/notification-badges.shared.resources-config.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoCG;AAEH,OAAO,EACL,+BAA+B,EAC/B,mCAAmC,GACpC,MAAM,+BAA+B,CAAC;AACvC,OAAO,EAAE,0CAA0C,EAAE,MAAM,8CAA8C,CAAC;AAC1G,OAAO,EACL,qBAAqB,EACrB,gBAAgB,EAChB,kCAAkC,GACnC,MAAM,gDAAgD,CAAC;AACxD,OAAO,EACL,0BAA0B,EAC1B,4BAA4B,GAE7B,MAAM,uCAAuC,CAAC;AAE/C,OAAO,EAAE,cAAc,EAAE,cAAc,EAAE,MAAM,iDAAiD,CAAC;AACjG,OAAO,EAAE,wBAAwB,EAAE,MAAM,8CAA8C,CAAC;AACxF,OAAO,EAAE,yBAAyB,EAAE,MAAM,qDAAqD,CAAC;AAWhG,MAAM,CAAC,MAAM,iEAAiE,GAAG,CAC/E,sBAA8C,EAK9C,EAAE,CAAC,0CAA0C,CAI7C;IACA,UAAU,EAAE,+BAA+B;IAC3C,kBAAkB,EAAE,gBAAgB,CAAC,wBAAwB;IAC7D,uBAAuB,EACrB,kCAAkC,CAAC,gBAAgB,CAAC,wBAAwB,CAAC;IAC/E,qBAAqB,EAAE,sBAAsB;IAC7C,gBAAgB,EAAE,IAAI;IACtB,+JAA+J;IAC/J,kBAAkB,EAAE,EAAE,aAAa,EAAE,wBAAwB,CAAC,OAAO,EAAE;IACvE,iBAAiB,EAAE,EAAE,iBAAiB,EAAE,yBAAyB,CAAC,OAAO,EAAE;IAG3E;;;;;;;;;;;;;;OAcG;IAEH,cAAc,EAAE;QACd,qBA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BAA4B,CAAC,QAAQ;oBAClD,SAAS,EAAE,IAAI;oBACf,KAAK,EAAE,CAAC,cAAc,CAAC,UAAU,CAAC;oBAClC,SAAS,EAAE,0BAA0B,CAAC,GAAG;iBAC1C;aACF;SACF;QACD,CAAC,qBAAqB,CAAC,MAAM,CAAC,EAAE;YAC9B,QAAQ,EAAE;gBACR;oBACE,WAAW,EAAE,4BAA4B,CAAC,eAAe;oBACzD,SAAS,EAAE,IAAI;oBACf,KAAK,EAAE,CAAC,cAAc,CAAC,qBAAqB,CAAC;oBAC7C,SAAS,EAAE,0BAA0B,CAAC,GAAG;iBAC1C;aACF;SACF;QACD,CAAC,qBAAqB,CAAC,MAAM,CAAC,EAAE;YAC9B,QAAQ,EAAE;gBACR;oBACE,WAAW,EAAE,4BAA4B,CAAC,eAAe;oBACzD,SAAS,EAAE,IAAI;oBACf,KAAK,EAAE,CAAC,cAAc,CAAC,qBAAqB,CAAC;oBAC7C,SAAS,EAAE,0BAA0B,CAAC,GAAG;iBAC1C;aACF;SACF;QAED,yEAAyE;QACzE,8EAA8E;QAC9E,gFAAgF;QAChF,mEAAmE;QACnE,oEAAoE;QACpE,8EAA8E;QAC9E,CAAC,qBAAqB,CAAC,MAAM,CAAC,EAAE;YAC9B,QAAQ,EAAE;gBACR;oBACE,WAAW,EAAE,4BAA4B,CAAC,eAAe;oBACzD,SAAS,EAAE,IAAI;oBACf,KAAK,EAAE,CAAC,cAAc,CAAC,qBAAqB,CAAC;oBAC7C,SAAS,EAAE,0BAA0B,CAAC,IAAI;iBAC3C;aACF;SACF;KACF;CACF,CAAC,CAAC","sourcesContent":["/**\n * Notification Badges Shared Resource Configurations\n *\n * Polymorphic dual-scope (USER + ORGANIZATION). Two completely separate factories,\n * each registered against its own `ResourceType` member and backed by its own\n * MongoDB collection. We follow the lifecycle-state / guidance-state pattern\n * (two side-by-side factories) rather than `createPolymorphicResourceConfigurations`\n * because the variants have:\n * - Different schemas (`NotificationBadgeUserSelfSchema` vs\n * `NotificationBadgeOrganizationSchema`),\n * - Different role surfaces (`APP_USER` reads on the USER variant vs\n * `ORG_MEMBER` reads on the ORG variant), and\n * - Different parent-scope anchors (USERS vs ORGANIZATIONS).\n *\n * Both variants:\n * - Operations: READ / LIST / CREATE / UPDATE (no DELETE — badges are reset to 0).\n * - `isSystemResource: true` — internal infrastructure, accessed via\n * `NotificationBadgeBackendService` (the public API is `increment`,\n * `decrement`, `set`, `reset` — never raw repository calls from app code).\n *\n * Role + variant assignments per D-2 of `.cursor/plans/notification-badges-polymorphism-refactor.md`\n * (mirrors the lifecycle-state precedent: READ/LIST exposed as `API_CALL` so\n * the user can read their own badges through the framework's HTTP surface;\n * CREATE/UPDATE stay `REPOSITORY_ONLY` because badge writes are exclusively\n * driven by `NotificationBadgeBackendService` from internal dispatchers):\n * - USER variant:\n * READ / LIST → `[CORE_APP_ROLES.APP_USER]` via `API_CALL`\n * CREATE/UPDATE → `[CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN]` via `REPOSITORY_ONLY`\n * - ORG variant:\n * READ / LIST → `[CORE_ORG_ROLES.ORG_MEMBER]` via `API_CALL`\n * (any org member can see aggregate org badges; matches\n * the lifecycle-state pattern's symmetric ORG_MEMBER read)\n * CREATE/UPDATE → `[CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN]` via `REPOSITORY_ONLY`\n *\n * @see notification-badges.schemas.ts — discriminated union at the data layer\n * @see .cursor/plans/notification-badges-polymorphism-refactor.md\n */\n\nimport {\n NotificationBadgeUserSelfSchema,\n NotificationBadgeOrganizationSchema,\n} from './notification-badges.schemas';\nimport { createResourceConfiguration_Initialization } from '../resources/resources-config.shared.factory';\nimport {\n CoreResourceOperation,\n CoreResourceType,\n coreResourceShared_FieldIdentifier,\n} from '../resources/resources.shared.core.definitions';\nimport {\n ResourceOperationRiskLevel,\n ResourceOperationVariantType,\n ResourceRelationship,\n} from '../resources/resources.shared.schemas';\nimport { ResourceConfiguration } from '../resources/resources-config.shared.schemas';\nimport { CORE_APP_ROLES, CORE_ORG_ROLES } from '../security/authorizations/roles.shared.schemas';\nimport { ResourceSystemAccessMode } from '../resources/resources-config.shared.schemas';\nimport { DataPortabilityProvenance } from '../compliance/privacy/subject-export.shared.schemas';\n\n// ─── USER NOTIFICATION BADGES ─────────────────────────────────────────────────\n\ntype UserNotificationBadgesCoreOperations =\n | CoreResourceOperation.READ\n | CoreResourceOperation.LIST\n | CoreResourceOperation.CREATE\n | CoreResourceOperation.UPDATE\n | CoreResourceOperation.DELETE;\n\nexport const userNotificationBadgesResourceConfiguration_InitializationFactory = (\n resourcesRelationships: ResourceRelationship[]\n): ResourceConfiguration<\n undefined,\n UserNotificationBadgesCoreOperations,\n typeof NotificationBadgeUserSelfSchema\n> => createResourceConfiguration_Initialization<\n undefined,\n UserNotificationBadgesCoreOperations,\n typeof NotificationBadgeUserSelfSchema\n>({\n mainSchema: NotificationBadgeUserSelfSchema,\n resourceIdentifier: CoreResourceType.USER_NOTIFICATION_BADGES,\n resourceFieldIdentifier:\n coreResourceShared_FieldIdentifier[CoreResourceType.USER_NOTIFICATION_BADGES],\n resourceRelationships: resourcesRelationships,\n isSystemResource: true,\n /** Subject-export disclosure. The subject's own data. Secrets and backend-only values are withheld by the export's security floor regardless of this grant. */\n systemAccessPolicy: { exportSubject: ResourceSystemAccessMode.ALLOWED },\n portabilityPolicy: { defaultProvenance: DataPortabilityProvenance.DERIVED },\n\n\n /*\n * NO `retentionPolicy`, so a subject erasure DESTROYS the badge rows (#1569, decided by Paul\n * 2026-09-24).\n *\n * It declared `RETAIN_ONLY` — \"a badge holds nothing to scrub\" — and since #1279 an erasure takes a\n * silent edge's treatment from that declaration, so an erased person's unread counters stayed live and\n * frozen. A counter of someone's unread items has no retention value once that someone is erased, so\n * the USERS → USER_NOTIFICATION_BADGES edge AUTHORS `strategy: DELETE`, and re-adding a retention mode\n * here would be refused as a contradiction. Only the USER_SELF badge is in the subject-erasure\n * population; the organization badge below is tenant-scoped and was never affected.\n *\n * And so no `dataSubjectPolicy` either: the factory pairs the two in both directions, because only a\n * retention-governed resource can be passed to an erasure as its SUBJECT. This row is never the\n * subject of an erasure; it is a child an erasure destroys.\n */\n\n coreOperations: [\n CoreResourceOperation.READ,\n CoreResourceOperation.LIST,\n CoreResourceOperation.CREATE,\n CoreResourceOperation.UPDATE,\n // DELETE is REPOSITORY_ONLY (no HTTP route): badges are reset to 0 during normal\n // use (via UPDATE), never API-deleted — but the composition onParentDelete cascade\n // must physically remove the row when its owning user/org is deleted. Without it\n // the cascade throws ErrorType.CONFIGURATION on any parent that has a badge row.\n CoreResourceOperation.DELETE,\n ],\n operationsConfiguration: {\n [CoreResourceOperation.READ]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.API_CALL,\n isDefault: true,\n // The framework's user-self filter (USER_SELF primary scope) restricts\n // results to the authenticated user's own row.\n roles: [CORE_APP_ROLES.APP_USER],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.LIST]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.API_CALL,\n isDefault: true,\n roles: [CORE_APP_ROLES.APP_USER],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.CREATE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n // System-internal: only the dispatcher / batch services drive badge writes.\n roles: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.UPDATE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n roles: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n\n // Internal-only (REPOSITORY_ONLY, no HTTP route): powers the composition\n // onParentDelete cascade so badge rows are physically removed when the owning\n // user/org is deleted (badges are reset to 0 in normal use, never API-deleted).\n // Without a DELETE op the cascade (deleteChildrenImmediate) throws\n // ErrorType.CONFIGURATION on any parent that still has a badge row.\n // Super-admin/HIGH: badge writes are system-internal (dispatcher/batch only).\n [CoreResourceOperation.DELETE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n roles: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n riskLevel: ResourceOperationRiskLevel.HIGH,\n },\n ],\n },\n },\n});\n\n// ─── ORGANIZATION NOTIFICATION BADGES ─────────────────────────────────────────\n\ntype OrganizationNotificationBadgesCoreOperations =\n | CoreResourceOperation.READ\n | CoreResourceOperation.LIST\n | CoreResourceOperation.CREATE\n | CoreResourceOperation.UPDATE\n | CoreResourceOperation.DELETE;\n\nexport const organizationNotificationBadgesResourceConfiguration_InitializationFactory = (\n resourcesRelationships: ResourceRelationship[]\n): ResourceConfiguration<\n undefined,\n OrganizationNotificationBadgesCoreOperations,\n typeof NotificationBadgeOrganizationSchema\n> => createResourceConfiguration_Initialization<\n undefined,\n OrganizationNotificationBadgesCoreOperations,\n typeof NotificationBadgeOrganizationSchema\n>({\n mainSchema: NotificationBadgeOrganizationSchema,\n resourceIdentifier: CoreResourceType.ORGANIZATION_NOTIFICATION_BADGES,\n resourceFieldIdentifier:\n coreResourceShared_FieldIdentifier[CoreResourceType.ORGANIZATION_NOTIFICATION_BADGES],\n resourceRelationships: resourcesRelationships,\n isSystemResource: true,\n coreOperations: [\n CoreResourceOperation.READ,\n CoreResourceOperation.LIST,\n CoreResourceOperation.CREATE,\n CoreResourceOperation.UPDATE,\n // DELETE is REPOSITORY_ONLY (no HTTP route): badges are reset to 0 during normal\n // use (via UPDATE), never API-deleted — but the composition onParentDelete cascade\n // must physically remove the row when its owning user/org is deleted. Without it\n // the cascade throws ErrorType.CONFIGURATION on any parent that has a badge row.\n CoreResourceOperation.DELETE,\n ],\n operationsConfiguration: {\n [CoreResourceOperation.READ]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.API_CALL,\n isDefault: true,\n // Any org member can see aggregate org badges (e.g. unpaid invoices\n // count surfaced in the navbar). Matches the lifecycle-state pattern.\n roles: [CORE_ORG_ROLES.ORG_MEMBER],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.LIST]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.API_CALL,\n isDefault: true,\n roles: [CORE_ORG_ROLES.ORG_MEMBER],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.CREATE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n roles: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.UPDATE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n roles: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n\n // Internal-only (REPOSITORY_ONLY, no HTTP route): powers the composition\n // onParentDelete cascade so badge rows are physically removed when the owning\n // user/org is deleted (badges are reset to 0 in normal use, never API-deleted).\n // Without a DELETE op the cascade (deleteChildrenImmediate) throws\n // ErrorType.CONFIGURATION on any parent that still has a badge row.\n // Super-admin/HIGH: badge writes are system-internal (dispatcher/batch only).\n [CoreResourceOperation.DELETE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n roles: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n riskLevel: ResourceOperationRiskLevel.HIGH,\n },\n ],\n },\n },\n});\n"]}
1
+ {"version":3,"file":"notification-badges.shared.resources-config.schemas.js","sourceRoot":"","sources":["../../../src/notifications/notification-badges.shared.resources-config.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAo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,CAAC,cAAc,CAAC,qBAAqB,CAAC;oBAC7C,SAAS,EAAE,0BAA0B,CAAC,GAAG;iBAC1C;aACF;SACF;QACD,CAAC,qBAAqB,CAAC,MAAM,CAAC,EAAE;YAC9B,QAAQ,EAAE;gBACR;oBACE,WAAW,EAAE,4BAA4B,CAAC,eAAe;oBACzD,SAAS,EAAE,IAAI;oBACf,KAAK,EAAE,CAAC,cAAc,CAAC,qBAAqB,CAAC;oBAC7C,SAAS,EAAE,0BAA0B,CAAC,GAAG;iBAC1C;aACF;SACF;QAED,yEAAyE;QACzE,8EAA8E;QAC9E,gFAAgF;QAChF,mEAAmE;QACnE,oEAAoE;QACpE,8EAA8E;QAC9E,CAAC,qBAAqB,CAAC,MAAM,CAAC,EAAE;YAC9B,QAAQ,EAAE;gBACR;oBACE,WAAW,EAAE,4BAA4B,CAAC,eAAe;oBACzD,SAAS,EAAE,IAAI;oBACf,KAAK,EAAE,CAAC,cAAc,CAAC,qBAAqB,CAAC;oBAC7C,SAAS,EAAE,0BAA0B,CAAC,IAAI;iBAC3C;aACF;SACF;KACF;CACF,CAAC,CAAC","sourcesContent":["/**\n * Notification Badges Shared Resource Configurations\n *\n * Polymorphic dual-scope (USER + ORGANIZATION). Two completely separate factories,\n * each registered against its own `ResourceType` member and backed by its own\n * MongoDB collection. We follow the lifecycle-state / guidance-state pattern\n * (two side-by-side factories) rather than `createPolymorphicResourceConfigurations`\n * because the variants have:\n * - Different schemas (`NotificationBadgeUserSelfSchema` vs\n * `NotificationBadgeOrganizationSchema`),\n * - Different role surfaces (`APP_USER` reads on the USER variant vs\n * `ORG_MEMBER` reads on the ORG variant), and\n * - Different parent-scope anchors (USERS vs ORGANIZATIONS).\n *\n * Both variants:\n * - Operations: READ / LIST / CREATE / UPDATE (no DELETE — badges are reset to 0).\n * - `isSystemResource: true` — internal infrastructure, accessed via\n * `NotificationBadgeBackendService` (the public API is `increment`,\n * `decrement`, `set`, `reset` — never raw repository calls from app code).\n *\n * Role + variant assignments per D-2 of `.cursor/plans/notification-badges-polymorphism-refactor.md`\n * (mirrors the lifecycle-state precedent: READ/LIST exposed as `API_CALL` so\n * the user can read their own badges through the framework's HTTP surface;\n * CREATE/UPDATE stay `REPOSITORY_ONLY` because badge writes are exclusively\n * driven by `NotificationBadgeBackendService` from internal dispatchers):\n * - USER variant:\n * READ / LIST → `[CORE_APP_ROLES.APP_USER]` via `API_CALL`\n * CREATE/UPDATE → `[CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN]` via `REPOSITORY_ONLY`\n * - ORG variant:\n * READ / LIST → `[CORE_ORG_ROLES.ORG_MEMBER]` via `API_CALL`\n * (any org member can see aggregate org badges; matches\n * the lifecycle-state pattern's symmetric ORG_MEMBER read)\n * CREATE/UPDATE → `[CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN]` via `REPOSITORY_ONLY`\n *\n * @see notification-badges.schemas.ts — discriminated union at the data layer\n * @see .cursor/plans/notification-badges-polymorphism-refactor.md\n */\n\nimport {\n NotificationBadgeUserSelfSchema,\n NotificationBadgeOrganizationSchema,\n} from './notification-badges.schemas';\nimport { createResourceConfiguration_Initialization } from '../resources/resources-config.shared.factory';\nimport {\n CoreResourceOperation,\n CoreResourceType,\n coreResourceShared_FieldIdentifier,\n} from '../resources/resources.shared.core.definitions';\nimport {\n ResourceOperationRiskLevel,\n ResourceOperationVariantType,\n ResourceRelationship,\n} from '../resources/resources.shared.schemas';\nimport { ResourceConfiguration } from '../resources/resources-config.shared.schemas';\nimport { CORE_APP_ROLES, CORE_ORG_ROLES } from '../security/authorizations/roles.shared.schemas';\nimport { ResourceSystemAccessMode } from '../resources/resources-config.shared.schemas';\nimport { DataPortabilityProvenance } from '../compliance/privacy/subject-export.shared.schemas';\n\n// ─── USER NOTIFICATION BADGES ─────────────────────────────────────────────────\n\ntype UserNotificationBadgesCoreOperations =\n | CoreResourceOperation.READ\n | CoreResourceOperation.LIST\n | CoreResourceOperation.CREATE\n | CoreResourceOperation.UPDATE\n | CoreResourceOperation.DELETE;\n\nexport const userNotificationBadgesResourceConfiguration_InitializationFactory = (\n resourcesRelationships: ResourceRelationship[]\n): ResourceConfiguration<\n undefined,\n UserNotificationBadgesCoreOperations,\n typeof NotificationBadgeUserSelfSchema\n> => createResourceConfiguration_Initialization<\n undefined,\n UserNotificationBadgesCoreOperations,\n typeof NotificationBadgeUserSelfSchema\n>({\n mainSchema: NotificationBadgeUserSelfSchema,\n resourceIdentifier: CoreResourceType.USER_NOTIFICATION_BADGES,\n resourceFieldIdentifier:\n coreResourceShared_FieldIdentifier[CoreResourceType.USER_NOTIFICATION_BADGES],\n resourceRelationships: resourcesRelationships,\n isSystemResource: true,\n /** Subject-export disclosure. The subject's own data. Secrets and backend-only values are withheld by the export's security floor regardless of this grant. */\n systemAccessPolicy: { exportSubject: ResourceSystemAccessMode.ALLOWED },\n portabilityPolicy: { defaultProvenance: DataPortabilityProvenance.DERIVED },\n\n\n /*\n * NO `retentionPolicy`, so a subject erasure DESTROYS the badge rows (#1569, decided by Paul\n * 2026-09-24).\n *\n * It declared `RETAIN_ONLY` — \"a badge holds nothing to scrub\" — and since #1279 an erasure takes a\n * silent edge's treatment from that declaration, so an erased person's unread counters stayed live and\n * frozen. A counter of someone's unread items has no retention value once that someone is erased, so\n * the USERS → USER_NOTIFICATION_BADGES edge AUTHORS `strategy: DELETE`, and re-adding a retention mode\n * here would be refused as a contradiction. Only the USER_SELF badge is in the subject-erasure\n * population; the organization badge below is tenant-scoped and was never affected.\n *\n * And so no `dataSubjectPolicy` either: the factory pairs the two in both directions, because only a\n * retention-governed resource can be passed to an erasure as its SUBJECT. This row is never the\n * subject of an erasure; it is a child an erasure destroys.\n */\n\n coreOperations: [\n CoreResourceOperation.READ,\n CoreResourceOperation.LIST,\n CoreResourceOperation.CREATE,\n CoreResourceOperation.UPDATE,\n // DELETE is REPOSITORY_ONLY (no HTTP route): badges are reset to 0 during normal\n // use (via UPDATE), never API-deleted — but the composition onParentDelete cascade\n // must physically remove the row when its owning user/org is deleted. Without it\n // the cascade throws ErrorType.CONFIGURATION on any parent that has a badge row.\n CoreResourceOperation.DELETE,\n ],\n operationsConfiguration: {\n [CoreResourceOperation.READ]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.API_CALL,\n isDefault: true,\n // The framework's user-self filter (USER_SELF primary scope) restricts\n // results to the authenticated user's own row.\n roles: [CORE_APP_ROLES.APP_USER],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.LIST]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.API_CALL,\n isDefault: true,\n roles: [CORE_APP_ROLES.APP_USER],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.CREATE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n // System-internal: only the dispatcher / batch services drive badge writes.\n roles: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.UPDATE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n roles: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n\n // Internal-only (REPOSITORY_ONLY, no HTTP route): powers the composition\n // onParentDelete cascade so badge rows are physically removed when the owning\n // user/org is deleted (badges are reset to 0 in normal use, never API-deleted).\n // Without a DELETE op the cascade (deleteChildrenImmediate) throws\n // ErrorType.CONFIGURATION on any parent that still has a badge row.\n // Super-admin/HIGH: badge writes are system-internal (dispatcher/batch only).\n [CoreResourceOperation.DELETE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n roles: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n riskLevel: ResourceOperationRiskLevel.HIGH,\n },\n ],\n },\n },\n});\n\n// ─── ORGANIZATION NOTIFICATION BADGES ─────────────────────────────────────────\n\ntype OrganizationNotificationBadgesCoreOperations =\n | CoreResourceOperation.READ\n | CoreResourceOperation.LIST\n | CoreResourceOperation.CREATE\n | CoreResourceOperation.UPDATE\n | CoreResourceOperation.DELETE;\n\nexport const organizationNotificationBadgesResourceConfiguration_InitializationFactory = (\n resourcesRelationships: ResourceRelationship[]\n): ResourceConfiguration<\n undefined,\n OrganizationNotificationBadgesCoreOperations,\n typeof NotificationBadgeOrganizationSchema\n> => createResourceConfiguration_Initialization<\n undefined,\n OrganizationNotificationBadgesCoreOperations,\n typeof NotificationBadgeOrganizationSchema\n>({\n mainSchema: NotificationBadgeOrganizationSchema,\n resourceIdentifier: CoreResourceType.ORGANIZATION_NOTIFICATION_BADGES,\n resourceFieldIdentifier:\n coreResourceShared_FieldIdentifier[CoreResourceType.ORGANIZATION_NOTIFICATION_BADGES],\n resourceRelationships: resourcesRelationships,\n isSystemResource: true,\n coreOperations: [\n CoreResourceOperation.READ,\n CoreResourceOperation.LIST,\n CoreResourceOperation.CREATE,\n CoreResourceOperation.UPDATE,\n // DELETE is REPOSITORY_ONLY (no HTTP route): badges are reset to 0 during normal\n // use (via UPDATE), never API-deleted — but the composition onParentDelete cascade\n // must physically remove the row when its owning user/org is deleted. Without it\n // the cascade throws ErrorType.CONFIGURATION on any parent that has a badge row.\n CoreResourceOperation.DELETE,\n ],\n operationsConfiguration: {\n [CoreResourceOperation.READ]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.API_CALL,\n isDefault: true,\n // Any org member can see aggregate org badges (e.g. unpaid invoices\n // count surfaced in the navbar). Matches the lifecycle-state pattern.\n roles: [CORE_ORG_ROLES.ORG_MEMBER],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.LIST]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.API_CALL,\n isDefault: true,\n roles: [CORE_ORG_ROLES.ORG_MEMBER],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.CREATE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n roles: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n [CoreResourceOperation.UPDATE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n roles: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n riskLevel: ResourceOperationRiskLevel.LOW,\n },\n ],\n },\n\n // Internal-only (REPOSITORY_ONLY, no HTTP route): powers the composition\n // onParentDelete cascade so badge rows are physically removed when the owning\n // user/org is deleted (badges are reset to 0 in normal use, never API-deleted).\n // Without a DELETE op the cascade (deleteChildrenImmediate) throws\n // ErrorType.CONFIGURATION on any parent that still has a badge row.\n // Super-admin/HIGH: badge writes are system-internal (dispatcher/batch only).\n [CoreResourceOperation.DELETE]: {\n variants: [\n {\n variantType: ResourceOperationVariantType.REPOSITORY_ONLY,\n isDefault: true,\n roles: [CORE_APP_ROLES.APP_ADMIN_SUPER_ADMIN],\n riskLevel: ResourceOperationRiskLevel.HIGH,\n },\n ],\n },\n },\n});\n"]}
@@ -216,9 +216,11 @@ export type FrontendDisplayHints = z.infer<typeof FrontendDisplayHintsSchema>;
216
216
  * dropped, and were removed. The framework's SMS transport serves authentication's one-time codes, not
217
217
  * resource notifications.
218
218
  *
219
- * For an EMAIL, create the template directory the reference names. The startup validator resolves
220
- * every declared reference through the configured locale chain before the application takes traffic,
221
- * and prints the exact directory to create when one is missing.
219
+ * For an EMAIL, create the template the derived reference names: one per operation variant that declares a
220
+ * `variantKey`, since the reference carries it. The startup validator resolves every declared reference through
221
+ * the configured locale chain before the application takes traffic and names the folder to create when one is
222
+ * missing. It REFUSES to start only for an operation with `tokenGeneration` (the email carries the token its flow
223
+ * needs); for any other operation it WARNS and starts, and that email is silently never sent.
222
224
  *
223
225
  * ## The recipient's preferences are honoured, and three things override them
224
226
  *
@@ -1 +1 @@
1
- {"version":3,"file":"notifications.shared.schemas.d.ts","sourceRoot":"","sources":["../../../../src/notifications/notifications.shared.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,oBAAoB,EAAE,MAAM,uCAAuC,CAAC;AAG7E;;;;;;;;;GASG;AACH,oBAAY,2BAA2B;IACrC,KAAK,UAAU;IACf,SAAS,cAAc;IACvB,iBAAiB,sBAAsB;CACxC;AAED,oBAAY,qBAAqB;IAC/B,IAAI,SAAS;IACb,OAAO,YAAY;IACnB,OAAO,YAAY;IACnB,KAAK,UAAU;CAChB;AAED,yFAAyF;AACzF,eAAO,MAAM,6BAA6B,+CAAsC,CAAC;AAGjF,iHAAiH;AACjH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAoDG;AACH,oBAAY,0BAA0B;IAClC,yBAAyB,8BAA8B;IACvD,mBAAmB,wBAAwB;IAC3C,2BAA2B,gCAAgC;IAC3D,oBAAoB,yBAAyB;IAC7C,mBAAmB,wBAAwB;IAC3C,iBAAiB,sBAAsB;IACvC,wBAAwB,6BAA6B;IACrD,YAAY,iBAAiB;IAC7B,kBAAkB,uBAAuB;IACzC,oBAAoB,yBAAyB;IAC7C,4BAA4B,iCAAiC;IAC7D,2BAA2B,gCAAgC;IAC3D,qBAAqB,0BAA0B;IAC/C,SAAS,cAAc;IACvB,YAAY,iBAAiB;IAC7B,eAAe,oBAAoB;CACtC;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,yDAAyD,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAGjG;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,wBAAgB,oCAAoC,CAAC,MAAM,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAe7F;AACD,+DAA+D;AAE/D;;;;;;;GA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C,MAAM,EAAE,GAAG,CAAC,CAAA;SAAE,CAAC;QAC/E,YAAY,EAAE;YAAE,MAAM,CAAC,EAAE,MAAM,CAAC;YAAC,cAAc,CAAC,EAAE,MAAM,CAAC;YAAC,aAAa,CAAC,EAAE,MAAM,CAAA;SAAE,CAAC;KACpF,KAAK,OAAO,WALJ;QACP,aAAa,EAAE,GAAG,CAAC;QACnB,QAAQ,EAAE,GAAG,CAAC;QACd,aAAa,EAAE;YAAE,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;YAAC,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;SAAE,CAAC;QAC/E,YAAY,EAAE;YAAE,MAAM,CAAC,EAAE,MAAM,CAAC;YAAC,cAAc,CAAC,EAAE,MAAM,CAAC;YAAC,aAAa,CAAC,EAAE,MAAM,CAAA;SAAE,CAAC;KACpF,KAAK,OAAO;;;;;;;;;;;mBA4Kf,CAAC;AACL,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gCAAgC,CAAC,CAAC;AAC1F,oFAAoF;AAEpF;;GAEG;AAIH,oBAAY,oBAAoB;IAC5B,IAAI,SAAS;IACb,OAAO,YAAY;IACnB,KAAK,UAAU;CAChB;AAEH,oBAAY,0BAA0B;IAClC,oBAAoB,yBAAyB;IAC7C,mBAAmB,wBAAwB;CAC9C;AAED;;;;;;GAMG;AACH,eAAO,MAAM,4BAA4B,8CAAqC,CAAC;AAE/E,eAAO,MAAM,+BAA+B;;;;iBAI1C,CAAC;AACH,MAAM,MAAM,yBAAyB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAC"}
1
+ {"version":3,"file":"notifications.shared.schemas.d.ts","sourceRoot":"","sources":["../../../src/notifications/notifications.shared.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,oBAAoB,EAA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aAAa,EAAE,GAAG,CAAC;QACnB,QAAQ,EAAE,GAAG,CAAC;QACd,aAAa,EAAE;YAAE,OAAO,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;YAAC,QAAQ,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;SAAE,CAAC;QAC/E,YAAY,EAAE;YAAE,MAAM,CAAC,EAAE,MAAM,CAAC;YAAC,cAAc,CAAC,EAAE,MAAM,CAAC;YAAC,aAAa,CAAC,EAAE,MAAM,CAAA;SAAE,CAAC;KACpF,KAAK,OAAO;;;;;;;;;;;mBA4Kf,CAAC;AACL,MAAM,MAAM,0BAA0B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gCAAgC,CAAC,CAAC;AAC1F,oFAAoF;AAEpF;;GAEG;AAIH,oBAAY,oBAAoB;IAC5B,IAAI,SAAS;IACb,OAAO,YAAY;IACnB,KAAK,UAAU;CAChB;AAEH,oBAAY,0BAA0B;IAClC,oBAAoB,yBAAyB;IAC7C,mBAAmB,wBAAwB;CAC9C;AAED;;;;;;GAMG;AACH,eAAO,MAAM,4BAA4B,8CAAqC,CAAC;AAE/E,eAAO,MAAM,+BAA+B;;;;iBAI1C,CAAC;AACH,MAAM,MAAM,yBAAyB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,+BAA+B,CAAC,CAAC"}
@@ -241,9 +241,11 @@ export const FrontendDisplayHintsSchema = z.object({
241
241
  * dropped, and were removed. The framework's SMS transport serves authentication's one-time codes, not
242
242
  * resource notifications.
243
243
  *
244
- * For an EMAIL, create the template directory the reference names. The startup validator resolves
245
- * every declared reference through the configured locale chain before the application takes traffic,
246
- * and prints the exact directory to create when one is missing.
244
+ * For an EMAIL, create the template the derived reference names: one per operation variant that declares a
245
+ * `variantKey`, since the reference carries it. The startup validator resolves every declared reference through
246
+ * the configured locale chain before the application takes traffic and names the folder to create when one is
247
+ * missing. It REFUSES to start only for an operation with `tokenGeneration` (the email carries the token its flow
248
+ * needs); for any other operation it WARNS and starts, and that email is silently never sent.
247
249
  *
248
250
  * ## The recipient's preferences are honoured, and three things override them
249
251
  *