@wildo-ai/saas-specifications 1.1.3 → 1.1.5
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.
- package/dist/assurance/external-framework-mapping.json +1228 -0
- package/dist/esm/_core/application-maturity/application-maturity-validation.d.ts +34 -0
- package/dist/esm/_core/application-maturity/application-maturity-validation.d.ts.map +1 -0
- package/dist/esm/_core/application-maturity/application-maturity-validation.js +66 -0
- package/dist/esm/_core/application-maturity/application-maturity-validation.js.map +1 -0
- package/dist/esm/_core/application-maturity/application-maturity.family-aspects.d.ts +3 -0
- package/dist/esm/_core/application-maturity/application-maturity.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/application-maturity/application-maturity.family-aspects.js +48 -0
- package/dist/esm/_core/application-maturity/application-maturity.family-aspects.js.map +1 -0
- package/dist/esm/_core/application-maturity/application-maturity.schemas.d.ts +201 -0
- package/dist/esm/_core/application-maturity/application-maturity.schemas.d.ts.map +1 -0
- package/dist/esm/_core/application-maturity/application-maturity.schemas.js +306 -0
- package/dist/esm/_core/application-maturity/application-maturity.schemas.js.map +1 -0
- package/dist/esm/_core/application-specification-family-identity.schemas.d.ts +304 -0
- package/dist/esm/_core/application-specification-family-identity.schemas.d.ts.map +1 -0
- package/dist/esm/_core/application-specification-family-identity.schemas.js +314 -0
- package/dist/esm/_core/application-specification-family-identity.schemas.js.map +1 -0
- package/dist/esm/_core/assertions/assertion-authored-metadata.schemas.d.ts +2 -1
- package/dist/esm/_core/assertions/assertion-authored-metadata.schemas.d.ts.map +1 -1
- package/dist/esm/_core/assertions/assertion-authored-metadata.schemas.js +4 -1
- package/dist/esm/_core/assertions/assertion-authored-metadata.schemas.js.map +1 -1
- package/dist/esm/_core/assertions/assertion-behaviors.schemas.d.ts +4 -4
- package/dist/esm/_core/assertions/assertion-specification.schemas.d.ts +5 -4
- package/dist/esm/_core/assertions/assertion-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/assertions/assertion-specification.schemas.js +4 -1
- package/dist/esm/_core/assertions/assertion-specification.schemas.js.map +1 -1
- package/dist/esm/_core/brand/brand-asset.schemas.d.ts +5 -4
- package/dist/esm/_core/brand/brand-asset.schemas.d.ts.map +1 -1
- package/dist/esm/_core/brand/brand-asset.schemas.js +7 -4
- package/dist/esm/_core/brand/brand-asset.schemas.js.map +1 -1
- package/dist/esm/_core/brand/brand-audience.schemas.d.ts +31 -0
- package/dist/esm/_core/brand/brand-audience.schemas.d.ts.map +1 -0
- package/dist/esm/_core/brand/brand-audience.schemas.js +29 -0
- package/dist/esm/_core/brand/brand-audience.schemas.js.map +1 -0
- package/dist/esm/_core/brand/brand-authored-metadata.schemas.d.ts +3 -2
- package/dist/esm/_core/brand/brand-authored-metadata.schemas.d.ts.map +1 -1
- package/dist/esm/_core/brand/brand-authored-metadata.schemas.js +5 -2
- package/dist/esm/_core/brand/brand-authored-metadata.schemas.js.map +1 -1
- package/dist/esm/_core/brand/brand-generation.schemas.d.ts +4 -4
- package/dist/esm/_core/brand/brand-logo-direction.schemas.d.ts +12 -9
- package/dist/esm/_core/brand/brand-logo-direction.schemas.d.ts.map +1 -1
- package/dist/esm/_core/brand/brand-logo-direction.schemas.js +12 -7
- package/dist/esm/_core/brand/brand-logo-direction.schemas.js.map +1 -1
- package/dist/esm/_core/brand/brand-name.schemas.d.ts +2 -2
- package/dist/esm/_core/brand/brand-snapshot-validation.d.ts.map +1 -1
- package/dist/esm/_core/brand/brand-snapshot-validation.js +1 -8
- package/dist/esm/_core/brand/brand-snapshot-validation.js.map +1 -1
- package/dist/esm/_core/brand/brand-snapshot.schemas.d.ts +23 -12
- package/dist/esm/_core/brand/brand-snapshot.schemas.d.ts.map +1 -1
- package/dist/esm/_core/brand/brand-snapshot.schemas.js +7 -0
- package/dist/esm/_core/brand/brand-snapshot.schemas.js.map +1 -1
- package/dist/esm/_core/brand/brand-visual-tone.schemas.d.ts +2 -2
- package/dist/esm/_core/brand/brand.family-aspects.d.ts.map +1 -1
- package/dist/esm/_core/brand/brand.family-aspects.js +12 -1
- package/dist/esm/_core/brand/brand.family-aspects.js.map +1 -1
- package/dist/esm/_core/build-plan/build-plan-task-graph-generation.schemas.d.ts +252 -2
- package/dist/esm/_core/build-plan/build-plan-task-graph-generation.schemas.d.ts.map +1 -1
- package/dist/esm/_core/build-plan/build-plan-task-graph-generation.schemas.js +19 -1
- package/dist/esm/_core/build-plan/build-plan-task-graph-generation.schemas.js.map +1 -1
- package/dist/esm/_core/build-plan/build-plan-task-graph-validation.d.ts +121 -1
- package/dist/esm/_core/build-plan/build-plan-task-graph-validation.d.ts.map +1 -1
- package/dist/esm/_core/build-plan/build-plan-task-graph-validation.js +215 -2
- package/dist/esm/_core/build-plan/build-plan-task-graph-validation.js.map +1 -1
- package/dist/esm/_core/build-plan/build-plan-task-graph.schemas.d.ts +703 -14
- package/dist/esm/_core/build-plan/build-plan-task-graph.schemas.d.ts.map +1 -1
- package/dist/esm/_core/build-plan/build-plan-task-graph.schemas.js +536 -7
- package/dist/esm/_core/build-plan/build-plan-task-graph.schemas.js.map +1 -1
- package/dist/esm/_core/build-plan/build-plan.family-aspects.d.ts.map +1 -1
- package/dist/esm/_core/build-plan/build-plan.family-aspects.js +82 -2
- package/dist/esm/_core/build-plan/build-plan.family-aspects.js.map +1 -1
- package/dist/esm/_core/business-model-lite/business-model-authored-metadata.schemas.d.ts +3 -2
- package/dist/esm/_core/business-model-lite/business-model-authored-metadata.schemas.d.ts.map +1 -1
- package/dist/esm/_core/business-model-lite/business-model-authored-metadata.schemas.js +5 -2
- package/dist/esm/_core/business-model-lite/business-model-authored-metadata.schemas.js.map +1 -1
- package/dist/esm/_core/business-model-lite/business-model-lite-snapshot.schemas.d.ts +3 -3
- package/dist/esm/_core/business-model-lite/business-model.family-aspects.js +1 -1
- package/dist/esm/_core/business-model-lite/business-model.family-aspects.js.map +1 -1
- package/dist/esm/_core/business-model-lite/pricing-plan.schemas.d.ts +4 -3
- package/dist/esm/_core/business-model-lite/pricing-plan.schemas.d.ts.map +1 -1
- package/dist/esm/_core/business-model-lite/pricing-plan.schemas.js +4 -1
- package/dist/esm/_core/business-model-lite/pricing-plan.schemas.js.map +1 -1
- package/dist/esm/_core/business-semantics.specifications.schemas.d.ts +36 -0
- package/dist/esm/_core/business-semantics.specifications.schemas.d.ts.map +1 -1
- package/dist/esm/_core/business-semantics.specifications.schemas.js +52 -1
- package/dist/esm/_core/business-semantics.specifications.schemas.js.map +1 -1
- package/dist/esm/_core/capability-composition/capability-composition-validation.d.ts +22 -0
- package/dist/esm/_core/capability-composition/capability-composition-validation.d.ts.map +1 -0
- package/dist/esm/_core/capability-composition/capability-composition-validation.js +89 -0
- package/dist/esm/_core/capability-composition/capability-composition-validation.js.map +1 -0
- package/dist/esm/_core/capability-composition/capability-composition.family-aspects.d.ts +3 -0
- package/dist/esm/_core/capability-composition/capability-composition.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/capability-composition/capability-composition.family-aspects.js +26 -0
- package/dist/esm/_core/capability-composition/capability-composition.family-aspects.js.map +1 -0
- package/dist/esm/_core/capability-composition/capability-composition.schemas.d.ts +141 -0
- package/dist/esm/_core/capability-composition/capability-composition.schemas.d.ts.map +1 -0
- package/dist/esm/_core/capability-composition/capability-composition.schemas.js +147 -0
- package/dist/esm/_core/capability-composition/capability-composition.schemas.js.map +1 -0
- package/dist/esm/_core/compliance-documents/compliance-document-candidate-generation.schemas.d.ts +160 -0
- package/dist/esm/_core/compliance-documents/compliance-document-candidate-generation.schemas.d.ts.map +1 -1
- package/dist/esm/_core/compliance-documents/compliance-document-candidate-generation.schemas.js +124 -4
- package/dist/esm/_core/compliance-documents/compliance-document-candidate-generation.schemas.js.map +1 -1
- package/dist/esm/_core/compliance-documents/compliance-document-candidate-set.schemas.d.ts +95 -0
- package/dist/esm/_core/compliance-documents/compliance-document-candidate-set.schemas.d.ts.map +1 -0
- package/dist/esm/_core/compliance-documents/compliance-document-candidate-set.schemas.js +85 -0
- package/dist/esm/_core/compliance-documents/compliance-document-candidate-set.schemas.js.map +1 -0
- package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.d.ts +743 -14
- package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.d.ts.map +1 -1
- package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.js +699 -22
- package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.js.map +1 -1
- package/dist/esm/_core/compliance-documents/compliance-documents.family-aspects.d.ts +98 -6
- package/dist/esm/_core/compliance-documents/compliance-documents.family-aspects.d.ts.map +1 -1
- package/dist/esm/_core/compliance-documents/compliance-documents.family-aspects.js +197 -8
- package/dist/esm/_core/compliance-documents/compliance-documents.family-aspects.js.map +1 -1
- package/dist/esm/_core/compliance-documents/computed-document-facts.schemas.d.ts +64 -0
- package/dist/esm/_core/compliance-documents/computed-document-facts.schemas.d.ts.map +1 -0
- package/dist/esm/_core/compliance-documents/computed-document-facts.schemas.js +283 -0
- package/dist/esm/_core/compliance-documents/computed-document-facts.schemas.js.map +1 -0
- package/dist/esm/_core/compliance-documents/document-fact-specification-generation.schemas.d.ts.map +1 -1
- package/dist/esm/_core/compliance-documents/document-fact-specification-generation.schemas.js +30 -1
- package/dist/esm/_core/compliance-documents/document-fact-specification-generation.schemas.js.map +1 -1
- package/dist/esm/_core/compliance-documents/processor-register.family-aspects.js +1 -1
- package/dist/esm/_core/compliance-documents/processor-register.family-aspects.js.map +1 -1
- package/dist/esm/_core/compliance-documents/processor-register.schemas.d.ts +220 -4
- package/dist/esm/_core/compliance-documents/processor-register.schemas.d.ts.map +1 -1
- package/dist/esm/_core/compliance-documents/processor-register.schemas.js +149 -2
- package/dist/esm/_core/compliance-documents/processor-register.schemas.js.map +1 -1
- package/dist/esm/_core/compliance-documents/required-document-set.schemas.d.ts +70 -3
- package/dist/esm/_core/compliance-documents/required-document-set.schemas.d.ts.map +1 -1
- package/dist/esm/_core/compliance-documents/required-document-set.schemas.js +75 -3
- package/dist/esm/_core/compliance-documents/required-document-set.schemas.js.map +1 -1
- package/dist/esm/_core/composite-view-specification.schemas.d.ts +14 -0
- package/dist/esm/_core/composite-view-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/composite-view-specification.schemas.js +13 -0
- package/dist/esm/_core/composite-view-specification.schemas.js.map +1 -1
- package/dist/esm/_core/cross-registry-assertions.d.ts +6 -4
- package/dist/esm/_core/cross-registry-assertions.d.ts.map +1 -1
- package/dist/esm/_core/cross-registry-assertions.js +7 -5
- package/dist/esm/_core/cross-registry-assertions.js.map +1 -1
- package/dist/esm/_core/domain-plan/domain-plan-output-set.schemas.d.ts +5 -4
- package/dist/esm/_core/domain-plan/domain-plan-output-set.schemas.d.ts.map +1 -1
- package/dist/esm/_core/domain-plan/domain-plan-output-set.schemas.js +5 -2
- package/dist/esm/_core/domain-plan/domain-plan-output-set.schemas.js.map +1 -1
- package/dist/esm/_core/domain-plan/domain-plan.family-aspects.d.ts +30 -0
- package/dist/esm/_core/domain-plan/domain-plan.family-aspects.d.ts.map +1 -1
- package/dist/esm/_core/domain-plan/domain-plan.family-aspects.js +99 -6
- package/dist/esm/_core/domain-plan/domain-plan.family-aspects.js.map +1 -1
- package/dist/esm/_core/experience-plan/experience-plan-generation.schemas.d.ts +58 -0
- package/dist/esm/_core/experience-plan/experience-plan-generation.schemas.d.ts.map +1 -0
- package/dist/esm/_core/experience-plan/experience-plan-generation.schemas.js +71 -0
- package/dist/esm/_core/experience-plan/experience-plan-generation.schemas.js.map +1 -0
- package/dist/esm/_core/experience-plan/experience-plan-validation.d.ts +37 -0
- package/dist/esm/_core/experience-plan/experience-plan-validation.d.ts.map +1 -0
- package/dist/esm/_core/experience-plan/experience-plan-validation.js +83 -0
- package/dist/esm/_core/experience-plan/experience-plan-validation.js.map +1 -0
- package/dist/esm/_core/experience-plan/experience-plan.family-aspects.d.ts +3 -0
- package/dist/esm/_core/experience-plan/experience-plan.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/experience-plan/experience-plan.family-aspects.js +78 -0
- package/dist/esm/_core/experience-plan/experience-plan.family-aspects.js.map +1 -0
- package/dist/esm/_core/experience-plan/experience-plan.schemas.d.ts +285 -0
- package/dist/esm/_core/experience-plan/experience-plan.schemas.d.ts.map +1 -0
- package/dist/esm/_core/experience-plan/experience-plan.schemas.js +293 -0
- package/dist/esm/_core/experience-plan/experience-plan.schemas.js.map +1 -0
- package/dist/esm/_core/expert-personas/expert-persona-authored-metadata.schemas.d.ts +3 -2
- package/dist/esm/_core/expert-personas/expert-persona-authored-metadata.schemas.d.ts.map +1 -1
- package/dist/esm/_core/expert-personas/expert-persona-authored-metadata.schemas.js +5 -2
- package/dist/esm/_core/expert-personas/expert-persona-authored-metadata.schemas.js.map +1 -1
- package/dist/esm/_core/expert-personas/expert-persona-charter.schemas.d.ts +9 -2
- package/dist/esm/_core/expert-personas/expert-persona-charter.schemas.d.ts.map +1 -1
- package/dist/esm/_core/expert-personas/expert-persona-charter.schemas.js +7 -0
- package/dist/esm/_core/expert-personas/expert-persona-charter.schemas.js.map +1 -1
- package/dist/esm/_core/expert-personas/expert-personas.family-aspects.d.ts +18 -0
- package/dist/esm/_core/expert-personas/expert-personas.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/expert-personas/expert-personas.family-aspects.js +21 -0
- package/dist/esm/_core/expert-personas/expert-personas.family-aspects.js.map +1 -0
- package/dist/esm/_core/expert-personas/expert-role-template.schemas.d.ts +19 -0
- package/dist/esm/_core/expert-personas/expert-role-template.schemas.d.ts.map +1 -1
- package/dist/esm/_core/expert-personas/expert-role-template.schemas.js +23 -0
- package/dist/esm/_core/expert-personas/expert-role-template.schemas.js.map +1 -1
- package/dist/esm/_core/family-aspects.registry.d.ts.map +1 -1
- package/dist/esm/_core/family-aspects.registry.js +22 -1
- package/dist/esm/_core/family-aspects.registry.js.map +1 -1
- package/dist/esm/_core/family-aspects.schemas.d.ts +64 -1
- package/dist/esm/_core/family-aspects.schemas.d.ts.map +1 -1
- package/dist/esm/_core/family-aspects.schemas.js.map +1 -1
- package/dist/esm/_core/feature-drafts/capability-map-output-set-generation.schemas.d.ts +27 -27
- package/dist/esm/_core/feature-drafts/capability-map-output-set.schemas.d.ts +59 -59
- package/dist/esm/_core/feature-drafts/feature-drafts.family-aspects.js +1 -1
- package/dist/esm/_core/feature-drafts/feature-drafts.family-aspects.js.map +1 -1
- package/dist/esm/_core/feature-drafts/feature-specification-drafts.schemas.d.ts.map +1 -1
- package/dist/esm/_core/feature-drafts/feature-specification-drafts.schemas.js +6 -1
- package/dist/esm/_core/feature-drafts/feature-specification-drafts.schemas.js.map +1 -1
- package/dist/esm/_core/guidance-flow-specification.schemas.d.ts +11 -15
- package/dist/esm/_core/guidance-flow-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/guidance-flow-specification.schemas.js +12 -11
- package/dist/esm/_core/guidance-flow-specification.schemas.js.map +1 -1
- package/dist/esm/_core/index.d.ts +16 -0
- package/dist/esm/_core/index.d.ts.map +1 -1
- package/dist/esm/_core/index.js +16 -0
- package/dist/esm/_core/index.js.map +1 -1
- package/dist/esm/_core/integration-plan/integration-plan-generation.schemas.d.ts +52 -0
- package/dist/esm/_core/integration-plan/integration-plan-generation.schemas.d.ts.map +1 -0
- package/dist/esm/_core/integration-plan/integration-plan-generation.schemas.js +50 -0
- package/dist/esm/_core/integration-plan/integration-plan-generation.schemas.js.map +1 -0
- package/dist/esm/_core/integration-plan/integration-plan-validation.d.ts +27 -0
- package/dist/esm/_core/integration-plan/integration-plan-validation.d.ts.map +1 -0
- package/dist/esm/_core/integration-plan/integration-plan-validation.js +63 -0
- package/dist/esm/_core/integration-plan/integration-plan-validation.js.map +1 -0
- package/dist/esm/_core/integration-plan/integration-plan.family-aspects.d.ts +3 -0
- package/dist/esm/_core/integration-plan/integration-plan.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/integration-plan/integration-plan.family-aspects.js +52 -0
- package/dist/esm/_core/integration-plan/integration-plan.family-aspects.js.map +1 -0
- package/dist/esm/_core/integration-plan/integration-plan.schemas.d.ts +168 -0
- package/dist/esm/_core/integration-plan/integration-plan.schemas.d.ts.map +1 -0
- package/dist/esm/_core/integration-plan/integration-plan.schemas.js +170 -0
- package/dist/esm/_core/integration-plan/integration-plan.schemas.js.map +1 -0
- package/dist/esm/_core/market/feature-benefit.schemas.d.ts +6 -5
- package/dist/esm/_core/market/feature-benefit.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/feature-benefit.schemas.js +5 -2
- package/dist/esm/_core/market/feature-benefit.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-alternative.schemas.d.ts +4 -3
- package/dist/esm/_core/market/market-alternative.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-alternative.schemas.js +4 -1
- package/dist/esm/_core/market/market-alternative.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-authored-metadata.schemas.d.ts +11 -9
- package/dist/esm/_core/market/market-authored-metadata.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-authored-metadata.schemas.js +13 -10
- package/dist/esm/_core/market/market-authored-metadata.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-buying-journey.schemas.d.ts +5 -4
- package/dist/esm/_core/market/market-buying-journey.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-buying-journey.schemas.js +4 -1
- package/dist/esm/_core/market/market-buying-journey.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-category.schemas.d.ts +2 -2
- package/dist/esm/_core/market/market-channel.schemas.d.ts +6 -5
- package/dist/esm/_core/market/market-channel.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-channel.schemas.js +6 -3
- package/dist/esm/_core/market/market-channel.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-gain.schemas.d.ts +4 -3
- package/dist/esm/_core/market/market-gain.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-gain.schemas.js +4 -1
- package/dist/esm/_core/market/market-gain.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-icp.schemas.d.ts +12 -11
- package/dist/esm/_core/market/market-icp.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-icp.schemas.js +12 -9
- package/dist/esm/_core/market/market-icp.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-job.schemas.d.ts +4 -3
- package/dist/esm/_core/market/market-job.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-job.schemas.js +4 -1
- package/dist/esm/_core/market/market-job.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-message-template.schemas.d.ts +5 -4
- package/dist/esm/_core/market/market-message-template.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-message-template.schemas.js +5 -2
- package/dist/esm/_core/market/market-message-template.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-objection.schemas.d.ts +4 -3
- package/dist/esm/_core/market/market-objection.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-objection.schemas.js +4 -1
- package/dist/esm/_core/market/market-objection.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-pain.schemas.d.ts +4 -3
- package/dist/esm/_core/market/market-pain.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-pain.schemas.js +4 -1
- package/dist/esm/_core/market/market-pain.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-persona.schemas.d.ts +5 -4
- package/dist/esm/_core/market/market-persona.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-persona.schemas.js +5 -2
- package/dist/esm/_core/market/market-persona.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-positioning.schemas.d.ts +2 -2
- package/dist/esm/_core/market/market-proof.schemas.d.ts +4 -3
- package/dist/esm/_core/market/market-proof.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-proof.schemas.js +4 -1
- package/dist/esm/_core/market/market-proof.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-snapshot-generation.schemas.d.ts +54 -54
- package/dist/esm/_core/market/market-snapshot.schemas.d.ts +59 -59
- package/dist/esm/_core/market/market-tone-of-voice.schemas.d.ts +4 -3
- package/dist/esm/_core/market/market-tone-of-voice.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-tone-of-voice.schemas.js +4 -1
- package/dist/esm/_core/market/market-tone-of-voice.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-trigger.schemas.d.ts +4 -3
- package/dist/esm/_core/market/market-trigger.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-trigger.schemas.js +4 -1
- package/dist/esm/_core/market/market-trigger.schemas.js.map +1 -1
- package/dist/esm/_core/market/market.family-aspects.d.ts.map +1 -1
- package/dist/esm/_core/market/market.family-aspects.js +25 -1
- package/dist/esm/_core/market/market.family-aspects.js.map +1 -1
- package/dist/esm/_core/onboarding-view-specification.schemas.d.ts +27 -22
- package/dist/esm/_core/onboarding-view-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/onboarding-view-specification.schemas.js +7 -12
- package/dist/esm/_core/onboarding-view-specification.schemas.js.map +1 -1
- package/dist/esm/_core/placement-plan/placement-plan-generation.schemas.d.ts +21 -21
- package/dist/esm/_core/placement-plan/placement-plan-validation.d.ts +30 -16
- package/dist/esm/_core/placement-plan/placement-plan-validation.d.ts.map +1 -1
- package/dist/esm/_core/placement-plan/placement-plan-validation.js +34 -12
- package/dist/esm/_core/placement-plan/placement-plan-validation.js.map +1 -1
- package/dist/esm/_core/placement-plan/placement-plan.family-aspects.d.ts.map +1 -1
- package/dist/esm/_core/placement-plan/placement-plan.family-aspects.js +24 -1
- package/dist/esm/_core/placement-plan/placement-plan.family-aspects.js.map +1 -1
- package/dist/esm/_core/placement-plan/placement-plan.schemas.d.ts +78 -47
- package/dist/esm/_core/placement-plan/placement-plan.schemas.d.ts.map +1 -1
- package/dist/esm/_core/placement-plan/placement-plan.schemas.js +62 -24
- package/dist/esm/_core/placement-plan/placement-plan.schemas.js.map +1 -1
- package/dist/esm/_core/provider-specification.schemas.d.ts +19 -0
- package/dist/esm/_core/provider-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/provider-specification.schemas.js +0 -20
- package/dist/esm/_core/provider-specification.schemas.js.map +1 -1
- package/dist/esm/_core/requirements/functional-requirement.schemas.d.ts +2 -2
- package/dist/esm/_core/requirements/non-functional-requirement.schemas.d.ts +2 -2
- package/dist/esm/_core/requirements/requirements-authored-metadata.schemas.d.ts +3 -2
- package/dist/esm/_core/requirements/requirements-authored-metadata.schemas.d.ts.map +1 -1
- package/dist/esm/_core/requirements/requirements-authored-metadata.schemas.js +5 -2
- package/dist/esm/_core/requirements/requirements-authored-metadata.schemas.js.map +1 -1
- package/dist/esm/_core/requirements/requirements-snapshot.schemas.d.ts +4 -4
- package/dist/esm/_core/requirements/requirements.family-aspects.d.ts.map +1 -1
- package/dist/esm/_core/requirements/requirements.family-aspects.js +3 -1
- package/dist/esm/_core/requirements/requirements.family-aspects.js.map +1 -1
- package/dist/esm/_core/resource-specification.schemas.d.ts +8 -0
- package/dist/esm/_core/resource-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/resource-specification.schemas.js.map +1 -1
- package/dist/esm/_core/roadmap/roadmap-authored-metadata.schemas.d.ts +3 -2
- package/dist/esm/_core/roadmap/roadmap-authored-metadata.schemas.d.ts.map +1 -1
- package/dist/esm/_core/roadmap/roadmap-authored-metadata.schemas.js +5 -2
- package/dist/esm/_core/roadmap/roadmap-authored-metadata.schemas.js.map +1 -1
- package/dist/esm/_core/roadmap/roadmap-phase.schemas.d.ts +2 -2
- package/dist/esm/_core/roadmap/roadmap-snapshot-validation.d.ts +5 -0
- package/dist/esm/_core/roadmap/roadmap-snapshot-validation.d.ts.map +1 -1
- package/dist/esm/_core/roadmap/roadmap-snapshot-validation.js +1 -8
- package/dist/esm/_core/roadmap/roadmap-snapshot-validation.js.map +1 -1
- package/dist/esm/_core/roadmap/roadmap-snapshot.schemas.d.ts +2 -2
- package/dist/esm/_core/roadmap/roadmap.family-aspects.js +1 -1
- package/dist/esm/_core/roadmap/roadmap.family-aspects.js.map +1 -1
- package/dist/esm/_core/utils/extract-field-specs.d.ts.map +1 -1
- package/dist/esm/_core/utils/extract-field-specs.js +4 -2
- package/dist/esm/_core/utils/extract-field-specs.js.map +1 -1
- package/dist/esm/_core/vision/vision-authored-metadata.schemas.d.ts +3 -2
- package/dist/esm/_core/vision/vision-authored-metadata.schemas.d.ts.map +1 -1
- package/dist/esm/_core/vision/vision-authored-metadata.schemas.js +5 -2
- package/dist/esm/_core/vision/vision-authored-metadata.schemas.js.map +1 -1
- package/dist/esm/_core/vision/vision-constraint.schemas.d.ts +2 -2
- package/dist/esm/_core/vision/vision-idea.schemas.d.ts +2 -2
- package/dist/esm/_core/vision/vision-mission.schemas.d.ts +2 -2
- package/dist/esm/_core/vision/vision-problem.schemas.d.ts +2 -2
- package/dist/esm/_core/vision/vision-snapshot.schemas.d.ts +10 -10
- package/dist/esm/_core/vision/vision-success-criterion.schemas.d.ts +2 -2
- package/dist/esm/_core/vision/vision.family-aspects.js +1 -1
- package/dist/esm/_core/vision/vision.family-aspects.js.map +1 -1
- package/dist/esm/_core/website-plan/website-plan-generation.schemas.d.ts +45 -0
- package/dist/esm/_core/website-plan/website-plan-generation.schemas.d.ts.map +1 -0
- package/dist/esm/_core/website-plan/website-plan-generation.schemas.js +55 -0
- package/dist/esm/_core/website-plan/website-plan-generation.schemas.js.map +1 -0
- package/dist/esm/_core/website-plan/website-plan-validation.d.ts +37 -0
- package/dist/esm/_core/website-plan/website-plan-validation.d.ts.map +1 -0
- package/dist/esm/_core/website-plan/website-plan-validation.js +77 -0
- package/dist/esm/_core/website-plan/website-plan-validation.js.map +1 -0
- package/dist/esm/_core/website-plan/website-plan.family-aspects.d.ts +3 -0
- package/dist/esm/_core/website-plan/website-plan.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/website-plan/website-plan.family-aspects.js +35 -0
- package/dist/esm/_core/website-plan/website-plan.family-aspects.js.map +1 -0
- package/dist/esm/_core/website-plan/website-plan.schemas.d.ts +194 -0
- package/dist/esm/_core/website-plan/website-plan.schemas.d.ts.map +1 -0
- package/dist/esm/_core/website-plan/website-plan.schemas.js +193 -0
- package/dist/esm/_core/website-plan/website-plan.schemas.js.map +1 -0
- package/dist/esm/_core/zod-core-nameability.d.ts +47 -0
- package/dist/esm/_core/zod-core-nameability.d.ts.map +1 -0
- package/dist/esm/_core/zod-core-nameability.js +1 -0
- package/dist/esm/_core/zod-core-nameability.js.map +1 -0
- package/dist/esm/application-creation/application-creator-inputs.application-creation.schemas.d.ts +86 -0
- package/dist/esm/application-creation/application-creator-inputs.application-creation.schemas.d.ts.map +1 -0
- package/dist/esm/application-creation/application-creator-inputs.application-creation.schemas.js +96 -0
- package/dist/esm/application-creation/application-creator-inputs.application-creation.schemas.js.map +1 -0
- package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.d.ts +139 -34
- package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.d.ts.map +1 -1
- package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.js +182 -11
- package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.js.map +1 -1
- package/dist/esm/application-creation/application-document-release-policy-specification.application-creation.schemas.d.ts +71 -2
- package/dist/esm/application-creation/application-document-release-policy-specification.application-creation.schemas.d.ts.map +1 -1
- package/dist/esm/application-creation/application-document-release-policy-specification.application-creation.schemas.js +88 -1
- package/dist/esm/application-creation/application-document-release-policy-specification.application-creation.schemas.js.map +1 -1
- package/dist/esm/application-creation/creator-inputs.family-aspects.d.ts +14 -0
- package/dist/esm/application-creation/creator-inputs.family-aspects.d.ts.map +1 -0
- package/dist/esm/application-creation/creator-inputs.family-aspects.js +17 -0
- package/dist/esm/application-creation/creator-inputs.family-aspects.js.map +1 -0
- package/dist/esm/application-creation/document-facts.family-aspects.d.ts.map +1 -1
- package/dist/esm/application-creation/document-facts.family-aspects.js +25 -1
- package/dist/esm/application-creation/document-facts.family-aspects.js.map +1 -1
- package/dist/esm/application-creation/document-release-policy.family-aspects.js +1 -1
- package/dist/esm/application-creation/document-release-policy.family-aspects.js.map +1 -1
- package/dist/esm/application-creation/journey.application-creation.schemas.d.ts +14 -48
- package/dist/esm/application-creation/journey.application-creation.schemas.d.ts.map +1 -1
- package/dist/esm/application-creation/journey.application-creation.schemas.js +52 -52
- package/dist/esm/application-creation/journey.application-creation.schemas.js.map +1 -1
- package/dist/esm/application-creation/playbooks.application-creation.schemas.d.ts +209 -495
- package/dist/esm/application-creation/playbooks.application-creation.schemas.d.ts.map +1 -1
- package/dist/esm/application-creation/playbooks.application-creation.schemas.js +257 -534
- package/dist/esm/application-creation/playbooks.application-creation.schemas.js.map +1 -1
- package/dist/esm/application-creation/structured-artifact-landing.application-creation.schemas.d.ts +10 -0
- package/dist/esm/application-creation/structured-artifact-landing.application-creation.schemas.d.ts.map +1 -1
- package/dist/esm/application-creation/structured-artifact-landing.application-creation.schemas.js +10 -0
- package/dist/esm/application-creation/structured-artifact-landing.application-creation.schemas.js.map +1 -1
- package/dist/esm/application-creation.exports.d.ts +73 -8
- package/dist/esm/application-creation.exports.d.ts.map +1 -1
- package/dist/esm/application-creation.exports.js +103 -8
- package/dist/esm/application-creation.exports.js.map +1 -1
- package/dist/esm/assurance/__tests__/authority-evaluation-instant.fixture.d.ts +24 -0
- package/dist/esm/assurance/__tests__/authority-evaluation-instant.fixture.d.ts.map +1 -0
- package/dist/esm/assurance/__tests__/authority-evaluation-instant.fixture.js +24 -0
- package/dist/esm/assurance/__tests__/authority-evaluation-instant.fixture.js.map +1 -0
- package/dist/esm/assurance/application-document-publication.schemas.d.ts +49 -0
- package/dist/esm/assurance/application-document-publication.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/application-document-publication.schemas.js +51 -0
- package/dist/esm/assurance/application-document-publication.schemas.js.map +1 -1
- package/dist/esm/assurance/application-document-release-set.schemas.d.ts +161 -0
- package/dist/esm/assurance/application-document-release-set.schemas.d.ts.map +1 -0
- package/dist/esm/assurance/application-document-release-set.schemas.js +138 -0
- package/dist/esm/assurance/application-document-release-set.schemas.js.map +1 -0
- package/dist/esm/assurance/application-risk-register.family-aspects.d.ts +28 -0
- package/dist/esm/assurance/application-risk-register.family-aspects.d.ts.map +1 -0
- package/dist/esm/assurance/application-risk-register.family-aspects.js +58 -0
- package/dist/esm/assurance/application-risk-register.family-aspects.js.map +1 -0
- package/dist/esm/assurance/application-risk-register.schemas.d.ts +172 -0
- package/dist/esm/assurance/application-risk-register.schemas.d.ts.map +1 -0
- package/dist/esm/assurance/application-risk-register.schemas.js +192 -0
- package/dist/esm/assurance/application-risk-register.schemas.js.map +1 -0
- package/dist/esm/assurance/application-risk-signals.derivations.d.ts +177 -0
- package/dist/esm/assurance/application-risk-signals.derivations.d.ts.map +1 -0
- package/dist/esm/assurance/application-risk-signals.derivations.js +229 -0
- package/dist/esm/assurance/application-risk-signals.derivations.js.map +1 -0
- package/dist/esm/assurance/assurance-authority-basis.definitions.d.ts +257 -13
- package/dist/esm/assurance/assurance-authority-basis.definitions.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-authority-basis.definitions.js +836 -69
- package/dist/esm/assurance/assurance-authority-basis.definitions.js.map +1 -1
- package/dist/esm/assurance/assurance-authority-basis.schemas.d.ts +99 -33
- package/dist/esm/assurance/assurance-authority-basis.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-authority-basis.schemas.js +38 -1
- package/dist/esm/assurance/assurance-authority-basis.schemas.js.map +1 -1
- package/dist/esm/assurance/assurance-document-blueprint-selection.d.ts +30 -0
- package/dist/esm/assurance/assurance-document-blueprint-selection.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-document-blueprint-selection.js +40 -0
- package/dist/esm/assurance/assurance-document-blueprint-selection.js.map +1 -1
- package/dist/esm/assurance/assurance-document-system.definitions.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-document-system.definitions.js +99 -8
- package/dist/esm/assurance/assurance-document-system.definitions.js.map +1 -1
- package/dist/esm/assurance/assurance-document-system.schemas.d.ts +133 -41
- package/dist/esm/assurance/assurance-document-system.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-document-system.schemas.js +60 -11
- package/dist/esm/assurance/assurance-document-system.schemas.js.map +1 -1
- package/dist/esm/assurance/assurance-evidence-judgement.schemas.d.ts +470 -0
- package/dist/esm/assurance/assurance-evidence-judgement.schemas.d.ts.map +1 -0
- package/dist/esm/assurance/assurance-evidence-judgement.schemas.js +451 -0
- package/dist/esm/assurance/assurance-evidence-judgement.schemas.js.map +1 -0
- package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.d.ts +0 -33
- package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.js +3339 -159
- package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.js.map +1 -1
- package/dist/esm/assurance/assurance-foundation.schemas.d.ts +21 -0
- package/dist/esm/assurance/assurance-foundation.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-foundation.schemas.js +21 -0
- package/dist/esm/assurance/assurance-foundation.schemas.js.map +1 -1
- package/dist/esm/assurance/assurance-objective-catalog.definitions.d.ts +32 -2
- package/dist/esm/assurance/assurance-objective-catalog.definitions.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-objective-catalog.definitions.js +148 -5
- package/dist/esm/assurance/assurance-objective-catalog.definitions.js.map +1 -1
- package/dist/esm/assurance/assurance-program-generation.schemas.d.ts +257 -14
- package/dist/esm/assurance/assurance-program-generation.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-program-generation.schemas.js +588 -45
- package/dist/esm/assurance/assurance-program-generation.schemas.js.map +1 -1
- package/dist/esm/assurance/assurance-program.family-aspects.d.ts +32 -8
- package/dist/esm/assurance/assurance-program.family-aspects.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-program.family-aspects.js +288 -10
- package/dist/esm/assurance/assurance-program.family-aspects.js.map +1 -1
- package/dist/esm/assurance/assurance-program.schemas.d.ts +1182 -333
- package/dist/esm/assurance/assurance-program.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-program.schemas.js +460 -68
- package/dist/esm/assurance/assurance-program.schemas.js.map +1 -1
- package/dist/esm/assurance/assurance-source-registry.definitions.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-source-registry.definitions.js +70 -2
- package/dist/esm/assurance/assurance-source-registry.definitions.js.map +1 -1
- package/dist/esm/assurance/assurance-sources.schemas.d.ts +17 -0
- package/dist/esm/assurance/assurance-sources.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-sources.schemas.js +17 -0
- package/dist/esm/assurance/assurance-sources.schemas.js.map +1 -1
- package/dist/esm/assurance/assurance-verification-requirement-bodies.definitions.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-verification-requirement-bodies.definitions.js +205 -3
- package/dist/esm/assurance/assurance-verification-requirement-bodies.definitions.js.map +1 -1
- package/dist/esm/assurance/document-publication.family-aspects.js +1 -1
- package/dist/esm/assurance/document-publication.family-aspects.js.map +1 -1
- package/dist/esm/assurance/document-release-set.family-aspects.d.ts +11 -0
- package/dist/esm/assurance/document-release-set.family-aspects.d.ts.map +1 -0
- package/dist/esm/assurance/document-release-set.family-aspects.js +36 -0
- package/dist/esm/assurance/document-release-set.family-aspects.js.map +1 -0
- package/dist/esm/assurance/governed-document-release.d.ts +211 -0
- package/dist/esm/assurance/governed-document-release.d.ts.map +1 -0
- package/dist/esm/assurance/governed-document-release.js +314 -0
- package/dist/esm/assurance/governed-document-release.js.map +1 -0
- package/dist/esm/assurance.exports.d.ts +5 -0
- package/dist/esm/assurance.exports.d.ts.map +1 -1
- package/dist/esm/assurance.exports.js +5 -0
- package/dist/esm/assurance.exports.js.map +1 -1
- package/dist/esm/companion-exports.d.ts +135 -11
- package/dist/esm/companion-exports.d.ts.map +1 -1
- package/dist/esm/companion-exports.js.map +1 -1
- package/dist/esm/engine/_bootstrap.d.ts +1 -1
- package/dist/esm/engine/_bootstrap.js +1 -1
- package/dist/esm/engine/_bootstrap.js.map +1 -1
- package/dist/esm/engine/applications/resources/application-metadata.resource.specification.d.ts +1 -1
- package/dist/esm/engine/applications/resources/application-metadata.resource.specification.js +1 -1
- package/dist/esm/engine/applications/resources/application-metadata.resource.specification.js.map +1 -1
- package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.d.ts +0 -23
- package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.js +110 -28
- package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.js.map +1 -1
- package/dist/esm/engine/applications/resources/application-versions.resource.specification.d.ts +1 -1
- package/dist/esm/engine/applications/resources/application-versions.resource.specification.js +1 -1
- package/dist/esm/engine/applications/resources/application-versions.resource.specification.js.map +1 -1
- package/dist/esm/engine/applications/resources/applications.resource.specification.d.ts +1 -0
- package/dist/esm/engine/applications/resources/applications.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/application-access-grants.resource.specification.d.ts +57 -0
- package/dist/esm/engine/auth/resources/application-access-grants.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/auth/resources/application-access-grants.resource.specification.js +412 -0
- package/dist/esm/engine/auth/resources/application-access-grants.resource.specification.js.map +1 -0
- package/dist/esm/engine/auth/resources/index.d.ts +2 -0
- package/dist/esm/engine/auth/resources/index.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/index.js +2 -0
- package/dist/esm/engine/auth/resources/index.js.map +1 -1
- package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.d.ts +4 -4
- package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.js +57 -6
- package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/organization-onboarding-operations.resource.specification.d.ts +9 -0
- package/dist/esm/engine/auth/resources/organization-onboarding-operations.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/auth/resources/organization-onboarding-operations.resource.specification.js +141 -0
- package/dist/esm/engine/auth/resources/organization-onboarding-operations.resource.specification.js.map +1 -0
- package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.d.ts +4 -1
- package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.js +10 -6
- package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/scim-provisioning-config.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/scim-provisioning-config.resource.specification.js +5 -4
- package/dist/esm/engine/auth/resources/scim-provisioning-config.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/siem-delivery-outbox.resource.specification.d.ts +4 -0
- package/dist/esm/engine/auth/resources/siem-delivery-outbox.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/auth/resources/siem-delivery-outbox.resource.specification.js +129 -0
- package/dist/esm/engine/auth/resources/siem-delivery-outbox.resource.specification.js.map +1 -0
- package/dist/esm/engine/auth/resources/siem-export-config.resource.specification.d.ts +19 -7
- package/dist/esm/engine/auth/resources/siem-export-config.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/siem-export-config.resource.specification.js +24 -13
- package/dist/esm/engine/auth/resources/siem-export-config.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/sso-config.resource.specification.d.ts +0 -40
- package/dist/esm/engine/auth/resources/sso-config.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/sso-config.resource.specification.js +14 -27
- package/dist/esm/engine/auth/resources/sso-config.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/sso-connections.resource.specification.d.ts +8 -2
- package/dist/esm/engine/auth/resources/sso-connections.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/sso-connections.resource.specification.js +16 -3
- package/dist/esm/engine/auth/resources/sso-connections.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/user-provider-credentials.resource.specification.d.ts +5 -2
- package/dist/esm/engine/auth/resources/user-provider-credentials.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/user-provider-credentials.resource.specification.js +10 -16
- package/dist/esm/engine/auth/resources/user-provider-credentials.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/billing-accounts.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/billing-accounts.resource.specification.js +15 -5
- package/dist/esm/engine/billing/resources/billing-accounts.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/billing-effect-outbox.resource.specification.d.ts +9 -0
- package/dist/esm/engine/billing/resources/billing-effect-outbox.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/billing/resources/billing-effect-outbox.resource.specification.js +164 -0
- package/dist/esm/engine/billing/resources/billing-effect-outbox.resource.specification.js.map +1 -0
- package/dist/esm/engine/billing/resources/billing-provider-event-settlements.resource.specification.d.ts +14 -0
- package/dist/esm/engine/billing/resources/billing-provider-event-settlements.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/billing/resources/billing-provider-event-settlements.resource.specification.js +124 -0
- package/dist/esm/engine/billing/resources/billing-provider-event-settlements.resource.specification.js.map +1 -0
- package/dist/esm/engine/billing/resources/billing-subscription-mutation-completions.resource.specification.d.ts +9 -0
- package/dist/esm/engine/billing/resources/billing-subscription-mutation-completions.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/billing/resources/billing-subscription-mutation-completions.resource.specification.js +123 -0
- package/dist/esm/engine/billing/resources/billing-subscription-mutation-completions.resource.specification.js.map +1 -0
- package/dist/esm/engine/billing/resources/billing-subscription-mutation-intents.resource.specification.d.ts +11 -0
- package/dist/esm/engine/billing/resources/billing-subscription-mutation-intents.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/billing/resources/billing-subscription-mutation-intents.resource.specification.js +172 -0
- package/dist/esm/engine/billing/resources/billing-subscription-mutation-intents.resource.specification.js.map +1 -0
- package/dist/esm/engine/billing/resources/index.d.ts +4 -0
- package/dist/esm/engine/billing/resources/index.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/index.js +4 -0
- package/dist/esm/engine/billing/resources/index.js.map +1 -1
- package/dist/esm/engine/billing/resources/prices.resource.specification.d.ts +3 -3
- package/dist/esm/engine/billing/resources/products.resource.specification.d.ts +3 -3
- package/dist/esm/engine/billing/resources/products.resource.specification.js +1 -1
- package/dist/esm/engine/billing/resources/products.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/subscriptions.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/subscriptions.resource.specification.js +92 -36
- package/dist/esm/engine/billing/resources/subscriptions.resource.specification.js.map +1 -1
- package/dist/esm/engine/compliance/resources/application-audit-logs.resource.specification.d.ts +77 -0
- package/dist/esm/engine/compliance/resources/application-audit-logs.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/compliance/resources/application-audit-logs.resource.specification.js +375 -0
- package/dist/esm/engine/compliance/resources/application-audit-logs.resource.specification.js.map +1 -0
- package/dist/esm/engine/compliance/resources/audit-logs.resource.specification.d.ts +1 -1
- package/dist/esm/engine/compliance/resources/index.d.ts +2 -0
- package/dist/esm/engine/compliance/resources/index.d.ts.map +1 -1
- package/dist/esm/engine/compliance/resources/index.js +2 -0
- package/dist/esm/engine/compliance/resources/index.js.map +1 -1
- package/dist/esm/engine/compliance/resources/user-governed-document-acceptances.resource.specification.d.ts +16 -0
- package/dist/esm/engine/compliance/resources/user-governed-document-acceptances.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/compliance/resources/user-governed-document-acceptances.resource.specification.js +183 -0
- package/dist/esm/engine/compliance/resources/user-governed-document-acceptances.resource.specification.js.map +1 -0
- package/dist/esm/engine/engine-resource-specifications.registry.d.ts.map +1 -1
- package/dist/esm/engine/engine-resource-specifications.registry.js +28 -0
- package/dist/esm/engine/engine-resource-specifications.registry.js.map +1 -1
- package/dist/esm/engine/errors/error-messages.specification.d.ts.map +1 -1
- package/dist/esm/engine/errors/error-messages.specification.js +123 -19
- package/dist/esm/engine/errors/error-messages.specification.js.map +1 -1
- package/dist/esm/engine/features/resources/application-features.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/features/resources/application-features.resource.specification.js +2 -1
- package/dist/esm/engine/features/resources/application-features.resource.specification.js.map +1 -1
- package/dist/esm/engine/features/resources/organization-features.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/features/resources/organization-features.resource.specification.js +1 -0
- package/dist/esm/engine/features/resources/organization-features.resource.specification.js.map +1 -1
- package/dist/esm/engine/features/resources/user-features.resource.specification.d.ts +1 -1
- package/dist/esm/engine/features/resources/user-features.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/features/resources/user-features.resource.specification.js +4 -1
- package/dist/esm/engine/features/resources/user-features.resource.specification.js.map +1 -1
- package/dist/esm/engine/files/resources/files.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/files/resources/files.resource.specification.js +15 -3
- package/dist/esm/engine/files/resources/files.resource.specification.js.map +1 -1
- package/dist/esm/engine/flows-actors/resources/flow-actor-executions.resource.specification.d.ts +3 -0
- package/dist/esm/engine/flows-actors/resources/flow-actor-executions.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/flows-actors/resources/flow-actor-executions.resource.specification.js +1 -1
- package/dist/esm/engine/flows-actors/resources/flow-actor-executions.resource.specification.js.map +1 -1
- package/dist/esm/engine/flows-actors/resources/flow-actor-tasks.resource.specification.d.ts +3 -3
- package/dist/esm/engine/flows-actors/resources/provider-call-records.resource.specification.d.ts +14 -0
- package/dist/esm/engine/flows-actors/resources/provider-call-records.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/flows-actors/resources/provider-call-records.resource.specification.js +184 -0
- package/dist/esm/engine/flows-actors/resources/provider-call-records.resource.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/actions/button-group-separator.frontend-component.specification.js +3 -3
- package/dist/esm/engine/frontend-components/actions/button-group-separator.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/actions/button-group.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/actions/button-group.frontend-component.specification.js +3 -2
- package/dist/esm/engine/frontend-components/actions/button-group.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/actions/button.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/actions/button.frontend-component.specification.js +18 -0
- package/dist/esm/engine/frontend-components/actions/button.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/ai-elements/artifacts/ai-diff-block.frontend-component.specification.d.ts +4 -0
- package/dist/esm/engine/frontend-components/ai-elements/artifacts/ai-diff-block.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/ai-elements/artifacts/ai-diff-block.frontend-component.specification.js +21 -0
- package/dist/esm/engine/frontend-components/ai-elements/artifacts/ai-diff-block.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/ai-elements/trace/ai-chain-of-thought.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/ai-elements/trace/ai-chain-of-thought.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/app/app-layout-billing-settings.frontend-component.specification.d.ts +5 -0
- package/dist/esm/engine/frontend-components/app/app-layout-billing-settings.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/app/app-layout-billing-settings.frontend-component.specification.js +82 -0
- package/dist/esm/engine/frontend-components/app/app-layout-billing-settings.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/app/app-layout-connected-accounts-settings.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/app/app-layout-connected-accounts-settings.frontend-component.specification.js +6 -5
- package/dist/esm/engine/frontend-components/app/app-layout-connected-accounts-settings.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/app/app-layout-consent-gate.frontend-component.specification.d.ts +4 -0
- package/dist/esm/engine/frontend-components/app/app-layout-consent-gate.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/app/app-layout-consent-gate.frontend-component.specification.js +22 -0
- package/dist/esm/engine/frontend-components/app/app-layout-consent-gate.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/app/app-layout-document-acceptance-gate.frontend-component.specification.d.ts +4 -0
- package/dist/esm/engine/frontend-components/app/app-layout-document-acceptance-gate.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/app/app-layout-document-acceptance-gate.frontend-component.specification.js +22 -0
- package/dist/esm/engine/frontend-components/app/app-layout-document-acceptance-gate.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/app/app-layout-surface-error-boundary.frontend-component.specification.d.ts +5 -0
- package/dist/esm/engine/frontend-components/app/app-layout-surface-error-boundary.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/app/app-layout-surface-error-boundary.frontend-component.specification.js +81 -0
- package/dist/esm/engine/frontend-components/app/app-layout-surface-error-boundary.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/app/public-layout-main-container.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/app/public-layout-main-container.frontend-component.specification.js +4 -2
- package/dist/esm/engine/frontend-components/app/public-layout-main-container.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/app/public-layout-terms.frontend-component.specification.js +4 -4
- package/dist/esm/engine/frontend-components/app/public-layout-terms.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/auth/public-layout-auth-callback.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/auth/public-layout-auth-callback.frontend-component.specification.js +3 -2
- package/dist/esm/engine/frontend-components/auth/public-layout-auth-callback.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/auth/public-layout-enrollment-required.frontend-component.specification.js +4 -4
- package/dist/esm/engine/frontend-components/auth/public-layout-enrollment-required.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/auth/public-layout-magic-link-verify.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/auth/public-layout-magic-link-verify.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/auth/public-layout-organization-onboarding.frontend-component.specification.d.ts +4 -0
- package/dist/esm/engine/frontend-components/auth/public-layout-organization-onboarding.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/auth/public-layout-organization-onboarding.frontend-component.specification.js +22 -0
- package/dist/esm/engine/frontend-components/auth/public-layout-organization-onboarding.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/auth/public-layout-user-auth.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/auth/public-layout-user-auth.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/auth/public-layout-user-register.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/auth/public-layout-user-register.frontend-component.specification.js +4 -4
- package/dist/esm/engine/frontend-components/auth/public-layout-user-register.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/billing/billing-invoice-history.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/billing/billing-invoice-history.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/billing/billing-plan-change-preview.frontend-component.specification.d.ts +4 -0
- package/dist/esm/engine/frontend-components/billing/billing-plan-change-preview.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/billing/billing-plan-change-preview.frontend-component.specification.js +21 -0
- package/dist/esm/engine/frontend-components/billing/billing-plan-change-preview.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/billing/billing-portal-link.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/billing/billing-portal-link.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/billing/billing-pricing-table.frontend-component.specification.js +2 -2
- package/dist/esm/engine/frontend-components/billing/billing-pricing-table.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/billing/billing-subscription-status.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/billing/billing-subscription-status.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/billing/billing-usage-dashboard.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/billing/billing-usage-dashboard.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/data-display/description-list.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/data-display/description-list.frontend-component.specification.js +20 -2
- package/dist/esm/engine/frontend-components/data-display/description-list.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/data-display/duration.frontend-component.specification.d.ts +5 -0
- package/dist/esm/engine/frontend-components/data-display/duration.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/data-display/duration.frontend-component.specification.js +177 -0
- package/dist/esm/engine/frontend-components/data-display/duration.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/data-display/formatters/display-field-address.frontend-component.specification.d.ts +5 -0
- package/dist/esm/engine/frontend-components/data-display/formatters/display-field-address.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/data-display/formatters/display-field-address.frontend-component.specification.js +22 -0
- package/dist/esm/engine/frontend-components/data-display/formatters/display-field-address.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/data-display/formatters/display-field-file-document.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/data-display/formatters/display-field-file-document.frontend-component.specification.js +10 -2
- package/dist/esm/engine/frontend-components/data-display/formatters/display-field-file-document.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/data-display/identifier.frontend-component.specification.d.ts +5 -0
- package/dist/esm/engine/frontend-components/data-display/identifier.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/data-display/identifier.frontend-component.specification.js +166 -0
- package/dist/esm/engine/frontend-components/data-display/identifier.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/data-display/kbd.frontend-component.specification.d.ts +5 -0
- package/dist/esm/engine/frontend-components/data-display/kbd.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/data-display/kbd.frontend-component.specification.js +122 -0
- package/dist/esm/engine/frontend-components/data-display/kbd.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/data-display/timeline.frontend-component.specification.d.ts +5 -0
- package/dist/esm/engine/frontend-components/data-display/timeline.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/data-display/timeline.frontend-component.specification.js +152 -0
- package/dist/esm/engine/frontend-components/data-display/timeline.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/feedback/celebration-overlay.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/feedback/celebration-overlay.frontend-component.specification.js +13 -0
- package/dist/esm/engine/frontend-components/feedback/celebration-overlay.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/flows-actors/low-level-ai-approval.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/flows-actors/low-level-ai-approval.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/form/controls/string/inline-edit-text.frontend-component.specification.d.ts +5 -0
- package/dist/esm/engine/frontend-components/form/controls/string/inline-edit-text.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/form/controls/string/inline-edit-text.frontend-component.specification.js +92 -0
- package/dist/esm/engine/frontend-components/form/controls/string/inline-edit-text.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/form/fields/form-field-address.frontend-component.specification.d.ts +5 -0
- package/dist/esm/engine/frontend-components/form/fields/form-field-address.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/form/fields/form-field-address.frontend-component.specification.js +29 -0
- package/dist/esm/engine/frontend-components/form/fields/form-field-address.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/form/fields/form-field-enum.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/form/fields/form-field-enum.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/form/fields/form-field-file.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/form/fields/form-field-file.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/index.d.ts +12 -0
- package/dist/esm/engine/frontend-components/index.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/index.js +40 -0
- package/dist/esm/engine/frontend-components/index.js.map +1 -1
- package/dist/esm/engine/frontend-components/internal/_tier2-virtual-slot-spec.factory.d.ts +25 -1
- package/dist/esm/engine/frontend-components/internal/_tier2-virtual-slot-spec.factory.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/internal/_tier2-virtual-slot-spec.factory.js +16 -2
- package/dist/esm/engine/frontend-components/internal/_tier2-virtual-slot-spec.factory.js.map +1 -1
- package/dist/esm/engine/frontend-components/navigation/app-level/navigation-back.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/navigation/app-level/navigation-back.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/progression/progression-milestone-tracker.frontend-component.specification.d.ts +9 -0
- package/dist/esm/engine/frontend-components/progression/progression-milestone-tracker.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/progression/progression-milestone-tracker.frontend-component.specification.js +91 -7
- package/dist/esm/engine/frontend-components/progression/progression-milestone-tracker.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/sections/accordion.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/sections/accordion.frontend-component.specification.js +9 -3
- package/dist/esm/engine/frontend-components/sections/accordion.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/sections/card.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/sections/card.frontend-component.specification.js +41 -1
- package/dist/esm/engine/frontend-components/sections/card.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/sections/collapsible.frontend-component.specification.js +2 -2
- package/dist/esm/engine/frontend-components/sections/collapsible.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/sections/tabs.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/sections/tabs.frontend-component.specification.js +19 -1
- package/dist/esm/engine/frontend-components/sections/tabs.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/typography/link.frontend-component.specification.js +3 -3
- package/dist/esm/engine/frontend-components/typography/link.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/typography/text.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/typography/text.frontend-component.specification.js +21 -1
- package/dist/esm/engine/frontend-components/typography/text.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/guidance/resources/progression-state.resource.specification.d.ts +2 -0
- package/dist/esm/engine/guidance/resources/progression-state.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership.resource.specification.d.ts +4 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership.resource.specification.js +48 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership.resource.specification.js.map +1 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-states.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-states.resource.specification.js +3 -2
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-states.resource.specification.js.map +1 -1
- package/dist/esm/engine/infrastructure/resources/job-executions.resource.specification.d.ts +77 -3
- package/dist/esm/engine/infrastructure/resources/job-executions.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/infrastructure/resources/job-executions.resource.specification.js +11 -3
- package/dist/esm/engine/infrastructure/resources/job-executions.resource.specification.js.map +1 -1
- package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.d.ts +26 -1
- package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.js +17 -8
- package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.js.map +1 -1
- package/dist/esm/engine/infrastructure/resources/system-of-record-partition-assignments.resource.specification.d.ts +49 -0
- package/dist/esm/engine/infrastructure/resources/system-of-record-partition-assignments.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/infrastructure/resources/system-of-record-partition-assignments.resource.specification.js +293 -0
- package/dist/esm/engine/infrastructure/resources/system-of-record-partition-assignments.resource.specification.js.map +1 -0
- package/dist/esm/engine/notifications/resources/m2m-webhook-delivery-log.resource.specification.js +5 -5
- package/dist/esm/engine/notifications/resources/m2m-webhook-delivery-log.resource.specification.js.map +1 -1
- package/dist/esm/engine/notifications/resources/notification-badges.resource.specification.d.ts +1 -1
- package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.js +6 -6
- package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.js.map +1 -1
- package/dist/esm/engine/notifications/system-emails/security.system-emails.specification.js +3 -3
- package/dist/esm/engine/notifications/system-emails/security.system-emails.specification.js.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-members.resource.specification.d.ts +1 -1
- package/dist/esm/engine/organizations/resources/organization-profiles.resource.specification.js +2 -2
- package/dist/esm/engine/organizations/resources/organization-profiles.resource.specification.js.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-units.resource.specification.d.ts +3 -1
- package/dist/esm/engine/organizations/resources/organization-units.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-units.resource.specification.js +27 -5
- package/dist/esm/engine/organizations/resources/organization-units.resource.specification.js.map +1 -1
- package/dist/esm/engine/organizations/resources/organizations.resource.specification.d.ts +1 -1
- package/dist/esm/engine/organizations/resources/organizations.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/organizations/resources/organizations.resource.specification.js +31 -12
- package/dist/esm/engine/organizations/resources/organizations.resource.specification.js.map +1 -1
- package/dist/esm/engine/providers/anthropic.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/anthropic.provider.specification.js +10 -1
- package/dist/esm/engine/providers/anthropic.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/apple.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/apple.provider.specification.js +12 -1
- package/dist/esm/engine/providers/apple.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/email-preview.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/email-preview.provider.specification.js +9 -1
- package/dist/esm/engine/providers/email-preview.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/github.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/github.provider.specification.js +12 -1
- package/dist/esm/engine/providers/github.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/google.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/google.provider.specification.js +12 -1
- package/dist/esm/engine/providers/google.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/grok.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/grok.provider.specification.js +10 -1
- package/dist/esm/engine/providers/grok.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/microsoft.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/microsoft.provider.specification.js +22 -1
- package/dist/esm/engine/providers/microsoft.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/mistral.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/mistral.provider.specification.js +10 -1
- package/dist/esm/engine/providers/mistral.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/openai.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/openai.provider.specification.js +10 -1
- package/dist/esm/engine/providers/openai.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/opencode.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/opencode.provider.specification.js +9 -1
- package/dist/esm/engine/providers/opencode.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/perplexity.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/perplexity.provider.specification.js +10 -1
- package/dist/esm/engine/providers/perplexity.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/resend.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/resend.provider.specification.js +10 -1
- package/dist/esm/engine/providers/resend.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/stripe.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/stripe.provider.specification.js +10 -1
- package/dist/esm/engine/providers/stripe.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/twilio.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/twilio.provider.specification.js +10 -1
- package/dist/esm/engine/providers/twilio.provider.specification.js.map +1 -1
- package/dist/esm/engine/roles/app-audit-evidence-reader.role.specification.d.ts +2 -0
- package/dist/esm/engine/roles/app-audit-evidence-reader.role.specification.d.ts.map +1 -0
- package/dist/esm/engine/roles/app-audit-evidence-reader.role.specification.js +21 -0
- package/dist/esm/engine/roles/app-audit-evidence-reader.role.specification.js.map +1 -0
- package/dist/esm/engine/roles/index.d.ts +4 -3
- package/dist/esm/engine/roles/index.d.ts.map +1 -1
- package/dist/esm/engine/roles/index.js +6 -4
- package/dist/esm/engine/roles/index.js.map +1 -1
- package/dist/esm/engine/users/resources/anonymous-users.resource.specification.d.ts +5 -3
- package/dist/esm/engine/users/resources/anonymous-users.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/anonymous-users.resource.specification.js +2 -2
- package/dist/esm/engine/users/resources/anonymous-users.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/inbound-contacts.resource.specification.d.ts +2 -1
- package/dist/esm/engine/users/resources/inbound-contacts.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/inbound-contacts.resource.specification.js +2 -2
- package/dist/esm/engine/users/resources/inbound-contacts.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/user-identity-links.resource.specification.d.ts +1 -0
- package/dist/esm/engine/users/resources/user-identity-links.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/user-identity-links.resource.specification.js +8 -3
- package/dist/esm/engine/users/resources/user-identity-links.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/user-preferences-api-reference.examples.d.ts +2 -2
- package/dist/esm/engine/users/resources/user-preferences-api-reference.examples.js +2 -2
- package/dist/esm/engine/users/resources/user-preferences-api-reference.examples.js.map +1 -1
- package/dist/esm/engine/users/resources/user-preferences.resource.specification.d.ts +5 -5
- package/dist/esm/engine/users/resources/user-preferences.resource.specification.js +1 -1
- package/dist/esm/engine/users/resources/user-preferences.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.d.ts +4 -4
- package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.js +3 -3
- package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/user-self.resource.specification.d.ts +1 -0
- package/dist/esm/engine/users/resources/user-self.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/user-self.resource.specification.js +1 -1
- package/dist/esm/engine/users/resources/user-self.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/users.resource.specification.d.ts +1 -0
- package/dist/esm/engine/users/resources/users.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/users.resource.specification.js +2 -2
- package/dist/esm/engine/users/resources/users.resource.specification.js.map +1 -1
- package/dist/esm/index.d.ts +39 -0
- package/dist/esm/index.d.ts.map +1 -1
- package/dist/esm/index.js +39 -0
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/technical-documentation/application-documentation-chapters.schemas.d.ts +134 -0
- package/dist/esm/technical-documentation/application-documentation-chapters.schemas.d.ts.map +1 -0
- package/dist/esm/technical-documentation/application-documentation-chapters.schemas.js +142 -0
- package/dist/esm/technical-documentation/application-documentation-chapters.schemas.js.map +1 -0
- package/dist/esm/technical-documentation/application-documentation-plan-generation.schemas.d.ts +35 -0
- package/dist/esm/technical-documentation/application-documentation-plan-generation.schemas.d.ts.map +1 -0
- package/dist/esm/technical-documentation/application-documentation-plan-generation.schemas.js +45 -0
- package/dist/esm/technical-documentation/application-documentation-plan-generation.schemas.js.map +1 -0
- package/dist/esm/technical-documentation/application-documentation-plan-validation.d.ts +33 -0
- package/dist/esm/technical-documentation/application-documentation-plan-validation.d.ts.map +1 -0
- package/dist/esm/technical-documentation/application-documentation-plan-validation.js +77 -0
- package/dist/esm/technical-documentation/application-documentation-plan-validation.js.map +1 -0
- package/dist/esm/technical-documentation/application-documentation-plan.family-aspects.d.ts +3 -0
- package/dist/esm/technical-documentation/application-documentation-plan.family-aspects.d.ts.map +1 -0
- package/dist/esm/technical-documentation/application-documentation-plan.family-aspects.js +40 -0
- package/dist/esm/technical-documentation/application-documentation-plan.family-aspects.js.map +1 -0
- package/dist/esm/technical-documentation/application-documentation-plan.schemas.d.ts +122 -0
- package/dist/esm/technical-documentation/application-documentation-plan.schemas.d.ts.map +1 -0
- package/dist/esm/technical-documentation/application-documentation-plan.schemas.js +138 -0
- package/dist/esm/technical-documentation/application-documentation-plan.schemas.js.map +1 -0
- package/dist/esm/technical-documentation/engine-documentation-specification-catalog.companion.d.ts.map +1 -1
- package/dist/esm/technical-documentation/engine-documentation-specification-catalog.companion.js +7 -15
- package/dist/esm/technical-documentation/engine-documentation-specification-catalog.companion.js.map +1 -1
- package/dist/esm/technical-documentation/technical-documentation-assets.schemas.js +1 -1
- package/dist/esm/technical-documentation/technical-documentation-assets.schemas.js.map +1 -1
- package/dist/esm/technical-documentation/technical-documentation-capture.schemas.js +1 -1
- package/dist/esm/technical-documentation/technical-documentation-capture.schemas.js.map +1 -1
- package/dist/esm/technical-documentation/technical-documentation-common.schemas.js +1 -1
- package/dist/esm/technical-documentation/technical-documentation-common.schemas.js.map +1 -1
- package/dist/esm/technical-documentation/technical-documentation-evidence.schemas.js +1 -1
- package/dist/esm/technical-documentation/technical-documentation-evidence.schemas.js.map +1 -1
- package/dist/esm/technical-documentation/technical-documentation-lifecycle.schemas.js +1 -1
- package/dist/esm/technical-documentation/technical-documentation-lifecycle.schemas.js.map +1 -1
- package/dist/esm/technical-documentation/technical-documentation-publication.schemas.js +1 -1
- package/dist/esm/technical-documentation/technical-documentation-publication.schemas.js.map +1 -1
- package/dist/esm/technical-documentation/technical-documentation-units.schemas.d.ts +14 -0
- package/dist/esm/technical-documentation/technical-documentation-units.schemas.d.ts.map +1 -1
- package/dist/esm/technical-documentation/technical-documentation-units.schemas.js +16 -3
- package/dist/esm/technical-documentation/technical-documentation-units.schemas.js.map +1 -1
- package/dist/esm/technical-documentation.exports.d.ts +4 -0
- package/dist/esm/technical-documentation.exports.d.ts.map +1 -1
- package/dist/esm/technical-documentation.exports.js +24 -0
- package/dist/esm/technical-documentation.exports.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +8 -13
- package/dist/esm/application-creation/application-coding-tasks.application-creation.schemas.d.ts +0 -103
- package/dist/esm/application-creation/application-coding-tasks.application-creation.schemas.d.ts.map +0 -1
- package/dist/esm/application-creation/application-coding-tasks.application-creation.schemas.js +0 -76
- package/dist/esm/application-creation/application-coding-tasks.application-creation.schemas.js.map +0 -1
- package/dist/esm/application-creation/application-specification-family-identity.application-creation.schemas.d.ts +0 -108
- package/dist/esm/application-creation/application-specification-family-identity.application-creation.schemas.d.ts.map +0 -1
- package/dist/esm/application-creation/application-specification-family-identity.application-creation.schemas.js +0 -119
- package/dist/esm/application-creation/application-specification-family-identity.application-creation.schemas.js.map +0 -1
- package/dist/esm/application-creation-playbook-runtime.exports.d.ts +0 -3
- package/dist/esm/application-creation-playbook-runtime.exports.d.ts.map +0 -1
- package/dist/esm/application-creation-playbook-runtime.exports.js +0 -3
- package/dist/esm/application-creation-playbook-runtime.exports.js.map +0 -1
- package/dist/esm/engine/frontend-components/billing/billing-promotion-code-input.frontend-component.specification.d.ts +0 -0
- package/dist/esm/engine/frontend-components/billing/billing-promotion-code-input.frontend-component.specification.d.ts.map +0 -0
- package/dist/esm/engine/frontend-components/billing/billing-promotion-code-input.frontend-component.specification.js +0 -0
- package/dist/esm/engine/frontend-components/billing/billing-promotion-code-input.frontend-component.specification.js.map +0 -0
|
@@ -1,4 +1,9 @@
|
|
|
1
|
+
import { ProviderDeploymentModel } from "@wildo-ai/saas-models";
|
|
1
2
|
import { z } from "zod";
|
|
3
|
+
// Side-effect import: this module calls `.systemEnum()` at load, so the decorators must be installed first —
|
|
4
|
+
// never by the importer's luck (#966). A named import used only as a type would be elided and install nothing.
|
|
5
|
+
import '@wildo-ai/zod-decorators';
|
|
6
|
+
/** @wildo_source:part:start saas.specifications.processor-register facet:layer:shared facet:audience:app-developer */
|
|
2
7
|
/**
|
|
3
8
|
* **Who else processes personal data, under what legal identity, and where.**
|
|
4
9
|
*
|
|
@@ -75,6 +80,121 @@ export var ProcessorRegisterEntryKind;
|
|
|
75
80
|
/** A subprocessor nothing in the configuration mentions. Unverifiable by construction, and stated as authored. */
|
|
76
81
|
ProcessorRegisterEntryKind["AUTHORED"] = "AUTHORED";
|
|
77
82
|
})(ProcessorRegisterEntryKind || (ProcessorRegisterEntryKind = {}));
|
|
83
|
+
/**
|
|
84
|
+
* The instrument that makes a transfer of personal data out of its origin jurisdiction lawful.
|
|
85
|
+
*
|
|
86
|
+
* spec-cite: GDPR Chapter V — Art. 45 (adequacy), Art. 46(2)(b)–(f) (appropriate safeguards), Art. 47 (binding
|
|
87
|
+
* corporate rules), Art. 49(1) (derogations). The UK GDPR keeps the same structure, so one vocabulary serves
|
|
88
|
+
* both; the INSTRUMENT that fills a member differs by jurisdiction (the EU clauses, the UK Addendum), which is
|
|
89
|
+
* why each safeguard names its instrument in prose beside the member.
|
|
90
|
+
*
|
|
91
|
+
* Recorded, never computed (#126): which mechanism applies is a legal determination with a shelf life —
|
|
92
|
+
* an adequacy decision can be struck down while the vendor stays where it is — so the framework offers the
|
|
93
|
+
* place to write it down and derives nothing from a region.
|
|
94
|
+
*/
|
|
95
|
+
export var InternationalTransferMechanism;
|
|
96
|
+
(function (InternationalTransferMechanism) {
|
|
97
|
+
/** Art. 45 — the destination is covered by an adequacy decision (for the United States, the Data Privacy Framework, for a certified recipient). */
|
|
98
|
+
InternationalTransferMechanism["ADEQUACY_DECISION"] = "ADEQUACY_DECISION";
|
|
99
|
+
/** Art. 46(2)(c)/(d) — standard data protection clauses, or a jurisdiction's equivalent (the UK Addendum to them). */
|
|
100
|
+
InternationalTransferMechanism["STANDARD_CONTRACTUAL_CLAUSES"] = "STANDARD_CONTRACTUAL_CLAUSES";
|
|
101
|
+
/** Art. 46(2)(b) and Art. 47 — binding corporate rules approved for the recipient's group. */
|
|
102
|
+
InternationalTransferMechanism["BINDING_CORPORATE_RULES"] = "BINDING_CORPORATE_RULES";
|
|
103
|
+
/** Art. 46(2)(e) — an approved code of conduct with binding commitments of the recipient. */
|
|
104
|
+
InternationalTransferMechanism["APPROVED_CODE_OF_CONDUCT"] = "APPROVED_CODE_OF_CONDUCT";
|
|
105
|
+
/** Art. 46(2)(f) — an approved certification with binding commitments of the recipient. */
|
|
106
|
+
InternationalTransferMechanism["APPROVED_CERTIFICATION"] = "APPROVED_CERTIFICATION";
|
|
107
|
+
/** Art. 49 — a derogation for a specific situation. Requires {@link InternationalTransferDerogation}. */
|
|
108
|
+
InternationalTransferMechanism["DEROGATION"] = "DEROGATION";
|
|
109
|
+
})(InternationalTransferMechanism || (InternationalTransferMechanism = {}));
|
|
110
|
+
/** Which Art. 49 derogation a {@link InternationalTransferMechanism.DEROGATION} relies on. spec-cite: GDPR Art. 49(1). */
|
|
111
|
+
export var InternationalTransferDerogation;
|
|
112
|
+
(function (InternationalTransferDerogation) {
|
|
113
|
+
/** Art. 49(1)(a) — explicit consent after being informed of the risks. */
|
|
114
|
+
InternationalTransferDerogation["EXPLICIT_CONSENT"] = "EXPLICIT_CONSENT";
|
|
115
|
+
/** Art. 49(1)(b) — necessary for a contract with the data subject. */
|
|
116
|
+
InternationalTransferDerogation["CONTRACT_WITH_SUBJECT"] = "CONTRACT_WITH_SUBJECT";
|
|
117
|
+
/** Art. 49(1)(c) — necessary for a contract concluded in the subject's interest with another party. */
|
|
118
|
+
InternationalTransferDerogation["CONTRACT_IN_SUBJECT_INTEREST"] = "CONTRACT_IN_SUBJECT_INTEREST";
|
|
119
|
+
/** Art. 49(1)(d) — important reasons of public interest. */
|
|
120
|
+
InternationalTransferDerogation["PUBLIC_INTEREST"] = "PUBLIC_INTEREST";
|
|
121
|
+
/** Art. 49(1)(e) — establishment, exercise or defence of legal claims. */
|
|
122
|
+
InternationalTransferDerogation["LEGAL_CLAIMS"] = "LEGAL_CLAIMS";
|
|
123
|
+
/** Art. 49(1)(f) — vital interests where the subject cannot consent. */
|
|
124
|
+
InternationalTransferDerogation["VITAL_INTERESTS"] = "VITAL_INTERESTS";
|
|
125
|
+
/** Art. 49(1)(g) — a transfer from a public register. */
|
|
126
|
+
InternationalTransferDerogation["PUBLIC_REGISTER"] = "PUBLIC_REGISTER";
|
|
127
|
+
/** Art. 49(1), second subparagraph — compelling legitimate interests, for a non-repetitive transfer. */
|
|
128
|
+
InternationalTransferDerogation["COMPELLING_LEGITIMATE_INTERESTS"] = "COMPELLING_LEGITIMATE_INTERESTS";
|
|
129
|
+
})(InternationalTransferDerogation || (InternationalTransferDerogation = {}));
|
|
130
|
+
/**
|
|
131
|
+
* Whether reaching this processor moves personal data out of the jurisdiction it came from.
|
|
132
|
+
*
|
|
133
|
+
* A DETERMINATION, recorded by the operator, because regions are free text: nothing can compare
|
|
134
|
+
* `United States` or `eu-west-1` with a declared operating jurisdiction, so the framework cannot tell a
|
|
135
|
+
* domestic processor from a foreign one and does not guess.
|
|
136
|
+
*/
|
|
137
|
+
export var ProcessorTransferDeterminationKind;
|
|
138
|
+
(function (ProcessorTransferDeterminationKind) {
|
|
139
|
+
/** Every region this processor (and its subprocessors) uses lies within the jurisdictions the data comes from. */
|
|
140
|
+
ProcessorTransferDeterminationKind["NO_TRANSFER"] = "NO_TRANSFER";
|
|
141
|
+
/** Personal data leaves its origin jurisdiction to reach this processor, under the safeguards named. */
|
|
142
|
+
ProcessorTransferDeterminationKind["TRANSFER"] = "TRANSFER";
|
|
143
|
+
})(ProcessorTransferDeterminationKind || (ProcessorTransferDeterminationKind = {}));
|
|
144
|
+
/** The safeguard one origin jurisdiction's data travels under. */
|
|
145
|
+
export const ProcessorTransferSafeguardSchema = z
|
|
146
|
+
.strictObject({
|
|
147
|
+
/** The jurisdiction the data leaves — one of the application's `operatingJurisdictions`. */
|
|
148
|
+
originJurisdictionSlug: z.string().trim().min(1),
|
|
149
|
+
mechanism: z.enum(InternationalTransferMechanism).systemEnum("InternationalTransferMechanism"),
|
|
150
|
+
/** Required with {@link InternationalTransferMechanism.DEROGATION}, refused otherwise. */
|
|
151
|
+
derogation: z.enum(InternationalTransferDerogation).systemEnum("InternationalTransferDerogation").optional(),
|
|
152
|
+
/**
|
|
153
|
+
* The instrument, as a reader could look it up: "EU SCCs (Commission Decision 2021/914), Module Two",
|
|
154
|
+
* "UK Addendum to the EU SCCs", "EU-US Data Privacy Framework — recipient certified". A mechanism
|
|
155
|
+
* member alone tells a reader the article, not the document that binds the recipient.
|
|
156
|
+
*/
|
|
157
|
+
instrument: z.string().trim().min(1),
|
|
158
|
+
})
|
|
159
|
+
.superRefine((safeguard, context) => {
|
|
160
|
+
const isDerogation = safeguard.mechanism === InternationalTransferMechanism.DEROGATION;
|
|
161
|
+
if (isDerogation !== (safeguard.derogation !== undefined)) {
|
|
162
|
+
context.addIssue({
|
|
163
|
+
code: "custom",
|
|
164
|
+
path: ["derogation"],
|
|
165
|
+
message: isDerogation ? "a derogation must name which Art. 49 ground it relies on" : "only a DEROGATION mechanism names a derogation",
|
|
166
|
+
});
|
|
167
|
+
}
|
|
168
|
+
});
|
|
169
|
+
/**
|
|
170
|
+
* The operator's transfer determination for one register entry.
|
|
171
|
+
*
|
|
172
|
+
* Carried by the ENTRY, not the provider, and not per subprocessor: a vendor's regions change when it opens
|
|
173
|
+
* a data centre, a mechanism changes when a court rules, and the processor's own contract is what binds its
|
|
174
|
+
* onward transfers to its subprocessors — so the determination for reaching this processor covers the chain
|
|
175
|
+
* behind it. It is OPTIONAL, and absence means "not determined": the `international-transfers` fact then
|
|
176
|
+
* answers nothing, because a register with an undetermined entry cannot support either "no transfer" or a
|
|
177
|
+
* list of safeguards.
|
|
178
|
+
*/
|
|
179
|
+
export const ProcessorTransferDeterminationSchema = z.discriminatedUnion("kind", [
|
|
180
|
+
z.strictObject({
|
|
181
|
+
kind: z.literal(ProcessorTransferDeterminationKind.NO_TRANSFER).systemEnum("ProcessorTransferDeterminationKind"),
|
|
182
|
+
/** Why none of the regions is outside the origin jurisdictions — the comparison the framework cannot make. */
|
|
183
|
+
rationale: z.string().trim().min(1),
|
|
184
|
+
}),
|
|
185
|
+
z
|
|
186
|
+
.strictObject({
|
|
187
|
+
kind: z.literal(ProcessorTransferDeterminationKind.TRANSFER).systemEnum("ProcessorTransferDeterminationKind"),
|
|
188
|
+
/** One safeguard per origin jurisdiction whose data reaches this processor. */
|
|
189
|
+
safeguards: z.array(ProcessorTransferSafeguardSchema).min(1),
|
|
190
|
+
})
|
|
191
|
+
.superRefine((determination, context) => {
|
|
192
|
+
const origins = determination.safeguards.map((safeguard) => safeguard.originJurisdictionSlug);
|
|
193
|
+
if (new Set(origins).size !== origins.length) {
|
|
194
|
+
context.addIssue({ code: "custom", path: ["safeguards"], message: "one safeguard per origin jurisdiction" });
|
|
195
|
+
}
|
|
196
|
+
}),
|
|
197
|
+
]);
|
|
78
198
|
const ProcessorIdentityFieldsSchema = z.object({
|
|
79
199
|
/**
|
|
80
200
|
* The processor's LEGAL entity — the party a data-protection obligation actually binds.
|
|
@@ -105,11 +225,13 @@ const ProcessorIdentityFieldsSchema = z.object({
|
|
|
105
225
|
* nobody has looked.
|
|
106
226
|
*/
|
|
107
227
|
subprocessors: z.array(ProcessorSubprocessorSchema),
|
|
228
|
+
/** Whether reaching this processor is an international transfer, and under what. See {@link ProcessorTransferDeterminationSchema}. */
|
|
229
|
+
transferDetermination: ProcessorTransferDeterminationSchema.optional(),
|
|
108
230
|
});
|
|
109
231
|
/** One entry in the register — a configured provider, or a subprocessor nothing configures. */
|
|
110
232
|
export const ApplicationProcessorDeclarationSchema = z.discriminatedUnion("kind", [
|
|
111
233
|
ProcessorIdentityFieldsSchema.extend({
|
|
112
|
-
kind: z.literal(ProcessorRegisterEntryKind.CONFIGURED_PROVIDER),
|
|
234
|
+
kind: z.literal(ProcessorRegisterEntryKind.CONFIGURED_PROVIDER).systemEnum('ProcessorRegisterEntryKind'),
|
|
113
235
|
/**
|
|
114
236
|
* The configured provider this describes — the same ref the application's composition uses.
|
|
115
237
|
*
|
|
@@ -129,7 +251,7 @@ export const ApplicationProcessorDeclarationSchema = z.discriminatedUnion("kind"
|
|
|
129
251
|
purpose: z.string().trim().min(1).optional(),
|
|
130
252
|
}).strict(),
|
|
131
253
|
ProcessorIdentityFieldsSchema.extend({
|
|
132
|
-
kind: z.literal(ProcessorRegisterEntryKind.AUTHORED),
|
|
254
|
+
kind: z.literal(ProcessorRegisterEntryKind.AUTHORED).systemEnum('ProcessorRegisterEntryKind'),
|
|
133
255
|
/**
|
|
134
256
|
* A stable slug for a subprocessor the configuration never mentions — `hosting`, `cdn`,
|
|
135
257
|
* `support-desk`. Its own key, because there is no `providerRef` to borrow.
|
|
@@ -190,6 +312,7 @@ export const ApplicationProcessorRegisterSchema = z
|
|
|
190
312
|
seenSubprocessorRefs.add(processor.subprocessorRef);
|
|
191
313
|
});
|
|
192
314
|
});
|
|
315
|
+
/** @wildo_source:part:end saas.specifications.processor-register */
|
|
193
316
|
/**
|
|
194
317
|
* Every region personal data reaches THROUGH A DECLARED PROCESSOR, across both arms and their own
|
|
195
318
|
* subprocessors (issue #126).
|
|
@@ -281,4 +404,28 @@ export function processorRefsNotConfigured(configuredProviderRefs, register) {
|
|
|
281
404
|
.map((processor) => processor.providerRef)
|
|
282
405
|
.filter((providerRef) => !configured.has(providerRef));
|
|
283
406
|
}
|
|
407
|
+
/**
|
|
408
|
+
* Which configured providers are recipients, and which of those the register has not established.
|
|
409
|
+
*
|
|
410
|
+
* One function, because two readers need the same answer: the drafter's brief renders it, and the
|
|
411
|
+
* computed `recipients-and-processors` fact states it. Before this existed the brief held the rule
|
|
412
|
+
* inline, and a second copy would have been free to disagree about a self-hosted provider, which is
|
|
413
|
+
* exactly the disagreement wildo-ai/wildo-ai#208 recorded between two renderers in one section.
|
|
414
|
+
*
|
|
415
|
+
* Only an EXPLICIT `SELF_HOSTED` choice excludes a provider. A provider with no choice stays a recipient
|
|
416
|
+
* candidate: absence means nobody has answered, and assuming self-hosted would silence that gap.
|
|
417
|
+
* `configuredProviderRefs` must be the RUNTIME-scoped providers; a build-time companion provider is not in
|
|
418
|
+
* the path of anyone's data. Order follows the configured list, so the answer reads like the composition.
|
|
419
|
+
*/
|
|
420
|
+
export function classifyConfiguredProviderRecipients(configuredProviderRefs, register, choices) {
|
|
421
|
+
const operatorRunRefs = new Set(Object.entries(choices ?? {})
|
|
422
|
+
.filter(([, choice]) => choice.deploymentModel === ProviderDeploymentModel.SELF_HOSTED)
|
|
423
|
+
.map(([providerRef]) => providerRef));
|
|
424
|
+
const recipientCandidateRefs = configuredProviderRefs.filter((providerRef) => !operatorRunRefs.has(providerRef));
|
|
425
|
+
return {
|
|
426
|
+
operatorRunProviderRefs: configuredProviderRefs.filter((providerRef) => operatorRunRefs.has(providerRef)),
|
|
427
|
+
undeclaredProviderRefs: undeclaredProcessorRefs(recipientCandidateRefs, register),
|
|
428
|
+
staleProviderRefs: processorRefsNotConfigured(recipientCandidateRefs, register),
|
|
429
|
+
};
|
|
430
|
+
}
|
|
284
431
|
//# sourceMappingURL=processor-register.schemas.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"processor-register.schemas.js","sourceRoot":"","sources":["../../../../../src/_core/compliance-documents/processor-register.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AAEH;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,2BAA2B,GAAG,CAAC,CAAC,YAAY,CAAC;IACxD,6DAA6D;IAC7D,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IAC9B;;;;;OAKG;IACH,iBAAiB,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;CAC5D,CAAC,CAAC;AAGH;;;;;;;;;;;;;;;GAeG;AACH,MAAM,CAAN,IAAY,0BAKX;AALD,WAAY,0BAA0B;IACpC,oGAAoG;IACpG,yEAA2C,CAAA;IAC3C,kHAAkH;IAClH,mDAAqB,CAAA;AACvB,CAAC,EALW,0BAA0B,KAA1B,0BAA0B,QAKrC;AAED,MAAM,6BAA6B,GAAG,CAAC,CAAC,MAAM,CAAC;IAC7C;;;;;OAKG;IACH,eAAe,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC;IACzC;;;;;;;;;;;OAWG;IACH,iBAAiB,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,IAAI,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC;IAC3D;;;;;;;OAOG;IACH,aAAa,EAAE,CAAC,CAAC,KAAK,CAAC,2BAA2B,CAAC;CACpD,CAAC,CAAC;AAEH,+FAA+F;AAC/F,MAAM,CAAC,M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AO,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC;AACtC,CAAC;AAED;;;;;;;;;;;;GAYG;AACH,MAAM,UAAU,wCAAwC,CACtD,QAAkD;IAElD,OAAO,QAAQ,KAAK,SAAS,IAAI,QAAQ,CAAC,UAAU,CAAC,MAAM,KAAK,CAAC,CAAC;AACpE,CAAC;AAED;;;;;;;;;;;;GAYG;AACH,SAAS,yBAAyB,CAChC,QAAkD;IAElD,OAAO,CAAC,QAAQ,EAAE,UAAU,IAAI,EAAE,CAAC,CAAC,MAAM,CACxC,CAAC,SAAS,EAAmH,EAAE,CAC7H,SAAS,CAAC,IAAI,KAAK,0BAA0B,CAAC,mBAAmB,CACpE,CAAC;AACJ,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,uBAAuB,CACrC,sBAAyC,EACzC,QAAkD;IAElD,MAAM,QAAQ,GAAG,IAAI,GAAG,CAAC,yBAAyB,CAAC,QAAQ,CAAC,CAAC,GAAG,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,SAAS,CAAC,WAAW,CAAC,CAAC,CAAC;IACxG,OAAO,sBAAsB,CAAC,MAAM,CAAC,CAAC,WAAW,EAAE,EAAE,CAAC,CAAC,QAAQ,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC,CAAC;AACpF,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,0BAA0B,CACxC,sBAAyC,EACzC,QAAkD;IAElD,MAAM,UAAU,GAAG,IAAI,GAAG,CAAC,sBAAsB,CAAC,CAAC;IACnD,OAAO,yBAAyB,CAAC,QAAQ,CAAC;SACvC,GAAG,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,SAAS,CAAC,WAAW,CAAC;SACzC,MAAM,CAAC,CAAC,WAAW,EAAE,EAAE,CAAC,CAAC,UAAU,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC,CAAC;AAC3D,CAAC","sourcesContent":["import { z } from \"zod\";\n\n/**\n * **Who else processes personal data, under what legal identity, and where.**\n *\n * ## The gap this closes\n *\n * A configured provider establishes THAT a third party is involved and WHAT FUNCTION it performs —\n * `EngineCapability` gives email delivery, storage, payments, LLM inference, observability. It gives\n * none of the three things a reader of a privacy notice needs: the processor's legal identity, the\n * region it processes in, and its own subprocessors (issue #88).\n *\n * That gap blocks two concerns rather than one, and the second cannot be answered independently: an\n * international-transfer statement is a statement about WHERE a recipient processes, so a provider\n * carrying no region cannot support one.\n *\n * ## Declared by the APPLICATION, not derived from the provider\n *\n * A provider's legal entity is a fact about a vendor, and it is tempting to put it on the provider\n * definition so every application inherits it. It is not carried there, deliberately: what a document\n * must state is the arrangement THIS operator has — which vendor, in which region, under which\n * contract — and two applications using the same vendor can honestly differ on all three. A\n * framework-supplied identity would also be a fact the framework cannot keep true: vendors reorganise,\n * and a stale legal entity in a published notice is worse than an absent one.\n *\n * So the register is authored beside the application's other specifications and read from there. What\n * the framework contributes is the QUESTION and the gap report, never the answer.\n *\n * ## Absence is a gap with a NAME, because the configured set is already known\n *\n * The application's composition already lists its configured providers. Comparing that list against\n * this register turns \"processor identities are not established\" into \"`anthropic` is configured and\n * undeclared\" — a gap an operator can act on, per provider, rather than a sentence they cannot.\n *\n * See {@link undeclaredProcessorRefs}. An entry ABSENT from the register means nobody has established\n * that processor's identity; it never means the provider is not in use.\n */\n\n/**\n * One subprocessor a declared processor uses in turn.\n *\n * Carried because a privacy notice's recipient statement is only as true as its deepest hop: a\n * customer's data reaching a vendor's own hosting provider is a disclosure, and a notice naming only\n * the first hop understates who holds the data.\n */\nexport const ProcessorSubprocessorSchema = z.strictObject({\n /** The subprocessor's name as the processor discloses it. */\n name: z.string().trim().min(1),\n /**\n * Where this subprocessor processes, as the processor discloses it.\n *\n * Required: a subprocessor with no location cannot support the transfer statement that is the whole\n * reason for following the chain this far.\n */\n processingRegions: z.array(z.string().trim().min(1)).min(1),\n});\nexport type ProcessorSubprocessor = z.infer<typeof ProcessorSubprocessorSchema>;\n\n/**\n * WHICH KIND of subprocessor an entry describes.\n *\n * **Providers are a SUBSET of subprocessors, and this register was built as if they were the whole\n * set.** Every entry keyed on `providerRef` and the schema enforced one entry per provider, which\n * made it structurally unable to hold a subprocessor the application does not configure as a\n * provider — a hosting company, a CDN, a support tool, an accountant. Those are processors under\n * Art. 28 and belong in the same register a notice reads (issue #130).\n *\n * The discriminator exists because the two arms differ in what can be CHECKED, not merely in shape.\n * A configured-provider entry joins to the application's composition, so a claim about a provider it\n * does not configure is detectable and a configured provider with no entry is a reportable gap. An\n * authored entry joins to nothing: no configuration mentions the operator's hosting company, so the\n * framework can neither confirm it nor notice its absence. Collapsing them would present an\n * unverifiable claim with the same authority as a checkable one.\n */\nexport enum ProcessorRegisterEntryKind {\n /** A provider the application configures. Joins to `providerRef`, and its absence is reportable. */\n CONFIGURED_PROVIDER = \"CONFIGURED_PROVIDER\",\n /** A subprocessor nothing in the configuration mentions. Unverifiable by construction, and stated as authored. */\n AUTHORED = \"AUTHORED\",\n}\n\nconst ProcessorIdentityFieldsSchema = z.object({\n /**\n * The processor's LEGAL entity — the party a data-protection obligation actually binds.\n *\n * Not the brand. \"Anthropic\" is a product name; a notice, a DPA and a supervisory authority all need\n * the entity that signs.\n */\n legalEntityName: z.string().trim().min(1),\n /**\n * Where this processor processes personal data for this application.\n *\n * A LIST at the processor level rather than per capability. The issue that opened this suggested\n * per-capability regions, \"where a provider offers regional endpoints\" — declined for the reason\n * that settled the retention schedule the same day: an operator decides a small number of things and\n * defends them, and a granularity nobody maintains produces a register that is precise and wrong.\n * An operator using one vendor in two regions declares both, which is what a notice states anyway.\n *\n * Free text rather than a closed vocabulary: region names are genuinely open (`eu-west-1`, `EU`,\n * `Ireland`, `United States`), and a fixed list would be wrong for the next vendor.\n */\n processingRegions: z.array(z.string().trim().min(1)).min(1),\n /**\n * The processor's own subprocessors.\n *\n * EMPTY is a real answer — \"this processor discloses no subprocessors\" — and it is available only\n * because the whole entry is an authored declaration. An operator who has not checked omits the\n * ENTRY, not this field, keeping one clean absence axis: present means established, absent means\n * nobody has looked.\n */\n subprocessors: z.array(ProcessorSubprocessorSchema),\n});\n\n/** One entry in the register — a configured provider, or a subprocessor nothing configures. */\nexport const ApplicationProcessorDeclarationSchema = z.discriminatedUnion(\"kind\", [\n ProcessorIdentityFieldsSchema.extend({\n kind: z.literal(ProcessorRegisterEntryKind.CONFIGURED_PROVIDER),\n /**\n * The configured provider this describes — the same ref the application's composition uses.\n *\n * The join is what makes this arm checkable: a declaration naming a provider the application does\n * not configure describes a relationship it does not have, and a configured provider with no\n * declaration is the gap {@link undeclaredProcessorRefs} reports.\n */\n providerRef: z.string().trim().min(1),\n /**\n * Why this processor is used, where the capability does not already say.\n *\n * OPTIONAL on this arm alone, and the asymmetry is the point: a configured provider's purpose is\n * implied by the capability it serves — `AI_LLM` takes prompt content, `EMAIL` takes recipient\n * addresses — so restating it is a second authority for one fact. Supply it only where the\n * capability under-describes what this particular vendor does for this application.\n */\n purpose: z.string().trim().min(1).optional(),\n }).strict(),\n ProcessorIdentityFieldsSchema.extend({\n kind: z.literal(ProcessorRegisterEntryKind.AUTHORED),\n /**\n * A stable slug for a subprocessor the configuration never mentions — `hosting`, `cdn`,\n * `support-desk`. Its own key, because there is no `providerRef` to borrow.\n */\n subprocessorRef: z.string().trim().regex(/^[a-z0-9]+(?:-[a-z0-9]+)*$/),\n /**\n * Why this subprocessor is used. REQUIRED here, because nothing else can say.\n *\n * The configured-provider arm can lean on its capability; this arm has no capability, no\n * configuration and no runtime binding to imply anything. Without a purpose the entry is a name\n * and a region, which tells a reader that someone else holds their data and not what for.\n */\n purpose: z.string().trim().min(1),\n }).strict(),\n]);\nexport type ApplicationProcessorDeclaration = z.infer<typeof ApplicationProcessorDeclarationSchema>;\n\n/**\n * The application's accepted processor register.\n *\n * Deliberately NOT requiring an entry per configured provider. Requiring completeness would make the\n * register unauthorable until every vendor had been researched, which is the blocking this whole\n * capability exists to remove — a partial register is useful, and its holes are reported rather than\n * hidden.\n */\nexport const ApplicationProcessorRegisterSchema = z\n .strictObject({\n schemaVersion: z.literal(1),\n processors: z.array(ApplicationProcessorDeclarationSchema),\n })\n .superRefine((register, context) => {\n /*\n * Uniqueness PER ARM, on each arm's own key.\n *\n * Not one shared namespace: a `providerRef` and a `subprocessorRef` are addresses in different\n * spaces, and colliding them would refuse an application whose hosting company happens to share a\n * slug with a provider it configures — a refusal with no compliance meaning at all.\n */\n const seenProviderRefs = new Set<string>();\n const seenSubprocessorRefs = new Set<string>();\n\n register.processors.forEach((processor, index) => {\n if (processor.kind === ProcessorRegisterEntryKind.CONFIGURED_PROVIDER) {\n if (seenProviderRefs.has(processor.providerRef)) {\n context.addIssue({\n code: \"custom\",\n path: [\"processors\", index, \"providerRef\"],\n message: `\"${processor.providerRef}\" is declared twice; one provider carries one processor identity`,\n });\n }\n seenProviderRefs.add(processor.providerRef);\n return;\n }\n\n if (seenSubprocessorRefs.has(processor.subprocessorRef)) {\n context.addIssue({\n code: \"custom\",\n path: [\"processors\", index, \"subprocessorRef\"],\n message: `\"${processor.subprocessorRef}\" is declared twice; one subprocessor carries one identity`,\n });\n }\n seenSubprocessorRefs.add(processor.subprocessorRef);\n });\n });\nexport type ApplicationProcessorRegister = z.infer<typeof ApplicationProcessorRegisterSchema>;\n\n/**\n * Every region personal data reaches THROUGH A DECLARED PROCESSOR, across both arms and their own\n * subprocessors (issue #126).\n *\n * ## What this establishes, and the narrower claim it supports\n *\n * The transfer concern asks whether personal data leaves its origin jurisdiction. That question has\n * three inputs and the framework holds exactly one of them: WHERE declared processors process. The\n * other two — which jurisdiction is the origin, and which mechanism makes a given transfer lawful —\n * are a legal determination with a shelf life, deliberately not modelled (adequacy decisions move by\n * court ruling, so a list baked into the engine would go stale silently and emit a false statement).\n *\n * So this supports one derivable statement and it is narrower than \"no transfers\": when the register\n * declares NO processor at all, no personal data reaches a third party, therefore none is transferred\n * THROUGH ONE. What that does NOT establish is the operator's own processing — its infrastructure,\n * its staff, its own establishment — which is why a document must state the residual rather than\n * round the answer up to \"we do not transfer data internationally\".\n *\n * ## Why subprocessors count\n *\n * A processor's own subprocessors are where data actually lands, and the chain is exactly what makes\n * a transfer statement hard: an operator in France using a French vendor that runs on a US cloud has\n * a transfer, and reading only the vendor's region would miss it. Both levels contribute here for\n * that reason.\n *\n * Regions are returned deduplicated and sorted, so the same register produces the same sentence\n * between runs.\n */\nexport function processorProcessingRegions(\n register: ApplicationProcessorRegister | undefined,\n): readonly string[] {\n const regions = (register?.processors ?? []).flatMap((processor) => [\n ...processor.processingRegions,\n ...processor.subprocessors.flatMap((subprocessor) => subprocessor.processingRegions),\n ]);\n return [...new Set(regions)].sort();\n}\n\n/**\n * True when the register establishes that NO processor receives personal data.\n *\n * The one transfer statement derivable without a jurisdiction comparison, and it is deliberately\n * about the REGISTER rather than about the world: an EMPTY register means the operator declared no\n * processors, while an ABSENT register means nobody has looked. Those are opposite states and the\n * function refuses to conflate them — absent returns `false`, because \"nobody checked\" must never\n * produce \"nothing is transferred\".\n *\n * That distinction is the whole reason the register's own schema does not require an entry per\n * configured provider: a partial register is useful and its holes are reported, but a MISSING one\n * cannot support a negative claim about anything.\n */\nexport function registerEstablishesNoProcessorRecipients(\n register: ApplicationProcessorRegister | undefined,\n): boolean {\n return register !== undefined && register.processors.length === 0;\n}\n\n/**\n * The entries that JOIN to a configured provider — the only arm either gap function can reason about.\n *\n * Both functions compare the register against the application's configured provider set, and an\n * AUTHORED entry is by construction not in that set: nothing configures the operator's hosting\n * company. Before the register grew its second arm they iterated every entry and read `providerRef`\n * off it, which the compiler now refuses — and rightly, because the answer would have been wrong in\n * both directions at once. Every authored entry would have been reported as \"naming a provider the\n * application does not configure\", and the real gap list would have been drowned in false ones.\n *\n * Extracted rather than inlined twice so the two functions cannot drift about what they are\n * comparing.\n */\nfunction configuredProviderEntries(\n register: ApplicationProcessorRegister | undefined,\n): ReadonlyArray<Extract<ApplicationProcessorDeclaration, { kind: ProcessorRegisterEntryKind.CONFIGURED_PROVIDER }>> {\n return (register?.processors ?? []).filter(\n (processor): processor is Extract<ApplicationProcessorDeclaration, { kind: ProcessorRegisterEntryKind.CONFIGURED_PROVIDER }> =>\n processor.kind === ProcessorRegisterEntryKind.CONFIGURED_PROVIDER,\n );\n}\n\n/**\n * Configured providers the register does not account for — the gap, per provider.\n *\n * Takes the configured set as an argument rather than reading it, so the same function serves the\n * companion (which reads the live composition) and a test (which supplies one). Order follows the\n * CONFIGURED list, so the answer is stable and reads like the composition it is about.\n */\nexport function undeclaredProcessorRefs(\n configuredProviderRefs: readonly string[],\n register: ApplicationProcessorRegister | undefined,\n): readonly string[] {\n const declared = new Set(configuredProviderEntries(register).map((processor) => processor.providerRef));\n return configuredProviderRefs.filter((providerRef) => !declared.has(providerRef));\n}\n\n/**\n * Declared processors naming a provider the application does not configure.\n *\n * The opposite error, and it is quieter: an entry left behind after a vendor was dropped keeps a\n * recipient in the notice that receives nothing. Reported rather than refused — a register is edited\n * by hand, and a stale entry is a thing to notice, not a reason to reject the file.\n */\nexport function processorRefsNotConfigured(\n configuredProviderRefs: readonly string[],\n register: ApplicationProcessorRegister | undefined,\n): readonly string[] {\n const configured = new Set(configuredProviderRefs);\n return configuredProviderEntries(register)\n .map((processor) => processor.providerRef)\n .filter((providerRef) => !configured.has(providerRef));\n}\n"]}
|
|
1
|
+
{"version":3,"file":"processor-register.schemas.js","sourceRoot":"","sources":["../../../../../src/_core/compliance-documents/processor-register.schemas.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,uBAAuB,EAA6C,MAAM,uBAAuB,CAAC;AAC3G,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,6GAA6G;AAC7G,+GAA+G;AAC/G,OAAO,0BAA0B,CAAC;AAElC,sHAAsH;AACtH;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAkCG;AAEH;;;;;;GAMG;AACH,MAAM,CAAC,MAAM,2BAA2B,GAAG,CAAC,CAAC,YAAY,CAAC;IACxD,6DAA6D;IAC7D,IAAI,EAAE,CAAC,CAAC,MAAM,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AC,QAAQ,CAAC;SACvC,GAAG,CAAC,CAAC,SAAS,EAAE,EAAE,CAAC,SAAS,CAAC,WAAW,CAAC;SACzC,MAAM,CAAC,CAAC,WAAW,EAAE,EAAE,CAAC,CAAC,UAAU,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC,CAAC;AAC3D,CAAC;AAYD;;;;;;;;;;;;GAYG;AACH,MAAM,UAAU,oCAAoC,CAClD,sBAAyC,EACzC,QAAkD,EAClD,OAAyD;IAEzD,MAAM,eAAe,GAAG,IAAI,GAAG,CAC7B,MAAM,CAAC,OAAO,CAAC,OAAO,IAAI,EAAE,CAAC;SAC1B,MAAM,CAAC,CAAC,CAAC,EAAE,MAAM,CAAC,EAAE,EAAE,CAAC,MAAM,CAAC,eAAe,KAAK,uBAAuB,CAAC,WAAW,CAAC;SACtF,GAAG,CAAC,CAAC,CAAC,WAAW,CAAC,EAAE,EAAE,CAAC,WAAW,CAAC,CACvC,CAAC;IACF,MAAM,sBAAsB,GAAG,sBAAsB,CAAC,MAAM,CAAC,CAAC,WAAW,EAAE,EAAE,CAAC,CAAC,eAAe,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC,CAAC;IACjH,OAAO;QACL,uBAAuB,EAAE,sBAAsB,CAAC,MAAM,CAAC,CAAC,WAAW,EAAE,EAAE,CAAC,eAAe,CAAC,GAAG,CAAC,WAAW,CAAC,CAAC;QACzG,sBAAsB,EAAE,uBAAuB,CAAC,sBAAsB,EAAE,QAAQ,CAAC;QACjF,iBAAiB,EAAE,0BAA0B,CAAC,sBAAsB,EAAE,QAAQ,CAAC;KAChF,CAAC;AACJ,CAAC","sourcesContent":["import { ProviderDeploymentModel, type ApplicationProviderComplianceChoices } from \"@wildo-ai/saas-models\";\nimport { z } from \"zod\";\n// Side-effect import: this module calls `.systemEnum()` at load, so the decorators must be installed first —\n// never by the importer's luck (#966). A named import used only as a type would be elided and install nothing.\nimport '@wildo-ai/zod-decorators';\n\n/** @wildo_source:part:start saas.specifications.processor-register facet:layer:shared facet:audience:app-developer */\n/**\n * **Who else processes personal data, under what legal identity, and where.**\n *\n * ## The gap this closes\n *\n * A configured provider establishes THAT a third party is involved and WHAT FUNCTION it performs —\n * `EngineCapability` gives email delivery, storage, payments, LLM inference, observability. It gives\n * none of the three things a reader of a privacy notice needs: the processor's legal identity, the\n * region it processes in, and its own subprocessors (issue #88).\n *\n * That gap blocks two concerns rather than one, and the second cannot be answered independently: an\n * international-transfer statement is a statement about WHERE a recipient processes, so a provider\n * carrying no region cannot support one.\n *\n * ## Declared by the APPLICATION, not derived from the provider\n *\n * A provider's legal entity is a fact about a vendor, and it is tempting to put it on the provider\n * definition so every application inherits it. It is not carried there, deliberately: what a document\n * must state is the arrangement THIS operator has — which vendor, in which region, under which\n * contract — and two applications using the same vendor can honestly differ on all three. A\n * framework-supplied identity would also be a fact the framework cannot keep true: vendors reorganise,\n * and a stale legal entity in a published notice is worse than an absent one.\n *\n * So the register is authored beside the application's other specifications and read from there. What\n * the framework contributes is the QUESTION and the gap report, never the answer.\n *\n * ## Absence is a gap with a NAME, because the configured set is already known\n *\n * The application's composition already lists its configured providers. Comparing that list against\n * this register turns \"processor identities are not established\" into \"`anthropic` is configured and\n * undeclared\" — a gap an operator can act on, per provider, rather than a sentence they cannot.\n *\n * See {@link undeclaredProcessorRefs}. An entry ABSENT from the register means nobody has established\n * that processor's identity; it never means the provider is not in use.\n */\n\n/**\n * One subprocessor a declared processor uses in turn.\n *\n * Carried because a privacy notice's recipient statement is only as true as its deepest hop: a\n * customer's data reaching a vendor's own hosting provider is a disclosure, and a notice naming only\n * the first hop understates who holds the data.\n */\nexport const ProcessorSubprocessorSchema = z.strictObject({\n /** The subprocessor's name as the processor discloses it. */\n name: z.string().trim().min(1),\n /**\n * Where this subprocessor processes, as the processor discloses it.\n *\n * Required: a subprocessor with no location cannot support the transfer statement that is the whole\n * reason for following the chain this far.\n */\n processingRegions: z.array(z.string().trim().min(1)).min(1),\n});\nexport type ProcessorSubprocessor = z.infer<typeof ProcessorSubprocessorSchema>;\n\n/**\n * WHICH KIND of subprocessor an entry describes.\n *\n * **Providers are a SUBSET of subprocessors, and this register was built as if they were the whole\n * set.** Every entry keyed on `providerRef` and the schema enforced one entry per provider, which\n * made it structurally unable to hold a subprocessor the application does not configure as a\n * provider — a hosting company, a CDN, a support tool, an accountant. Those are processors under\n * Art. 28 and belong in the same register a notice reads (issue #130).\n *\n * The discriminator exists because the two arms differ in what can be CHECKED, not merely in shape.\n * A configured-provider entry joins to the application's composition, so a claim about a provider it\n * does not configure is detectable and a configured provider with no entry is a reportable gap. An\n * authored entry joins to nothing: no configuration mentions the operator's hosting company, so the\n * framework can neither confirm it nor notice its absence. Collapsing them would present an\n * unverifiable claim with the same authority as a checkable one.\n */\nexport enum ProcessorRegisterEntryKind {\n /** A provider the application configures. Joins to `providerRef`, and its absence is reportable. */\n CONFIGURED_PROVIDER = \"CONFIGURED_PROVIDER\",\n /** A subprocessor nothing in the configuration mentions. Unverifiable by construction, and stated as authored. */\n AUTHORED = \"AUTHORED\",\n}\n\n/**\n * The instrument that makes a transfer of personal data out of its origin jurisdiction lawful.\n *\n * spec-cite: GDPR Chapter V — Art. 45 (adequacy), Art. 46(2)(b)–(f) (appropriate safeguards), Art. 47 (binding\n * corporate rules), Art. 49(1) (derogations). The UK GDPR keeps the same structure, so one vocabulary serves\n * both; the INSTRUMENT that fills a member differs by jurisdiction (the EU clauses, the UK Addendum), which is\n * why each safeguard names its instrument in prose beside the member.\n *\n * Recorded, never computed (#126): which mechanism applies is a legal determination with a shelf life —\n * an adequacy decision can be struck down while the vendor stays where it is — so the framework offers the\n * place to write it down and derives nothing from a region.\n */\nexport enum InternationalTransferMechanism {\n /** Art. 45 — the destination is covered by an adequacy decision (for the United States, the Data Privacy Framework, for a certified recipient). */\n ADEQUACY_DECISION = \"ADEQUACY_DECISION\",\n /** Art. 46(2)(c)/(d) — standard data protection clauses, or a jurisdiction's equivalent (the UK Addendum to them). */\n STANDARD_CONTRACTUAL_CLAUSES = \"STANDARD_CONTRACTUAL_CLAUSES\",\n /** Art. 46(2)(b) and Art. 47 — binding corporate rules approved for the recipient's group. */\n BINDING_CORPORATE_RULES = \"BINDING_CORPORATE_RULES\",\n /** Art. 46(2)(e) — an approved code of conduct with binding commitments of the recipient. */\n APPROVED_CODE_OF_CONDUCT = \"APPROVED_CODE_OF_CONDUCT\",\n /** Art. 46(2)(f) — an approved certification with binding commitments of the recipient. */\n APPROVED_CERTIFICATION = \"APPROVED_CERTIFICATION\",\n /** Art. 49 — a derogation for a specific situation. Requires {@link InternationalTransferDerogation}. */\n DEROGATION = \"DEROGATION\",\n}\n\n/** Which Art. 49 derogation a {@link InternationalTransferMechanism.DEROGATION} relies on. spec-cite: GDPR Art. 49(1). */\nexport enum InternationalTransferDerogation {\n /** Art. 49(1)(a) — explicit consent after being informed of the risks. */\n EXPLICIT_CONSENT = \"EXPLICIT_CONSENT\",\n /** Art. 49(1)(b) — necessary for a contract with the data subject. */\n CONTRACT_WITH_SUBJECT = \"CONTRACT_WITH_SUBJECT\",\n /** Art. 49(1)(c) — necessary for a contract concluded in the subject's interest with another party. */\n CONTRACT_IN_SUBJECT_INTEREST = \"CONTRACT_IN_SUBJECT_INTEREST\",\n /** Art. 49(1)(d) — important reasons of public interest. */\n PUBLIC_INTEREST = \"PUBLIC_INTEREST\",\n /** Art. 49(1)(e) — establishment, exercise or defence of legal claims. */\n LEGAL_CLAIMS = \"LEGAL_CLAIMS\",\n /** Art. 49(1)(f) — vital interests where the subject cannot consent. */\n VITAL_INTERESTS = \"VITAL_INTERESTS\",\n /** Art. 49(1)(g) — a transfer from a public register. */\n PUBLIC_REGISTER = \"PUBLIC_REGISTER\",\n /** Art. 49(1), second subparagraph — compelling legitimate interests, for a non-repetitive transfer. */\n COMPELLING_LEGITIMATE_INTERESTS = \"COMPELLING_LEGITIMATE_INTERESTS\",\n}\n\n/**\n * Whether reaching this processor moves personal data out of the jurisdiction it came from.\n *\n * A DETERMINATION, recorded by the operator, because regions are free text: nothing can compare\n * `United States` or `eu-west-1` with a declared operating jurisdiction, so the framework cannot tell a\n * domestic processor from a foreign one and does not guess.\n */\nexport enum ProcessorTransferDeterminationKind {\n /** Every region this processor (and its subprocessors) uses lies within the jurisdictions the data comes from. */\n NO_TRANSFER = \"NO_TRANSFER\",\n /** Personal data leaves its origin jurisdiction to reach this processor, under the safeguards named. */\n TRANSFER = \"TRANSFER\",\n}\n\n/** The safeguard one origin jurisdiction's data travels under. */\nexport const ProcessorTransferSafeguardSchema = z\n .strictObject({\n /** The jurisdiction the data leaves — one of the application's `operatingJurisdictions`. */\n originJurisdictionSlug: z.string().trim().min(1),\n mechanism: z.enum(InternationalTransferMechanism).systemEnum(\"InternationalTransferMechanism\"),\n /** Required with {@link InternationalTransferMechanism.DEROGATION}, refused otherwise. */\n derogation: z.enum(InternationalTransferDerogation).systemEnum(\"InternationalTransferDerogation\").optional(),\n /**\n * The instrument, as a reader could look it up: \"EU SCCs (Commission Decision 2021/914), Module Two\",\n * \"UK Addendum to the EU SCCs\", \"EU-US Data Privacy Framework — recipient certified\". A mechanism\n * member alone tells a reader the article, not the document that binds the recipient.\n */\n instrument: z.string().trim().min(1),\n })\n .superRefine((safeguard, context) => {\n const isDerogation = safeguard.mechanism === InternationalTransferMechanism.DEROGATION;\n if (isDerogation !== (safeguard.derogation !== undefined)) {\n context.addIssue({\n code: \"custom\",\n path: [\"derogation\"],\n message: isDerogation ? \"a derogation must name which Art. 49 ground it relies on\" : \"only a DEROGATION mechanism names a derogation\",\n });\n }\n });\nexport type ProcessorTransferSafeguard = z.infer<typeof ProcessorTransferSafeguardSchema>;\n\n/**\n * The operator's transfer determination for one register entry.\n *\n * Carried by the ENTRY, not the provider, and not per subprocessor: a vendor's regions change when it opens\n * a data centre, a mechanism changes when a court rules, and the processor's own contract is what binds its\n * onward transfers to its subprocessors — so the determination for reaching this processor covers the chain\n * behind it. It is OPTIONAL, and absence means \"not determined\": the `international-transfers` fact then\n * answers nothing, because a register with an undetermined entry cannot support either \"no transfer\" or a\n * list of safeguards.\n */\nexport const ProcessorTransferDeterminationSchema = z.discriminatedUnion(\"kind\", [\n z.strictObject({\n kind: z.literal(ProcessorTransferDeterminationKind.NO_TRANSFER).systemEnum(\"ProcessorTransferDeterminationKind\"),\n /** Why none of the regions is outside the origin jurisdictions — the comparison the framework cannot make. */\n rationale: z.string().trim().min(1),\n }),\n z\n .strictObject({\n kind: z.literal(ProcessorTransferDeterminationKind.TRANSFER).systemEnum(\"ProcessorTransferDeterminationKind\"),\n /** One safeguard per origin jurisdiction whose data reaches this processor. */\n safeguards: z.array(ProcessorTransferSafeguardSchema).min(1),\n })\n .superRefine((determination, context) => {\n const origins = determination.safeguards.map((safeguard) => safeguard.originJurisdictionSlug);\n if (new Set(origins).size !== origins.length) {\n context.addIssue({ code: \"custom\", path: [\"safeguards\"], message: \"one safeguard per origin jurisdiction\" });\n }\n }),\n]);\nexport type ProcessorTransferDetermination = z.infer<typeof ProcessorTransferDeterminationSchema>;\n\nconst ProcessorIdentityFieldsSchema = z.object({\n /**\n * The processor's LEGAL entity — the party a data-protection obligation actually binds.\n *\n * Not the brand. \"Anthropic\" is a product name; a notice, a DPA and a supervisory authority all need\n * the entity that signs.\n */\n legalEntityName: z.string().trim().min(1),\n /**\n * Where this processor processes personal data for this application.\n *\n * A LIST at the processor level rather than per capability. The issue that opened this suggested\n * per-capability regions, \"where a provider offers regional endpoints\" — declined for the reason\n * that settled the retention schedule the same day: an operator decides a small number of things and\n * defends them, and a granularity nobody maintains produces a register that is precise and wrong.\n * An operator using one vendor in two regions declares both, which is what a notice states anyway.\n *\n * Free text rather than a closed vocabulary: region names are genuinely open (`eu-west-1`, `EU`,\n * `Ireland`, `United States`), and a fixed list would be wrong for the next vendor.\n */\n processingRegions: z.array(z.string().trim().min(1)).min(1),\n /**\n * The processor's own subprocessors.\n *\n * EMPTY is a real answer — \"this processor discloses no subprocessors\" — and it is available only\n * because the whole entry is an authored declaration. An operator who has not checked omits the\n * ENTRY, not this field, keeping one clean absence axis: present means established, absent means\n * nobody has looked.\n */\n subprocessors: z.array(ProcessorSubprocessorSchema),\n /** Whether reaching this processor is an international transfer, and under what. See {@link ProcessorTransferDeterminationSchema}. */\n transferDetermination: ProcessorTransferDeterminationSchema.optional(),\n});\n\n/** One entry in the register — a configured provider, or a subprocessor nothing configures. */\nexport const ApplicationProcessorDeclarationSchema = z.discriminatedUnion(\"kind\", [\n ProcessorIdentityFieldsSchema.extend({\n kind: z.literal(ProcessorRegisterEntryKind.CONFIGURED_PROVIDER).systemEnum('ProcessorRegisterEntryKind'),\n /**\n * The configured provider this describes — the same ref the application's composition uses.\n *\n * The join is what makes this arm checkable: a declaration naming a provider the application does\n * not configure describes a relationship it does not have, and a configured provider with no\n * declaration is the gap {@link undeclaredProcessorRefs} reports.\n */\n providerRef: z.string().trim().min(1),\n /**\n * Why this processor is used, where the capability does not already say.\n *\n * OPTIONAL on this arm alone, and the asymmetry is the point: a configured provider's purpose is\n * implied by the capability it serves — `AI_LLM` takes prompt content, `EMAIL` takes recipient\n * addresses — so restating it is a second authority for one fact. Supply it only where the\n * capability under-describes what this particular vendor does for this application.\n */\n purpose: z.string().trim().min(1).optional(),\n }).strict(),\n ProcessorIdentityFieldsSchema.extend({\n kind: z.literal(ProcessorRegisterEntryKind.AUTHORED).systemEnum('ProcessorRegisterEntryKind'),\n /**\n * A stable slug for a subprocessor the configuration never mentions — `hosting`, `cdn`,\n * `support-desk`. Its own key, because there is no `providerRef` to borrow.\n */\n subprocessorRef: z.string().trim().regex(/^[a-z0-9]+(?:-[a-z0-9]+)*$/),\n /**\n * Why this subprocessor is used. REQUIRED here, because nothing else can say.\n *\n * The configured-provider arm can lean on its capability; this arm has no capability, no\n * configuration and no runtime binding to imply anything. Without a purpose the entry is a name\n * and a region, which tells a reader that someone else holds their data and not what for.\n */\n purpose: z.string().trim().min(1),\n }).strict(),\n]);\nexport type ApplicationProcessorDeclaration = z.infer<typeof ApplicationProcessorDeclarationSchema>;\n\n/**\n * The application's accepted processor register.\n *\n * Deliberately NOT requiring an entry per configured provider. Requiring completeness would make the\n * register unauthorable until every vendor had been researched, which is the blocking this whole\n * capability exists to remove — a partial register is useful, and its holes are reported rather than\n * hidden.\n */\nexport const ApplicationProcessorRegisterSchema = z\n .strictObject({\n schemaVersion: z.literal(1),\n processors: z.array(ApplicationProcessorDeclarationSchema),\n })\n .superRefine((register, context) => {\n /*\n * Uniqueness PER ARM, on each arm's own key.\n *\n * Not one shared namespace: a `providerRef` and a `subprocessorRef` are addresses in different\n * spaces, and colliding them would refuse an application whose hosting company happens to share a\n * slug with a provider it configures — a refusal with no compliance meaning at all.\n */\n const seenProviderRefs = new Set<string>();\n const seenSubprocessorRefs = new Set<string>();\n\n register.processors.forEach((processor, index) => {\n if (processor.kind === ProcessorRegisterEntryKind.CONFIGURED_PROVIDER) {\n if (seenProviderRefs.has(processor.providerRef)) {\n context.addIssue({\n code: \"custom\",\n path: [\"processors\", index, \"providerRef\"],\n message: `\"${processor.providerRef}\" is declared twice; one provider carries one processor identity`,\n });\n }\n seenProviderRefs.add(processor.providerRef);\n return;\n }\n\n if (seenSubprocessorRefs.has(processor.subprocessorRef)) {\n context.addIssue({\n code: \"custom\",\n path: [\"processors\", index, \"subprocessorRef\"],\n message: `\"${processor.subprocessorRef}\" is declared twice; one subprocessor carries one identity`,\n });\n }\n seenSubprocessorRefs.add(processor.subprocessorRef);\n });\n });\nexport type ApplicationProcessorRegister = z.infer<typeof ApplicationProcessorRegisterSchema>;\n/** @wildo_source:part:end saas.specifications.processor-register */\n\n/**\n * Every region personal data reaches THROUGH A DECLARED PROCESSOR, across both arms and their own\n * subprocessors (issue #126).\n *\n * ## What this establishes, and the narrower claim it supports\n *\n * The transfer concern asks whether personal data leaves its origin jurisdiction. That question has\n * three inputs and the framework holds exactly one of them: WHERE declared processors process. The\n * other two — which jurisdiction is the origin, and which mechanism makes a given transfer lawful —\n * are a legal determination with a shelf life, deliberately not modelled (adequacy decisions move by\n * court ruling, so a list baked into the engine would go stale silently and emit a false statement).\n *\n * So this supports one derivable statement and it is narrower than \"no transfers\": when the register\n * declares NO processor at all, no personal data reaches a third party, therefore none is transferred\n * THROUGH ONE. What that does NOT establish is the operator's own processing — its infrastructure,\n * its staff, its own establishment — which is why a document must state the residual rather than\n * round the answer up to \"we do not transfer data internationally\".\n *\n * ## Why subprocessors count\n *\n * A processor's own subprocessors are where data actually lands, and the chain is exactly what makes\n * a transfer statement hard: an operator in France using a French vendor that runs on a US cloud has\n * a transfer, and reading only the vendor's region would miss it. Both levels contribute here for\n * that reason.\n *\n * Regions are returned deduplicated and sorted, so the same register produces the same sentence\n * between runs.\n */\nexport function processorProcessingRegions(\n register: ApplicationProcessorRegister | undefined,\n): readonly string[] {\n const regions = (register?.processors ?? []).flatMap((processor) => [\n ...processor.processingRegions,\n ...processor.subprocessors.flatMap((subprocessor) => subprocessor.processingRegions),\n ]);\n return [...new Set(regions)].sort();\n}\n\n/**\n * True when the register establishes that NO processor receives personal data.\n *\n * The one transfer statement derivable without a jurisdiction comparison, and it is deliberately\n * about the REGISTER rather than about the world: an EMPTY register means the operator declared no\n * processors, while an ABSENT register means nobody has looked. Those are opposite states and the\n * function refuses to conflate them — absent returns `false`, because \"nobody checked\" must never\n * produce \"nothing is transferred\".\n *\n * That distinction is the whole reason the register's own schema does not require an entry per\n * configured provider: a partial register is useful and its holes are reported, but a MISSING one\n * cannot support a negative claim about anything.\n */\nexport function registerEstablishesNoProcessorRecipients(\n register: ApplicationProcessorRegister | undefined,\n): boolean {\n return register !== undefined && register.processors.length === 0;\n}\n\n/**\n * The entries that JOIN to a configured provider — the only arm either gap function can reason about.\n *\n * Both functions compare the register against the application's configured provider set, and an\n * AUTHORED entry is by construction not in that set: nothing configures the operator's hosting\n * company. Before the register grew its second arm they iterated every entry and read `providerRef`\n * off it, which the compiler now refuses — and rightly, because the answer would have been wrong in\n * both directions at once. Every authored entry would have been reported as \"naming a provider the\n * application does not configure\", and the real gap list would have been drowned in false ones.\n *\n * Extracted rather than inlined twice so the two functions cannot drift about what they are\n * comparing.\n */\nfunction configuredProviderEntries(\n register: ApplicationProcessorRegister | undefined,\n): ReadonlyArray<Extract<ApplicationProcessorDeclaration, { kind: ProcessorRegisterEntryKind.CONFIGURED_PROVIDER }>> {\n return (register?.processors ?? []).filter(\n (processor): processor is Extract<ApplicationProcessorDeclaration, { kind: ProcessorRegisterEntryKind.CONFIGURED_PROVIDER }> =>\n processor.kind === ProcessorRegisterEntryKind.CONFIGURED_PROVIDER,\n );\n}\n\n/**\n * Configured providers the register does not account for — the gap, per provider.\n *\n * Takes the configured set as an argument rather than reading it, so the same function serves the\n * companion (which reads the live composition) and a test (which supplies one). Order follows the\n * CONFIGURED list, so the answer is stable and reads like the composition it is about.\n */\nexport function undeclaredProcessorRefs(\n configuredProviderRefs: readonly string[],\n register: ApplicationProcessorRegister | undefined,\n): readonly string[] {\n const declared = new Set(configuredProviderEntries(register).map((processor) => processor.providerRef));\n return configuredProviderRefs.filter((providerRef) => !declared.has(providerRef));\n}\n\n/**\n * Declared processors naming a provider the application does not configure.\n *\n * The opposite error, and it is quieter: an entry left behind after a vendor was dropped keeps a\n * recipient in the notice that receives nothing. Reported rather than refused — a register is edited\n * by hand, and a stale entry is a thing to notice, not a reason to reject the file.\n */\nexport function processorRefsNotConfigured(\n configuredProviderRefs: readonly string[],\n register: ApplicationProcessorRegister | undefined,\n): readonly string[] {\n const configured = new Set(configuredProviderRefs);\n return configuredProviderEntries(register)\n .map((processor) => processor.providerRef)\n .filter((providerRef) => !configured.has(providerRef));\n}\n\n/** The configured providers, sorted by what the register and the deployment choices establish about each. */\nexport interface ConfiguredProviderRecipientClassification {\n /** Providers the operator declared `SELF_HOSTED`. No data leaves the operator, so none is a recipient. */\n readonly operatorRunProviderRefs: readonly string[];\n /** Recipient candidates with no register entry: in use, identity not established. */\n readonly undeclaredProviderRefs: readonly string[];\n /** Register entries naming a provider no recipient candidate configures, which must not be published as recipients. */\n readonly staleProviderRefs: readonly string[];\n}\n\n/**\n * Which configured providers are recipients, and which of those the register has not established.\n *\n * One function, because two readers need the same answer: the drafter's brief renders it, and the\n * computed `recipients-and-processors` fact states it. Before this existed the brief held the rule\n * inline, and a second copy would have been free to disagree about a self-hosted provider, which is\n * exactly the disagreement wildo-ai/wildo-ai#208 recorded between two renderers in one section.\n *\n * Only an EXPLICIT `SELF_HOSTED` choice excludes a provider. A provider with no choice stays a recipient\n * candidate: absence means nobody has answered, and assuming self-hosted would silence that gap.\n * `configuredProviderRefs` must be the RUNTIME-scoped providers; a build-time companion provider is not in\n * the path of anyone's data. Order follows the configured list, so the answer reads like the composition.\n */\nexport function classifyConfiguredProviderRecipients(\n configuredProviderRefs: readonly string[],\n register: ApplicationProcessorRegister | undefined,\n choices: ApplicationProviderComplianceChoices | undefined,\n): ConfiguredProviderRecipientClassification {\n const operatorRunRefs = new Set(\n Object.entries(choices ?? {})\n .filter(([, choice]) => choice.deploymentModel === ProviderDeploymentModel.SELF_HOSTED)\n .map(([providerRef]) => providerRef),\n );\n const recipientCandidateRefs = configuredProviderRefs.filter((providerRef) => !operatorRunRefs.has(providerRef));\n return {\n operatorRunProviderRefs: configuredProviderRefs.filter((providerRef) => operatorRunRefs.has(providerRef)),\n undeclaredProviderRefs: undeclaredProcessorRefs(recipientCandidateRefs, register),\n staleProviderRefs: processorRefsNotConfigured(recipientCandidateRefs, register),\n };\n}\n"]}
|
|
@@ -42,6 +42,66 @@ export declare enum ComplianceRegime {
|
|
|
42
42
|
*/
|
|
43
43
|
CCPA_CPRA = "CCPA_CPRA"
|
|
44
44
|
}
|
|
45
|
+
/**
|
|
46
|
+
* Where each regime REACHES, as jurisdiction slugs measured against the ones an application declares
|
|
47
|
+
* in `operatingJurisdictions`.
|
|
48
|
+
*
|
|
49
|
+
* TOTAL over {@link ComplianceRegime} by its type, so a third regime cannot be added without saying
|
|
50
|
+
* where it applies — the alternative, a lookup that silently answers "nowhere" for a member nobody
|
|
51
|
+
* mapped, is how a regime enters the vocabulary and binds no application.
|
|
52
|
+
*
|
|
53
|
+
* ## Why a jurisdiction and not a recorded posture answer
|
|
54
|
+
*
|
|
55
|
+
* `regimes` was ALWAYS EMPTY for every application (#1161), because the only thing that could have
|
|
56
|
+
* filled it was a free-prose compliance constraint on the vision, and scanning prose for the token
|
|
57
|
+
* `GDPR` would manufacture a structured posture out of a sentence. That refusal was right, and it
|
|
58
|
+
* left the field with no producer: every application's privacy notice derived DEFERRED, including one
|
|
59
|
+
* whose configuration says plainly that it operates in the EU.
|
|
60
|
+
*
|
|
61
|
+
* `operatingJurisdictions` is the declaration that already decides this (#229) — typed, committed,
|
|
62
|
+
* diffable, and carrying a `basis` sentence per jurisdiction. So the regime is DERIVED from where the
|
|
63
|
+
* application says it operates, never recorded a second time and never asked of a human.
|
|
64
|
+
*/
|
|
65
|
+
export declare const COMPLIANCE_REGIME_JURISDICTIONAL_REACH: Readonly<Record<ComplianceRegime, readonly string[]>>;
|
|
66
|
+
/** What {@link deriveComplianceRegimes} answers: the regimes, and what it could not place. */
|
|
67
|
+
export interface DerivedComplianceRegimes {
|
|
68
|
+
/** Every regime whose territory overlaps a declared jurisdiction. Sorted, so the answer is stable. */
|
|
69
|
+
readonly regimes: readonly ComplianceRegime[];
|
|
70
|
+
/**
|
|
71
|
+
* Declared jurisdictions no regime in the vocabulary covers — `gb`, say, whose UK GDPR this small
|
|
72
|
+
* enum does not name.
|
|
73
|
+
*
|
|
74
|
+
* REPORTED rather than dropped: an application operating somewhere the framework has no regime for
|
|
75
|
+
* is a real state, and the honest answer is to say which places those are. Silently returning only
|
|
76
|
+
* the regimes would read as "nothing else applies here", which is a claim about the law that this
|
|
77
|
+
* derivation is in no position to make.
|
|
78
|
+
*/
|
|
79
|
+
readonly jurisdictionsWithNoKnownRegime: readonly string[];
|
|
80
|
+
}
|
|
81
|
+
/**
|
|
82
|
+
* Which privacy regimes bind an application, from where it declares it operates.
|
|
83
|
+
*
|
|
84
|
+
* A regime applies when its territory and a declared jurisdiction OVERLAP, which is deliberately
|
|
85
|
+
* tested in both directions: an application declaring `fr` is reached by GDPR (`eu` contains it), and
|
|
86
|
+
* one declaring `us` reaches Californians (`us-ca` sits inside it). Testing containment one way only
|
|
87
|
+
* would miss whichever half the author of a slug happened not to write.
|
|
88
|
+
*
|
|
89
|
+
* ## The asymmetry that makes an over-broad reading the safe one
|
|
90
|
+
*
|
|
91
|
+
* The output can only ever ADD a document to the required set — `deriveRequiredDocumentSet` uses it to
|
|
92
|
+
* make a privacy notice REQUIRED, never to refuse one. So a regime derived too readily costs a
|
|
93
|
+
* document the application would be free to publish anyway, while one derived too narrowly hides an
|
|
94
|
+
* obligation behind a DEFERRED status nobody reads. Where the two errors are not equal, prefer the one
|
|
95
|
+
* that produces the document.
|
|
96
|
+
*
|
|
97
|
+
* It is NOT a legal conclusion, and nothing here should be read as one: thresholds, establishment and
|
|
98
|
+
* targeting all sit outside what a slug can say. It answers the narrower question the document lane
|
|
99
|
+
* actually asks — is there a privacy regime this application must be able to speak to.
|
|
100
|
+
*
|
|
101
|
+
* An EMPTY declaration yields no regimes, unchanged in meaning: not assessed, so the notice stays
|
|
102
|
+
* admissible rather than required. Absence is not a finding that no law applies.
|
|
103
|
+
*/
|
|
104
|
+
export declare function deriveComplianceRegimes(declaredJurisdictionSlugs: readonly string[]): DerivedComplianceRegimes;
|
|
45
105
|
/** Why a document is required, so a reader can act on the answer rather than only receiving it. */
|
|
46
106
|
export declare enum RequiredDocumentReason {
|
|
47
107
|
/** A privacy regime applies AND the application holds personal data. Both halves are necessary. */
|
|
@@ -87,9 +147,16 @@ export interface RequiredDocument {
|
|
|
87
147
|
readonly documentRef: string;
|
|
88
148
|
readonly reason: RequiredDocumentReason;
|
|
89
149
|
}
|
|
90
|
-
/**
|
|
91
|
-
|
|
92
|
-
|
|
150
|
+
/**
|
|
151
|
+
* The six document definitions the engine catalog declares.
|
|
152
|
+
*
|
|
153
|
+
* The two PUBLIC ones are re-exported from `saas-models` rather than declared here: they are the
|
|
154
|
+
* only two a browser has to name (`AppRouter` mounts `/privacy` and `/terms`), and
|
|
155
|
+
* `saas-frontend-lib` cannot reach this design-time package. One source, both directions — see
|
|
156
|
+
* {@link PUBLIC_GOVERNED_DOCUMENT_REFS}.
|
|
157
|
+
*/
|
|
158
|
+
export declare const DOCUMENT_REF_PRIVACY_NOTICE: "document:public.privacy-notice";
|
|
159
|
+
export declare const DOCUMENT_REF_SERVICE_TERMS: "document:public.service-terms";
|
|
93
160
|
export declare const DOCUMENT_REF_PROGRAM_HANDBOOK = "document:governance.program-handbook";
|
|
94
161
|
export declare const DOCUMENT_REF_SCOPE_SYSTEM_DESCRIPTION = "document:governance.scope-system-description";
|
|
95
162
|
export declare const DOCUMENT_REF_ROLES_RESPONSIBILITIES = "document:governance.roles-responsibilities";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"required-document-set.schemas.d.ts","sourceRoot":"","sources":["../../../../../src/_core/compliance-documents/required-document-set.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"required-document-set.schemas.d.ts","sourceRoot":"","sources":["../../../../../src/_core/compliance-documents/required-document-set.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,gGAAgG;AAChG,oBAAY,gBAAgB;IAC1B;;;OAGG;IACH,IAAI,SAAS;IACb;;;OAGG;IACH,SAAS,cAAc;CACxB;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,eAAO,MAAM,sCAAsC,EAAE,QAAQ,CAAC,MAAM,CAAC,gBAAgB,EAAE,SAAS,MAAM,EAAE,CAAC,CAGvG,CAAC;AAEH,8FAA8F;AAC9F,MAAM,WAAW,wBAAwB;IACvC,sGAAsG;IACtG,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,gBAAgB,EAAE,CA8BtG;AAED,oBAAY,4BAA4B;IACtC,wGAAwG;IACxG,gBAAgB,qBAAqB;IACrC,sEAAsE;IACtE,qBAAqB,0BAA0B;CAChD;AAED,MAAM,WAAW,wBAAwB;IACvC,QAAQ,CAAC,IAAI,EAAE,4BAA4B,CAAC;IAC5C,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B;AAED;;;;;;;;;;;;;;;;;GAiBG;AACH,wBAAgB,oCAAoC,CAClD,WAAW,EAAE,MAAM,EACnB,KAAK,EAAE,wBAAwB,GAC9B;IAAE,QAAQ,CAAC,EAAE,EAAE,OAAO,CAAC;IAAC,QAAQ,CAAC,MAAM,EAAE,SAAS,wBAAwB,EAAE,CAAA;CAAE,CAsChF"}
|
|
@@ -29,6 +29,7 @@
|
|
|
29
29
|
* has no reader, and producing one is the invention failure at document scale.
|
|
30
30
|
*/
|
|
31
31
|
import { z } from "zod";
|
|
32
|
+
import { PUBLIC_GOVERNED_DOCUMENT_REFS, jurisdictionReachCovers } from "@wildo-ai/saas-models";
|
|
32
33
|
/** The regimes a compliance posture can record. Deliberately small — one worldwide baseline. */
|
|
33
34
|
export var ComplianceRegime;
|
|
34
35
|
(function (ComplianceRegime) {
|
|
@@ -43,6 +44,70 @@ export var ComplianceRegime;
|
|
|
43
44
|
*/
|
|
44
45
|
ComplianceRegime["CCPA_CPRA"] = "CCPA_CPRA";
|
|
45
46
|
})(ComplianceRegime || (ComplianceRegime = {}));
|
|
47
|
+
/**
|
|
48
|
+
* Where each regime REACHES, as jurisdiction slugs measured against the ones an application declares
|
|
49
|
+
* in `operatingJurisdictions`.
|
|
50
|
+
*
|
|
51
|
+
* TOTAL over {@link ComplianceRegime} by its type, so a third regime cannot be added without saying
|
|
52
|
+
* where it applies — the alternative, a lookup that silently answers "nowhere" for a member nobody
|
|
53
|
+
* mapped, is how a regime enters the vocabulary and binds no application.
|
|
54
|
+
*
|
|
55
|
+
* ## Why a jurisdiction and not a recorded posture answer
|
|
56
|
+
*
|
|
57
|
+
* `regimes` was ALWAYS EMPTY for every application (#1161), because the only thing that could have
|
|
58
|
+
* filled it was a free-prose compliance constraint on the vision, and scanning prose for the token
|
|
59
|
+
* `GDPR` would manufacture a structured posture out of a sentence. That refusal was right, and it
|
|
60
|
+
* left the field with no producer: every application's privacy notice derived DEFERRED, including one
|
|
61
|
+
* whose configuration says plainly that it operates in the EU.
|
|
62
|
+
*
|
|
63
|
+
* `operatingJurisdictions` is the declaration that already decides this (#229) — typed, committed,
|
|
64
|
+
* diffable, and carrying a `basis` sentence per jurisdiction. So the regime is DERIVED from where the
|
|
65
|
+
* application says it operates, never recorded a second time and never asked of a human.
|
|
66
|
+
*/
|
|
67
|
+
export const COMPLIANCE_REGIME_JURISDICTIONAL_REACH = Object.freeze({
|
|
68
|
+
[ComplianceRegime.GDPR]: Object.freeze(["eu"]),
|
|
69
|
+
[ComplianceRegime.CCPA_CPRA]: Object.freeze(["us-ca"]),
|
|
70
|
+
});
|
|
71
|
+
/**
|
|
72
|
+
* Which privacy regimes bind an application, from where it declares it operates.
|
|
73
|
+
*
|
|
74
|
+
* A regime applies when its territory and a declared jurisdiction OVERLAP, which is deliberately
|
|
75
|
+
* tested in both directions: an application declaring `fr` is reached by GDPR (`eu` contains it), and
|
|
76
|
+
* one declaring `us` reaches Californians (`us-ca` sits inside it). Testing containment one way only
|
|
77
|
+
* would miss whichever half the author of a slug happened not to write.
|
|
78
|
+
*
|
|
79
|
+
* ## The asymmetry that makes an over-broad reading the safe one
|
|
80
|
+
*
|
|
81
|
+
* The output can only ever ADD a document to the required set — `deriveRequiredDocumentSet` uses it to
|
|
82
|
+
* make a privacy notice REQUIRED, never to refuse one. So a regime derived too readily costs a
|
|
83
|
+
* document the application would be free to publish anyway, while one derived too narrowly hides an
|
|
84
|
+
* obligation behind a DEFERRED status nobody reads. Where the two errors are not equal, prefer the one
|
|
85
|
+
* that produces the document.
|
|
86
|
+
*
|
|
87
|
+
* It is NOT a legal conclusion, and nothing here should be read as one: thresholds, establishment and
|
|
88
|
+
* targeting all sit outside what a slug can say. It answers the narrower question the document lane
|
|
89
|
+
* actually asks — is there a privacy regime this application must be able to speak to.
|
|
90
|
+
*
|
|
91
|
+
* An EMPTY declaration yields no regimes, unchanged in meaning: not assessed, so the notice stays
|
|
92
|
+
* admissible rather than required. Absence is not a finding that no law applies.
|
|
93
|
+
*/
|
|
94
|
+
export function deriveComplianceRegimes(declaredJurisdictionSlugs) {
|
|
95
|
+
const regimes = [];
|
|
96
|
+
const placed = new Set();
|
|
97
|
+
for (const regime of Object.values(ComplianceRegime)) {
|
|
98
|
+
const reaches = COMPLIANCE_REGIME_JURISDICTIONAL_REACH[regime];
|
|
99
|
+
const covered = declaredJurisdictionSlugs.filter((declared) => reaches.some((reach) => jurisdictionReachCovers(reach, declared) || jurisdictionReachCovers(declared, reach)));
|
|
100
|
+
if (covered.length === 0)
|
|
101
|
+
continue;
|
|
102
|
+
regimes.push(regime);
|
|
103
|
+
for (const slug of covered)
|
|
104
|
+
placed.add(slug);
|
|
105
|
+
}
|
|
106
|
+
return {
|
|
107
|
+
regimes: [...regimes].sort(),
|
|
108
|
+
jurisdictionsWithNoKnownRegime: [...new Set(declaredJurisdictionSlugs)].filter((slug) => !placed.has(slug)).sort(),
|
|
109
|
+
};
|
|
110
|
+
}
|
|
46
111
|
/** Why a document is required, so a reader can act on the answer rather than only receiving it. */
|
|
47
112
|
export var RequiredDocumentReason;
|
|
48
113
|
(function (RequiredDocumentReason) {
|
|
@@ -84,9 +149,16 @@ export const RequiredDocumentSetInputSchema = z.strictObject({
|
|
|
84
149
|
*/
|
|
85
150
|
runsGovernanceProgramme: z.boolean(),
|
|
86
151
|
});
|
|
87
|
-
/**
|
|
88
|
-
|
|
89
|
-
|
|
152
|
+
/**
|
|
153
|
+
* The six document definitions the engine catalog declares.
|
|
154
|
+
*
|
|
155
|
+
* The two PUBLIC ones are re-exported from `saas-models` rather than declared here: they are the
|
|
156
|
+
* only two a browser has to name (`AppRouter` mounts `/privacy` and `/terms`), and
|
|
157
|
+
* `saas-frontend-lib` cannot reach this design-time package. One source, both directions — see
|
|
158
|
+
* {@link PUBLIC_GOVERNED_DOCUMENT_REFS}.
|
|
159
|
+
*/
|
|
160
|
+
export const DOCUMENT_REF_PRIVACY_NOTICE = PUBLIC_GOVERNED_DOCUMENT_REFS.PRIVACY_NOTICE;
|
|
161
|
+
export const DOCUMENT_REF_SERVICE_TERMS = PUBLIC_GOVERNED_DOCUMENT_REFS.SERVICE_TERMS;
|
|
90
162
|
export const DOCUMENT_REF_PROGRAM_HANDBOOK = "document:governance.program-handbook";
|
|
91
163
|
export const DOCUMENT_REF_SCOPE_SYSTEM_DESCRIPTION = "document:governance.scope-system-description";
|
|
92
164
|
export const DOCUMENT_REF_ROLES_RESPONSIBILITIES = "document:governance.roles-responsibilities";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"required-document-set.schemas.js","sourceRoot":"","sources":["../../../../../src/_core/compliance-documents/required-document-set.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,gGAAgG;AAChG,MAAM,CAAN,IAAY,gBAWX;AAXD,WAAY,gBAAgB;IAC1B;;;OAGG;IACH,iCAAa,CAAA;IACb;;;OAGG;IACH,2CAAuB,CAAA;AACzB,CAAC,EAXW,gBAAgB,KAAhB,gBAAgB,QAW3B;AAED,mGAAmG;AACnG,MAAM,CAAN,IAAY,sBAOX;AAPD,WAAY,sBAAsB;IAChC,mGAAmG;IACnG,+FAAqE,CAAA;IACrE,6FAA6F;IAC7F,iFAAuD,CAAA;IACvD,qFAAqF;IACrF,uEAA6C,CAAA;AAC/C,CAAC,EAPW,sBAAsB,KAAtB,sBAAsB,QAOjC;AAED,4FAA4F;AAC5F,MAAM,CAAC,MAAM,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C;SACH,CAAC;IACJ,CAAC;IAED,MAAM,QAAQ,GAAG,IAAI,GAAG,CAAC,yBAAyB,CAAC,KAAK,CAAC,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC;IAC7F,IAAI,QAAQ,CAAC,GAAG,CAAC,WAAW,CAAC;QAAE,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC;IAE/D,+FAA+F;IAC/F,uEAAuE;IACvE,IAAI,WAAW,KAAK,2BAA2B,IAAI,KAAK,CAAC,iBAAiB;QAAE,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC;IAE5G,OAAO;QACL,EAAE,EAAE,KAAK;QACT,MAAM,EAAE,CAAC;gBACP,IAAI,EAAE,4BAA4B,CAAC,qBAAqB;gBACxD,IAAI,EAAE,aAAa;gBACnB,8FAA8F;gBAC9F,6CAA6C;gBAC7C,OAAO,EACL,mCAAmC,WAAW,KAAK;sBACjD,CAAC,WAAW,KAAK,0BAA0B;wBAC3C,CAAC,CAAC,2FAA2F;wBAC7F,CAAC,CAAC,WAAW,KAAK,2BAA2B;4BAC3C,CAAC,CAAC,uGAAuG;4BACzG,CAAC,CAAC,sFAAsF,CAAC;sBAC3F,+GAA+G;aACpH,CAAC;KACH,CAAC;AACJ,CAAC","sourcesContent":["/**\n * WHICH governed documents an application needs — derived from what the application is, not\n * elicited from a human and not assumed from a template.\n *\n * ## Why this exists\n *\n * `ComplianceDocumentCandidate.documentRef` was unconstrained: nothing checked that a draft named a\n * document this application actually needs. So a drafter could produce a service-terms document for\n * an application that sells nothing, or a privacy notice for one that holds no personal data, and\n * both would land as files a human is then asked to review.\n *\n * That is the same defect class as a clause asserting an undeclared fact, one level up — invention at\n * DOCUMENT scale rather than clause scale — and it gets the same treatment: a pure function over what\n * the application declared, checked before the write.\n *\n * ## Why it is DERIVED rather than declared in a compliance programme\n *\n * The obvious alternative is an authored obligation register listing the documents the operator owes.\n * That was rejected: it makes producing a privacy notice wait on somebody first authoring a programme\n * that says a privacy notice is required — a gate whose only content is a restatement of the law,\n * and one more artifact to keep in agreement with the application. Approvers and review authority\n * attach to documents AFTER they exist; deciding which documents exist is a question the codebase\n * plus a regime list already answers.\n *\n * ## An unrequired document is a THIRD disposition\n *\n * It is neither incomplete (nothing is missing) nor a false assertion (nothing untrue is stated), so\n * neither the mark-it nor the refuse-invention rule reaches it. It is refused: an unrequired document\n * has no reader, and producing one is the invention failure at document scale.\n */\n\nimport { z } from \"zod\";\n\n/** The regimes a compliance posture can record. Deliberately small — one worldwide baseline. */\nexport enum ComplianceRegime {\n /**\n * The EU General Data Protection Regulation. Binds any operator offering goods or services to\n * people in the EU, wherever the operator sits — so for most B2B SaaS this is present.\n */\n GDPR = \"GDPR\",\n /**\n * California's CCPA as amended by the CPRA. Substantially the same document SHAPE as GDPR for our\n * purposes, which is why one baseline serves both and there are no per-jurisdiction variants.\n */\n CCPA_CPRA = \"CCPA_CPRA\",\n}\n\n/** Why a document is required, so a reader can act on the answer rather than only receiving it. */\nexport enum RequiredDocumentReason {\n /** A privacy regime applies AND the application holds personal data. Both halves are necessary. */\n PRIVACY_REGIME_AND_PERSONAL_DATA = \"PRIVACY_REGIME_AND_PERSONAL_DATA\",\n /** The application sells something, so the terms on which it does are owed to a customer. */\n COMMERCIAL_MODEL_DECLARED = \"COMMERCIAL_MODEL_DECLARED\",\n /** The operator runs a governance programme that this internal policy is part of. */\n GOVERNANCE_PROGRAMME = \"GOVERNANCE_PROGRAMME\",\n}\n\n/** What the derivation reads. Every field is something the application already declared. */\nexport const RequiredDocumentSetInputSchema = z.strictObject({\n /**\n * Regimes recorded by the compliance-posture pass as `compliance`-kind constraints on the vision.\n *\n * EMPTY is a real and common state — an application whose posture has not been assessed — and it is\n * NOT read as \"no regime applies\". It suppresses the privacy notice from the REQUIRED set while\n * leaving it admissible, because concluding that no privacy law applies from the absence of an\n * assessment is exactly the negative-as-proof error.\n */\n regimes: z.array(z.enum(ComplianceRegime)),\n /**\n * True when any resource declares `ErasureRetentionMode.RETAIN_AND_IMPERSONALIZE` — the\n * factory-enforced statement that a resource holds personal data of its own.\n *\n * Derived from resource configurations by the companion's `compliance-primary-facts` behavior, and\n * true for essentially every application: the ENGINE's own identity, credential, session and\n * membership resources declare it, and every generated application inherits them.\n */\n holdsPersonalData: z.boolean(),\n /** True when the application declares any billing product — the terms it sells on are then owed. */\n declaresCommercialModel: z.boolean(),\n /**\n * True when the operator runs a governance programme the internal policies belong to.\n *\n * Separate from the two above because it is a DECISION rather than a derivation: an operator may\n * hold personal data and sell a product without running a documented assurance programme, and\n * generating four internal policies for one that does not is producing documents with no reader.\n */\n runsGovernanceProgramme: z.boolean(),\n});\nexport type RequiredDocumentSetInput = z.infer<typeof RequiredDocumentSetInputSchema>;\n\nexport interface RequiredDocument {\n readonly documentRef: string;\n readonly reason: RequiredDocumentReason;\n}\n\n/** The six document definitions the engine catalog declares. */\nexport const DOCUMENT_REF_PRIVACY_NOTICE = \"document:public.privacy-notice\";\nexport const DOCUMENT_REF_SERVICE_TERMS = \"document:public.service-terms\";\nexport const DOCUMENT_REF_PROGRAM_HANDBOOK = \"document:governance.program-handbook\";\nexport const DOCUMENT_REF_SCOPE_SYSTEM_DESCRIPTION = \"document:governance.scope-system-description\";\nexport const DOCUMENT_REF_ROLES_RESPONSIBILITIES = \"document:governance.roles-responsibilities\";\nexport const DOCUMENT_REF_DOCUMENT_RECORD_CONTROL = \"document:governance.document-record-control\";\n\n/**\n * Every document this runtime knows how to compose, required or not.\n *\n * A `documentRef` outside this set is refused as UNKNOWN rather than as unrequired, and the two\n * messages differ on purpose: an unknown ref is usually a typo or an invented document, while an\n * unrequired one is a real document produced for the wrong application.\n */\nexport const KNOWN_DOCUMENT_REFS_BY_NAME = Object.freeze({\n PRIVACY_NOTICE: DOCUMENT_REF_PRIVACY_NOTICE,\n SERVICE_TERMS: DOCUMENT_REF_SERVICE_TERMS,\n PROGRAM_HANDBOOK: DOCUMENT_REF_PROGRAM_HANDBOOK,\n SCOPE_SYSTEM_DESCRIPTION: DOCUMENT_REF_SCOPE_SYSTEM_DESCRIPTION,\n ROLES_RESPONSIBILITIES: DOCUMENT_REF_ROLES_RESPONSIBILITIES,\n DOCUMENT_RECORD_CONTROL: DOCUMENT_REF_DOCUMENT_RECORD_CONTROL,\n} as const);\n\n/**\n * The same set as a list, for membership checks that read better as one.\n *\n * DERIVED from the named bundle above rather than written twice: a seventh document added to one and\n * not the other would make a draft that the required-set check accepts and the generation contract\n * refuses, or the reverse — and neither half would fail a test of its own.\n */\nexport const KNOWN_DOCUMENT_REFS: readonly string[] = Object.freeze(Object.values(KNOWN_DOCUMENT_REFS_BY_NAME));\n\n/**\n * Derive which documents this application needs.\n *\n * Pure, total, and it merges: two branches with different declarations each derive their own answer,\n * and the merged tree derives one from the merged declarations. Nothing is stored, so there is no\n * second description of the document set to fall out of agreement with the application\n * (`.claude/rules/one-source-of-truth.md`, Rule 0).\n */\nexport function deriveRequiredDocumentSet(input: RequiredDocumentSetInput): readonly RequiredDocument[] {\n const required: RequiredDocument[] = [];\n\n /*\n * BOTH halves are necessary, and the conjunction is the interesting part.\n *\n * A regime applying does not by itself oblige a privacy notice — a service that holds no personal\n * data has nothing to disclose. And holding personal data without an assessed regime is not\n * evidence that no regime applies; it is evidence that nobody has looked. So the document becomes\n * REQUIRED only when both are established, and stays ADMISSIBLE otherwise: a drafter who wants to\n * produce it early is not blocked, and the compliance-posture pass landing later flips it to\n * required without anything being redrafted.\n */\n if (input.regimes.length > 0 && input.holdsPersonalData) {\n required.push({ documentRef: DOCUMENT_REF_PRIVACY_NOTICE, reason: RequiredDocumentReason.PRIVACY_REGIME_AND_PERSONAL_DATA });\n }\n if (input.declaresCommercialModel) {\n required.push({ documentRef: DOCUMENT_REF_SERVICE_TERMS, reason: RequiredDocumentReason.COMMERCIAL_MODEL_DECLARED });\n }\n if (input.runsGovernanceProgramme) {\n for (const documentRef of [\n DOCUMENT_REF_PROGRAM_HANDBOOK,\n DOCUMENT_REF_SCOPE_SYSTEM_DESCRIPTION,\n DOCUMENT_REF_ROLES_RESPONSIBILITIES,\n DOCUMENT_REF_DOCUMENT_RECORD_CONTROL,\n ]) {\n required.push({ documentRef, reason: RequiredDocumentReason.GOVERNANCE_PROGRAMME });\n }\n }\n return required;\n}\n\nexport enum RequiredDocumentSetIssueKind {\n /** The draft names a document no engine definition composes. Usually a typo or an invented document. */\n UNKNOWN_DOCUMENT = \"UNKNOWN_DOCUMENT\",\n /** The draft names a real document this application does not need. */\n DOCUMENT_NOT_REQUIRED = \"DOCUMENT_NOT_REQUIRED\",\n}\n\nexport interface RequiredDocumentSetIssue {\n readonly kind: RequiredDocumentSetIssueKind;\n readonly path: string;\n readonly message: string;\n}\n\n/**\n * Refuse a draft naming a document this application does not need.\n *\n * ## Why an unrequired document is REFUSED rather than marked\n *\n * The completeness states describe a document that is missing something. This document is not\n * missing anything — it should not exist. Marking it would put a document with no reader into the\n * application's specifications package and ask a human to review it, which is the cost the mark\n * mechanism exists to avoid, not an instance of it.\n *\n * ## The one case that is NOT refused, and why it matters\n *\n * A privacy notice is admissible whenever the application holds personal data, even before a\n * compliance posture has recorded a regime. Refusing it would mean an application cannot draft its\n * privacy notice until somebody completes an assessment — reintroducing exactly the ordering gate\n * this lane removed, one artifact along. The rule reads: **required means we know you need it;\n * admissible means we have no reason to say you do not.** Only the second is a refusal.\n */\nexport function validateComplianceDocumentIsRequired(\n documentRef: string,\n input: RequiredDocumentSetInput,\n): { readonly ok: boolean; readonly issues: readonly RequiredDocumentSetIssue[] } {\n if (!KNOWN_DOCUMENT_REFS.includes(documentRef)) {\n return {\n ok: false,\n issues: [{\n kind: RequiredDocumentSetIssueKind.UNKNOWN_DOCUMENT,\n path: \"documentRef\",\n message:\n `\"${documentRef}\" is not a governed document this framework composes. `\n + `Name one of: ${KNOWN_DOCUMENT_REFS.join(\", \")}.`,\n }],\n };\n }\n\n const required = new Set(deriveRequiredDocumentSet(input).map((entry) => entry.documentRef));\n if (required.has(documentRef)) return { ok: true, issues: [] };\n\n // Admissible-but-not-required: a privacy notice for an application holding personal data whose\n // regimes have not been assessed. Not a refusal — see the JSDoc above.\n if (documentRef === DOCUMENT_REF_PRIVACY_NOTICE && input.holdsPersonalData) return { ok: true, issues: [] };\n\n return {\n ok: false,\n issues: [{\n kind: RequiredDocumentSetIssueKind.DOCUMENT_NOT_REQUIRED,\n path: \"documentRef\",\n // The message names WHY it is not required, because the fix is usually to declare the missing\n // thing rather than to abandon the document.\n message:\n `this application does not need \"${documentRef}\". `\n + (documentRef === DOCUMENT_REF_SERVICE_TERMS\n ? \"Service terms are owed once the application declares a billing product; it declares none.\"\n : documentRef === DOCUMENT_REF_PRIVACY_NOTICE\n ? \"A privacy notice is owed once the application holds personal data; no resource declares that it does.\"\n : \"The governance policies belong to an assurance programme this operator does not run.\")\n + \" Declare the missing thing, or drop the document — a governed document with no reader is not worth reviewing.\",\n }],\n };\n}\n"]}
|
|
1
|
+
{"version":3,"file":"required-document-set.schemas.js","sourceRoot":"","sources":["../../../../../src/_core/compliance-documents/required-document-set.schemas.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA6BG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,6BAA6B,EAAE,uBAAuB,EAAE,MAAM,uBAAuB,CAAC;AAE/F,gGAAgG;AAChG,MAAM,CAAN,IAAY,gBAWX;AAXD,WAAY,gBAAgB;IAC1B;;;OAGG;IACH,iCAAa,CAAA;IACb;;;OAGG;IACH,2CAAuB,CAAA;AACzB,CAAC,EAXW,gBAAgB,KAAhB,gBAAgB,QAW3B;AAED;;;;;;;;;;;;;;;;;;;GAmBG;AACH,MAAM,CAAC,MAAM,sCAAsC,GAA0D,MAAM,CAAC,MAAM,CAAC;IACzH,CAAC,gBAAgB,CAAC,IAAI,CAAC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AE,CAAC;QAC/C,OAAO;YACL,EAAE,EAAE,KAAK;YACT,MAAM,EAAE,CAAC;oBACP,IAAI,EAAE,4BAA4B,CAAC,gBAAgB;oBACnD,IAAI,EAAE,aAAa;oBACnB,OAAO,EACL,IAAI,WAAW,wDAAwD;0BACrE,gBAAgB,mBAAmB,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG;iBACtD,CAAC;SACH,CAAC;IACJ,CAAC;IAED,MAAM,QAAQ,GAAG,IAAI,GAAG,CAAC,yBAAyB,CAAC,KAAK,CAAC,CAAC,GAAG,CAAC,CAAC,KAAK,EAAE,EAAE,CAAC,KAAK,CAAC,WAAW,CAAC,CAAC,CAAC;IAC7F,IAAI,QAAQ,CAAC,GAAG,CAAC,WAAW,CAAC;QAAE,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC;IAE/D,+FAA+F;IAC/F,uEAAuE;IACvE,IAAI,WAAW,KAAK,2BAA2B,IAAI,KAAK,CAAC,iBAAiB;QAAE,OAAO,EAAE,EAAE,EAAE,IAAI,EAAE,MAAM,EAAE,EAAE,EAAE,CAAC;IAE5G,OAAO;QACL,EAAE,EAAE,KAAK;QACT,MAAM,EAAE,CAAC;gBACP,IAAI,EAAE,4BAA4B,CAAC,qBAAqB;gBACxD,IAAI,EAAE,aAAa;gBACnB,8FAA8F;gBAC9F,6CAA6C;gBAC7C,OAAO,EACL,mCAAmC,WAAW,KAAK;sBACjD,CAAC,WAAW,KAAK,0BAA0B;wBAC3C,CAAC,CAAC,2FAA2F;wBAC7F,CAAC,CAAC,WAAW,KAAK,2BAA2B;4BAC3C,CAAC,CAAC,uGAAuG;4BACzG,CAAC,CAAC,sFAAsF,CAAC;sBAC3F,+GAA+G;aACpH,CAAC;KACH,CAAC;AACJ,CAAC","sourcesContent":["/**\n * WHICH governed documents an application needs — derived from what the application is, not\n * elicited from a human and not assumed from a template.\n *\n * ## Why this exists\n *\n * `ComplianceDocumentCandidate.documentRef` was unconstrained: nothing checked that a draft named a\n * document this application actually needs. So a drafter could produce a service-terms document for\n * an application that sells nothing, or a privacy notice for one that holds no personal data, and\n * both would land as files a human is then asked to review.\n *\n * That is the same defect class as a clause asserting an undeclared fact, one level up — invention at\n * DOCUMENT scale rather than clause scale — and it gets the same treatment: a pure function over what\n * the application declared, checked before the write.\n *\n * ## Why it is DERIVED rather than declared in a compliance programme\n *\n * The obvious alternative is an authored obligation register listing the documents the operator owes.\n * That was rejected: it makes producing a privacy notice wait on somebody first authoring a programme\n * that says a privacy notice is required — a gate whose only content is a restatement of the law,\n * and one more artifact to keep in agreement with the application. Approvers and review authority\n * attach to documents AFTER they exist; deciding which documents exist is a question the codebase\n * plus a regime list already answers.\n *\n * ## An unrequired document is a THIRD disposition\n *\n * It is neither incomplete (nothing is missing) nor a false assertion (nothing untrue is stated), so\n * neither the mark-it nor the refuse-invention rule reaches it. It is refused: an unrequired document\n * has no reader, and producing one is the invention failure at document scale.\n */\n\nimport { z } from \"zod\";\nimport { PUBLIC_GOVERNED_DOCUMENT_REFS, jurisdictionReachCovers } from \"@wildo-ai/saas-models\";\n\n/** The regimes a compliance posture can record. Deliberately small — one worldwide baseline. */\nexport enum ComplianceRegime {\n /**\n * The EU General Data Protection Regulation. Binds any operator offering goods or services to\n * people in the EU, wherever the operator sits — so for most B2B SaaS this is present.\n */\n GDPR = \"GDPR\",\n /**\n * California's CCPA as amended by the CPRA. Substantially the same document SHAPE as GDPR for our\n * purposes, which is why one baseline serves both and there are no per-jurisdiction variants.\n */\n CCPA_CPRA = \"CCPA_CPRA\",\n}\n\n/**\n * Where each regime REACHES, as jurisdiction slugs measured against the ones an application declares\n * in `operatingJurisdictions`.\n *\n * TOTAL over {@link ComplianceRegime} by its type, so a third regime cannot be added without saying\n * where it applies — the alternative, a lookup that silently answers \"nowhere\" for a member nobody\n * mapped, is how a regime enters the vocabulary and binds no application.\n *\n * ## Why a jurisdiction and not a recorded posture answer\n *\n * `regimes` was ALWAYS EMPTY for every application (#1161), because the only thing that could have\n * filled it was a free-prose compliance constraint on the vision, and scanning prose for the token\n * `GDPR` would manufacture a structured posture out of a sentence. That refusal was right, and it\n * left the field with no producer: every application's privacy notice derived DEFERRED, including one\n * whose configuration says plainly that it operates in the EU.\n *\n * `operatingJurisdictions` is the declaration that already decides this (#229) — typed, committed,\n * diffable, and carrying a `basis` sentence per jurisdiction. So the regime is DERIVED from where the\n * application says it operates, never recorded a second time and never asked of a human.\n */\nexport const COMPLIANCE_REGIME_JURISDICTIONAL_REACH: Readonly<Record<ComplianceRegime, readonly string[]>> = Object.freeze({\n [ComplianceRegime.GDPR]: Object.freeze([\"eu\"]),\n [ComplianceRegime.CCPA_CPRA]: Object.freeze([\"us-ca\"]),\n});\n\n/** What {@link deriveComplianceRegimes} answers: the regimes, and what it could not place. */\nexport interface DerivedComplianceRegimes {\n /** Every regime whose territory overlaps a declared jurisdiction. Sorted, so the answer is stable. */\n readonly regimes: readonly ComplianceRegime[];\n /**\n * Declared jurisdictions no regime in the vocabulary covers — `gb`, say, whose UK GDPR this small\n * enum does not name.\n *\n * REPORTED rather than dropped: an application operating somewhere the framework has no regime for\n * is a real state, and the honest answer is to say which places those are. Silently returning only\n * the regimes would read as \"nothing else applies here\", which is a claim about the law that this\n * derivation is in no position to make.\n */\n readonly jurisdictionsWithNoKnownRegime: readonly string[];\n}\n\n/**\n * Which privacy regimes bind an application, from where it declares it operates.\n *\n * A regime applies when its territory and a declared jurisdiction OVERLAP, which is deliberately\n * tested in both directions: an application declaring `fr` is reached by GDPR (`eu` contains it), and\n * one declaring `us` reaches Californians (`us-ca` sits inside it). Testing containment one way only\n * would miss whichever half the author of a slug happened not to write.\n *\n * ## The asymmetry that makes an over-broad reading the safe one\n *\n * The output can only ever ADD a document to the required set — `deriveRequiredDocumentSet` uses it to\n * make a privacy notice REQUIRED, never to refuse one. So a regime derived too readily costs a\n * document the application would be free to publish anyway, while one derived too narrowly hides an\n * obligation behind a DEFERRED status nobody reads. Where the two errors are not equal, prefer the one\n * that produces the document.\n *\n * It is NOT a legal conclusion, and nothing here should be read as one: thresholds, establishment and\n * targeting all sit outside what a slug can say. It answers the narrower question the document lane\n * actually asks — is there a privacy regime this application must be able to speak to.\n *\n * An EMPTY declaration yields no regimes, unchanged in meaning: not assessed, so the notice stays\n * admissible rather than required. Absence is not a finding that no law applies.\n */\nexport function deriveComplianceRegimes(declaredJurisdictionSlugs: readonly string[]): DerivedComplianceRegimes {\n const regimes: ComplianceRegime[] = [];\n const placed = new Set<string>();\n for (const regime of Object.values(ComplianceRegime)) {\n const reaches = COMPLIANCE_REGIME_JURISDICTIONAL_REACH[regime];\n const covered = declaredJurisdictionSlugs.filter((declared) =>\n reaches.some((reach) => jurisdictionReachCovers(reach, declared) || jurisdictionReachCovers(declared, reach)),\n );\n if (covered.length === 0) continue;\n regimes.push(regime);\n for (const slug of covered) placed.add(slug);\n }\n return {\n regimes: [...regimes].sort(),\n jurisdictionsWithNoKnownRegime: [...new Set(declaredJurisdictionSlugs)].filter((slug) => !placed.has(slug)).sort(),\n };\n}\n\n/** Why a document is required, so a reader can act on the answer rather than only receiving it. */\nexport enum RequiredDocumentReason {\n /** A privacy regime applies AND the application holds personal data. Both halves are necessary. */\n PRIVACY_REGIME_AND_PERSONAL_DATA = \"PRIVACY_REGIME_AND_PERSONAL_DATA\",\n /** The application sells something, so the terms on which it does are owed to a customer. */\n COMMERCIAL_MODEL_DECLARED = \"COMMERCIAL_MODEL_DECLARED\",\n /** The operator runs a governance programme that this internal policy is part of. */\n GOVERNANCE_PROGRAMME = \"GOVERNANCE_PROGRAMME\",\n}\n\n/** What the derivation reads. Every field is something the application already declared. */\nexport const RequiredDocumentSetInputSchema = z.strictObject({\n /**\n * Regimes recorded by the compliance-posture pass as `compliance`-kind constraints on the vision.\n *\n * EMPTY is a real and common state — an application whose posture has not been assessed — and it is\n * NOT read as \"no regime applies\". It suppresses the privacy notice from the REQUIRED set while\n * leaving it admissible, because concluding that no privacy law applies from the absence of an\n * assessment is exactly the negative-as-proof error.\n */\n regimes: z.array(z.enum(ComplianceRegime)),\n /**\n * True when any resource declares `ErasureRetentionMode.RETAIN_AND_IMPERSONALIZE` — the\n * factory-enforced statement that a resource holds personal data of its own.\n *\n * Derived from resource configurations by the companion's `compliance-primary-facts` behavior, and\n * true for essentially every application: the ENGINE's own identity, credential, session and\n * membership resources declare it, and every generated application inherits them.\n */\n holdsPersonalData: z.boolean(),\n /** True when the application declares any billing product — the terms it sells on are then owed. */\n declaresCommercialModel: z.boolean(),\n /**\n * True when the operator runs a governance programme the internal policies belong to.\n *\n * Separate from the two above because it is a DECISION rather than a derivation: an operator may\n * hold personal data and sell a product without running a documented assurance programme, and\n * generating four internal policies for one that does not is producing documents with no reader.\n */\n runsGovernanceProgramme: z.boolean(),\n});\nexport type RequiredDocumentSetInput = z.infer<typeof RequiredDocumentSetInputSchema>;\n\nexport interface RequiredDocument {\n readonly documentRef: string;\n readonly reason: RequiredDocumentReason;\n}\n\n/**\n * The six document definitions the engine catalog declares.\n *\n * The two PUBLIC ones are re-exported from `saas-models` rather than declared here: they are the\n * only two a browser has to name (`AppRouter` mounts `/privacy` and `/terms`), and\n * `saas-frontend-lib` cannot reach this design-time package. One source, both directions — see\n * {@link PUBLIC_GOVERNED_DOCUMENT_REFS}.\n */\nexport const DOCUMENT_REF_PRIVACY_NOTICE = PUBLIC_GOVERNED_DOCUMENT_REFS.PRIVACY_NOTICE;\nexport const DOCUMENT_REF_SERVICE_TERMS = PUBLIC_GOVERNED_DOCUMENT_REFS.SERVICE_TERMS;\nexport const DOCUMENT_REF_PROGRAM_HANDBOOK = \"document:governance.program-handbook\";\nexport const DOCUMENT_REF_SCOPE_SYSTEM_DESCRIPTION = \"document:governance.scope-system-description\";\nexport const DOCUMENT_REF_ROLES_RESPONSIBILITIES = \"document:governance.roles-responsibilities\";\nexport const DOCUMENT_REF_DOCUMENT_RECORD_CONTROL = \"document:governance.document-record-control\";\n\n/**\n * Every document this runtime knows how to compose, required or not.\n *\n * A `documentRef` outside this set is refused as UNKNOWN rather than as unrequired, and the two\n * messages differ on purpose: an unknown ref is usually a typo or an invented document, while an\n * unrequired one is a real document produced for the wrong application.\n */\nexport const KNOWN_DOCUMENT_REFS_BY_NAME = Object.freeze({\n PRIVACY_NOTICE: DOCUMENT_REF_PRIVACY_NOTICE,\n SERVICE_TERMS: DOCUMENT_REF_SERVICE_TERMS,\n PROGRAM_HANDBOOK: DOCUMENT_REF_PROGRAM_HANDBOOK,\n SCOPE_SYSTEM_DESCRIPTION: DOCUMENT_REF_SCOPE_SYSTEM_DESCRIPTION,\n ROLES_RESPONSIBILITIES: DOCUMENT_REF_ROLES_RESPONSIBILITIES,\n DOCUMENT_RECORD_CONTROL: DOCUMENT_REF_DOCUMENT_RECORD_CONTROL,\n} as const);\n\n/**\n * The same set as a list, for membership checks that read better as one.\n *\n * DERIVED from the named bundle above rather than written twice: a seventh document added to one and\n * not the other would make a draft that the required-set check accepts and the generation contract\n * refuses, or the reverse — and neither half would fail a test of its own.\n */\nexport const KNOWN_DOCUMENT_REFS: readonly string[] = Object.freeze(Object.values(KNOWN_DOCUMENT_REFS_BY_NAME));\n\n/**\n * Derive which documents this application needs.\n *\n * Pure, total, and it merges: two branches with different declarations each derive their own answer,\n * and the merged tree derives one from the merged declarations. Nothing is stored, so there is no\n * second description of the document set to fall out of agreement with the application\n * (`.claude/rules/one-source-of-truth.md`, Rule 0).\n */\nexport function deriveRequiredDocumentSet(input: RequiredDocumentSetInput): readonly RequiredDocument[] {\n const required: RequiredDocument[] = [];\n\n /*\n * BOTH halves are necessary, and the conjunction is the interesting part.\n *\n * A regime applying does not by itself oblige a privacy notice — a service that holds no personal\n * data has nothing to disclose. And holding personal data without an assessed regime is not\n * evidence that no regime applies; it is evidence that nobody has looked. So the document becomes\n * REQUIRED only when both are established, and stays ADMISSIBLE otherwise: a drafter who wants to\n * produce it early is not blocked, and the compliance-posture pass landing later flips it to\n * required without anything being redrafted.\n */\n if (input.regimes.length > 0 && input.holdsPersonalData) {\n required.push({ documentRef: DOCUMENT_REF_PRIVACY_NOTICE, reason: RequiredDocumentReason.PRIVACY_REGIME_AND_PERSONAL_DATA });\n }\n if (input.declaresCommercialModel) {\n required.push({ documentRef: DOCUMENT_REF_SERVICE_TERMS, reason: RequiredDocumentReason.COMMERCIAL_MODEL_DECLARED });\n }\n if (input.runsGovernanceProgramme) {\n for (const documentRef of [\n DOCUMENT_REF_PROGRAM_HANDBOOK,\n DOCUMENT_REF_SCOPE_SYSTEM_DESCRIPTION,\n DOCUMENT_REF_ROLES_RESPONSIBILITIES,\n DOCUMENT_REF_DOCUMENT_RECORD_CONTROL,\n ]) {\n required.push({ documentRef, reason: RequiredDocumentReason.GOVERNANCE_PROGRAMME });\n }\n }\n return required;\n}\n\nexport enum RequiredDocumentSetIssueKind {\n /** The draft names a document no engine definition composes. Usually a typo or an invented document. */\n UNKNOWN_DOCUMENT = \"UNKNOWN_DOCUMENT\",\n /** The draft names a real document this application does not need. */\n DOCUMENT_NOT_REQUIRED = \"DOCUMENT_NOT_REQUIRED\",\n}\n\nexport interface RequiredDocumentSetIssue {\n readonly kind: RequiredDocumentSetIssueKind;\n readonly path: string;\n readonly message: string;\n}\n\n/**\n * Refuse a draft naming a document this application does not need.\n *\n * ## Why an unrequired document is REFUSED rather than marked\n *\n * The completeness states describe a document that is missing something. This document is not\n * missing anything — it should not exist. Marking it would put a document with no reader into the\n * application's specifications package and ask a human to review it, which is the cost the mark\n * mechanism exists to avoid, not an instance of it.\n *\n * ## The one case that is NOT refused, and why it matters\n *\n * A privacy notice is admissible whenever the application holds personal data, even before a\n * compliance posture has recorded a regime. Refusing it would mean an application cannot draft its\n * privacy notice until somebody completes an assessment — reintroducing exactly the ordering gate\n * this lane removed, one artifact along. The rule reads: **required means we know you need it;\n * admissible means we have no reason to say you do not.** Only the second is a refusal.\n */\nexport function validateComplianceDocumentIsRequired(\n documentRef: string,\n input: RequiredDocumentSetInput,\n): { readonly ok: boolean; readonly issues: readonly RequiredDocumentSetIssue[] } {\n if (!KNOWN_DOCUMENT_REFS.includes(documentRef)) {\n return {\n ok: false,\n issues: [{\n kind: RequiredDocumentSetIssueKind.UNKNOWN_DOCUMENT,\n path: \"documentRef\",\n message:\n `\"${documentRef}\" is not a governed document this framework composes. `\n + `Name one of: ${KNOWN_DOCUMENT_REFS.join(\", \")}.`,\n }],\n };\n }\n\n const required = new Set(deriveRequiredDocumentSet(input).map((entry) => entry.documentRef));\n if (required.has(documentRef)) return { ok: true, issues: [] };\n\n // Admissible-but-not-required: a privacy notice for an application holding personal data whose\n // regimes have not been assessed. Not a refusal — see the JSDoc above.\n if (documentRef === DOCUMENT_REF_PRIVACY_NOTICE && input.holdsPersonalData) return { ok: true, issues: [] };\n\n return {\n ok: false,\n issues: [{\n kind: RequiredDocumentSetIssueKind.DOCUMENT_NOT_REQUIRED,\n path: \"documentRef\",\n // The message names WHY it is not required, because the fix is usually to declare the missing\n // thing rather than to abandon the document.\n message:\n `this application does not need \"${documentRef}\". `\n + (documentRef === DOCUMENT_REF_SERVICE_TERMS\n ? \"Service terms are owed once the application declares a billing product; it declares none.\"\n : documentRef === DOCUMENT_REF_PRIVACY_NOTICE\n ? \"A privacy notice is owed once the application holds personal data; no resource declares that it does.\"\n : \"The governance policies belong to an assurance programme this operator does not run.\")\n + \" Declare the missing thing, or drop the document — a governed document with no reader is not worth reviewing.\",\n }],\n };\n}\n"]}
|