@wildo-ai/saas-specifications 1.1.5 → 1.1.6

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 (677) hide show
  1. package/dist/esm/_catalogs/schema-org/_catalog-spec.shared.schemas.d.ts +10 -8
  2. package/dist/esm/_catalogs/schema-org/_catalog-spec.shared.schemas.d.ts.map +1 -1
  3. package/dist/esm/_catalogs/schema-org/_catalog-spec.shared.schemas.js +14 -13
  4. package/dist/esm/_catalogs/schema-org/_catalog-spec.shared.schemas.js.map +1 -1
  5. package/dist/esm/_catalogs/schema-org/aggregate-offer.catalog-spec.d.ts +3 -2
  6. package/dist/esm/_catalogs/schema-org/aggregate-offer.catalog-spec.d.ts.map +1 -1
  7. package/dist/esm/_catalogs/schema-org/aggregate-offer.catalog-spec.js +4 -3
  8. package/dist/esm/_catalogs/schema-org/aggregate-offer.catalog-spec.js.map +1 -1
  9. package/dist/esm/_catalogs/schema-org/index.d.ts +31 -15
  10. package/dist/esm/_catalogs/schema-org/index.d.ts.map +1 -1
  11. package/dist/esm/_catalogs/schema-org/index.js +34 -13
  12. package/dist/esm/_catalogs/schema-org/index.js.map +1 -1
  13. package/dist/esm/_catalogs/schema-org/product.catalog-spec.d.ts +2 -2
  14. package/dist/esm/_catalogs/schema-org/product.catalog-spec.js +4 -4
  15. package/dist/esm/_catalogs/schema-org/product.catalog-spec.js.map +1 -1
  16. package/dist/esm/_catalogs/schema-org/software-application.catalog-spec.d.ts +45 -0
  17. package/dist/esm/_catalogs/schema-org/software-application.catalog-spec.d.ts.map +1 -0
  18. package/dist/esm/_catalogs/schema-org/software-application.catalog-spec.js +58 -0
  19. package/dist/esm/_catalogs/schema-org/software-application.catalog-spec.js.map +1 -0
  20. package/dist/esm/_core/application-specification-family-identity.schemas.d.ts +3 -2
  21. package/dist/esm/_core/application-specification-family-identity.schemas.d.ts.map +1 -1
  22. package/dist/esm/_core/application-specification-family-identity.schemas.js +3 -2
  23. package/dist/esm/_core/application-specification-family-identity.schemas.js.map +1 -1
  24. package/dist/esm/_core/build-plan/build-plan-task-graph-generation.schemas.d.ts +18 -0
  25. package/dist/esm/_core/build-plan/build-plan-task-graph-generation.schemas.d.ts.map +1 -1
  26. package/dist/esm/_core/build-plan/build-plan-task-graph-validation.d.ts +39 -13
  27. package/dist/esm/_core/build-plan/build-plan-task-graph-validation.d.ts.map +1 -1
  28. package/dist/esm/_core/build-plan/build-plan-task-graph-validation.js +43 -13
  29. package/dist/esm/_core/build-plan/build-plan-task-graph-validation.js.map +1 -1
  30. package/dist/esm/_core/build-plan/build-plan-task-graph.schemas.d.ts +90 -2
  31. package/dist/esm/_core/build-plan/build-plan-task-graph.schemas.d.ts.map +1 -1
  32. package/dist/esm/_core/build-plan/build-plan-task-graph.schemas.js +70 -6
  33. package/dist/esm/_core/build-plan/build-plan-task-graph.schemas.js.map +1 -1
  34. package/dist/esm/_core/build-plan/build-plan.family-aspects.d.ts.map +1 -1
  35. package/dist/esm/_core/build-plan/build-plan.family-aspects.js +26 -4
  36. package/dist/esm/_core/build-plan/build-plan.family-aspects.js.map +1 -1
  37. package/dist/esm/_core/business-semantics.specifications.schemas.d.ts +14 -0
  38. package/dist/esm/_core/business-semantics.specifications.schemas.d.ts.map +1 -1
  39. package/dist/esm/_core/business-semantics.specifications.schemas.js.map +1 -1
  40. package/dist/esm/_core/capability-composition/capability-composition-validation.d.ts.map +1 -1
  41. package/dist/esm/_core/capability-composition/capability-composition-validation.js +1 -0
  42. package/dist/esm/_core/capability-composition/capability-composition-validation.js.map +1 -1
  43. package/dist/esm/_core/capability-composition/capability-composition.schemas.d.ts +21 -2
  44. package/dist/esm/_core/capability-composition/capability-composition.schemas.d.ts.map +1 -1
  45. package/dist/esm/_core/capability-composition/capability-composition.schemas.js +20 -1
  46. package/dist/esm/_core/capability-composition/capability-composition.schemas.js.map +1 -1
  47. package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.d.ts +11 -32
  48. package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.d.ts.map +1 -1
  49. package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.js +70 -3
  50. package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.js.map +1 -1
  51. package/dist/esm/_core/compliance-documents/computed-document-facts.schemas.d.ts +142 -17
  52. package/dist/esm/_core/compliance-documents/computed-document-facts.schemas.d.ts.map +1 -1
  53. package/dist/esm/_core/compliance-documents/computed-document-facts.schemas.js +285 -30
  54. package/dist/esm/_core/compliance-documents/computed-document-facts.schemas.js.map +1 -1
  55. package/dist/esm/_core/compliance-documents/processor-register.schemas.d.ts +183 -18
  56. package/dist/esm/_core/compliance-documents/processor-register.schemas.d.ts.map +1 -1
  57. package/dist/esm/_core/compliance-documents/processor-register.schemas.js +165 -18
  58. package/dist/esm/_core/compliance-documents/processor-register.schemas.js.map +1 -1
  59. package/dist/esm/_core/compliance-documents/recipient-disclosures.schemas.d.ts +139 -0
  60. package/dist/esm/_core/compliance-documents/recipient-disclosures.schemas.d.ts.map +1 -0
  61. package/dist/esm/_core/compliance-documents/recipient-disclosures.schemas.js +172 -0
  62. package/dist/esm/_core/compliance-documents/recipient-disclosures.schemas.js.map +1 -0
  63. package/dist/esm/_core/compliance-documents/recipient-population.schemas.d.ts +306 -0
  64. package/dist/esm/_core/compliance-documents/recipient-population.schemas.d.ts.map +1 -0
  65. package/dist/esm/_core/compliance-documents/recipient-population.schemas.js +502 -0
  66. package/dist/esm/_core/compliance-documents/recipient-population.schemas.js.map +1 -0
  67. package/dist/esm/_core/compliance-documents/retention-enforcement-facts.schemas.d.ts +107 -0
  68. package/dist/esm/_core/compliance-documents/retention-enforcement-facts.schemas.d.ts.map +1 -0
  69. package/dist/esm/_core/compliance-documents/retention-enforcement-facts.schemas.js +118 -0
  70. package/dist/esm/_core/compliance-documents/retention-enforcement-facts.schemas.js.map +1 -0
  71. package/dist/esm/_core/compliance-documents/subject-data-recipients.schemas.d.ts +56 -0
  72. package/dist/esm/_core/compliance-documents/subject-data-recipients.schemas.d.ts.map +1 -0
  73. package/dist/esm/_core/compliance-documents/subject-data-recipients.schemas.js +100 -0
  74. package/dist/esm/_core/compliance-documents/subject-data-recipients.schemas.js.map +1 -0
  75. package/dist/esm/_core/composite-view-specification.schemas.js +8 -1
  76. package/dist/esm/_core/composite-view-specification.schemas.js.map +1 -1
  77. package/dist/esm/_core/domain-plan/domain-plan.family-aspects.d.ts +3 -2
  78. package/dist/esm/_core/domain-plan/domain-plan.family-aspects.d.ts.map +1 -1
  79. package/dist/esm/_core/domain-plan/domain-plan.family-aspects.js +3 -2
  80. package/dist/esm/_core/domain-plan/domain-plan.family-aspects.js.map +1 -1
  81. package/dist/esm/_core/experience-plan/experience-plan.schemas.d.ts +16 -3
  82. package/dist/esm/_core/experience-plan/experience-plan.schemas.d.ts.map +1 -1
  83. package/dist/esm/_core/experience-plan/experience-plan.schemas.js +70 -5
  84. package/dist/esm/_core/experience-plan/experience-plan.schemas.js.map +1 -1
  85. package/dist/esm/_core/family-aspects.schemas.d.ts +10 -0
  86. package/dist/esm/_core/family-aspects.schemas.d.ts.map +1 -1
  87. package/dist/esm/_core/family-aspects.schemas.js.map +1 -1
  88. package/dist/esm/_core/feature-drafts/capability-map-output-set-generation.schemas.d.ts +2 -2
  89. package/dist/esm/_core/feature-drafts/capability-map-output-set.schemas.d.ts +1 -0
  90. package/dist/esm/_core/feature-drafts/capability-map-output-set.schemas.d.ts.map +1 -1
  91. package/dist/esm/_core/feature-drafts/feature-specification-drafts.schemas.d.ts +16 -0
  92. package/dist/esm/_core/feature-drafts/feature-specification-drafts.schemas.d.ts.map +1 -1
  93. package/dist/esm/_core/feature-drafts/feature-specification-drafts.schemas.js +8 -0
  94. package/dist/esm/_core/feature-drafts/feature-specification-drafts.schemas.js.map +1 -1
  95. package/dist/esm/_core/index.d.ts +3 -0
  96. package/dist/esm/_core/index.d.ts.map +1 -1
  97. package/dist/esm/_core/index.js +3 -0
  98. package/dist/esm/_core/index.js.map +1 -1
  99. package/dist/esm/_core/integration-plan/integration-plan-generation.schemas.d.ts +5 -0
  100. package/dist/esm/_core/integration-plan/integration-plan-generation.schemas.d.ts.map +1 -1
  101. package/dist/esm/_core/integration-plan/integration-plan-generation.schemas.js +3 -1
  102. package/dist/esm/_core/integration-plan/integration-plan-generation.schemas.js.map +1 -1
  103. package/dist/esm/_core/integration-plan/integration-plan.family-aspects.d.ts.map +1 -1
  104. package/dist/esm/_core/integration-plan/integration-plan.family-aspects.js +12 -2
  105. package/dist/esm/_core/integration-plan/integration-plan.family-aspects.js.map +1 -1
  106. package/dist/esm/_core/integration-plan/integration-plan.schemas.d.ts +30 -2
  107. package/dist/esm/_core/integration-plan/integration-plan.schemas.d.ts.map +1 -1
  108. package/dist/esm/_core/integration-plan/integration-plan.schemas.js +32 -2
  109. package/dist/esm/_core/integration-plan/integration-plan.schemas.js.map +1 -1
  110. package/dist/esm/_core/market/feature-benefit.schemas.js +2 -2
  111. package/dist/esm/_core/market/feature-benefit.schemas.js.map +1 -1
  112. package/dist/esm/_core/market/market-alternative.schemas.js +2 -2
  113. package/dist/esm/_core/market/market-alternative.schemas.js.map +1 -1
  114. package/dist/esm/_core/market/market-buying-journey.schemas.js +2 -2
  115. package/dist/esm/_core/market/market-buying-journey.schemas.js.map +1 -1
  116. package/dist/esm/_core/market/market-category.schemas.js +2 -2
  117. package/dist/esm/_core/market/market-category.schemas.js.map +1 -1
  118. package/dist/esm/_core/market/market-channel.schemas.js +2 -2
  119. package/dist/esm/_core/market/market-channel.schemas.js.map +1 -1
  120. package/dist/esm/_core/market/market-gain.schemas.js +2 -2
  121. package/dist/esm/_core/market/market-gain.schemas.js.map +1 -1
  122. package/dist/esm/_core/market/market-icp.schemas.d.ts.map +1 -1
  123. package/dist/esm/_core/market/market-icp.schemas.js +2 -2
  124. package/dist/esm/_core/market/market-icp.schemas.js.map +1 -1
  125. package/dist/esm/_core/market/market-job.schemas.js +2 -2
  126. package/dist/esm/_core/market/market-job.schemas.js.map +1 -1
  127. package/dist/esm/_core/market/market-message-template.schemas.js +2 -2
  128. package/dist/esm/_core/market/market-message-template.schemas.js.map +1 -1
  129. package/dist/esm/_core/market/market-objection.schemas.js +2 -2
  130. package/dist/esm/_core/market/market-objection.schemas.js.map +1 -1
  131. package/dist/esm/_core/market/market-pain.schemas.js +2 -2
  132. package/dist/esm/_core/market/market-pain.schemas.js.map +1 -1
  133. package/dist/esm/_core/market/market-persona.schemas.d.ts.map +1 -1
  134. package/dist/esm/_core/market/market-persona.schemas.js +2 -2
  135. package/dist/esm/_core/market/market-persona.schemas.js.map +1 -1
  136. package/dist/esm/_core/market/market-positioning.schemas.js +2 -2
  137. package/dist/esm/_core/market/market-positioning.schemas.js.map +1 -1
  138. package/dist/esm/_core/market/market-proof.schemas.js +2 -2
  139. package/dist/esm/_core/market/market-proof.schemas.js.map +1 -1
  140. package/dist/esm/_core/market/market-references.schemas.d.ts +6 -0
  141. package/dist/esm/_core/market/market-references.schemas.d.ts.map +1 -1
  142. package/dist/esm/_core/market/market-references.schemas.js +6 -0
  143. package/dist/esm/_core/market/market-references.schemas.js.map +1 -1
  144. package/dist/esm/_core/market/market-snapshot-generation.schemas.d.ts +4 -4
  145. package/dist/esm/_core/market/market-tone-of-voice.schemas.js +2 -2
  146. package/dist/esm/_core/market/market-tone-of-voice.schemas.js.map +1 -1
  147. package/dist/esm/_core/market/market-trigger.schemas.js +2 -2
  148. package/dist/esm/_core/market/market-trigger.schemas.js.map +1 -1
  149. package/dist/esm/_core/market/market.family-aspects.js +1 -1
  150. package/dist/esm/_core/market/market.family-aspects.js.map +1 -1
  151. package/dist/esm/_core/placement-plan/placement-plan.schemas.d.ts.map +1 -1
  152. package/dist/esm/_core/placement-plan/placement-plan.schemas.js +6 -1
  153. package/dist/esm/_core/placement-plan/placement-plan.schemas.js.map +1 -1
  154. package/dist/esm/_core/requirements/functional-requirement.schemas.d.ts +1 -0
  155. package/dist/esm/_core/requirements/functional-requirement.schemas.d.ts.map +1 -1
  156. package/dist/esm/_core/requirements/functional-requirement.schemas.js +8 -0
  157. package/dist/esm/_core/requirements/functional-requirement.schemas.js.map +1 -1
  158. package/dist/esm/_core/requirements/requirements-snapshot.schemas.d.ts +1 -0
  159. package/dist/esm/_core/requirements/requirements-snapshot.schemas.d.ts.map +1 -1
  160. package/dist/esm/_core/resource-specification.schemas.d.ts +86 -28
  161. package/dist/esm/_core/resource-specification.schemas.d.ts.map +1 -1
  162. package/dist/esm/_core/resource-specification.schemas.js +110 -24
  163. package/dist/esm/_core/resource-specification.schemas.js.map +1 -1
  164. package/dist/esm/_core/utils/retention-clock-field-specs.d.ts +13 -0
  165. package/dist/esm/_core/utils/retention-clock-field-specs.d.ts.map +1 -0
  166. package/dist/esm/_core/utils/retention-clock-field-specs.js +26 -0
  167. package/dist/esm/_core/utils/retention-clock-field-specs.js.map +1 -0
  168. package/dist/esm/_core/website-plan/website-plan.schemas.d.ts +31 -6
  169. package/dist/esm/_core/website-plan/website-plan.schemas.d.ts.map +1 -1
  170. package/dist/esm/_core/website-plan/website-plan.schemas.js +35 -6
  171. package/dist/esm/_core/website-plan/website-plan.schemas.js.map +1 -1
  172. package/dist/esm/application-creation/application-creator-inputs.application-creation.schemas.d.ts +142 -3
  173. package/dist/esm/application-creation/application-creator-inputs.application-creation.schemas.d.ts.map +1 -1
  174. package/dist/esm/application-creation/application-creator-inputs.application-creation.schemas.js +148 -14
  175. package/dist/esm/application-creation/application-creator-inputs.application-creation.schemas.js.map +1 -1
  176. package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.d.ts +70 -10
  177. package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.d.ts.map +1 -1
  178. package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.js +98 -11
  179. package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.js.map +1 -1
  180. package/dist/esm/application-creation/application-line.application-creation.schemas.d.ts +215 -0
  181. package/dist/esm/application-creation/application-line.application-creation.schemas.d.ts.map +1 -0
  182. package/dist/esm/application-creation/application-line.application-creation.schemas.js +253 -0
  183. package/dist/esm/application-creation/application-line.application-creation.schemas.js.map +1 -0
  184. package/dist/esm/application-creation/application-specification-family-decisions.application-creation.schemas.d.ts +39 -0
  185. package/dist/esm/application-creation/application-specification-family-decisions.application-creation.schemas.d.ts.map +1 -0
  186. package/dist/esm/application-creation/application-specification-family-decisions.application-creation.schemas.js +37 -0
  187. package/dist/esm/application-creation/application-specification-family-decisions.application-creation.schemas.js.map +1 -0
  188. package/dist/esm/application-creation/journey.application-creation.schemas.d.ts +5 -49
  189. package/dist/esm/application-creation/journey.application-creation.schemas.d.ts.map +1 -1
  190. package/dist/esm/application-creation/journey.application-creation.schemas.js +25 -60
  191. package/dist/esm/application-creation/journey.application-creation.schemas.js.map +1 -1
  192. package/dist/esm/application-creation/playbook-instance.application-creation.schemas.d.ts +28 -0
  193. package/dist/esm/application-creation/playbook-instance.application-creation.schemas.d.ts.map +1 -0
  194. package/dist/esm/application-creation/playbook-instance.application-creation.schemas.js +32 -0
  195. package/dist/esm/application-creation/playbook-instance.application-creation.schemas.js.map +1 -0
  196. package/dist/esm/application-creation/playbooks.application-creation.schemas.d.ts +26 -6
  197. package/dist/esm/application-creation/playbooks.application-creation.schemas.d.ts.map +1 -1
  198. package/dist/esm/application-creation/playbooks.application-creation.schemas.js +28 -1
  199. package/dist/esm/application-creation/playbooks.application-creation.schemas.js.map +1 -1
  200. package/dist/esm/application-creation.exports.d.ts +7 -0
  201. package/dist/esm/application-creation.exports.d.ts.map +1 -1
  202. package/dist/esm/application-creation.exports.js +7 -0
  203. package/dist/esm/application-creation.exports.js.map +1 -1
  204. package/dist/esm/assurance/__tests__/authority-evaluation-instant.fixture.d.ts +1 -1
  205. package/dist/esm/assurance/__tests__/authority-evaluation-instant.fixture.js +1 -1
  206. package/dist/esm/assurance/__tests__/authority-evaluation-instant.fixture.js.map +1 -1
  207. package/dist/esm/assurance/assurance-authority-basis.definitions.d.ts +24 -1
  208. package/dist/esm/assurance/assurance-authority-basis.definitions.d.ts.map +1 -1
  209. package/dist/esm/assurance/assurance-authority-basis.definitions.js +75 -5
  210. package/dist/esm/assurance/assurance-authority-basis.definitions.js.map +1 -1
  211. package/dist/esm/assurance/assurance-authority-basis.schemas.d.ts +6 -0
  212. package/dist/esm/assurance/assurance-authority-basis.schemas.d.ts.map +1 -1
  213. package/dist/esm/assurance/assurance-document-blueprint-selection.d.ts +11 -0
  214. package/dist/esm/assurance/assurance-document-blueprint-selection.d.ts.map +1 -1
  215. package/dist/esm/assurance/assurance-document-blueprint-selection.js +22 -3
  216. package/dist/esm/assurance/assurance-document-blueprint-selection.js.map +1 -1
  217. package/dist/esm/assurance/assurance-document-system.definitions.d.ts.map +1 -1
  218. package/dist/esm/assurance/assurance-document-system.definitions.js +39 -6
  219. package/dist/esm/assurance/assurance-document-system.definitions.js.map +1 -1
  220. package/dist/esm/assurance/assurance-document-system.schemas.d.ts +11 -0
  221. package/dist/esm/assurance/assurance-document-system.schemas.d.ts.map +1 -1
  222. package/dist/esm/assurance/assurance-document-system.schemas.js +19 -0
  223. package/dist/esm/assurance/assurance-document-system.schemas.js.map +1 -1
  224. package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.d.ts.map +1 -1
  225. package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.js +295 -31
  226. package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.js.map +1 -1
  227. package/dist/esm/assurance/assurance-foundation.schemas.d.ts +7 -0
  228. package/dist/esm/assurance/assurance-foundation.schemas.d.ts.map +1 -1
  229. package/dist/esm/assurance/assurance-foundation.schemas.js +7 -0
  230. package/dist/esm/assurance/assurance-foundation.schemas.js.map +1 -1
  231. package/dist/esm/assurance/assurance-objective-catalog.definitions.d.ts.map +1 -1
  232. package/dist/esm/assurance/assurance-objective-catalog.definitions.js +17 -0
  233. package/dist/esm/assurance/assurance-objective-catalog.definitions.js.map +1 -1
  234. package/dist/esm/assurance/assurance-program-generation.schemas.d.ts +5 -1
  235. package/dist/esm/assurance/assurance-program-generation.schemas.d.ts.map +1 -1
  236. package/dist/esm/assurance/assurance-program-generation.schemas.js +6 -3
  237. package/dist/esm/assurance/assurance-program-generation.schemas.js.map +1 -1
  238. package/dist/esm/assurance/assurance-program.family-aspects.js +1 -1
  239. package/dist/esm/assurance/assurance-program.family-aspects.js.map +1 -1
  240. package/dist/esm/assurance/assurance-program.schemas.d.ts +232 -3
  241. package/dist/esm/assurance/assurance-program.schemas.d.ts.map +1 -1
  242. package/dist/esm/assurance/assurance-program.schemas.js +107 -14
  243. package/dist/esm/assurance/assurance-program.schemas.js.map +1 -1
  244. package/dist/esm/assurance/assurance-source-registry.definitions.d.ts.map +1 -1
  245. package/dist/esm/assurance/assurance-source-registry.definitions.js +77 -1
  246. package/dist/esm/assurance/assurance-source-registry.definitions.js.map +1 -1
  247. package/dist/esm/assurance/assurance-verification-requirement-bodies.definitions.d.ts.map +1 -1
  248. package/dist/esm/assurance/assurance-verification-requirement-bodies.definitions.js +23 -1
  249. package/dist/esm/assurance/assurance-verification-requirement-bodies.definitions.js.map +1 -1
  250. package/dist/esm/assurance/governed-document-release.d.ts +7 -0
  251. package/dist/esm/assurance/governed-document-release.d.ts.map +1 -1
  252. package/dist/esm/assurance/governed-document-release.js +11 -2
  253. package/dist/esm/assurance/governed-document-release.js.map +1 -1
  254. package/dist/esm/companion-exports.d.ts +6 -5
  255. package/dist/esm/companion-exports.d.ts.map +1 -1
  256. package/dist/esm/companion-exports.js.map +1 -1
  257. package/dist/esm/engine/applications/resources/application-api-keys.resource.specification.d.ts +1 -0
  258. package/dist/esm/engine/applications/resources/application-api-keys.resource.specification.d.ts.map +1 -1
  259. package/dist/esm/engine/applications/resources/application-api-keys.resource.specification.js +35 -33
  260. package/dist/esm/engine/applications/resources/application-api-keys.resource.specification.js.map +1 -1
  261. package/dist/esm/engine/applications/resources/application-metadata.resource.specification.d.ts.map +1 -1
  262. package/dist/esm/engine/applications/resources/application-metadata.resource.specification.js +6 -2
  263. package/dist/esm/engine/applications/resources/application-metadata.resource.specification.js.map +1 -1
  264. package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.d.ts.map +1 -1
  265. package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.js +13 -12
  266. package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.js.map +1 -1
  267. package/dist/esm/engine/applications/resources/application-versions.resource.specification.d.ts.map +1 -1
  268. package/dist/esm/engine/applications/resources/application-versions.resource.specification.js +26 -2
  269. package/dist/esm/engine/applications/resources/application-versions.resource.specification.js.map +1 -1
  270. package/dist/esm/engine/applications/resources/applications.resource.specification.d.ts.map +1 -1
  271. package/dist/esm/engine/applications/resources/applications.resource.specification.js +4 -4
  272. package/dist/esm/engine/applications/resources/applications.resource.specification.js.map +1 -1
  273. package/dist/esm/engine/auth/resources/application-access-grants.resource.specification.d.ts.map +1 -1
  274. package/dist/esm/engine/auth/resources/application-access-grants.resource.specification.js +11 -9
  275. package/dist/esm/engine/auth/resources/application-access-grants.resource.specification.js.map +1 -1
  276. package/dist/esm/engine/auth/resources/oauth-consent-grants.resource.specification.js +2 -2
  277. package/dist/esm/engine/auth/resources/oauth-consent-grants.resource.specification.js.map +1 -1
  278. package/dist/esm/engine/auth/resources/organization-api-keys.resource.specification.d.ts +1 -0
  279. package/dist/esm/engine/auth/resources/organization-api-keys.resource.specification.d.ts.map +1 -1
  280. package/dist/esm/engine/auth/resources/organization-api-keys.resource.specification.js +45 -32
  281. package/dist/esm/engine/auth/resources/organization-api-keys.resource.specification.js.map +1 -1
  282. package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.d.ts +1 -23
  283. package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.d.ts.map +1 -1
  284. package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.js +185 -31
  285. package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.js.map +1 -1
  286. package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.d.ts +2 -1
  287. package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.d.ts.map +1 -1
  288. package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.js +29 -7
  289. package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.js.map +1 -1
  290. package/dist/esm/engine/auth/resources/platform-access-grants.resource.specification.d.ts.map +1 -1
  291. package/dist/esm/engine/auth/resources/platform-access-grants.resource.specification.js +7 -1
  292. package/dist/esm/engine/auth/resources/platform-access-grants.resource.specification.js.map +1 -1
  293. package/dist/esm/engine/auth/resources/scim-provisioning-config.resource.specification.d.ts.map +1 -1
  294. package/dist/esm/engine/auth/resources/scim-provisioning-config.resource.specification.js +9 -6
  295. package/dist/esm/engine/auth/resources/scim-provisioning-config.resource.specification.js.map +1 -1
  296. package/dist/esm/engine/auth/resources/scim-tokens.resource.specification.d.ts +1 -0
  297. package/dist/esm/engine/auth/resources/scim-tokens.resource.specification.d.ts.map +1 -1
  298. package/dist/esm/engine/auth/resources/scim-tokens.resource.specification.js +11 -7
  299. package/dist/esm/engine/auth/resources/scim-tokens.resource.specification.js.map +1 -1
  300. package/dist/esm/engine/auth/resources/siem-delivery-dlq.resource.specification.d.ts.map +1 -1
  301. package/dist/esm/engine/auth/resources/siem-delivery-dlq.resource.specification.js +18 -16
  302. package/dist/esm/engine/auth/resources/siem-delivery-dlq.resource.specification.js.map +1 -1
  303. package/dist/esm/engine/auth/resources/siem-export-config.resource.specification.d.ts.map +1 -1
  304. package/dist/esm/engine/auth/resources/siem-export-config.resource.specification.js +9 -11
  305. package/dist/esm/engine/auth/resources/siem-export-config.resource.specification.js.map +1 -1
  306. package/dist/esm/engine/auth/resources/sso-config.resource.specification.d.ts.map +1 -1
  307. package/dist/esm/engine/auth/resources/sso-config.resource.specification.js +238 -219
  308. package/dist/esm/engine/auth/resources/sso-config.resource.specification.js.map +1 -1
  309. package/dist/esm/engine/auth/resources/sso-connections.resource.specification.d.ts +0 -24
  310. package/dist/esm/engine/auth/resources/sso-connections.resource.specification.d.ts.map +1 -1
  311. package/dist/esm/engine/auth/resources/sso-connections.resource.specification.js +76 -16
  312. package/dist/esm/engine/auth/resources/sso-connections.resource.specification.js.map +1 -1
  313. package/dist/esm/engine/auth/resources/user-provider-credentials.resource.specification.d.ts +2 -1
  314. package/dist/esm/engine/auth/resources/user-provider-credentials.resource.specification.d.ts.map +1 -1
  315. package/dist/esm/engine/auth/resources/user-provider-credentials.resource.specification.js +28 -6
  316. package/dist/esm/engine/auth/resources/user-provider-credentials.resource.specification.js.map +1 -1
  317. package/dist/esm/engine/billing/resources/billing-accounts.resource.specification.d.ts.map +1 -1
  318. package/dist/esm/engine/billing/resources/billing-accounts.resource.specification.js +29 -11
  319. package/dist/esm/engine/billing/resources/billing-accounts.resource.specification.js.map +1 -1
  320. package/dist/esm/engine/billing/resources/billing-provider-event-settlements.resource.specification.js +1 -1
  321. package/dist/esm/engine/billing/resources/billing-provider-event-settlements.resource.specification.js.map +1 -1
  322. package/dist/esm/engine/billing/resources/credit-pools.resource.specification.d.ts +2 -0
  323. package/dist/esm/engine/billing/resources/credit-pools.resource.specification.d.ts.map +1 -1
  324. package/dist/esm/engine/billing/resources/credit-pools.resource.specification.js +13 -12
  325. package/dist/esm/engine/billing/resources/credit-pools.resource.specification.js.map +1 -1
  326. package/dist/esm/engine/billing/resources/invoice-refs.resource.specification.js +5 -5
  327. package/dist/esm/engine/billing/resources/invoice-refs.resource.specification.js.map +1 -1
  328. package/dist/esm/engine/billing/resources/prices.resource.specification.d.ts.map +1 -1
  329. package/dist/esm/engine/billing/resources/prices.resource.specification.js +12 -9
  330. package/dist/esm/engine/billing/resources/prices.resource.specification.js.map +1 -1
  331. package/dist/esm/engine/billing/resources/products.resource.specification.d.ts +7 -4
  332. package/dist/esm/engine/billing/resources/products.resource.specification.d.ts.map +1 -1
  333. package/dist/esm/engine/billing/resources/products.resource.specification.js +36 -16
  334. package/dist/esm/engine/billing/resources/products.resource.specification.js.map +1 -1
  335. package/dist/esm/engine/billing/resources/promotions.resource.specification.d.ts.map +1 -1
  336. package/dist/esm/engine/billing/resources/promotions.resource.specification.js +13 -10
  337. package/dist/esm/engine/billing/resources/promotions.resource.specification.js.map +1 -1
  338. package/dist/esm/engine/billing/resources/referrals.resource.specification.d.ts +13 -8
  339. package/dist/esm/engine/billing/resources/referrals.resource.specification.d.ts.map +1 -1
  340. package/dist/esm/engine/billing/resources/referrals.resource.specification.js +54 -20
  341. package/dist/esm/engine/billing/resources/referrals.resource.specification.js.map +1 -1
  342. package/dist/esm/engine/billing/resources/subscriptions.resource.specification.d.ts +30 -4
  343. package/dist/esm/engine/billing/resources/subscriptions.resource.specification.d.ts.map +1 -1
  344. package/dist/esm/engine/billing/resources/subscriptions.resource.specification.js +85 -25
  345. package/dist/esm/engine/billing/resources/subscriptions.resource.specification.js.map +1 -1
  346. package/dist/esm/engine/billing/resources/usage-records.resource.specification.js +2 -2
  347. package/dist/esm/engine/billing/resources/usage-records.resource.specification.js.map +1 -1
  348. package/dist/esm/engine/compliance/resources/application-audit-logs.resource.specification.d.ts +15 -2
  349. package/dist/esm/engine/compliance/resources/application-audit-logs.resource.specification.d.ts.map +1 -1
  350. package/dist/esm/engine/compliance/resources/application-audit-logs.resource.specification.js +45 -10
  351. package/dist/esm/engine/compliance/resources/application-audit-logs.resource.specification.js.map +1 -1
  352. package/dist/esm/engine/compliance/resources/audit-logs.resource.specification.d.ts +15 -2
  353. package/dist/esm/engine/compliance/resources/audit-logs.resource.specification.d.ts.map +1 -1
  354. package/dist/esm/engine/compliance/resources/audit-logs.resource.specification.js +52 -12
  355. package/dist/esm/engine/compliance/resources/audit-logs.resource.specification.js.map +1 -1
  356. package/dist/esm/engine/compliance/resources/index.d.ts +1 -0
  357. package/dist/esm/engine/compliance/resources/index.d.ts.map +1 -1
  358. package/dist/esm/engine/compliance/resources/index.js +1 -0
  359. package/dist/esm/engine/compliance/resources/index.js.map +1 -1
  360. package/dist/esm/engine/compliance/resources/legal-holds.resource.specification.d.ts +39 -0
  361. package/dist/esm/engine/compliance/resources/legal-holds.resource.specification.d.ts.map +1 -0
  362. package/dist/esm/engine/compliance/resources/legal-holds.resource.specification.js +325 -0
  363. package/dist/esm/engine/compliance/resources/legal-holds.resource.specification.js.map +1 -0
  364. package/dist/esm/engine/compliance/resources/retention-enforcement-records.resource.specification.d.ts +23 -0
  365. package/dist/esm/engine/compliance/resources/retention-enforcement-records.resource.specification.d.ts.map +1 -0
  366. package/dist/esm/engine/compliance/resources/retention-enforcement-records.resource.specification.js +197 -0
  367. package/dist/esm/engine/compliance/resources/retention-enforcement-records.resource.specification.js.map +1 -0
  368. package/dist/esm/engine/engine-resource-specifications.registry.d.ts.map +1 -1
  369. package/dist/esm/engine/engine-resource-specifications.registry.js +59 -0
  370. package/dist/esm/engine/engine-resource-specifications.registry.js.map +1 -1
  371. package/dist/esm/engine/errors/error-messages.specification.d.ts.map +1 -1
  372. package/dist/esm/engine/errors/error-messages.specification.js +69 -0
  373. package/dist/esm/engine/errors/error-messages.specification.js.map +1 -1
  374. package/dist/esm/engine/features/resources/application-features.resource.specification.d.ts +5 -5
  375. package/dist/esm/engine/features/resources/application-features.resource.specification.d.ts.map +1 -1
  376. package/dist/esm/engine/features/resources/application-features.resource.specification.js +9 -10
  377. package/dist/esm/engine/features/resources/application-features.resource.specification.js.map +1 -1
  378. package/dist/esm/engine/features/resources/organization-features.resource.specification.d.ts +5 -5
  379. package/dist/esm/engine/features/resources/organization-features.resource.specification.js +11 -11
  380. package/dist/esm/engine/features/resources/organization-features.resource.specification.js.map +1 -1
  381. package/dist/esm/engine/features/resources/user-features.resource.specification.d.ts +5 -5
  382. package/dist/esm/engine/features/resources/user-features.resource.specification.js +3 -3
  383. package/dist/esm/engine/features/resources/user-features.resource.specification.js.map +1 -1
  384. package/dist/esm/engine/files/resources/files.resource.specification.d.ts.map +1 -1
  385. package/dist/esm/engine/files/resources/files.resource.specification.js +7 -8
  386. package/dist/esm/engine/files/resources/files.resource.specification.js.map +1 -1
  387. package/dist/esm/engine/flows-actors/resources/a2a-push-delivery-log.resource.specification.d.ts.map +1 -1
  388. package/dist/esm/engine/flows-actors/resources/a2a-push-delivery-log.resource.specification.js +16 -4
  389. package/dist/esm/engine/flows-actors/resources/a2a-push-delivery-log.resource.specification.js.map +1 -1
  390. package/dist/esm/engine/flows-actors/resources/a2a-token-budget-state.resource.specification.js +1 -1
  391. package/dist/esm/engine/flows-actors/resources/a2a-token-budget-state.resource.specification.js.map +1 -1
  392. package/dist/esm/engine/flows-actors/resources/agent-work-decisions.resource.specification.d.ts +11 -0
  393. package/dist/esm/engine/flows-actors/resources/agent-work-decisions.resource.specification.d.ts.map +1 -0
  394. package/dist/esm/engine/flows-actors/resources/agent-work-decisions.resource.specification.js +382 -0
  395. package/dist/esm/engine/flows-actors/resources/agent-work-decisions.resource.specification.js.map +1 -0
  396. package/dist/esm/engine/flows-actors/resources/flow-actor-executions.resource.specification.d.ts +139 -1
  397. package/dist/esm/engine/flows-actors/resources/flow-actor-executions.resource.specification.d.ts.map +1 -1
  398. package/dist/esm/engine/flows-actors/resources/flow-actor-executions.resource.specification.js +150 -4
  399. package/dist/esm/engine/flows-actors/resources/flow-actor-executions.resource.specification.js.map +1 -1
  400. package/dist/esm/engine/flows-actors/resources/flow-actor-tasks.resource.specification.d.ts.map +1 -1
  401. package/dist/esm/engine/flows-actors/resources/flow-actor-tasks.resource.specification.js +9 -1
  402. package/dist/esm/engine/flows-actors/resources/flow-actor-tasks.resource.specification.js.map +1 -1
  403. package/dist/esm/engine/flows-actors/resources/model-call-attributions.resource.specification.d.ts +3 -0
  404. package/dist/esm/engine/flows-actors/resources/model-call-attributions.resource.specification.d.ts.map +1 -0
  405. package/dist/esm/engine/flows-actors/resources/model-call-attributions.resource.specification.js +162 -0
  406. package/dist/esm/engine/flows-actors/resources/model-call-attributions.resource.specification.js.map +1 -0
  407. package/dist/esm/engine/flows-actors/resources/model-cost-period-aggregates.resource.specification.d.ts +3 -0
  408. package/dist/esm/engine/flows-actors/resources/model-cost-period-aggregates.resource.specification.d.ts.map +1 -0
  409. package/dist/esm/engine/flows-actors/resources/model-cost-period-aggregates.resource.specification.js +158 -0
  410. package/dist/esm/engine/flows-actors/resources/model-cost-period-aggregates.resource.specification.js.map +1 -0
  411. package/dist/esm/engine/flows-actors/resources/provider-call-records.resource.specification.d.ts +2 -1
  412. package/dist/esm/engine/flows-actors/resources/provider-call-records.resource.specification.d.ts.map +1 -1
  413. package/dist/esm/engine/flows-actors/resources/provider-call-records.resource.specification.js +16 -9
  414. package/dist/esm/engine/flows-actors/resources/provider-call-records.resource.specification.js.map +1 -1
  415. package/dist/esm/engine/frontend-components/ai-elements/decision/ai-approval-queue.frontend-component.specification.js +1 -1
  416. package/dist/esm/engine/frontend-components/ai-elements/decision/ai-approval-queue.frontend-component.specification.js.map +1 -1
  417. package/dist/esm/engine/frontend-components/ai-elements/decision/ai-approval-request.frontend-component.specification.js +1 -1
  418. package/dist/esm/engine/frontend-components/ai-elements/decision/ai-approval-request.frontend-component.specification.js.map +1 -1
  419. package/dist/esm/engine/frontend-components/app/app-layout-agent-work-override-rate-settings.frontend-component.specification.d.ts +5 -0
  420. package/dist/esm/engine/frontend-components/app/app-layout-agent-work-override-rate-settings.frontend-component.specification.d.ts.map +1 -0
  421. package/dist/esm/engine/frontend-components/app/app-layout-agent-work-override-rate-settings.frontend-component.specification.js +79 -0
  422. package/dist/esm/engine/frontend-components/app/app-layout-agent-work-override-rate-settings.frontend-component.specification.js.map +1 -0
  423. package/dist/esm/engine/frontend-components/app/app-layout-appearance-settings.frontend-component.specification.js +1 -1
  424. package/dist/esm/engine/frontend-components/app/app-layout-appearance-settings.frontend-component.specification.js.map +1 -1
  425. package/dist/esm/engine/frontend-components/app/app-layout-billing-settings.frontend-component.specification.d.ts.map +1 -1
  426. package/dist/esm/engine/frontend-components/app/app-layout-billing-settings.frontend-component.specification.js +3 -1
  427. package/dist/esm/engine/frontend-components/app/app-layout-billing-settings.frontend-component.specification.js.map +1 -1
  428. package/dist/esm/engine/frontend-components/app/app-layout-connected-accounts-settings.frontend-component.specification.d.ts.map +1 -1
  429. package/dist/esm/engine/frontend-components/app/app-layout-connected-accounts-settings.frontend-component.specification.js +5 -4
  430. package/dist/esm/engine/frontend-components/app/app-layout-connected-accounts-settings.frontend-component.specification.js.map +1 -1
  431. package/dist/esm/engine/frontend-components/app/app-layout-invitations-settings.frontend-component.specification.js +1 -1
  432. package/dist/esm/engine/frontend-components/app/app-layout-invitations-settings.frontend-component.specification.js.map +1 -1
  433. package/dist/esm/engine/frontend-components/auth/admin-config/app-page-security-settings.frontend-component.specification.js +1 -1
  434. package/dist/esm/engine/frontend-components/auth/admin-config/app-page-security-settings.frontend-component.specification.js.map +1 -1
  435. package/dist/esm/engine/frontend-components/billing/billing-pricing-table.frontend-component.specification.js +2 -2
  436. package/dist/esm/engine/frontend-components/billing/billing-pricing-table.frontend-component.specification.js.map +1 -1
  437. package/dist/esm/engine/frontend-components/data-display/formatters/display-field-number.frontend-component.specification.js +1 -1
  438. package/dist/esm/engine/frontend-components/data-display/formatters/display-field-number.frontend-component.specification.js.map +1 -1
  439. package/dist/esm/engine/frontend-components/data-display/formatters/display-field-string.frontend-component.specification.js +2 -2
  440. package/dist/esm/engine/frontend-components/data-display/formatters/display-field-string.frontend-component.specification.js.map +1 -1
  441. package/dist/esm/engine/frontend-components/flows-actors/low-level-ai-approval.frontend-component.specification.js +1 -1
  442. package/dist/esm/engine/frontend-components/flows-actors/low-level-ai-approval.frontend-component.specification.js.map +1 -1
  443. package/dist/esm/engine/frontend-components/flows-actors/low-level-ai-decision.frontend-component.specification.js +1 -1
  444. package/dist/esm/engine/frontend-components/flows-actors/low-level-ai-decision.frontend-component.specification.js.map +1 -1
  445. package/dist/esm/engine/frontend-components/form/fields/form-field-address.frontend-component.specification.d.ts.map +1 -1
  446. package/dist/esm/engine/frontend-components/form/fields/form-field-address.frontend-component.specification.js +1 -1
  447. package/dist/esm/engine/frontend-components/form/fields/form-field-address.frontend-component.specification.js.map +1 -1
  448. package/dist/esm/engine/frontend-components/form/fields/form-field-string.frontend-component.specification.js +2 -2
  449. package/dist/esm/engine/frontend-components/form/fields/form-field-string.frontend-component.specification.js.map +1 -1
  450. package/dist/esm/engine/frontend-components/index.d.ts +1 -0
  451. package/dist/esm/engine/frontend-components/index.d.ts.map +1 -1
  452. package/dist/esm/engine/frontend-components/index.js +3 -0
  453. package/dist/esm/engine/frontend-components/index.js.map +1 -1
  454. package/dist/esm/engine/frontend-components/resources/resource-layout-empty-state.frontend-component.specification.js +1 -1
  455. package/dist/esm/engine/frontend-components/resources/resource-layout-empty-state.frontend-component.specification.js.map +1 -1
  456. package/dist/esm/engine/frontend-components/resources/resources-fields-resource-reference-display.frontend-component.specification.js +1 -1
  457. package/dist/esm/engine/frontend-components/resources/resources-fields-resource-reference-display.frontend-component.specification.js.map +1 -1
  458. package/dist/esm/engine/frontend-components/resources/resources-fields-resource-reference-edit.frontend-component.specification.js +1 -1
  459. package/dist/esm/engine/frontend-components/resources/resources-fields-resource-reference-edit.frontend-component.specification.js.map +1 -1
  460. package/dist/esm/engine/frontend-components/sections/stepper.frontend-component.specification.d.ts.map +1 -1
  461. package/dist/esm/engine/frontend-components/sections/stepper.frontend-component.specification.js +9 -4
  462. package/dist/esm/engine/frontend-components/sections/stepper.frontend-component.specification.js.map +1 -1
  463. package/dist/esm/engine/guidance/resources/guidance-state.resource.specification.js +4 -4
  464. package/dist/esm/engine/guidance/resources/guidance-state.resource.specification.js.map +1 -1
  465. package/dist/esm/engine/guidance/resources/lifecycle-state.resource.specification.d.ts.map +1 -1
  466. package/dist/esm/engine/guidance/resources/lifecycle-state.resource.specification.js +34 -0
  467. package/dist/esm/engine/guidance/resources/lifecycle-state.resource.specification.js.map +1 -1
  468. package/dist/esm/engine/guidance/resources/progression-state.resource.specification.d.ts.map +1 -1
  469. package/dist/esm/engine/guidance/resources/progression-state.resource.specification.js +26 -0
  470. package/dist/esm/engine/guidance/resources/progression-state.resource.specification.js.map +1 -1
  471. package/dist/esm/engine/infrastructure/resources/data-seed-runs.resource.specification.js +2 -2
  472. package/dist/esm/engine/infrastructure/resources/data-seed-runs.resource.specification.js.map +1 -1
  473. package/dist/esm/engine/infrastructure/resources/external-data-erasure-suppressions.resource.specification.d.ts +9 -0
  474. package/dist/esm/engine/infrastructure/resources/external-data-erasure-suppressions.resource.specification.d.ts.map +1 -0
  475. package/dist/esm/engine/infrastructure/resources/external-data-erasure-suppressions.resource.specification.js +122 -0
  476. package/dist/esm/engine/infrastructure/resources/external-data-erasure-suppressions.resource.specification.js.map +1 -0
  477. package/dist/esm/engine/infrastructure/resources/external-data-outbound-changes.resource.specification.d.ts +9 -0
  478. package/dist/esm/engine/infrastructure/resources/external-data-outbound-changes.resource.specification.d.ts.map +1 -0
  479. package/dist/esm/engine/infrastructure/resources/external-data-outbound-changes.resource.specification.js +152 -0
  480. package/dist/esm/engine/infrastructure/resources/external-data-outbound-changes.resource.specification.js.map +1 -0
  481. package/dist/esm/engine/infrastructure/resources/external-data-pending-references.resource.specification.d.ts +10 -0
  482. package/dist/esm/engine/infrastructure/resources/external-data-pending-references.resource.specification.d.ts.map +1 -0
  483. package/dist/esm/engine/infrastructure/resources/external-data-pending-references.resource.specification.js +94 -0
  484. package/dist/esm/engine/infrastructure/resources/external-data-pending-references.resource.specification.js.map +1 -0
  485. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership-keys.resource.specification.d.ts +10 -0
  486. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership-keys.resource.specification.d.ts.map +1 -0
  487. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership-keys.resource.specification.js +64 -0
  488. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership-keys.resource.specification.js.map +1 -0
  489. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership.resource.specification.d.ts +4 -1
  490. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership.resource.specification.d.ts.map +1 -1
  491. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership.resource.specification.js +20 -16
  492. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership.resource.specification.js.map +1 -1
  493. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-run-records.resource.specification.d.ts +9 -0
  494. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-run-records.resource.specification.d.ts.map +1 -0
  495. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-run-records.resource.specification.js +200 -0
  496. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-run-records.resource.specification.js.map +1 -0
  497. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-states.resource.specification.d.ts.map +1 -1
  498. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-states.resource.specification.js +19 -6
  499. package/dist/esm/engine/infrastructure/resources/external-data-pipeline-states.resource.specification.js.map +1 -1
  500. package/dist/esm/engine/infrastructure/resources/external-data-remote-versions.resource.specification.d.ts +9 -0
  501. package/dist/esm/engine/infrastructure/resources/external-data-remote-versions.resource.specification.d.ts.map +1 -0
  502. package/dist/esm/engine/infrastructure/resources/external-data-remote-versions.resource.specification.js +97 -0
  503. package/dist/esm/engine/infrastructure/resources/external-data-remote-versions.resource.specification.js.map +1 -0
  504. package/dist/esm/engine/infrastructure/resources/job-executions.resource.specification.d.ts +8 -0
  505. package/dist/esm/engine/infrastructure/resources/job-executions.resource.specification.d.ts.map +1 -1
  506. package/dist/esm/engine/infrastructure/resources/job-executions.resource.specification.js +2 -2
  507. package/dist/esm/engine/infrastructure/resources/job-executions.resource.specification.js.map +1 -1
  508. package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.d.ts +8 -8
  509. package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.js +1 -1
  510. package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.js.map +1 -1
  511. package/dist/esm/engine/infrastructure/resources/system-of-record-partition-assignments.resource.specification.js +4 -4
  512. package/dist/esm/engine/infrastructure/resources/system-of-record-partition-assignments.resource.specification.js.map +1 -1
  513. package/dist/esm/engine/infrastructure/resources/system-of-record-write-admissions.resource.specification.d.ts +9 -0
  514. package/dist/esm/engine/infrastructure/resources/system-of-record-write-admissions.resource.specification.d.ts.map +1 -0
  515. package/dist/esm/engine/infrastructure/resources/system-of-record-write-admissions.resource.specification.js +153 -0
  516. package/dist/esm/engine/infrastructure/resources/system-of-record-write-admissions.resource.specification.js.map +1 -0
  517. package/dist/esm/engine/notifications/resources/conversation-threads.resource.specification.d.ts +81 -0
  518. package/dist/esm/engine/notifications/resources/conversation-threads.resource.specification.d.ts.map +1 -0
  519. package/dist/esm/engine/notifications/resources/conversation-threads.resource.specification.js +437 -0
  520. package/dist/esm/engine/notifications/resources/conversation-threads.resource.specification.js.map +1 -0
  521. package/dist/esm/engine/notifications/resources/inbound-deliveries.resource.specification.d.ts +112 -0
  522. package/dist/esm/engine/notifications/resources/inbound-deliveries.resource.specification.d.ts.map +1 -0
  523. package/dist/esm/engine/notifications/resources/inbound-deliveries.resource.specification.js +287 -0
  524. package/dist/esm/engine/notifications/resources/inbound-deliveries.resource.specification.js.map +1 -0
  525. package/dist/esm/engine/notifications/resources/inbound-email.resource.specification.d.ts +131 -0
  526. package/dist/esm/engine/notifications/resources/inbound-email.resource.specification.d.ts.map +1 -0
  527. package/dist/esm/engine/notifications/resources/inbound-email.resource.specification.js +594 -0
  528. package/dist/esm/engine/notifications/resources/inbound-email.resource.specification.js.map +1 -0
  529. package/dist/esm/engine/notifications/resources/index.d.ts +1 -0
  530. package/dist/esm/engine/notifications/resources/index.d.ts.map +1 -1
  531. package/dist/esm/engine/notifications/resources/index.js +1 -0
  532. package/dist/esm/engine/notifications/resources/index.js.map +1 -1
  533. package/dist/esm/engine/notifications/resources/m2m-webhook-delivery-log.resource.specification.d.ts +6 -3
  534. package/dist/esm/engine/notifications/resources/m2m-webhook-delivery-log.resource.specification.d.ts.map +1 -1
  535. package/dist/esm/engine/notifications/resources/m2m-webhook-delivery-log.resource.specification.js +20 -5
  536. package/dist/esm/engine/notifications/resources/m2m-webhook-delivery-log.resource.specification.js.map +1 -1
  537. package/dist/esm/engine/notifications/resources/notification-badges.resource.specification.d.ts.map +1 -1
  538. package/dist/esm/engine/notifications/resources/notification-badges.resource.specification.js +12 -2
  539. package/dist/esm/engine/notifications/resources/notification-badges.resource.specification.js.map +1 -1
  540. package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.d.ts +6 -6
  541. package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.d.ts.map +1 -1
  542. package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.js +8 -11
  543. package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.js.map +1 -1
  544. package/dist/esm/engine/notifications/system-emails/human-decision.system-emails.specification.d.ts +4 -0
  545. package/dist/esm/engine/notifications/system-emails/human-decision.system-emails.specification.d.ts.map +1 -0
  546. package/dist/esm/engine/notifications/system-emails/human-decision.system-emails.specification.js +62 -0
  547. package/dist/esm/engine/notifications/system-emails/human-decision.system-emails.specification.js.map +1 -0
  548. package/dist/esm/engine/notifications/system-emails/index.d.ts +2 -1
  549. package/dist/esm/engine/notifications/system-emails/index.d.ts.map +1 -1
  550. package/dist/esm/engine/notifications/system-emails/index.js +4 -2
  551. package/dist/esm/engine/notifications/system-emails/index.js.map +1 -1
  552. package/dist/esm/engine/organizations/resources/index.d.ts +2 -0
  553. package/dist/esm/engine/organizations/resources/index.d.ts.map +1 -1
  554. package/dist/esm/engine/organizations/resources/index.js +2 -0
  555. package/dist/esm/engine/organizations/resources/index.js.map +1 -1
  556. package/dist/esm/engine/organizations/resources/organization-members.resource.specification.d.ts +3 -0
  557. package/dist/esm/engine/organizations/resources/organization-members.resource.specification.d.ts.map +1 -1
  558. package/dist/esm/engine/organizations/resources/organization-members.resource.specification.js +40 -12
  559. package/dist/esm/engine/organizations/resources/organization-members.resource.specification.js.map +1 -1
  560. package/dist/esm/engine/organizations/resources/organization-notifications.resource.specification.js +2 -2
  561. package/dist/esm/engine/organizations/resources/organization-notifications.resource.specification.js.map +1 -1
  562. package/dist/esm/engine/organizations/resources/organization-preferences.resource.specification.js +2 -2
  563. package/dist/esm/engine/organizations/resources/organization-preferences.resource.specification.js.map +1 -1
  564. package/dist/esm/engine/organizations/resources/organization-profiles.resource.specification.d.ts +0 -1
  565. package/dist/esm/engine/organizations/resources/organization-profiles.resource.specification.d.ts.map +1 -1
  566. package/dist/esm/engine/organizations/resources/organization-profiles.resource.specification.js +4 -6
  567. package/dist/esm/engine/organizations/resources/organization-profiles.resource.specification.js.map +1 -1
  568. package/dist/esm/engine/organizations/resources/organization-unit-members.resource.specification.d.ts.map +1 -1
  569. package/dist/esm/engine/organizations/resources/organization-unit-members.resource.specification.js +7 -3
  570. package/dist/esm/engine/organizations/resources/organization-unit-members.resource.specification.js.map +1 -1
  571. package/dist/esm/engine/organizations/resources/organization-units.resource.specification.d.ts.map +1 -1
  572. package/dist/esm/engine/organizations/resources/organization-units.resource.specification.js +15 -8
  573. package/dist/esm/engine/organizations/resources/organization-units.resource.specification.js.map +1 -1
  574. package/dist/esm/engine/organizations/resources/organizations.resource.specification.d.ts +3 -1
  575. package/dist/esm/engine/organizations/resources/organizations.resource.specification.d.ts.map +1 -1
  576. package/dist/esm/engine/organizations/resources/organizations.resource.specification.js +36 -21
  577. package/dist/esm/engine/organizations/resources/organizations.resource.specification.js.map +1 -1
  578. package/dist/esm/engine/organizations/resources/service-provider-activity-feed.resource.specification.d.ts +38 -0
  579. package/dist/esm/engine/organizations/resources/service-provider-activity-feed.resource.specification.d.ts.map +1 -0
  580. package/dist/esm/engine/organizations/resources/service-provider-activity-feed.resource.specification.js +152 -0
  581. package/dist/esm/engine/organizations/resources/service-provider-activity-feed.resource.specification.js.map +1 -0
  582. package/dist/esm/engine/organizations/resources/service-provider-relationships.resource.specification.d.ts +106 -0
  583. package/dist/esm/engine/organizations/resources/service-provider-relationships.resource.specification.d.ts.map +1 -0
  584. package/dist/esm/engine/organizations/resources/service-provider-relationships.resource.specification.js +417 -0
  585. package/dist/esm/engine/organizations/resources/service-provider-relationships.resource.specification.js.map +1 -0
  586. package/dist/esm/engine/providers/apple.provider.specification.js +1 -1
  587. package/dist/esm/engine/providers/apple.provider.specification.js.map +1 -1
  588. package/dist/esm/engine/providers/github.provider.specification.js +1 -1
  589. package/dist/esm/engine/providers/github.provider.specification.js.map +1 -1
  590. package/dist/esm/engine/providers/google-places.provider.specification.d.ts +6 -0
  591. package/dist/esm/engine/providers/google-places.provider.specification.d.ts.map +1 -0
  592. package/dist/esm/engine/providers/google-places.provider.specification.js +44 -0
  593. package/dist/esm/engine/providers/google-places.provider.specification.js.map +1 -0
  594. package/dist/esm/engine/providers/google.provider.specification.js +1 -1
  595. package/dist/esm/engine/providers/google.provider.specification.js.map +1 -1
  596. package/dist/esm/engine/providers/index.d.ts +2 -0
  597. package/dist/esm/engine/providers/index.d.ts.map +1 -1
  598. package/dist/esm/engine/providers/index.js +5 -1
  599. package/dist/esm/engine/providers/index.js.map +1 -1
  600. package/dist/esm/engine/providers/microsoft.provider.specification.d.ts.map +1 -1
  601. package/dist/esm/engine/providers/microsoft.provider.specification.js +10 -6
  602. package/dist/esm/engine/providers/microsoft.provider.specification.js.map +1 -1
  603. package/dist/esm/engine/providers/recaptcha.provider.specification.d.ts +6 -0
  604. package/dist/esm/engine/providers/recaptcha.provider.specification.d.ts.map +1 -0
  605. package/dist/esm/engine/providers/recaptcha.provider.specification.js +38 -0
  606. package/dist/esm/engine/providers/recaptcha.provider.specification.js.map +1 -0
  607. package/dist/esm/engine/providers/resend.provider.specification.d.ts.map +1 -1
  608. package/dist/esm/engine/providers/resend.provider.specification.js +3 -1
  609. package/dist/esm/engine/providers/resend.provider.specification.js.map +1 -1
  610. package/dist/esm/engine/providers/stripe.provider.specification.d.ts.map +1 -1
  611. package/dist/esm/engine/providers/stripe.provider.specification.js +3 -2
  612. package/dist/esm/engine/providers/stripe.provider.specification.js.map +1 -1
  613. package/dist/esm/engine/roles/app-billing-provider-events.role.specification.d.ts +2 -0
  614. package/dist/esm/engine/roles/app-billing-provider-events.role.specification.d.ts.map +1 -0
  615. package/dist/esm/engine/roles/app-billing-provider-events.role.specification.js +21 -0
  616. package/dist/esm/engine/roles/app-billing-provider-events.role.specification.js.map +1 -0
  617. package/dist/esm/engine/roles/app-email-inbound-intake.role.specification.d.ts +2 -0
  618. package/dist/esm/engine/roles/app-email-inbound-intake.role.specification.d.ts.map +1 -0
  619. package/dist/esm/engine/roles/app-email-inbound-intake.role.specification.js +21 -0
  620. package/dist/esm/engine/roles/app-email-inbound-intake.role.specification.js.map +1 -0
  621. package/dist/esm/engine/roles/index.d.ts +13 -5
  622. package/dist/esm/engine/roles/index.d.ts.map +1 -1
  623. package/dist/esm/engine/roles/index.js +19 -6
  624. package/dist/esm/engine/roles/index.js.map +1 -1
  625. package/dist/esm/engine/roles/org-billing-provider-events.role.specification.d.ts +2 -0
  626. package/dist/esm/engine/roles/org-billing-provider-events.role.specification.d.ts.map +1 -0
  627. package/dist/esm/engine/roles/org-billing-provider-events.role.specification.js +21 -0
  628. package/dist/esm/engine/roles/org-billing-provider-events.role.specification.js.map +1 -0
  629. package/dist/esm/engine/roles/org-delegated-capabilities.role.specification.d.ts +7 -0
  630. package/dist/esm/engine/roles/org-delegated-capabilities.role.specification.d.ts.map +1 -0
  631. package/dist/esm/engine/roles/org-delegated-capabilities.role.specification.js +72 -0
  632. package/dist/esm/engine/roles/org-delegated-capabilities.role.specification.js.map +1 -0
  633. package/dist/esm/engine/roles/org-service-provider.role.specification.d.ts +2 -0
  634. package/dist/esm/engine/roles/org-service-provider.role.specification.d.ts.map +1 -0
  635. package/dist/esm/engine/roles/org-service-provider.role.specification.js +22 -0
  636. package/dist/esm/engine/roles/org-service-provider.role.specification.js.map +1 -0
  637. package/dist/esm/engine/users/resources/anonymous-users.resource.specification.js +2 -2
  638. package/dist/esm/engine/users/resources/anonymous-users.resource.specification.js.map +1 -1
  639. package/dist/esm/engine/users/resources/inbound-contacts.resource.specification.js +3 -3
  640. package/dist/esm/engine/users/resources/inbound-contacts.resource.specification.js.map +1 -1
  641. package/dist/esm/engine/users/resources/self-service-user-notifications.shared.d.ts +1 -1
  642. package/dist/esm/engine/users/resources/self-service-user-notifications.shared.d.ts.map +1 -1
  643. package/dist/esm/engine/users/resources/self-service-user-notifications.shared.js +3 -6
  644. package/dist/esm/engine/users/resources/self-service-user-notifications.shared.js.map +1 -1
  645. package/dist/esm/engine/users/resources/user-credentials.resource.specification.js +2 -2
  646. package/dist/esm/engine/users/resources/user-credentials.resource.specification.js.map +1 -1
  647. package/dist/esm/engine/users/resources/user-identity-links.resource.specification.js +2 -2
  648. package/dist/esm/engine/users/resources/user-identity-links.resource.specification.js.map +1 -1
  649. package/dist/esm/engine/users/resources/user-preferences-api-reference.examples.d.ts +0 -4
  650. package/dist/esm/engine/users/resources/user-preferences-api-reference.examples.d.ts.map +1 -1
  651. package/dist/esm/engine/users/resources/user-preferences-api-reference.examples.js +0 -3
  652. package/dist/esm/engine/users/resources/user-preferences-api-reference.examples.js.map +1 -1
  653. package/dist/esm/engine/users/resources/user-preferences.resource.specification.d.ts +0 -3
  654. package/dist/esm/engine/users/resources/user-preferences.resource.specification.d.ts.map +1 -1
  655. package/dist/esm/engine/users/resources/user-preferences.resource.specification.js +7 -7
  656. package/dist/esm/engine/users/resources/user-preferences.resource.specification.js.map +1 -1
  657. package/dist/esm/engine/users/resources/user-profiles.resource.specification.js +5 -5
  658. package/dist/esm/engine/users/resources/user-profiles.resource.specification.js.map +1 -1
  659. package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.d.ts +0 -3
  660. package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.d.ts.map +1 -1
  661. package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.js +11 -18
  662. package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.js.map +1 -1
  663. package/dist/esm/engine/users/resources/user-self-profiles.resource.specification.js +6 -6
  664. package/dist/esm/engine/users/resources/user-self-profiles.resource.specification.js.map +1 -1
  665. package/dist/esm/engine/users/resources/user-self.resource.specification.d.ts.map +1 -1
  666. package/dist/esm/engine/users/resources/user-self.resource.specification.js +5 -1
  667. package/dist/esm/engine/users/resources/user-self.resource.specification.js.map +1 -1
  668. package/dist/esm/engine/users/resources/users.resource.specification.d.ts +8 -5
  669. package/dist/esm/engine/users/resources/users.resource.specification.d.ts.map +1 -1
  670. package/dist/esm/engine/users/resources/users.resource.specification.js +49 -16
  671. package/dist/esm/engine/users/resources/users.resource.specification.js.map +1 -1
  672. package/dist/esm/technical-documentation/engine-documentation-specification-catalog.companion.d.ts.map +1 -1
  673. package/dist/esm/technical-documentation/engine-documentation-specification-catalog.companion.js +29 -10
  674. package/dist/esm/technical-documentation/engine-documentation-specification-catalog.companion.js.map +1 -1
  675. package/dist/tsconfig.build.tsbuildinfo +1 -1
  676. package/package.json +8 -8
  677. package/dist/assurance/external-framework-mapping.json +0 -1228
@@ -0,0 +1,107 @@
1
+ import { type ApplicationRetentionSchedule, type RetentionEnforcementEvidence, type ResourceRetentionBinding } from "@wildo-ai/saas-models";
2
+ /**
3
+ * # Was each declared retention period ENFORCED? — derived from the application's own records (#1636)
4
+ *
5
+ * assurance-control: WILDO.PRIVACY.STORAGE_LIMITATION — records evidence that declared retention was enforced.
6
+ *
7
+ * The first producer of `AssuranceDocumentFactAuthorityKind.RUNTIME_EVIDENCE`. Every other computed fact
8
+ * restates a DECLARATION; this one reads what the product DID — the retention-enforcement records the
9
+ * retention-class sweep writes on every run — and says, per declared class, one of three things. A privacy
10
+ * notice then says a period is enforced only when the product has shown it, which is the distinction
11
+ * `.claude/rules/compliance-is-derived-from-the-product.md` exists for: a declaration is not an enforcement.
12
+ *
13
+ * Rejected: answering "enforced" because a resource BINDS the class. A binding is configuration; it says
14
+ * the sweep WILL act, not that it did — and a sweep that stopped running, or fails every run, would still
15
+ * read as enforced. That conflation is the defect the runtime tier removes.
16
+ */
17
+ /** @wildo_source:part:start saas.specifications.compliance.retention-enforcement-state facet:layer:shared facet:audience:app-developer */
18
+ /** What the records show about one declared retention class. */
19
+ export declare enum RetentionEnforcementState {
20
+ /**
21
+ * At least one resource bound to the class has a recent run that deleted what was due (`COMPLETED`) or is
22
+ * working through a backlog bounded per run (`DEFERRED_BY_CEILING`), and every other bound resource does too
23
+ * or is enforced by the tenant purge instead. "Recent" is within {@link RETENTION_ENFORCEMENT_RECENT_SWEEP_INTERVALS}
24
+ * sweep intervals of the observation. A class whose ONLY bound resources are purge-enforced is not ENFORCED
25
+ * here: a purge-enforced skip records configuration, not an act, and these records never saw the purge run.
26
+ */
27
+ ENFORCED = "ENFORCED",
28
+ /**
29
+ * A period is declared and the records do not show it enforced: no resource binds the class, or a bound
30
+ * resource has no recent run. For `FILES` and `AUDIT_LOGS` this is also the answer when only their own
31
+ * mechanisms act (files cleanup, audit archival), because those leave no enforcement record — a true
32
+ * statement about the evidence, not a claim that nothing happens.
33
+ */
34
+ DECLARED = "DECLARED",
35
+ /** The latest run of at least one bound resource FAILED: retention is not being enforced for it now. */
36
+ FAILING = "FAILING"
37
+ }
38
+ /** @wildo_source:part:end saas.specifications.compliance.retention-enforcement-state */
39
+ /**
40
+ * How many sweep intervals a run may be old and still count as recent. Two, so a single missed or late run
41
+ * (a restart at the wrong moment) does not flip a class to DECLARED, while a sweep that has stopped does.
42
+ */
43
+ export declare const RETENTION_ENFORCEMENT_RECENT_SWEEP_INTERVALS = 2;
44
+ /** One resource's binding, as the derivation reads it — the same shape the retention-rules fact reads. */
45
+ export interface RetentionEnforcementBindingInput {
46
+ readonly resourceType: string;
47
+ readonly retentionBinding?: ResourceRetentionBinding;
48
+ }
49
+ /** What the derivation states about one declared class. JSON-shaped: it becomes a document fact's value. */
50
+ export interface RetentionClassEnforcement {
51
+ readonly dataClass: string;
52
+ readonly state: RetentionEnforcementState;
53
+ /** Every resource bound to the class, sorted. */
54
+ readonly boundResourceTypes: string[];
55
+ /** Bound resources whose recent run deleted what was due (or is working through a bounded backlog). */
56
+ readonly enforcedResourceTypes: string[];
57
+ /** Bound resources the tenant purge enforces instead: their recent record is a purge-enforced skip. */
58
+ readonly enforcedByTenantPurgeResourceTypes: string[];
59
+ /** Bound resources with no recent run at all. */
60
+ readonly unevidencedResourceTypes: string[];
61
+ /** Bound resources whose latest run FAILED. */
62
+ readonly failingResourceTypes: string[];
63
+ /** The latest run of any resource of the class, ISO. Absent when the window holds none. */
64
+ readonly latestSweptAt?: string;
65
+ /** Rows of this class deleted in the evidence window. */
66
+ readonly deletedCountInWindow: number;
67
+ /**
68
+ * Rows past their period a legal hold is keeping, as of each bound resource's LATEST run, summed (#1634). Not a
69
+ * sum over the window's runs: a row held for a day is kept by every hourly run, and summing would report it
70
+ * two dozen times. Absent when no latest run measured holds — "not measured" is never reported as zero.
71
+ */
72
+ readonly heldSkippedCountAtLatestRun?: number;
73
+ /** Every distinct period the runs in the window applied, ascending — a schedule change shows as two. */
74
+ readonly retentionDaysApplied: number[];
75
+ }
76
+ /** The whole derived answer: when it was observed, over which window, and one entry per declared class. */
77
+ export interface RetentionEnforcementFacts {
78
+ readonly observedAt: string;
79
+ readonly window: {
80
+ readonly from: string;
81
+ readonly to: string;
82
+ };
83
+ readonly sweepIntervalMinutes: number;
84
+ readonly runCount: number;
85
+ readonly classes: RetentionClassEnforcement[];
86
+ }
87
+ /**
88
+ * Per declared class: ENFORCED, DECLARED or FAILING, from the records the sweep wrote.
89
+ *
90
+ * Pure over its inputs so the rule is pinned directly. `records` crossed a JSON boundary (the evidence door,
91
+ * then the assurance repository), so `sweptAt` may arrive as a string; it is read either way.
92
+ *
93
+ * The decision per bound resource reads that resource's LATEST record in the window:
94
+ * - FAILED → the resource is failing, and the class is FAILING whatever its other resources show;
95
+ * - a non-failed outcome within the recent horizon → enforced (or enforced by the tenant purge);
96
+ * - anything else (no record, or only an old one) → unevidenced, and the class reads DECLARED.
97
+ * A class with no bound resource is DECLARED: nothing the sweep does applies to it.
98
+ */
99
+ export declare function deriveRetentionEnforcementFacts(input: {
100
+ readonly evidence: RetentionEnforcementEvidence;
101
+ readonly schedule: ApplicationRetentionSchedule;
102
+ readonly bindings: readonly RetentionEnforcementBindingInput[];
103
+ /** The instant the evidence was observed — the window's end. "Recent" is measured back from here, never from the reader's clock. */
104
+ readonly observedAt: Date;
105
+ readonly sweepIntervalMs: number;
106
+ }): RetentionEnforcementFacts;
107
+ //# sourceMappingURL=retention-enforcement-facts.schemas.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"retention-enforcement-facts.schemas.d.ts","sourceRoot":"","sources":["../../../../../src/_core/compliance-documents/retention-enforcement-facts.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAGL,KAAK,4BAA4B,EAEjC,KAAK,4BAA4B,EAEjC,KAAK,wBAAwB,EAC9B,MAAM,uBAAuB,CAAC;AAE/B;;;;;;;;;;;;;;GAcG;AAEH,0IAA0I;AAC1I,gEAAgE;AAChE,oBAAY,yBAAyB;IACnC;;;;;;OAMG;IACH,QAAQ,aAAa;IACrB;;;;;OAKG;IACH,QAAQ,aAAa;IACrB,wGAAwG;IACxG,OAAO,YAAY;CACpB;AACD,wFAAwF;AAExF;;;GAGG;AACH,eAAO,MAAM,4CAA4C,IAAI,CAAC;AAE9D,0GAA0G;AAC1G,MAAM,WAAW,gCAAgC;IAC/C,QAAQ,CAAC,YAAY,EAAE,MAAM,CAAC;IAC9B,QAAQ,CAAC,gBAAgB,CAAC,EAAE,wBAAwB,CAAC;CACtD;AAED,4GAA4G;AAC5G,MAAM,WAAW,yBAAyB;IACxC,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,KAAK,EAAE,yBAAyB,CAAC;IAC1C,iDAAiD;IACjD,QAAQ,CAAC,kBAAkB,EAAE,MAAM,EAAE,CAAC;IACtC,uGAAuG;IACvG,QAAQ,CAAC,qBAAqB,EAAE,MAAM,EAAE,CAAC;IACzC,uGAAuG;IACvG,QAAQ,CAAC,kCAAkC,EAAE,MAAM,EAAE,CAAC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? — derived from the application's own records (#1636)
4
+ *
5
+ * assurance-control: WILDO.PRIVACY.STORAGE_LIMITATION — records evidence that declared retention was enforced.
6
+ *
7
+ * The first producer of `AssuranceDocumentFactAuthorityKind.RUNTIME_EVIDENCE`. Every other computed fact
8
+ * restates a DECLARATION; this one reads what the product DID — the retention-enforcement records the
9
+ * retention-class sweep writes on every run — and says, per declared class, one of three things. A privacy
10
+ * notice then says a period is enforced only when the product has shown it, which is the distinction
11
+ * `.claude/rules/compliance-is-derived-from-the-product.md` exists for: a declaration is not an enforcement.
12
+ *
13
+ * Rejected: answering "enforced" because a resource BINDS the class. A binding is configuration; it says
14
+ * the sweep WILL act, not that it did — and a sweep that stopped running, or fails every run, would still
15
+ * read as enforced. That conflation is the defect the runtime tier removes.
16
+ */
17
+ /** @wildo_source:part:start saas.specifications.compliance.retention-enforcement-state facet:layer:shared facet:audience:app-developer */
18
+ /** What the records show about one declared retention class. */
19
+ export var RetentionEnforcementState;
20
+ (function (RetentionEnforcementState) {
21
+ /**
22
+ * At least one resource bound to the class has a recent run that deleted what was due (`COMPLETED`) or is
23
+ * working through a backlog bounded per run (`DEFERRED_BY_CEILING`), and every other bound resource does too
24
+ * or is enforced by the tenant purge instead. "Recent" is within {@link RETENTION_ENFORCEMENT_RECENT_SWEEP_INTERVALS}
25
+ * sweep intervals of the observation. A class whose ONLY bound resources are purge-enforced is not ENFORCED
26
+ * here: a purge-enforced skip records configuration, not an act, and these records never saw the purge run.
27
+ */
28
+ RetentionEnforcementState["ENFORCED"] = "ENFORCED";
29
+ /**
30
+ * A period is declared and the records do not show it enforced: no resource binds the class, or a bound
31
+ * resource has no recent run. For `FILES` and `AUDIT_LOGS` this is also the answer when only their own
32
+ * mechanisms act (files cleanup, audit archival), because those leave no enforcement record — a true
33
+ * statement about the evidence, not a claim that nothing happens.
34
+ */
35
+ RetentionEnforcementState["DECLARED"] = "DECLARED";
36
+ /** The latest run of at least one bound resource FAILED: retention is not being enforced for it now. */
37
+ RetentionEnforcementState["FAILING"] = "FAILING";
38
+ })(RetentionEnforcementState || (RetentionEnforcementState = {}));
39
+ /** @wildo_source:part:end saas.specifications.compliance.retention-enforcement-state */
40
+ /**
41
+ * How many sweep intervals a run may be old and still count as recent. Two, so a single missed or late run
42
+ * (a restart at the wrong moment) does not flip a class to DECLARED, while a sweep that has stopped does.
43
+ */
44
+ export const RETENTION_ENFORCEMENT_RECENT_SWEEP_INTERVALS = 2;
45
+ const sortedUnique = (values) => [...new Set(values)].sort();
46
+ const isEnforcingOutcome = (record) => record.outcome === RetentionEnforcementOutcome.COMPLETED || record.outcome === RetentionEnforcementOutcome.DEFERRED_BY_CEILING;
47
+ const isPurgeEnforcedSkip = (record) => record.outcome === RetentionEnforcementOutcome.SKIPPED && record.skipReason === RetentionClassSweepSkipReason.ENFORCED_BY_TENANT_PURGE;
48
+ const sweptAtMs = (record) => new Date(record.sweptAt).getTime();
49
+ /**
50
+ * Per declared class: ENFORCED, DECLARED or FAILING, from the records the sweep wrote.
51
+ *
52
+ * Pure over its inputs so the rule is pinned directly. `records` crossed a JSON boundary (the evidence door,
53
+ * then the assurance repository), so `sweptAt` may arrive as a string; it is read either way.
54
+ *
55
+ * The decision per bound resource reads that resource's LATEST record in the window:
56
+ * - FAILED → the resource is failing, and the class is FAILING whatever its other resources show;
57
+ * - a non-failed outcome within the recent horizon → enforced (or enforced by the tenant purge);
58
+ * - anything else (no record, or only an old one) → unevidenced, and the class reads DECLARED.
59
+ * A class with no bound resource is DECLARED: nothing the sweep does applies to it.
60
+ */
61
+ export function deriveRetentionEnforcementFacts(input) {
62
+ const recentSinceMs = input.observedAt.getTime() - RETENTION_ENFORCEMENT_RECENT_SWEEP_INTERVALS * input.sweepIntervalMs;
63
+ const declaredClasses = Object.keys(input.schedule)
64
+ .filter((dataClass) => input.schedule[dataClass] !== undefined)
65
+ .sort();
66
+ const classes = declaredClasses.map((dataClass) => {
67
+ const bound = sortedUnique(input.bindings.filter((binding) => binding.retentionBinding?.retentionClass === dataClass).map((binding) => binding.resourceType));
68
+ const classRecords = input.evidence.records.filter((record) => record.retentionClass === dataClass);
69
+ const enforced = [];
70
+ const byPurge = [];
71
+ const unevidenced = [];
72
+ const failing = [];
73
+ const latestHeldCounts = [];
74
+ for (const resourceType of bound) {
75
+ const latest = classRecords
76
+ .filter((record) => record.resourceType === resourceType)
77
+ .reduce((best, record) => (best === undefined || sweptAtMs(record) > sweptAtMs(best) ? record : best), undefined);
78
+ if (latest?.heldSkippedCount !== undefined)
79
+ latestHeldCounts.push(latest.heldSkippedCount);
80
+ if (latest?.outcome === RetentionEnforcementOutcome.FAILED)
81
+ failing.push(resourceType);
82
+ else if (latest !== undefined && sweptAtMs(latest) >= recentSinceMs && isEnforcingOutcome(latest))
83
+ enforced.push(resourceType);
84
+ else if (latest !== undefined && sweptAtMs(latest) >= recentSinceMs && isPurgeEnforcedSkip(latest))
85
+ byPurge.push(resourceType);
86
+ else
87
+ unevidenced.push(resourceType);
88
+ }
89
+ const state = failing.length > 0
90
+ ? RetentionEnforcementState.FAILING
91
+ : enforced.length > 0 && unevidenced.length === 0
92
+ ? RetentionEnforcementState.ENFORCED
93
+ : RetentionEnforcementState.DECLARED;
94
+ const latestSweptAtMs = classRecords.reduce((latest, record) => Math.max(latest, sweptAtMs(record)), Number.NEGATIVE_INFINITY);
95
+ const periods = [...new Set(classRecords.map((record) => record.retentionDaysApplied).filter((days) => days !== undefined))].sort((left, right) => left - right);
96
+ return {
97
+ dataClass,
98
+ state,
99
+ boundResourceTypes: bound,
100
+ enforcedResourceTypes: enforced,
101
+ enforcedByTenantPurgeResourceTypes: byPurge,
102
+ unevidencedResourceTypes: unevidenced,
103
+ failingResourceTypes: failing,
104
+ ...(Number.isFinite(latestSweptAtMs) ? { latestSweptAt: new Date(latestSweptAtMs).toISOString() } : {}),
105
+ deletedCountInWindow: classRecords.reduce((total, record) => total + record.deletedCount, 0),
106
+ ...(latestHeldCounts.length > 0 ? { heldSkippedCountAtLatestRun: latestHeldCounts.reduce((total, count) => total + count, 0) } : {}),
107
+ retentionDaysApplied: periods,
108
+ };
109
+ });
110
+ return {
111
+ observedAt: input.observedAt.toISOString(),
112
+ window: { from: input.evidence.window.from, to: input.evidence.window.to },
113
+ sweepIntervalMinutes: Math.round(input.sweepIntervalMs / 60_000),
114
+ runCount: input.evidence.runCount,
115
+ classes,
116
+ };
117
+ }
118
+ //# sourceMappingURL=retention-enforcement-facts.schemas.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"retention-enforcement-facts.schemas.js","sourceRoot":"","sources":["../../../../../src/_core/compliance-documents/retention-enforcement-facts.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,6BAA6B,EAC7B,2BAA2B,GAM5B,MAAM,uBAAuB,CAAC;AAE/B;;;;;;;;;;;;;;GAcG;AAEH,0IAA0I;AAC1I,gEAAgE;AAChE,MAAM,CAAN,IAAY,yBAkBX;AAlBD,WAAY,yBAAyB;IACnC;;;;;;OAMG;IACH,kDAAqB,CAAA;IACrB;;;;;OAKG;IACH,kDAAqB,CAAA;IACrB,wGAAwG;IACxG,gDAAmB,CAAA;AACrB,CAAC,EAlBW,yBAAyB,KAAzB,yBAAyB,QAkBpC;AACD,wFAAwF;AAExF;;;GAGG;AACH,MAAM,CAAC,MAAM,4CAA4C,GAAG,CAAC,CAAC;AA6C9D,MAAM,YAAY,GAAG,CAAC,MAAwB,EAAY,EAAE,CAAC,CAAC,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC;AAEzF,MAAM,kBAAkB,GAAG,CAAC,MAA0C,EAAW,EAAE,CACjF,MAAM,CAAC,OAAO,KAAK,2BAA2B,CAAC,SAAS,IAAI,MAAM,CAAC,OAAO,KAAK,2BAA2B,CAAC,mBAAmB,CAAC;AAEjI,MAAM,mBAAmB,GAAG,CAAC,MAA0C,EAAW,EAAE,CAClF,MAAM,CAAC,OAAO,KAAK,2BAA2B,CAAC,OAAO,IAAI,MAAM,CAAC,UAAU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AAC,CAAC,CAAC;IAEH,OAAO;QACL,UAAU,EAAE,KAAK,CAAC,UAAU,CAAC,WAAW,EAAE;QAC1C,MAAM,EAAE,EAAE,IAAI,EAAE,KAAK,CAAC,QAAQ,CAAC,MAAM,CAAC,IAAI,EAAE,EAAE,EAAE,KAAK,CAAC,QAAQ,CAAC,MAAM,CAAC,EAAE,EAAE;QAC1E,oBAAoB,EAAE,IAAI,CAAC,KAAK,CAAC,KAAK,CAAC,eAAe,GAAG,MAAM,CAAC;QAChE,QAAQ,EAAE,KAAK,CAAC,QAAQ,CAAC,QAAQ;QACjC,OAAO;KACR,CAAC;AACJ,CAAC","sourcesContent":["import {\n RetentionClassSweepSkipReason,\n RetentionEnforcementOutcome,\n type ApplicationRetentionSchedule,\n type DataRetentionClass,\n type RetentionEnforcementEvidence,\n type RetentionEnforcementEvidenceRecord,\n type ResourceRetentionBinding,\n} from \"@wildo-ai/saas-models\";\n\n/**\n * # Was each declared retention period ENFORCED? — derived from the application's own records (#1636)\n *\n * assurance-control: WILDO.PRIVACY.STORAGE_LIMITATION — records evidence that declared retention was enforced.\n *\n * The first producer of `AssuranceDocumentFactAuthorityKind.RUNTIME_EVIDENCE`. Every other computed fact\n * restates a DECLARATION; this one reads what the product DID — the retention-enforcement records the\n * retention-class sweep writes on every run — and says, per declared class, one of three things. A privacy\n * notice then says a period is enforced only when the product has shown it, which is the distinction\n * `.claude/rules/compliance-is-derived-from-the-product.md` exists for: a declaration is not an enforcement.\n *\n * Rejected: answering \"enforced\" because a resource BINDS the class. A binding is configuration; it says\n * the sweep WILL act, not that it did — and a sweep that stopped running, or fails every run, would still\n * read as enforced. That conflation is the defect the runtime tier removes.\n */\n\n/** @wildo_source:part:start saas.specifications.compliance.retention-enforcement-state facet:layer:shared facet:audience:app-developer */\n/** What the records show about one declared retention class. */\nexport enum RetentionEnforcementState {\n /**\n * At least one resource bound to the class has a recent run that deleted what was due (`COMPLETED`) or is\n * working through a backlog bounded per run (`DEFERRED_BY_CEILING`), and every other bound resource does too\n * or is enforced by the tenant purge instead. \"Recent\" is within {@link RETENTION_ENFORCEMENT_RECENT_SWEEP_INTERVALS}\n * sweep intervals of the observation. A class whose ONLY bound resources are purge-enforced is not ENFORCED\n * here: a purge-enforced skip records configuration, not an act, and these records never saw the purge run.\n */\n ENFORCED = \"ENFORCED\",\n /**\n * A period is declared and the records do not show it enforced: no resource binds the class, or a bound\n * resource has no recent run. For `FILES` and `AUDIT_LOGS` this is also the answer when only their own\n * mechanisms act (files cleanup, audit archival), because those leave no enforcement record — a true\n * statement about the evidence, not a claim that nothing happens.\n */\n DECLARED = \"DECLARED\",\n /** The latest run of at least one bound resource FAILED: retention is not being enforced for it now. */\n FAILING = \"FAILING\",\n}\n/** @wildo_source:part:end saas.specifications.compliance.retention-enforcement-state */\n\n/**\n * How many sweep intervals a run may be old and still count as recent. Two, so a single missed or late run\n * (a restart at the wrong moment) does not flip a class to DECLARED, while a sweep that has stopped does.\n */\nexport const RETENTION_ENFORCEMENT_RECENT_SWEEP_INTERVALS = 2;\n\n/** One resource's binding, as the derivation reads it — the same shape the retention-rules fact reads. */\nexport interface RetentionEnforcementBindingInput {\n readonly resourceType: string;\n readonly retentionBinding?: ResourceRetentionBinding;\n}\n\n/** What the derivation states about one declared class. JSON-shaped: it becomes a document fact's value. */\nexport interface RetentionClassEnforcement {\n readonly dataClass: string;\n readonly state: RetentionEnforcementState;\n /** Every resource bound to the class, sorted. */\n readonly boundResourceTypes: string[];\n /** Bound resources whose recent run deleted what was due (or is working through a bounded backlog). */\n readonly enforcedResourceTypes: string[];\n /** Bound resources the tenant purge enforces instead: their recent record is a purge-enforced skip. */\n readonly enforcedByTenantPurgeResourceTypes: string[];\n /** Bound resources with no recent run at all. */\n readonly unevidencedResourceTypes: string[];\n /** Bound resources whose latest run FAILED. */\n readonly failingResourceTypes: string[];\n /** The latest run of any resource of the class, ISO. Absent when the window holds none. */\n readonly latestSweptAt?: string;\n /** Rows of this class deleted in the evidence window. */\n readonly deletedCountInWindow: number;\n /**\n * Rows past their period a legal hold is keeping, as of each bound resource's LATEST run, summed (#1634). Not a\n * sum over the window's runs: a row held for a day is kept by every hourly run, and summing would report it\n * two dozen times. Absent when no latest run measured holds — \"not measured\" is never reported as zero.\n */\n readonly heldSkippedCountAtLatestRun?: number;\n /** Every distinct period the runs in the window applied, ascending — a schedule change shows as two. */\n readonly retentionDaysApplied: number[];\n}\n\n/** The whole derived answer: when it was observed, over which window, and one entry per declared class. */\nexport interface RetentionEnforcementFacts {\n readonly observedAt: string;\n readonly window: { readonly from: string; readonly to: string };\n readonly sweepIntervalMinutes: number;\n readonly runCount: number;\n readonly classes: RetentionClassEnforcement[];\n}\n\nconst sortedUnique = (values: Iterable<string>): string[] => [...new Set(values)].sort();\n\nconst isEnforcingOutcome = (record: RetentionEnforcementEvidenceRecord): boolean =>\n record.outcome === RetentionEnforcementOutcome.COMPLETED || record.outcome === RetentionEnforcementOutcome.DEFERRED_BY_CEILING;\n\nconst isPurgeEnforcedSkip = (record: RetentionEnforcementEvidenceRecord): boolean =>\n record.outcome === RetentionEnforcementOutcome.SKIPPED && record.skipReason === RetentionClassSweepSkipReason.ENFORCED_BY_TENANT_PURGE;\n\nconst sweptAtMs = (record: RetentionEnforcementEvidenceRecord): number => new Date(record.sweptAt).getTime();\n\n/**\n * Per declared class: ENFORCED, DECLARED or FAILING, from the records the sweep wrote.\n *\n * Pure over its inputs so the rule is pinned directly. `records` crossed a JSON boundary (the evidence door,\n * then the assurance repository), so `sweptAt` may arrive as a string; it is read either way.\n *\n * The decision per bound resource reads that resource's LATEST record in the window:\n * - FAILED → the resource is failing, and the class is FAILING whatever its other resources show;\n * - a non-failed outcome within the recent horizon → enforced (or enforced by the tenant purge);\n * - anything else (no record, or only an old one) → unevidenced, and the class reads DECLARED.\n * A class with no bound resource is DECLARED: nothing the sweep does applies to it.\n */\nexport function deriveRetentionEnforcementFacts(input: {\n readonly evidence: RetentionEnforcementEvidence;\n readonly schedule: ApplicationRetentionSchedule;\n readonly bindings: readonly RetentionEnforcementBindingInput[];\n /** The instant the evidence was observed — the window's end. \"Recent\" is measured back from here, never from the reader's clock. */\n readonly observedAt: Date;\n readonly sweepIntervalMs: number;\n}): RetentionEnforcementFacts {\n const recentSinceMs = input.observedAt.getTime() - RETENTION_ENFORCEMENT_RECENT_SWEEP_INTERVALS * input.sweepIntervalMs;\n const declaredClasses = (Object.keys(input.schedule) as DataRetentionClass[])\n .filter((dataClass) => input.schedule[dataClass] !== undefined)\n .sort();\n\n const classes = declaredClasses.map((dataClass): RetentionClassEnforcement => {\n const bound = sortedUnique(input.bindings.filter((binding) => binding.retentionBinding?.retentionClass === dataClass).map((binding) => binding.resourceType));\n const classRecords = input.evidence.records.filter((record) => record.retentionClass === dataClass);\n\n const enforced: string[] = [];\n const byPurge: string[] = [];\n const unevidenced: string[] = [];\n const failing: string[] = [];\n const latestHeldCounts: number[] = [];\n for (const resourceType of bound) {\n const latest = classRecords\n .filter((record) => record.resourceType === resourceType)\n .reduce<RetentionEnforcementEvidenceRecord | undefined>((best, record) => (best === undefined || sweptAtMs(record) > sweptAtMs(best) ? record : best), undefined);\n if (latest?.heldSkippedCount !== undefined) latestHeldCounts.push(latest.heldSkippedCount);\n if (latest?.outcome === RetentionEnforcementOutcome.FAILED) failing.push(resourceType);\n else if (latest !== undefined && sweptAtMs(latest) >= recentSinceMs && isEnforcingOutcome(latest)) enforced.push(resourceType);\n else if (latest !== undefined && sweptAtMs(latest) >= recentSinceMs && isPurgeEnforcedSkip(latest)) byPurge.push(resourceType);\n else unevidenced.push(resourceType);\n }\n\n const state = failing.length > 0\n ? RetentionEnforcementState.FAILING\n : enforced.length > 0 && unevidenced.length === 0\n ? RetentionEnforcementState.ENFORCED\n : RetentionEnforcementState.DECLARED;\n\n const latestSweptAtMs = classRecords.reduce((latest, record) => Math.max(latest, sweptAtMs(record)), Number.NEGATIVE_INFINITY);\n const periods = [...new Set(classRecords.map((record) => record.retentionDaysApplied).filter((days): days is number => days !== undefined))].sort((left, right) => left - right);\n\n return {\n dataClass,\n state,\n boundResourceTypes: bound,\n enforcedResourceTypes: enforced,\n enforcedByTenantPurgeResourceTypes: byPurge,\n unevidencedResourceTypes: unevidenced,\n failingResourceTypes: failing,\n ...(Number.isFinite(latestSweptAtMs) ? { latestSweptAt: new Date(latestSweptAtMs).toISOString() } : {}),\n deletedCountInWindow: classRecords.reduce((total, record) => total + record.deletedCount, 0),\n ...(latestHeldCounts.length > 0 ? { heldSkippedCountAtLatestRun: latestHeldCounts.reduce((total, count) => total + count, 0) } : {}),\n retentionDaysApplied: periods,\n };\n });\n\n return {\n observedAt: input.observedAt.toISOString(),\n window: { from: input.evidence.window.from, to: input.evidence.window.to },\n sweepIntervalMinutes: Math.round(input.sweepIntervalMs / 60_000),\n runCount: input.evidence.runCount,\n classes,\n };\n}\n"]}
@@ -0,0 +1,56 @@
1
+ import { type ApplicationProviderComplianceChoices, type OperatorRoleAllocation, type SubjectDataRecipientsDeclaration } from "@wildo-ai/saas-models";
2
+ import { type ApplicationProcessorRegister } from "./processor-register.schemas";
3
+ import type { RecipientDisclosure } from "./recipient-disclosures.schemas";
4
+ import { type RecipientPopulation } from "./recipient-population.schemas";
5
+ /**
6
+ * **The recipient list a running application states to a data subject** — derived here, once, from the application's
7
+ * committed declarations, and projected into the runtime by `wildo config subject-data-recipients` (#1710).
8
+ *
9
+ * Every input already exists and is already read by the companion and the evidence collector through these same
10
+ * functions: the recipient population (#1707), the #1709 disclosures, the processor register and the operator's
11
+ * compliance statement. This function only JOINS them into the shape the backend reads — so the recipients a privacy
12
+ * notice names, the recipients an evidence collector counts and the recipients a subject export lists are one list.
13
+ *
14
+ * - **Who**: every PROVIDER the disclosures name — operator sub-processors and tenant recipients. An operator-run or a
15
+ * declared-without-data-path member receives nothing and is not a recipient.
16
+ * - **Never a system of record.** A `systemsOfRecord` instance is maintained on its own lane: its erasure is accounted
17
+ * per bound resource by the HTTP_API erasure effects under the binding's declared D6 stance, and what it holds and
18
+ * supplies is the systems-of-record population's to state. Listing it here too would make two mechanisms answer for
19
+ * one system, maintained separately and free to disagree. {@link excludeSystemsOfRecord} is the guard.
20
+ * - **Identity**: the LEGAL entity and regions the operator's register adopted, for an operator-account recipient. A
21
+ * recipient the register has no entry for carries `null`, never the provider module's suggestion (Paul, 2026-09-25:
22
+ * vendor legal facts are suggestions adopted only by an operator commit). A tenant's own vendor is the tenant's to
23
+ * identify, so it carries `null` too.
24
+ * - **Erasure stance**: the vendor's declared stance on its compliance profile; otherwise the operator's acknowledged
25
+ * non-erasure on its compliance choice; otherwise `null` (the erasure reports UNMEASURED). A self-hosted choice does
26
+ * not reach here: it makes the member operator-run.
27
+ * - **Roles**: the operator's role allocations that name their resource types.
28
+ *
29
+ * Pure and report-only: it never refuses, and the output is validated against the runtime schema so a projection the
30
+ * backend would reject is caught where it is generated.
31
+ *
32
+ * @wildo_source:part:start saas.specifications.subject-data-recipients facet:layer:shared facet:audience:app-developer
33
+ */
34
+ export declare function deriveSubjectDataRecipients(inputs: {
35
+ readonly population: RecipientPopulation;
36
+ readonly disclosures: readonly RecipientDisclosure[];
37
+ readonly register: ApplicationProcessorRegister | undefined;
38
+ readonly providerComplianceChoices: ApplicationProviderComplianceChoices | undefined;
39
+ readonly roleAllocations: readonly OperatorRoleAllocation[] | undefined;
40
+ }): SubjectDataRecipientsDeclaration;
41
+ /**
42
+ * The guard that keeps systems of record out of the subject-data recipient list (see the function above). Exported so
43
+ * its one rule is pinned directly: a system-of-record member never becomes a recipient here, whatever it discloses.
44
+ */
45
+ export declare function excludeSystemsOfRecord(disclosures: readonly RecipientDisclosure[]): readonly RecipientDisclosure[];
46
+ /** Where the generated module lands in an application, relative to its root. */
47
+ export declare const SUBJECT_DATA_RECIPIENTS_GENERATED_RELATIVE_PATH = "backend-api/src/subject-data-recipients.generated.ts";
48
+ /** The constant the application's `saas-config.backend.ts` assigns to `compliance.subjectDataRecipients`. */
49
+ export declare const SUBJECT_DATA_RECIPIENTS_GENERATED_CONSTANT = "generatedSubjectDataRecipients";
50
+ /**
51
+ * Render the committed generated module. Pure, so it is pinned directly. The value is parsed at load, so a hand edit
52
+ * that breaks the runtime schema fails at startup instead of reaching an export as a recipient nobody declared.
53
+ */
54
+ export declare function renderSubjectDataRecipientsModule(declaration: SubjectDataRecipientsDeclaration): string;
55
+ /** @wildo_source:part:end saas.specifications.subject-data-recipients */
56
+ //# sourceMappingURL=subject-data-recipients.schemas.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"subject-data-recipients.schemas.d.ts","sourceRoot":"","sources":["../../../../../src/_core/compliance-documents/subject-data-recipients.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAKL,KAAK,oCAAoC,EACzC,KAAK,sBAAsB,EAG3B,KAAK,gCAAgC,EAEtC,MAAM,uBAAuB,CAAC;AAE/B,OAAO,EAA8B,KAAK,4BAA4B,EAAE,MAAM,8BAA8B,CAAC;AAC7G,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,iCAAiC,CAAC;AAC3E,OAAO,EAA2D,KAAK,mBAAmB,EAAE,MAAM,gCAAgC,CAAC;AAEnI;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AACH,wBAAgB,2BAA2B,CAAC,MAAM,EAAE;IAClD,QAAQ,CAAC,UAAU,EAAE,mBAAmB,CAAC;IACzC,QAAQ,CAAC,WAAW,EAAE,SAAS,mBAAmB,EAAE,CAAC;IACrD,QAAQ,CAAC,QAAQ,EAAE,4BAA4B,GAAG,SAAS,CAAC;IAC5D,QAAQ,CAAC,yBAAyB,EAAE,oCAAoC,GAAG,SAAS,CAAC;IACrF,QAAQ,CAAC,eAAe,EAAE,SAAS,sBAAsB,EAAE,GAAG,SAAS,CAAC;CACzE,GAAG,gCAAgC,CA4BnC;AAED;;;GAGG;AACH,wBAAgB,sBAAsB,CAAC,WAAW,EAAE,SAAS,mBAAmB,EAAE,GAAG,SAAS,mBAAmB,EAAE,CAElH;AAiBD,gFAAgF;AAChF,eAAO,MAAM,+CAA+C,yDAAyD,CAAC;AAEtH,6GAA6G;AAC7G,eAAO,MAAM,0CAA0C,mCAAmC,CAAC;AAE3F;;;GAGG;AACH,wBAAgB,iCAAiC,CAAC,WAAW,EAAE,gCAAgC,GAAG,MAAM,CAevG;AACD,yEAAyE"}
@@ -0,0 +1,100 @@
1
+ import { ProviderDeploymentModel, SubjectDataRecipientReach, SubjectDataRecipientsDeclarationSchema, establishedProviderComplianceProfile, HttpApiErasureStance, } from "@wildo-ai/saas-models";
2
+ import { ProcessorRegisterEntryKind } from "./processor-register.schemas.js";
3
+ import { RecipientPopulationClass, RecipientPopulationMemberKind } from "./recipient-population.schemas.js";
4
+ /**
5
+ * **The recipient list a running application states to a data subject** — derived here, once, from the application's
6
+ * committed declarations, and projected into the runtime by `wildo config subject-data-recipients` (#1710).
7
+ *
8
+ * Every input already exists and is already read by the companion and the evidence collector through these same
9
+ * functions: the recipient population (#1707), the #1709 disclosures, the processor register and the operator's
10
+ * compliance statement. This function only JOINS them into the shape the backend reads — so the recipients a privacy
11
+ * notice names, the recipients an evidence collector counts and the recipients a subject export lists are one list.
12
+ *
13
+ * - **Who**: every PROVIDER the disclosures name — operator sub-processors and tenant recipients. An operator-run or a
14
+ * declared-without-data-path member receives nothing and is not a recipient.
15
+ * - **Never a system of record.** A `systemsOfRecord` instance is maintained on its own lane: its erasure is accounted
16
+ * per bound resource by the HTTP_API erasure effects under the binding's declared D6 stance, and what it holds and
17
+ * supplies is the systems-of-record population's to state. Listing it here too would make two mechanisms answer for
18
+ * one system, maintained separately and free to disagree. {@link excludeSystemsOfRecord} is the guard.
19
+ * - **Identity**: the LEGAL entity and regions the operator's register adopted, for an operator-account recipient. A
20
+ * recipient the register has no entry for carries `null`, never the provider module's suggestion (Paul, 2026-09-25:
21
+ * vendor legal facts are suggestions adopted only by an operator commit). A tenant's own vendor is the tenant's to
22
+ * identify, so it carries `null` too.
23
+ * - **Erasure stance**: the vendor's declared stance on its compliance profile; otherwise the operator's acknowledged
24
+ * non-erasure on its compliance choice; otherwise `null` (the erasure reports UNMEASURED). A self-hosted choice does
25
+ * not reach here: it makes the member operator-run.
26
+ * - **Roles**: the operator's role allocations that name their resource types.
27
+ *
28
+ * Pure and report-only: it never refuses, and the output is validated against the runtime schema so a projection the
29
+ * backend would reject is caught where it is generated.
30
+ *
31
+ * @wildo_source:part:start saas.specifications.subject-data-recipients facet:layer:shared facet:audience:app-developer
32
+ */
33
+ export function deriveSubjectDataRecipients(inputs) {
34
+ const membersByRef = new Map(inputs.population.members.map((member) => [member.ref, member]));
35
+ const registerByProviderRef = new Map((inputs.register?.processors ?? [])
36
+ .flatMap((processor) => (processor.kind === ProcessorRegisterEntryKind.CONFIGURED_PROVIDER ? [[processor.providerRef, processor]] : [])));
37
+ const recipients = excludeSystemsOfRecord(inputs.disclosures).map((disclosure) => {
38
+ const reach = disclosure.populationClass === RecipientPopulationClass.TENANT_RECIPIENT
39
+ ? SubjectDataRecipientReach.TENANT_ACCOUNT
40
+ : SubjectDataRecipientReach.OPERATOR_ACCOUNT;
41
+ const registered = reach === SubjectDataRecipientReach.OPERATOR_ACCOUNT ? registerByProviderRef.get(disclosure.ref) : undefined;
42
+ return {
43
+ ref: disclosure.ref,
44
+ legalEntityName: registered?.legalEntityName ?? null,
45
+ processingRegions: [...(registered?.processingRegions ?? [])],
46
+ reach,
47
+ categories: [...disclosure.categories],
48
+ categoriesNotDerivable: [...disclosure.categoriesNotDerivable],
49
+ categoriesAreAFloor: disclosure.categoriesAreAFloor,
50
+ derivedFrom: [...disclosure.derivedFrom],
51
+ erasureStance: erasureStanceOf(disclosure.ref, membersByRef.get(disclosure.ref)?.complianceProfile ?? null, inputs.providerComplianceChoices),
52
+ };
53
+ }).sort((left, right) => left.ref.localeCompare(right.ref));
54
+ const roleAllocations = (inputs.roleAllocations ?? []).flatMap((allocation) => (allocation.resourceTypes === undefined ? [] : [{ role: allocation.role, resourceTypes: [...allocation.resourceTypes].sort() }]));
55
+ return SubjectDataRecipientsDeclarationSchema.parse({ recipients, roleAllocations });
56
+ }
57
+ /**
58
+ * The guard that keeps systems of record out of the subject-data recipient list (see the function above). Exported so
59
+ * its one rule is pinned directly: a system-of-record member never becomes a recipient here, whatever it discloses.
60
+ */
61
+ export function excludeSystemsOfRecord(disclosures) {
62
+ return disclosures.filter((disclosure) => disclosure.kind !== RecipientPopulationMemberKind.SYSTEM_OF_RECORD);
63
+ }
64
+ function erasureStanceOf(ref, profile, choices) {
65
+ const declared = establishedProviderComplianceProfile(profile)?.subjectErasure?.stance;
66
+ if (declared !== undefined)
67
+ return declared;
68
+ const choice = choices?.[ref];
69
+ // A self-hosted choice makes the member operator-run, which never reaches here; the guard keeps that true by construction.
70
+ if (choice?.subjectErasureAcknowledgement !== undefined && choice.deploymentModel !== ProviderDeploymentModel.SELF_HOSTED) {
71
+ return HttpApiErasureStance.CONTROLLER_ACKNOWLEDGED_NON_ERASURE;
72
+ }
73
+ return null;
74
+ }
75
+ /** Where the generated module lands in an application, relative to its root. */
76
+ export const SUBJECT_DATA_RECIPIENTS_GENERATED_RELATIVE_PATH = "backend-api/src/subject-data-recipients.generated.ts";
77
+ /** The constant the application's `saas-config.backend.ts` assigns to `compliance.subjectDataRecipients`. */
78
+ export const SUBJECT_DATA_RECIPIENTS_GENERATED_CONSTANT = "generatedSubjectDataRecipients";
79
+ /**
80
+ * Render the committed generated module. Pure, so it is pinned directly. The value is parsed at load, so a hand edit
81
+ * that breaks the runtime schema fails at startup instead of reaching an export as a recipient nobody declared.
82
+ */
83
+ export function renderSubjectDataRecipientsModule(declaration) {
84
+ return [
85
+ "import { SubjectDataRecipientsDeclarationSchema, type SubjectDataRecipientsDeclaration } from '@wildo-ai/saas-models';",
86
+ "",
87
+ "/**",
88
+ " * GENERATED by `wildo config subject-data-recipients`. DO NOT EDIT BY HAND — re-run it to regenerate.",
89
+ " *",
90
+ " * Who else holds a data subject's personal data (#1710): derived from the recipient population, the processor",
91
+ " * register, the declared flows and the operator's compliance statement. Composed into",
92
+ " * `compliance.subjectDataRecipients` by `saas-config.backend.ts`; a subject export lists these recipients and a",
93
+ " * subject erasure reports an outcome for each.",
94
+ " */",
95
+ `export const ${SUBJECT_DATA_RECIPIENTS_GENERATED_CONSTANT}: SubjectDataRecipientsDeclaration = SubjectDataRecipientsDeclarationSchema.parse(${JSON.stringify(declaration, null, 2)});`,
96
+ "",
97
+ ].join("\n");
98
+ }
99
+ /** @wildo_source:part:end saas.specifications.subject-data-recipients */
100
+ //# sourceMappingURL=subject-data-recipients.schemas.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"subject-data-recipients.schemas.js","sourceRoot":"","sources":["../../../../../src/_core/compliance-documents/subject-data-recipients.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,uBAAuB,EACvB,yBAAyB,EACzB,sCAAsC,EACtC,oCAAoC,EAMpC,oBAAoB,GACrB,MAAM,uBAAuB,CAAC;AAE/B,OAAO,EAAE,0BAA0B,EAAqC,MAAM,8BAA8B,CAAC;AAE7G,OAAO,EAAE,wBAAwB,EAAE,6BAA6B,EAA4B,MAAM,gCAAgC,CAAC;AAEnI;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA4BG;AACH,MAAM,UAAU,2BAA2B,CAAC,MAM3C;IACC,MAAM,YAAY,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,UAAU,CAAC,OAAO,CAAC,GAAG,CAAC,CAAC,MAAM,EAAE,EAAE,CAAC,CAAC,MAAM,CAAC,GAAG,EAAE,MAAM,CAAU,CAAC,CAAC,CAAC;IACvG,MAAM,qBAAqB,GAAG,IAAI,GAAG,CAAC,CAAC,MAAM,CAAC,QAAQ,EAAE,UAAU,IAAI,EAAE,CAAC;SACtE,OAAO,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,CAAC,SAAS,CAAC,IAAI,KAAK,0BAA0B,CAAC,mBAAmB,CAAC,CAAC,CAAC,CAAC,CAAC,SAAS,CAAC,WAAW,EAAE,SAAS,CAAU,CAAC,CAAC,CA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C;IAC7F,OAAO;QACL,wHAAwH;QACxH,EAAE;QACF,KAAK;QACL,wGAAwG;QACxG,IAAI;QACJ,gHAAgH;QAChH,wFAAwF;QACxF,kHAAkH;QAClH,iDAAiD;QACjD,KAAK;QACL,gBAAgB,0CAA0C,qFAAqF,IAAI,CAAC,SAAS,CAAC,WAAW,EAAE,IAAI,EAAE,CAAC,CAAC,IAAI;QACvL,EAAE;KACH,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC;AACf,CAAC;AACD,yEAAyE","sourcesContent":["import {\n ProviderDeploymentModel,\n SubjectDataRecipientReach,\n SubjectDataRecipientsDeclarationSchema,\n establishedProviderComplianceProfile,\n type ApplicationProviderComplianceChoices,\n type OperatorRoleAllocation,\n type ProviderComplianceProfile,\n type SubjectDataRecipient,\n type SubjectDataRecipientsDeclaration,\n HttpApiErasureStance,\n} from \"@wildo-ai/saas-models\";\n\nimport { ProcessorRegisterEntryKind, type ApplicationProcessorRegister } from \"./processor-register.schemas\";\nimport type { RecipientDisclosure } from \"./recipient-disclosures.schemas\";\nimport { RecipientPopulationClass, RecipientPopulationMemberKind, type RecipientPopulation } from \"./recipient-population.schemas\";\n\n/**\n * **The recipient list a running application states to a data subject** — derived here, once, from the application's\n * committed declarations, and projected into the runtime by `wildo config subject-data-recipients` (#1710).\n *\n * Every input already exists and is already read by the companion and the evidence collector through these same\n * functions: the recipient population (#1707), the #1709 disclosures, the processor register and the operator's\n * compliance statement. This function only JOINS them into the shape the backend reads — so the recipients a privacy\n * notice names, the recipients an evidence collector counts and the recipients a subject export lists are one list.\n *\n * - **Who**: every PROVIDER the disclosures name — operator sub-processors and tenant recipients. An operator-run or a\n * declared-without-data-path member receives nothing and is not a recipient.\n * - **Never a system of record.** A `systemsOfRecord` instance is maintained on its own lane: its erasure is accounted\n * per bound resource by the HTTP_API erasure effects under the binding's declared D6 stance, and what it holds and\n * supplies is the systems-of-record population's to state. Listing it here too would make two mechanisms answer for\n * one system, maintained separately and free to disagree. {@link excludeSystemsOfRecord} is the guard.\n * - **Identity**: the LEGAL entity and regions the operator's register adopted, for an operator-account recipient. A\n * recipient the register has no entry for carries `null`, never the provider module's suggestion (Paul, 2026-09-25:\n * vendor legal facts are suggestions adopted only by an operator commit). A tenant's own vendor is the tenant's to\n * identify, so it carries `null` too.\n * - **Erasure stance**: the vendor's declared stance on its compliance profile; otherwise the operator's acknowledged\n * non-erasure on its compliance choice; otherwise `null` (the erasure reports UNMEASURED). A self-hosted choice does\n * not reach here: it makes the member operator-run.\n * - **Roles**: the operator's role allocations that name their resource types.\n *\n * Pure and report-only: it never refuses, and the output is validated against the runtime schema so a projection the\n * backend would reject is caught where it is generated.\n *\n * @wildo_source:part:start saas.specifications.subject-data-recipients facet:layer:shared facet:audience:app-developer\n */\nexport function deriveSubjectDataRecipients(inputs: {\n readonly population: RecipientPopulation;\n readonly disclosures: readonly RecipientDisclosure[];\n readonly register: ApplicationProcessorRegister | undefined;\n readonly providerComplianceChoices: ApplicationProviderComplianceChoices | undefined;\n readonly roleAllocations: readonly OperatorRoleAllocation[] | undefined;\n}): SubjectDataRecipientsDeclaration {\n const membersByRef = new Map(inputs.population.members.map((member) => [member.ref, member] as const));\n const registerByProviderRef = new Map((inputs.register?.processors ?? [])\n .flatMap((processor) => (processor.kind === ProcessorRegisterEntryKind.CONFIGURED_PROVIDER ? [[processor.providerRef, processor] as const] : [])));\n\n const recipients = excludeSystemsOfRecord(inputs.disclosures).map((disclosure): SubjectDataRecipient => {\n const reach = disclosure.populationClass === RecipientPopulationClass.TENANT_RECIPIENT\n ? SubjectDataRecipientReach.TENANT_ACCOUNT\n : SubjectDataRecipientReach.OPERATOR_ACCOUNT;\n const registered = reach === SubjectDataRecipientReach.OPERATOR_ACCOUNT ? registerByProviderRef.get(disclosure.ref) : undefined;\n return {\n ref: disclosure.ref,\n legalEntityName: registered?.legalEntityName ?? null,\n processingRegions: [...(registered?.processingRegions ?? [])],\n reach,\n categories: [...disclosure.categories],\n categoriesNotDerivable: [...disclosure.categoriesNotDerivable],\n categoriesAreAFloor: disclosure.categoriesAreAFloor,\n derivedFrom: [...disclosure.derivedFrom],\n erasureStance: erasureStanceOf(disclosure.ref, membersByRef.get(disclosure.ref)?.complianceProfile ?? null, inputs.providerComplianceChoices),\n };\n }).sort((left, right) => left.ref.localeCompare(right.ref));\n\n const roleAllocations = (inputs.roleAllocations ?? []).flatMap((allocation) => (\n allocation.resourceTypes === undefined ? [] : [{ role: allocation.role, resourceTypes: [...allocation.resourceTypes].sort() }]\n ));\n\n return SubjectDataRecipientsDeclarationSchema.parse({ recipients, roleAllocations });\n}\n\n/**\n * The guard that keeps systems of record out of the subject-data recipient list (see the function above). Exported so\n * its one rule is pinned directly: a system-of-record member never becomes a recipient here, whatever it discloses.\n */\nexport function excludeSystemsOfRecord(disclosures: readonly RecipientDisclosure[]): readonly RecipientDisclosure[] {\n return disclosures.filter((disclosure) => disclosure.kind !== RecipientPopulationMemberKind.SYSTEM_OF_RECORD);\n}\n\nfunction erasureStanceOf(\n ref: string,\n profile: ProviderComplianceProfile | null,\n choices: ApplicationProviderComplianceChoices | undefined,\n): HttpApiErasureStance | null {\n const declared = establishedProviderComplianceProfile(profile)?.subjectErasure?.stance;\n if (declared !== undefined) return declared;\n const choice = choices?.[ref];\n // A self-hosted choice makes the member operator-run, which never reaches here; the guard keeps that true by construction.\n if (choice?.subjectErasureAcknowledgement !== undefined && choice.deploymentModel !== ProviderDeploymentModel.SELF_HOSTED) {\n return HttpApiErasureStance.CONTROLLER_ACKNOWLEDGED_NON_ERASURE;\n }\n return null;\n}\n\n/** Where the generated module lands in an application, relative to its root. */\nexport const SUBJECT_DATA_RECIPIENTS_GENERATED_RELATIVE_PATH = \"backend-api/src/subject-data-recipients.generated.ts\";\n\n/** The constant the application's `saas-config.backend.ts` assigns to `compliance.subjectDataRecipients`. */\nexport const SUBJECT_DATA_RECIPIENTS_GENERATED_CONSTANT = \"generatedSubjectDataRecipients\";\n\n/**\n * Render the committed generated module. Pure, so it is pinned directly. The value is parsed at load, so a hand edit\n * that breaks the runtime schema fails at startup instead of reaching an export as a recipient nobody declared.\n */\nexport function renderSubjectDataRecipientsModule(declaration: SubjectDataRecipientsDeclaration): string {\n return [\n \"import { SubjectDataRecipientsDeclarationSchema, type SubjectDataRecipientsDeclaration } from '@wildo-ai/saas-models';\",\n \"\",\n \"/**\",\n \" * GENERATED by `wildo config subject-data-recipients`. DO NOT EDIT BY HAND — re-run it to regenerate.\",\n \" *\",\n \" * Who else holds a data subject's personal data (#1710): derived from the recipient population, the processor\",\n \" * register, the declared flows and the operator's compliance statement. Composed into\",\n \" * `compliance.subjectDataRecipients` by `saas-config.backend.ts`; a subject export lists these recipients and a\",\n \" * subject erasure reports an outcome for each.\",\n \" */\",\n `export const ${SUBJECT_DATA_RECIPIENTS_GENERATED_CONSTANT}: SubjectDataRecipientsDeclaration = SubjectDataRecipientsDeclarationSchema.parse(${JSON.stringify(declaration, null, 2)});`,\n \"\",\n ].join(\"\\n\");\n}\n/** @wildo_source:part:end saas.specifications.subject-data-recipients */\n"]}
@@ -17,7 +17,14 @@ export function buildCompositeViewSpecificationMap(...specifications) {
17
17
  return result;
18
18
  }
19
19
  const COMPOSITE_VIEW_REQUIRED_TEXT_SLOTS = ['title', 'description'];
20
- const COMPOSITE_SECTION_REQUIRED_TEXT_SLOTS = ['title', 'description'];
20
+ /**
21
+ * A composite SECTION's description is optional (since 2026-09-25), the same decision as a resource
22
+ * layout section's — see `RESOURCE_LAYOUT_REQUIRED_TEXT_SLOTS`. Documented, it is generated and shown;
23
+ * left out, nothing is generated and the runtime renders nothing (`tCompositeViewSection(…,
24
+ * 'description')` answers '' on a miss). Requiring it made every section carry a sub-heading that
25
+ * restated its title ("Supporting Tasks — Tasks that support this todo").
26
+ */
27
+ const COMPOSITE_SECTION_REQUIRED_TEXT_SLOTS = ['title'];
21
28
  function validateCompositeViewSpecification(viewDefinition, specification) {
22
29
  validateRequiredTextSlots(`composite "${viewDefinition.translationRef}"`, specification.textSlots, COMPOSITE_VIEW_REQUIRED_TEXT_SLOTS);
23
30
  const documentedSectionRefs = Object.keys(specification.sections ?? {});
@@ -1 +1 @@
1
- {"version":3,"file":"composite-view-specification.schemas.js","sourceRoot":"","sources":["../../../../src/_core/composite-view-specification.schemas.ts"],"names":[],"mappings":"AAmFA,MAAM,UAAU,wCAAwC,CACtD,cAA8C,EAC9C,oBAA2D;IAE3D,MAAM,aAAa,GAAqC;QACtD,cAAc,EAAE,cAAc,CAAC,cAAc;QAC7C,GAAG,oBAAoB,EAAE;KAC1B,CAAC;IAEF,kCAAkC,CAAC,cAAc,EAAE,aAAa,CAAC,CAAC;IAElE,OAAO,aAAa,CAAC;AACvB,CAAC;AAED,MAAM,UAAU,kCAAkC,CAChD,GAAG,cAAkD;IAErD,MAAM,MAAM,GAA+B,EAAE,CAAC;IAE9C,KAAK,MAAM,aAAa,IAAI,cAAc,EAAE,CAAC;QAC3C,IAAI,MAAM,CAAC,aAAa,CAAC,cAAc,CAAC,EAAE,CAAC;YACzC,MAAM,IAAI,KAAK,CACb,6EAA6E,aAAa,CAAC,cAAc,IAAI,CAC9G,CAAC;QACJ,CAAC;QACD,MAAM,CAAC,aAAa,CAAC,cAAc,CAAC,GAAG,aAAa,CAAC;IACvD,CAAC;IAED,OAAO,MAAM,CAAC;AAChB,CAAC;AAED,MAAM,kCAAkC,GAAG,CAAC,OAAO,EAAE,aAAa,CAAC,CAAC;AACpE,MAAM,qCAAqC,GAAG,CAAC,OAAO,EAAE,aAAa,CAAC,CAAC;AAEvE,SAAS,kCAAkC,CACzC,cAA8C,EAC9C,aAA+C;IAE/C,yBAAyB,CACvB,cAAc,cAAc,CAAC,cAAc,GAAG,EAC9C,aAAa,CAAC,SAAS,EACvB,kCAAkC,CACnC,CAAC;IACF,MAAM,qBAAqB,GAAG,MAAM,CAAC,IAAI,CAAC,aAAa,CAAC,QAAQ,IAAI,EAAE,CAAC,CAAC;IACxE,MAAM,mBAAmB,GAAG,IAAI,GAAG,CAAC,cA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AC;IACH,CAAC;IACD,yBAAyB,CACvB,cAAc,cAAc,CAAC,cAAc,UAAU,EACrD,aAAa,CAAC,MAAM,EACpB,CAAC,GAAG,iBAAiB,CAAC,CACvB,CAAC;IAEF,KAAK,MAAM,CAAC,UAAU,EAAE,oBAAoB,CAAC,IAAI,MAAM,CAAC,OAAO,CAAC,aAAa,CAAC,QAAQ,IAAI,EAAE,CAAC,EAAE,CAAC;QAC9F,yBAAyB,CACvB,cAAc,cAAc,CAAC,cAAc,cAAc,UAAU,GAAG,EACtE,oBAAoB,CAAC,SAAS,EAC9B,qCAAqC,CACtC,CAAC;IACJ,CAAC;AACH,CAAC;AAED,SAAS,yBAAyB,CAChC,OAAe,EACf,mBAAgE,EAChE,iBAA2B;IAE3B,MAAM,cAAc,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,mBAAmB,IAAI,EAAE,CAAC,CAAC,CAAC;IACvE,KAAK,MAAM,WAAW,IAAI,iBAAiB,EAAE,CAAC;QAC5C,IAAI,CAAC,cAAc,CAAC,GAAG,CAAC,WAAW,CAAC,EAAE,CAAC;YACrC,MAAM,IAAI,KAAK,CACb,+CAA+C,OAAO,6BAA6B,WAAW,+DAA+D,CAC9J,CAAC;QACJ,CAAC;IACH,CAAC;AACH,CAAC","sourcesContent":["import type { SpecificationOwnerRef } from './definition-specification.schemas';\nimport type {\n StructuralTranslationSlotSpecification,\n TranslationSlotSpecificationMap,\n} from './translation-slot-specification.schemas';\n\ninterface PublicCodeSymbolRef {\n packageName: string;\n exportName: string;\n /**\n * PUBLIC SUBPATH only — a subpath the owning package declares in\n * `package.json#exports`, so `${packageName}/${importPath}` resolves. For a module\n * that has no public door, author `filePathHint` instead (issue #150).\n */\n importPath?: string;\n /**\n * MODULE LOCATION inside the owning package — a navigation aid, never concatenated\n * onto `packageName`. See `CodeSymbolRef` in `@wildo-ai/zod-decorators` for the\n * canonical contract this narrows.\n */\n filePathHint?: string;\n}\n\ninterface CompositeViewDefinitionSpecRef {\n translationRef: string;\n sectionRefs?: string[];\n /** The view's own declared label refs (`labels` on the authored definition). */\n labels?: ReadonlyArray<{ ref: string }>;\n}\n\n/**\n * @wildo_source:part:start saas.specifications.composite-view-specification facet:layer:specification facet:family:views\n *\n * Composite view semantic overlay: `codeHandling`, section/translation slots, and keyed `CompositeViewSpecification` map.\n */\nexport interface CompositeViewSpecificationCodeHandling {\n /** Module/application owner that authored the view. */\n definitionOwner?: SpecificationOwnerRef;\n /** Public symbol exposing the authored composite view component. */\n viewComponentSymbol?: PublicCodeSymbolRef;\n /** Public declarations where the composite view is wired into runtime registries. */\n declarationSymbols?: PublicCodeSymbolRef[];\n /** Extra caveats for coding/transposition consumers. */\n notes?: string[];\n}\n\nexport interface CompositeViewSpecificationConfig {\n /** Stable runtime translation identity for this composite surface. */\n translationRef: string;\n /** Why this composite surface exists from a product/workflow perspective. */\n purpose: string;\n /** Interaction role this composite plays in the surrounding UX. */\n uiRole: string;\n /** Situations where this composite surface is the right destination. */\n useWhen?: string;\n /** Situations where another surface should be preferred. */\n avoidWhen?: string;\n /** Meaning of the composite-view-level translatable slots. */\n textSlots?: TranslationSlotSpecificationMap;\n /** Meaning of each declared section inside the composite. */\n sections?: Record<string, StructuralTranslationSlotSpecification>;\n /**\n * Meaning of each label the view DECLARES for its own text (`labels` on the authored definition) —\n * the captions, KPI names and failure sentences its component renders beyond the title,\n * description and section headings.\n *\n * Keyed by the declared label ref. Without it the generator words a label from its bare ref, and\n * a ref is an identifier, not a meaning: `stat_in_flight` was generated as \"In progress\" — the\n * words of one status — for a tile that counts two. Validated like `sections`, both directions.\n */\n labels?: TranslationSlotSpecificationMap;\n /** Additional domain constraints that matter beyond raw runtime structure. */\n businessConstraints?: string[];\n /** Import-oriented coding/transposition metadata. */\n codeHandling?: CompositeViewSpecificationCodeHandling;\n}\n\n/** Keyed by the stable runtime translation identity (for example `app.foo`). */\nexport type CompositeViewSpecification = Record<string, CompositeViewSpecificationConfig>;\n/** @wildo_source:part:end saas.specifications.composite-view-specification */\n\nexport type CompositeViewSpecificationDraft = Omit<CompositeViewSpecificationConfig, 'translationRef'>;\n\nexport function compositeViewSpecificationFromDefinition(\n viewDefinition: CompositeViewDefinitionSpecRef,\n specificationFactory: () => CompositeViewSpecificationDraft,\n): CompositeViewSpecificationConfig {\n const specification: CompositeViewSpecificationConfig = {\n translationRef: viewDefinition.translationRef,\n ...specificationFactory(),\n };\n\n validateCompositeViewSpecification(viewDefinition, specification);\n\n return specification;\n}\n\nexport function buildCompositeViewSpecificationMap(\n ...specifications: CompositeViewSpecificationConfig[]\n): CompositeViewSpecification {\n const result: CompositeViewSpecification = {};\n\n for (const specification of specifications) {\n if (result[specification.translationRef]) {\n throw new Error(\n `buildCompositeViewSpecificationMap(): duplicate composite translationRef \"${specification.translationRef}\".`,\n );\n }\n result[specification.translationRef] = specification;\n }\n\n return result;\n}\n\nconst COMPOSITE_VIEW_REQUIRED_TEXT_SLOTS = ['title', 'description'];\nconst COMPOSITE_SECTION_REQUIRED_TEXT_SLOTS = ['title', 'description'];\n\nfunction validateCompositeViewSpecification(\n viewDefinition: CompositeViewDefinitionSpecRef,\n specification: CompositeViewSpecificationConfig,\n): void {\n validateRequiredTextSlots(\n `composite \"${viewDefinition.translationRef}\"`,\n specification.textSlots,\n COMPOSITE_VIEW_REQUIRED_TEXT_SLOTS,\n );\n const documentedSectionRefs = Object.keys(specification.sections ?? {});\n const declaredSectionRefs = new Set(viewDefinition.sectionRefs ?? []);\n\n for (const sectionRef of documentedSectionRefs) {\n if (!declaredSectionRefs.has(sectionRef)) {\n throw new Error(\n `compositeViewSpecificationFromDefinition(): composite \"${viewDefinition.translationRef}\" documents section \"${sectionRef}\" but the authored view definition does not declare it.`,\n );\n }\n }\n\n for (const sectionRef of declaredSectionRefs) {\n if (!documentedSectionRefs.includes(sectionRef)) {\n throw new Error(\n `compositeViewSpecificationFromDefinition(): composite \"${viewDefinition.translationRef}\" declares section \"${sectionRef}\" in the authored view definition but the semantic specification does not document it.`,\n );\n }\n }\n\n const documentedLabelRefs = Object.keys(specification.labels ?? {});\n const declaredLabelRefs = new Set((viewDefinition.labels ?? []).map((label) => label.ref));\n for (const labelRef of documentedLabelRefs) {\n if (!declaredLabelRefs.has(labelRef)) {\n throw new Error(\n `compositeViewSpecificationFromDefinition(): composite \"${viewDefinition.translationRef}\" documents label \"${labelRef}\" but the authored view definition does not declare it, so nothing would ever read it.`,\n );\n }\n }\n for (const labelRef of declaredLabelRefs) {\n if (!documentedLabelRefs.includes(labelRef)) {\n throw new Error(\n `compositeViewSpecificationFromDefinition(): composite \"${viewDefinition.translationRef}\" declares label \"${labelRef}\" but the semantic specification does not document it, so its words would be generated from the bare ref.`,\n );\n }\n }\n validateRequiredTextSlots(\n `composite \"${viewDefinition.translationRef}\" labels`,\n specification.labels,\n [...declaredLabelRefs],\n );\n\n for (const [sectionRef, sectionSpecification] of Object.entries(specification.sections ?? {})) {\n validateRequiredTextSlots(\n `composite \"${viewDefinition.translationRef}\" section \"${sectionRef}\"`,\n sectionSpecification.textSlots,\n COMPOSITE_SECTION_REQUIRED_TEXT_SLOTS,\n );\n }\n}\n\nfunction validateRequiredTextSlots(\n subject: string,\n documentedTextSlots: TranslationSlotSpecificationMap | undefined,\n requiredTextSlots: string[],\n): void {\n const knownTextSlots = new Set(Object.keys(documentedTextSlots ?? {}));\n for (const textSlotKey of requiredTextSlots) {\n if (!knownTextSlots.has(textSlotKey)) {\n throw new Error(\n `compositeViewSpecificationFromDefinition(): ${subject} must document text slot \"${textSlotKey}\" so the generated labelling keys stay semantically grounded.`,\n );\n }\n }\n}\n"]}
1
+ {"version":3,"file":"composite-view-specification.schemas.js","sourceRoot":"","sources":["../../../../src/_core/composite-view-specification.schemas.ts"],"names":[],"mappings":"AAmFA,MAAM,UAAU,wCAAwC,CACtD,cAA8C,EAC9C,oBAA2D;IAE3D,MAAM,aAAa,GAAqC;QACtD,cAAc,EAAE,cAAc,CAAC,cAAc;QAC7C,GAAG,oBAAoB,EAAE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EACtE,oBAAoB,CAAC,SAAS,EAC9B,qCAAqC,CACtC,CAAC;IACJ,CAAC;AACH,CAAC;AAED,SAAS,yBAAyB,CAChC,OAAe,EACf,mBAAgE,EAChE,iBAA2B;IAE3B,MAAM,cAAc,GAAG,IAAI,GAAG,CAAC,MAAM,CAAC,IAAI,CAAC,mBAAmB,IAAI,EAAE,CAAC,CAAC,CAAC;IACvE,KAAK,MAAM,WAAW,IAAI,iBAAiB,EAAE,CAAC;QAC5C,IAAI,CAAC,cAAc,CAAC,GAAG,CAAC,WAAW,CAAC,EAAE,CAAC;YACrC,MAAM,IAAI,KAAK,CACb,+CAA+C,OAAO,6BAA6B,WAAW,+DAA+D,CAC9J,CAAC;QACJ,CAAC;IACH,CAAC;AACH,CAAC","sourcesContent":["import type { SpecificationOwnerRef } from './definition-specification.schemas';\nimport type {\n StructuralTranslationSlotSpecification,\n TranslationSlotSpecificationMap,\n} from './translation-slot-specification.schemas';\n\ninterface PublicCodeSymbolRef {\n packageName: string;\n exportName: string;\n /**\n * PUBLIC SUBPATH only — a subpath the owning package declares in\n * `package.json#exports`, so `${packageName}/${importPath}` resolves. For a module\n * that has no public door, author `filePathHint` instead (issue #150).\n */\n importPath?: string;\n /**\n * MODULE LOCATION inside the owning package — a navigation aid, never concatenated\n * onto `packageName`. See `CodeSymbolRef` in `@wildo-ai/zod-decorators` for the\n * canonical contract this narrows.\n */\n filePathHint?: string;\n}\n\ninterface CompositeViewDefinitionSpecRef {\n translationRef: string;\n sectionRefs?: string[];\n /** The view's own declared label refs (`labels` on the authored definition). */\n labels?: ReadonlyArray<{ ref: string }>;\n}\n\n/**\n * @wildo_source:part:start saas.specifications.composite-view-specification facet:layer:specification facet:family:views\n *\n * Composite view semantic overlay: `codeHandling`, section/translation slots, and keyed `CompositeViewSpecification` map.\n */\nexport interface CompositeViewSpecificationCodeHandling {\n /** Module/application owner that authored the view. */\n definitionOwner?: SpecificationOwnerRef;\n /** Public symbol exposing the authored composite view component. */\n viewComponentSymbol?: PublicCodeSymbolRef;\n /** Public declarations where the composite view is wired into runtime registries. */\n declarationSymbols?: PublicCodeSymbolRef[];\n /** Extra caveats for coding/transposition consumers. */\n notes?: string[];\n}\n\nexport interface CompositeViewSpecificationConfig {\n /** Stable runtime translation identity for this composite surface. */\n translationRef: string;\n /** Why this composite surface exists from a product/workflow perspective. */\n purpose: string;\n /** Interaction role this composite plays in the surrounding UX. */\n uiRole: string;\n /** Situations where this composite surface is the right destination. */\n useWhen?: string;\n /** Situations where another surface should be preferred. */\n avoidWhen?: string;\n /** Meaning of the composite-view-level translatable slots. */\n textSlots?: TranslationSlotSpecificationMap;\n /** Meaning of each declared section inside the composite. */\n sections?: Record<string, StructuralTranslationSlotSpecification>;\n /**\n * Meaning of each label the view DECLARES for its own text (`labels` on the authored definition) —\n * the captions, KPI names and failure sentences its component renders beyond the title,\n * description and section headings.\n *\n * Keyed by the declared label ref. Without it the generator words a label from its bare ref, and\n * a ref is an identifier, not a meaning: `stat_in_flight` was generated as \"In progress\" — the\n * words of one status — for a tile that counts two. Validated like `sections`, both directions.\n */\n labels?: TranslationSlotSpecificationMap;\n /** Additional domain constraints that matter beyond raw runtime structure. */\n businessConstraints?: string[];\n /** Import-oriented coding/transposition metadata. */\n codeHandling?: CompositeViewSpecificationCodeHandling;\n}\n\n/** Keyed by the stable runtime translation identity (for example `app.foo`). */\nexport type CompositeViewSpecification = Record<string, CompositeViewSpecificationConfig>;\n/** @wildo_source:part:end saas.specifications.composite-view-specification */\n\nexport type CompositeViewSpecificationDraft = Omit<CompositeViewSpecificationConfig, 'translationRef'>;\n\nexport function compositeViewSpecificationFromDefinition(\n viewDefinition: CompositeViewDefinitionSpecRef,\n specificationFactory: () => CompositeViewSpecificationDraft,\n): CompositeViewSpecificationConfig {\n const specification: CompositeViewSpecificationConfig = {\n translationRef: viewDefinition.translationRef,\n ...specificationFactory(),\n };\n\n validateCompositeViewSpecification(viewDefinition, specification);\n\n return specification;\n}\n\nexport function buildCompositeViewSpecificationMap(\n ...specifications: CompositeViewSpecificationConfig[]\n): CompositeViewSpecification {\n const result: CompositeViewSpecification = {};\n\n for (const specification of specifications) {\n if (result[specification.translationRef]) {\n throw new Error(\n `buildCompositeViewSpecificationMap(): duplicate composite translationRef \"${specification.translationRef}\".`,\n );\n }\n result[specification.translationRef] = specification;\n }\n\n return result;\n}\n\nconst COMPOSITE_VIEW_REQUIRED_TEXT_SLOTS = ['title', 'description'];\n/**\n * A composite SECTION's description is optional (since 2026-09-25), the same decision as a resource\n * layout section's — see `RESOURCE_LAYOUT_REQUIRED_TEXT_SLOTS`. Documented, it is generated and shown;\n * left out, nothing is generated and the runtime renders nothing (`tCompositeViewSection(…,\n * 'description')` answers '' on a miss). Requiring it made every section carry a sub-heading that\n * restated its title (\"Supporting Tasks — Tasks that support this todo\").\n */\nconst COMPOSITE_SECTION_REQUIRED_TEXT_SLOTS = ['title'];\n\nfunction validateCompositeViewSpecification(\n viewDefinition: CompositeViewDefinitionSpecRef,\n specification: CompositeViewSpecificationConfig,\n): void {\n validateRequiredTextSlots(\n `composite \"${viewDefinition.translationRef}\"`,\n specification.textSlots,\n COMPOSITE_VIEW_REQUIRED_TEXT_SLOTS,\n );\n const documentedSectionRefs = Object.keys(specification.sections ?? {});\n const declaredSectionRefs = new Set(viewDefinition.sectionRefs ?? []);\n\n for (const sectionRef of documentedSectionRefs) {\n if (!declaredSectionRefs.has(sectionRef)) {\n throw new Error(\n `compositeViewSpecificationFromDefinition(): composite \"${viewDefinition.translationRef}\" documents section \"${sectionRef}\" but the authored view definition does not declare it.`,\n );\n }\n }\n\n for (const sectionRef of declaredSectionRefs) {\n if (!documentedSectionRefs.includes(sectionRef)) {\n throw new Error(\n `compositeViewSpecificationFromDefinition(): composite \"${viewDefinition.translationRef}\" declares section \"${sectionRef}\" in the authored view definition but the semantic specification does not document it.`,\n );\n }\n }\n\n const documentedLabelRefs = Object.keys(specification.labels ?? {});\n const declaredLabelRefs = new Set((viewDefinition.labels ?? []).map((label) => label.ref));\n for (const labelRef of documentedLabelRefs) {\n if (!declaredLabelRefs.has(labelRef)) {\n throw new Error(\n `compositeViewSpecificationFromDefinition(): composite \"${viewDefinition.translationRef}\" documents label \"${labelRef}\" but the authored view definition does not declare it, so nothing would ever read it.`,\n );\n }\n }\n for (const labelRef of declaredLabelRefs) {\n if (!documentedLabelRefs.includes(labelRef)) {\n throw new Error(\n `compositeViewSpecificationFromDefinition(): composite \"${viewDefinition.translationRef}\" declares label \"${labelRef}\" but the semantic specification does not document it, so its words would be generated from the bare ref.`,\n );\n }\n }\n validateRequiredTextSlots(\n `composite \"${viewDefinition.translationRef}\" labels`,\n specification.labels,\n [...declaredLabelRefs],\n );\n\n for (const [sectionRef, sectionSpecification] of Object.entries(specification.sections ?? {})) {\n validateRequiredTextSlots(\n `composite \"${viewDefinition.translationRef}\" section \"${sectionRef}\"`,\n sectionSpecification.textSlots,\n COMPOSITE_SECTION_REQUIRED_TEXT_SLOTS,\n );\n }\n}\n\nfunction validateRequiredTextSlots(\n subject: string,\n documentedTextSlots: TranslationSlotSpecificationMap | undefined,\n requiredTextSlots: string[],\n): void {\n const knownTextSlots = new Set(Object.keys(documentedTextSlots ?? {}));\n for (const textSlotKey of requiredTextSlots) {\n if (!knownTextSlots.has(textSlotKey)) {\n throw new Error(\n `compositeViewSpecificationFromDefinition(): ${subject} must document text slot \"${textSlotKey}\" so the generated labelling keys stay semantically grounded.`,\n );\n }\n }\n}\n"]}
@@ -8,8 +8,9 @@ export declare enum DomainPlanResourceRole {
8
8
  /**
9
9
  * ONE DOMAIN-PLAN RESOURCE, as the aspect registry projects it (#1482).
10
10
  *
11
- * A derived row, and the only one in the registry — see `deriveItems` on the declaration below for
12
- * why deriving beat reshaping the family. It carries nothing the committed file does not: the
11
+ * A derived row, the registry's first — see `deriveItems` on the declaration below for why deriving beat
12
+ * reshaping the family. (Not its only one: `assurance-program` obligation entries and governed-document
13
+ * sections are derived the same way.) It carries nothing the committed file does not: the
13
14
  * resource NAME as authored, the module that lists it, and which of the module's two lists it came
14
15
  * from. `resourceRef` is the authored string itself, so a referrer resolves against exactly what it
15
16
  * was written with.
@@ -1 +1 @@
1
- {"version":3,"file":"domain-plan.family-aspects.d.ts","sourceRoot":"","sources":["../../../../../src/_core/domain-plan/domain-plan.family-aspects.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,2BAA2B,CAAC;AAK1E,qFAAqF;AACrF,oBAAY,sBAAsB;IAChC,IAAI,SAAS;IACb,UAAU,eAAe;CAC1B;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,kCAAkC;;;;iBAI7C,CAAC;AACH,MAAM,MAAM,4BAA4B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kCAAkC,CAAC,CAAC;AAE9F;;;;;;;GAOG;AACH,wBAAgB,0BAA0B,CAAC,MAAM,EAAE,OAAO,GAAG,SAAS,4BAA4B,EAAE,CAmBnG;AAED,eAAO,MAAM,0BAA0B,EAAE,wBAiExC,CAAC"}
1
+ {"version":3,"file":"domain-plan.family-aspects.d.ts","sourceRoot":"","sources":["../../../../../src/_core/domain-plan/domain-plan.family-aspects.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,KAAK,EAAE,wBAAwB,EAAE,MAAM,2BAA2B,CAAC;AAK1E,qFAAqF;AACrF,oBAAY,sBAAsB;IAChC,IAAI,SAAS;IACb,UAAU,eAAe;CAC1B;AAED;;;;;;;;;GASG;AACH,eAAO,MAAM,kCAAkC;;;;iBAI7C,CAAC;AACH,MAAM,MAAM,4BAA4B,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,kCAAkC,CAAC,CAAC;AAE9F;;;;;;;GAOG;AACH,wBAAgB,0BAA0B,CAAC,MAAM,EAAE,OAAO,GAAG,SAAS,4BAA4B,EAAE,CAmBnG;AAED,eAAO,MAAM,0BAA0B,EAAE,wBAiExC,CAAC"}
@@ -12,8 +12,9 @@ export var DomainPlanResourceRole;
12
12
  /**
13
13
  * ONE DOMAIN-PLAN RESOURCE, as the aspect registry projects it (#1482).
14
14
  *
15
- * A derived row, and the only one in the registry — see `deriveItems` on the declaration below for
16
- * why deriving beat reshaping the family. It carries nothing the committed file does not: the
15
+ * A derived row, the registry's first — see `deriveItems` on the declaration below for why deriving beat
16
+ * reshaping the family. (Not its only one: `assurance-program` obligation entries and governed-document
17
+ * sections are derived the same way.) It carries nothing the committed file does not: the
17
18
  * resource NAME as authored, the module that lists it, and which of the module's two lists it came
18
19
  * from. `resourceRef` is the authored string itself, so a referrer resolves against exactly what it
19
20
  * was written with.