@wildo-ai/framework-knowledge 1.1.2 → 1.1.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/esm/framework-knowledge.definitions.d.ts +1 -1
- package/dist/esm/framework-knowledge.definitions.d.ts.map +1 -1
- package/dist/esm/framework-knowledge.definitions.js +351 -18
- package/dist/esm/framework-knowledge.definitions.js.map +1 -1
- package/dist/esm/framework-knowledge.loader.d.ts.map +1 -1
- package/dist/esm/framework-knowledge.schemas.d.ts +1 -2
- package/dist/esm/framework-knowledge.schemas.d.ts.map +1 -1
- package/dist/esm/framework-knowledge.schemas.js.map +1 -1
- package/dist/esm/index.d.ts.map +1 -1
- package/dist/esm/playbooks/bottom_up.assemble-verify/playbook.definition.d.ts +3 -4
- package/dist/esm/playbooks/bottom_up.assemble-verify/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/bottom_up.assemble-verify/playbook.definition.js +4 -4
- package/dist/esm/playbooks/bottom_up.assemble-verify/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/bottom_up.build-decompose/playbook.definition.d.ts +3 -4
- package/dist/esm/playbooks/bottom_up.build-decompose/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/bottom_up.build-decompose/playbook.definition.js +4 -4
- package/dist/esm/playbooks/bottom_up.build-decompose/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/bottom_up.build-dispatch/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/bottom_up.build-dispatch/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/bottom_up.build-dispatch/playbook.definition.js +0 -1
- package/dist/esm/playbooks/bottom_up.build-dispatch/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/bottom_up.build-scale/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/bottom_up.build-scale/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/bottom_up.build-scale/playbook.definition.js +0 -1
- package/dist/esm/playbooks/bottom_up.build-scale/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/bottom_up.domain-plan/playbook.definition.d.ts +1 -2
- package/dist/esm/playbooks/bottom_up.domain-plan/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/bottom_up.domain-plan/playbook.definition.js +1 -2
- package/dist/esm/playbooks/bottom_up.domain-plan/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/bottom_up.foundation/playbook.definition.d.ts +2 -3
- package/dist/esm/playbooks/bottom_up.foundation/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/bottom_up.foundation/playbook.definition.js +3 -3
- package/dist/esm/playbooks/bottom_up.foundation/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/bottom_up.placement-plan/playbook.definition.d.ts +1 -2
- package/dist/esm/playbooks/bottom_up.placement-plan/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/bottom_up.placement-plan/playbook.definition.js +1 -2
- package/dist/esm/playbooks/bottom_up.placement-plan/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/refinement.compliance-document-candidate/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/refinement.compliance-document-candidate/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/refinement.compliance-document-candidate/playbook.definition.js +0 -1
- package/dist/esm/playbooks/refinement.compliance-document-candidate/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/refinement.document-facts/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/refinement.document-facts/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/refinement.document-facts/playbook.definition.js +0 -1
- package/dist/esm/playbooks/refinement.document-facts/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.brand-identity/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.brand-identity/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.brand-identity/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.brand-identity/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.business-model/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.business-model/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.business-model/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.business-model/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.capability-map/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.capability-map/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.capability-map/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.capability-map/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.compliance-analysis/playbook.definition.d.ts +0 -2
- package/dist/esm/playbooks/top_down.compliance-analysis/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.compliance-analysis/playbook.definition.js +2 -2
- package/dist/esm/playbooks/top_down.compliance-analysis/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.compliance-conception/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.compliance-conception/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.compliance-conception/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.compliance-conception/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.compliance-evidence-adequacy/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.compliance-evidence-adequacy/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.compliance-evidence-adequacy/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.compliance-evidence-adequacy/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.compliance-posture/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.compliance-posture/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.compliance-posture/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.compliance-posture/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.compliance-research/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.compliance-research/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.compliance-research/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.compliance-research/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.market-analysis/playbook.definition.d.ts +0 -2
- package/dist/esm/playbooks/top_down.market-analysis/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.market-analysis/playbook.definition.js +9 -4
- package/dist/esm/playbooks/top_down.market-analysis/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.market-evidence-adequacy/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.market-evidence-adequacy/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.market-evidence-adequacy/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.market-evidence-adequacy/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.market-research/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.market-research/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.market-research/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.market-research/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.market-snapshot-produce/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.market-snapshot-produce/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.market-snapshot-produce/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.market-snapshot-produce/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.phase-gate/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.phase-gate/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.phase-gate/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.phase-gate/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.requirements-definition/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.requirements-definition/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.requirements-definition/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.requirements-definition/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.scope-roadmap/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.scope-roadmap/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.scope-roadmap/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.scope-roadmap/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.value-proposition/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.value-proposition/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.value-proposition/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.value-proposition/playbook.definition.js.map +1 -1
- package/dist/esm/playbooks/top_down.vision-elicitation/playbook.definition.d.ts +0 -1
- package/dist/esm/playbooks/top_down.vision-elicitation/playbook.definition.d.ts.map +1 -1
- package/dist/esm/playbooks/top_down.vision-elicitation/playbook.definition.js +0 -1
- package/dist/esm/playbooks/top_down.vision-elicitation/playbook.definition.js.map +1 -1
- package/dist/knowledge/assurance-authority-bases/wildo-safe-baseline-v1/authority-basis.json +1 -1
- package/dist/knowledge/manifest.json +8 -9
- package/dist/knowledge/playbooks/bottom_up.build-decompose/method.md +13 -70
- package/dist/knowledge/playbooks/bottom_up.build-decompose/playbook.json +11 -19
- package/dist/knowledge/playbooks/bottom_up.build-dispatch/method.md +5 -88
- package/dist/knowledge/playbooks/bottom_up.build-dispatch/playbook.json +15 -8
- package/dist/knowledge/playbooks/bottom_up.build-scale/method.md +4 -5
- package/dist/knowledge/playbooks/bottom_up.build-scale/playbook.json +15 -8
- package/dist/knowledge/playbooks/bottom_up.domain-plan/method.md +4 -0
- package/dist/knowledge/playbooks/bottom_up.domain-plan/playbook.json +8 -7
- package/dist/knowledge/playbooks/bottom_up.foundation/method.md +22 -49
- package/dist/knowledge/playbooks/bottom_up.foundation/playbook.json +8 -17
- package/dist/knowledge/playbooks/refinement.compliance-document-candidate/method.md +15 -780
- package/dist/knowledge/playbooks/refinement.compliance-document-candidate/playbook.json +11 -11
- package/dist/knowledge/playbooks/refinement.document-facts/method.md +20 -141
- package/dist/knowledge/playbooks/refinement.document-facts/playbook.json +15 -10
- package/dist/knowledge/playbooks/top_down.brand-identity/method.md +3 -2
- package/dist/knowledge/playbooks/top_down.brand-identity/playbook.json +16 -11
- package/dist/knowledge/playbooks/top_down.business-model/playbook.json +14 -6
- package/dist/knowledge/playbooks/top_down.capability-map/method.md +4 -2
- package/dist/knowledge/playbooks/top_down.capability-map/playbook.json +16 -7
- package/dist/knowledge/playbooks/top_down.compliance-posture/method.md +4 -21
- package/dist/knowledge/playbooks/top_down.compliance-posture/playbook.json +65 -16
- package/dist/knowledge/playbooks/{top_down.market-snapshot-produce → top_down.market-analysis}/evaluation-protocol.json +1 -1
- package/dist/knowledge/playbooks/{top_down.market-snapshot-produce → top_down.market-analysis}/evaluation-treatment.json +1 -1
- package/dist/knowledge/playbooks/top_down.market-analysis/method.md +165 -51
- package/dist/knowledge/playbooks/top_down.market-analysis/playbook.json +43 -23
- package/dist/knowledge/playbooks/top_down.phase-gate/method.md +4 -8
- package/dist/knowledge/playbooks/top_down.phase-gate/playbook.json +7 -9
- package/dist/knowledge/playbooks/top_down.requirements-definition/method.md +7 -9
- package/dist/knowledge/playbooks/top_down.requirements-definition/playbook.json +15 -7
- package/dist/knowledge/playbooks/top_down.scope-roadmap/method.md +3 -3
- package/dist/knowledge/playbooks/top_down.scope-roadmap/playbook.json +16 -11
- package/dist/knowledge/playbooks/top_down.value-proposition/method.md +4 -2
- package/dist/knowledge/playbooks/top_down.value-proposition/playbook.json +15 -7
- package/dist/knowledge/playbooks/top_down.vision-elicitation/method.md +2 -2
- package/dist/knowledge/playbooks/top_down.vision-elicitation/playbook.json +16 -11
- package/dist/knowledge/references/build-plan.task-graph.config.md +1 -45
- package/dist/knowledge/references/companion.technical-doc.service.md +2 -102
- package/dist/knowledge/references/example.config.app-shell.full.md +5 -0
- package/dist/knowledge/references/example.module.companion-exports.full.md +0 -1
- package/dist/knowledge/references/example.provider.backend-module-shape.md +0 -7
- package/dist/knowledge/references/example.resource.add-resource.module-factory-map.md +1 -0
- package/dist/knowledge/references/platform.config.saas.md +0 -51
- package/dist/knowledge/references/presets.models.surface-policy.md +10 -19
- package/dist/knowledge/references/saas.external-data.admin-endpoints.md +48 -0
- package/dist/knowledge/references/saas.frontend.app-level-component.configuration.md +11 -31
- package/dist/knowledge/references/saas.frontend.app-level-component.vocabulary.md +1 -0
- package/dist/knowledge/references/saas.frontend.composite-view.authoring.md +0 -45
- package/dist/knowledge/references/saas.frontend.resource-operation-frontend-config.md +0 -198
- package/dist/knowledge/references/saas.models.data-mode-read-list.md +0 -164
- package/dist/knowledge/references/saas.models.engine-capabilities.md +6 -26
- package/dist/knowledge/references/saas.models.http-api-binding.md +29 -3
- package/dist/knowledge/references/saas.models.provider-capabilities.md +3 -4
- package/dist/knowledge/references/saas.models.resource-config.builder-parameters.md +2 -4
- package/dist/knowledge/references/saas.models.resource-config.resource-configuration.md +0 -2
- package/dist/knowledge/references/saas.models.resource-config.resources-registry.md +0 -14
- package/dist/knowledge/references/saas.specifications.application-document-fact-specification.contract.md +31 -11
- package/dist/knowledge/references/saas.specifications.assurance-document-blueprint.contract.md +2 -32
- package/dist/knowledge/references/saas.specifications.assurance-program.contract.md +6 -29
- package/dist/knowledge/references/saas.specifications.companion-exports.contract.md +0 -56
- package/dist/knowledge/references/saas.specifications.resource-spec-config.md +0 -22
- package/dist/knowledge/references/zod.decorators.chainable-runtime.md +0 -26
- package/dist/knowledge/references/zod.decorators.decorator-vocabulary.md +0 -45
- package/dist/knowledge/references/zod.decorators.display-edit-modes.md +1 -7
- package/dist/knowledge/references/zod.decorators.field-spec-params.md +5 -31
- package/dist/knowledge/references/zod.decorators.per-primitive-ui.md +1 -44
- package/dist/knowledge/references/zod.decorators.primitive-ui.md +0 -3
- package/dist/knowledge/references/zod.decorators.schema-metadata.md +0 -1
- package/dist/knowledge/references/zod.decorators.shared-structural-params.md +0 -15
- package/dist/knowledge/registries/assurance-authority-bases.json +2 -3
- package/dist/knowledge/registries/framework-topics.json +11 -146
- package/dist/knowledge/registries/playbooks.json +18 -154
- package/dist/knowledge/registries/source-tags.json +630 -883
- package/dist/knowledge/skills/INDEX.md +3 -4
- package/dist/knowledge/skills/brand-logo-authoring/SKILL.md +1 -2
- package/dist/knowledge/skills/compliance-document-authoring/SKILL.md +2 -16
- package/dist/knowledge/skills/compliance-document-authoring/references/document-composition-governance.md +9 -31
- package/dist/knowledge/skills/compliance-document-authoring/references/document-composition-privacy-notice.md +74 -252
- package/dist/knowledge/skills/compliance-document-authoring/references/document-composition-service-terms.md +8 -26
- package/dist/knowledge/skills/compliance-document-authoring/references/framework-application-document-fact-specification-contract.md +53 -97
- package/dist/knowledge/skills/compliance-document-authoring/references/framework-assurance-document-blueprint-contract.md +21 -84
- package/dist/knowledge/skills/config-app-shell/SKILL.md +9 -31
- package/dist/knowledge/skills/config-app-shell/references/framework-app-shell-api.md +12 -31
- package/dist/knowledge/skills/config-design-system/SKILL.md +1 -23
- package/dist/knowledge/skills/config-design-system/references/framework-surface-policy-api.md +10 -19
- package/dist/knowledge/skills/config-navigation/SKILL.md +2 -75
- package/dist/knowledge/skills/config-saas/SKILL.md +2 -19
- package/dist/knowledge/skills/config-saas/references/framework-provider-capabilities-api.md +9 -30
- package/dist/knowledge/skills/config-saas/references/framework-wildo-saas-config-api.md +0 -51
- package/dist/knowledge/skills/configure-billing/references/example-backend-provider-module-shape.md +0 -7
- package/dist/knowledge/skills/flows-actors-a2a-exposure/SKILL.md +1 -2
- package/dist/knowledge/skills/flows-actors-a2a-exposure/references/framework-flows-actors-a2a-contract.md +3 -4
- package/dist/knowledge/skills/market-companion-prompt-enrichment/SKILL.md +0 -56
- package/dist/knowledge/skills/market-companion-prompt-enrichment/references/framework-companion-behavior-api.md +0 -56
- package/dist/knowledge/skills/module-companion-exports/SKILL.md +0 -1
- package/dist/knowledge/skills/module-companion-exports/references/companion-exports-by-package.md +0 -56
- package/dist/knowledge/skills/resource-add-field/SKILL.md +3 -3
- package/dist/knowledge/skills/resource-add-field/references/framework-field-cross-layer-api.md +0 -213
- package/dist/knowledge/skills/resource-add-resource/SKILL.md +1 -2
- package/dist/knowledge/skills/resource-add-resource/references/framework-new-resource-core-config-api.md +2 -4
- package/dist/knowledge/skills/resource-config-wiring/SKILL.md +0 -15
- package/dist/knowledge/skills/resource-config-wiring/references/framework-saas-models-resource-config-api.md +2 -224
- package/dist/knowledge/skills/resource-custom-view/references/custom-view-contracts.md +0 -198
- package/dist/knowledge/skills/resource-external-data/SKILL.md +2 -0
- package/dist/knowledge/skills/resource-external-data/references/framework-http-api-binding-api.md +29 -3
- package/dist/knowledge/skills/resource-external-data/references/framework-pipeline-admin-endpoints-api.md +70 -0
- package/dist/knowledge/skills/resource-mcp-tool-exposure/SKILL.md +1 -22
- package/dist/knowledge/skills/resource-rag-source-fields/references/framework-embeddings-capability-api.md +8 -28
- package/dist/knowledge/skills/resource-schema-authoring/SKILL.md +0 -1
- package/dist/knowledge/skills/resource-schema-authoring/references/decorator-layer-map.md +0 -17
- package/dist/knowledge/skills/resource-schema-authoring/references/framework-decorator-vocabulary-api.md +0 -46
- package/dist/knowledge/skills/resource-schema-authoring/references/framework-shared-structural-params-api.md +0 -15
- package/dist/knowledge/skills/resource-schema-authoring/references/framework-zod-lifecycle-and-chainable-api.md +0 -26
- package/dist/knowledge/skills/resource-ui-behavior/references/framework-display-edit-modes-api.md +1 -7
- package/dist/knowledge/skills/resource-ui-behavior/references/framework-frontend-resource-ui-contracts-api.md +0 -198
- package/dist/knowledge/skills/resource-ui-behavior/references/framework-per-primitive-ui-api.md +1 -44
- package/dist/knowledge/skills/resource-ui-behavior/references/framework-primitive-ui-api.md +0 -3
- package/dist/knowledge/skills/spec-companion-exports/SKILL.md +0 -1
- package/dist/knowledge/skills/spec-companion-exports/references/framework-companion-exports-contract-api.md +0 -56
- package/dist/knowledge/skills/spec-resource-update/references/framework-field-spec-params-api.md +5 -31
- package/dist/knowledge/skills/spec-resource-update/references/framework-spec-resource-contracts-api.md +0 -22
- package/dist/knowledge/skills/views-composite-authoring/references/framework-composite-view-contracts-api.md +0 -45
- package/dist/knowledge/topic-index.json +220 -725
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/dist/tsconfig.tsbuildinfo +1 -1
- package/package.json +4 -4
- package/dist/knowledge/assurance-authority-bases/wildo-safe-baseline-v1/external-framework-mapping.json +0 -1
- package/dist/knowledge/playbooks/bottom_up.assemble-verify/method.md +0 -51
- package/dist/knowledge/playbooks/bottom_up.assemble-verify/playbook.json +0 -43
- package/dist/knowledge/playbooks/bottom_up.placement-plan/method.md +0 -185
- package/dist/knowledge/playbooks/bottom_up.placement-plan/playbook.json +0 -64
- package/dist/knowledge/playbooks/top_down.compliance-analysis/method.md +0 -41
- package/dist/knowledge/playbooks/top_down.compliance-analysis/playbook.json +0 -100
- package/dist/knowledge/playbooks/top_down.compliance-conception/method.md +0 -117
- package/dist/knowledge/playbooks/top_down.compliance-conception/playbook.json +0 -86
- package/dist/knowledge/playbooks/top_down.compliance-evidence-adequacy/method.md +0 -61
- package/dist/knowledge/playbooks/top_down.compliance-evidence-adequacy/playbook.json +0 -41
- package/dist/knowledge/playbooks/top_down.compliance-research/method.md +0 -76
- package/dist/knowledge/playbooks/top_down.compliance-research/playbook.json +0 -42
- package/dist/knowledge/playbooks/top_down.market-evidence-adequacy/method.md +0 -56
- package/dist/knowledge/playbooks/top_down.market-evidence-adequacy/playbook.json +0 -42
- package/dist/knowledge/playbooks/top_down.market-research/method.md +0 -68
- package/dist/knowledge/playbooks/top_down.market-research/playbook.json +0 -44
- package/dist/knowledge/playbooks/top_down.market-snapshot-produce/method.md +0 -239
- package/dist/knowledge/playbooks/top_down.market-snapshot-produce/playbook.json +0 -67
- package/dist/knowledge/references/placement-plan.config.md +0 -330
- package/dist/knowledge/references/saas.frontend.display-layout.reading-measure.md +0 -34
- package/dist/knowledge/references/saas.frontend.navigation.operation-override.md +0 -45
- package/dist/knowledge/references/saas.frontend.public-shell.identity-mode.md +0 -65
- package/dist/knowledge/references/saas.frontend.settings-hub.engine-destinations.md +0 -58
- package/dist/knowledge/references/saas.frontend.settings-hub.placement.md +0 -118
- package/dist/knowledge/references/saas.models.file-upload-grant.md +0 -179
- package/dist/knowledge/references/saas.models.navigation.surface-vocabulary.md +0 -124
- package/dist/knowledge/references/saas.models.navigation.transition-vocabulary.md +0 -99
- package/dist/knowledge/references/saas.models.navigation.zone-declaration.md +0 -127
- package/dist/knowledge/references/saas.models.resource-config.operation-variant-client-timeout.md +0 -42
- package/dist/knowledge/references/saas.specifications.application-authored-document-fact-specification.contract.md +0 -29
- package/dist/knowledge/references/zod.decorators.data-categories.md +0 -197
- package/dist/knowledge/rules/resource-schema-awareness.md +0 -77
- package/dist/knowledge/skills/config-app-shell/references/framework-public-shell-identity-api.md +0 -124
- package/dist/knowledge/skills/config-design-system/references/loading-placeholder-authoring.md +0 -47
- package/dist/knowledge/skills/config-navigation/references/framework-content-width-api.md +0 -98
- package/dist/knowledge/skills/config-navigation/references/framework-navigation-operation-override-api.md +0 -54
- package/dist/knowledge/skills/config-navigation/references/framework-navigation-vocabulary-api.md +0 -232
- package/dist/knowledge/skills/config-navigation/references/framework-navigation-zone-declaration-api.md +0 -149
- package/dist/knowledge/skills/config-navigation/references/how-navigation-resolves.md +0 -114
- package/dist/knowledge/skills/config-navigation/references/navigation-configuration-map.md +0 -133
- package/dist/knowledge/skills/config-saas/references/compliance-declarations.md +0 -111
- package/dist/knowledge/skills/resource-config-wiring/references/framework-personal-data-declaration-api.md +0 -622
- package/dist/knowledge/skills/resource-mcp-tool-exposure/references/framework-file-upload-grant-contract.md +0 -192
- package/dist/knowledge/skills/resource-schema-authoring/references/framework-personal-data-category-api.md +0 -245
- package/dist/knowledge/skills/settings-placement-authoring/SKILL.md +0 -134
- package/dist/knowledge/skills/settings-placement-authoring/references/framework-settings-destinations-catalog.md +0 -65
- package/dist/knowledge/skills/settings-placement-authoring/references/framework-settings-placement-api.md +0 -127
- /package/dist/knowledge/playbooks/{top_down.market-snapshot-produce → top_down.market-analysis}/structured-artifact-action.json +0 -0
|
@@ -155,106 +155,6 @@ export enum ActionPlacement {
|
|
|
155
155
|
DANGER_ZONE = 'danger_zone',
|
|
156
156
|
}
|
|
157
157
|
|
|
158
|
-
/**
|
|
159
|
-
* HOW an operation's action collects its input and shows its result — the chrome the user meets
|
|
160
|
-
* when they click the button.
|
|
161
|
-
*
|
|
162
|
-
* ## Why this axis exists
|
|
163
|
-
*
|
|
164
|
-
* Until this axis, one rule decided the answer for every custom operation:
|
|
165
|
-
* *has a `requestDto` ⇒ navigate*. So an action asking for a single reason string got the same
|
|
166
|
-
* full-page treatment as a multi-step wizard, and the only way out was to author
|
|
167
|
-
* `navigationOverrides` — per operation, in terms of a zone, a transition verb and an appearance.
|
|
168
|
-
* Three concepts to answer one question.
|
|
169
|
-
*
|
|
170
|
-
* This is that one question. It is a **display-only** axis: backend authorization is untouched and
|
|
171
|
-
* `roles` remain the only security authority, exactly like its siblings {@link ActionVisibility},
|
|
172
|
-
* {@link ActionPlacement} and {@link ResourceOperationActionScope}.
|
|
173
|
-
*
|
|
174
|
-
* ## It is an ALIAS, not a parallel mechanism
|
|
175
|
-
*
|
|
176
|
-
* `MODAL` and `PAGE` do not render anything themselves — they resolve to the navigation transitions
|
|
177
|
-
* that already exist (`OVERLAY`, and the ordinary chain), so there is one runtime mechanism and one
|
|
178
|
-
* set of zone/appearance/URL semantics. `DIRECT`, `POPOVER` and `INLINE` never enter navigation at
|
|
179
|
-
* all, because none of them is a destination: nothing is pushed, no zone changes, and there is
|
|
180
|
-
* nothing for a back button to pop. `INLINE` is hosted by the collection the element belongs to —
|
|
181
|
-
* see `InPlaceOperationContext` for why that is not the navigation layer's job.
|
|
182
|
-
*
|
|
183
|
-
* Consequently an explicit `navigationOverrides` entry still WINS over a presentation authored here
|
|
184
|
-
* (it is the more specific instrument, and it is checked first in the resolution chain). Author this
|
|
185
|
-
* axis to say what KIND of chrome the action wants; author `navigationOverrides` when you need to
|
|
186
|
-
* name the zone, the appearance or the viewport yourself.
|
|
187
|
-
*
|
|
188
|
-
* ## When omitted
|
|
189
|
-
*
|
|
190
|
-
* It is DERIVED from the operation — see `resolveResourceOperationActionPresentation()`. An
|
|
191
|
-
* operation that asks for nothing executes directly; a small field set opens a modal; input the
|
|
192
|
-
* framework cannot fit in an overlay (files, nested writes, a large field set) keeps the page it
|
|
193
|
-
* has always had. An operation whose `surface` is `ADDRESSABLE` always keeps its page: the author
|
|
194
|
-
* has already said it is a deep-linkable destination.
|
|
195
|
-
*/
|
|
196
|
-
export enum ResourceOperationActionPresentation {
|
|
197
|
-
/**
|
|
198
|
-
* Execute on click, with no form at all — the confirmation dialog for a risky operation is the
|
|
199
|
-
* only thing between the click and the request.
|
|
200
|
-
*
|
|
201
|
-
* Only meaningful for an operation that needs no caller input. Declaring it on an operation that
|
|
202
|
-
* DOES have required request fields would send an empty body, so the resolver refuses to derive it
|
|
203
|
-
* there and an author who declares it anyway gets the operation's fields dropped — check
|
|
204
|
-
* `requestDto` before reaching for this.
|
|
205
|
-
*/
|
|
206
|
-
DIRECT = 'direct',
|
|
207
|
-
/**
|
|
208
|
-
* A small form anchored to the button that opened it, dismissed by clicking away.
|
|
209
|
-
*
|
|
210
|
-
* The single-input idiom ("assign to…", "snooze until…"). Transient by construction: no URL, no
|
|
211
|
-
* history entry, nothing to deep-link. Use it when the surrounding context is the point — the user
|
|
212
|
-
* is reading the row they are acting on and must not lose sight of it.
|
|
213
|
-
*/
|
|
214
|
-
POPOVER = 'popover',
|
|
215
|
-
/**
|
|
216
|
-
* The element being acted on transforms in place to collect the input, leaving its neighbours
|
|
217
|
-
* visible — the row becomes the form rather than being covered by one.
|
|
218
|
-
*
|
|
219
|
-
* Use it when the surrounding rows are the point: the user is comparing, and an overlay would hide
|
|
220
|
-
* the very thing that made them act on this row.
|
|
221
|
-
*
|
|
222
|
-
* **Transient, like {@link POPOVER}, and for the same reason.** Nothing is pushed, no URL changes,
|
|
223
|
-
* and a reload returns the list to rest. An inline row-edit is a momentary state of a listing, not
|
|
224
|
-
* a place — which is also why no admin framework deep-links one, and why anything that SHOULD be
|
|
225
|
-
* linkable, reloadable or reachable by a back button wants {@link PAGE}.
|
|
226
|
-
*
|
|
227
|
-
* **It requires a collection.** The host is provided by the list the element belongs to
|
|
228
|
-
* (`InPlaceOperationProvider`); the same action rendered on a detail page, in a danger zone or in a
|
|
229
|
-
* picker has no row to transform and degrades to an overlay rather than becoming a dead button.
|
|
230
|
-
*
|
|
231
|
-
* Note it does NOT resolve to `NavigationTransition.INPLACE`. Element-level hosting uses none of
|
|
232
|
-
* what the navigation layer offers — no zone, no stack entry, no appearance — and routing it there
|
|
233
|
-
* is exactly why that transition has never done what its own docstring promises. See
|
|
234
|
-
* `InPlaceOperationContext`.
|
|
235
|
-
*/
|
|
236
|
-
INLINE = 'inline',
|
|
237
|
-
/**
|
|
238
|
-
* An overlay above the layout — the workhorse for "a handful of fields", and the default the
|
|
239
|
-
* derivation reaches for.
|
|
240
|
-
*
|
|
241
|
-
* Resolves to {@link NavigationTransition.OVERLAY}. The concrete appearance (dialog / sheet /
|
|
242
|
-
* drawer / panel) stays the app's decision, resolved from its navigation layout exactly as any
|
|
243
|
-
* other overlay: this axis says "an overlay", not "a dialog specifically". Author
|
|
244
|
-
* `navigationOverrides` when you need to name one.
|
|
245
|
-
*/
|
|
246
|
-
MODAL = 'modal',
|
|
247
|
-
/**
|
|
248
|
-
* A routable page, resolved through the ordinary navigation chain (zone transitions, viewport
|
|
249
|
-
* overrides, the framework `PUSH` fallback) — i.e. exactly the behaviour every parameterised
|
|
250
|
-
* action had before this axis existed.
|
|
251
|
-
*
|
|
252
|
-
* The right answer for complex or multi-step input, and for anything a user should be able to
|
|
253
|
-
* link to, reload, or reach with a back button.
|
|
254
|
-
*/
|
|
255
|
-
PAGE = 'page',
|
|
256
|
-
}
|
|
257
|
-
|
|
258
158
|
/**
|
|
259
159
|
* Does an operation's action target a SINGLE resource instance, or the WHOLE
|
|
260
160
|
* collection in the current scope?
|
|
@@ -383,26 +283,6 @@ export const CardActionPlacementSchema = z.object({
|
|
|
383
283
|
/** Authored 2-axis card action placement — inferred from {@link CardActionPlacementSchema}. */
|
|
384
284
|
export type CardActionPlacement = z.infer<typeof CardActionPlacementSchema>;
|
|
385
285
|
|
|
386
|
-
/**
|
|
387
|
-
* Who paints the identity GLYPH on this operation's page header.
|
|
388
|
-
*
|
|
389
|
-
* The header band renders the resource's registry icon beside the identity line by default. A
|
|
390
|
-
* `layout.header` template that composes its own record-linked glyph (a per-row kind icon, a
|
|
391
|
-
* per-family symbol) would otherwise sit BESIDE the resource icon — two glyphs naming one thing.
|
|
392
|
-
*
|
|
393
|
-
* Declared at the OPERATION layer rather than detected from the template, deliberately: the
|
|
394
|
-
* resource icon renders before the template mounts, so detection could only suppress it after the
|
|
395
|
-
* fact — a glyph that flashes and vanishes on every load. Mirrors
|
|
396
|
-
* `SummaryTitlePlacement.TEMPLATE_OWNED`, the same contract one surface over: ceding a
|
|
397
|
-
* framework-owned element to the template is a declaration, not an inference.
|
|
398
|
-
*/
|
|
399
|
-
export enum HeaderIconPlacement {
|
|
400
|
-
/** The framework renders the resource's registry icon (default). */
|
|
401
|
-
AUTO = 'auto',
|
|
402
|
-
/** The header template owns the glyph; the framework renders none. */
|
|
403
|
-
TEMPLATE_OWNED = 'template_owned',
|
|
404
|
-
}
|
|
405
|
-
|
|
406
286
|
export const ResourceOperationFrontendConfigSchema = z.object({
|
|
407
287
|
/**
|
|
408
288
|
* The operation's frontend **surface** — see {@link ResourceOperationFrontendSurface}.
|
|
@@ -414,8 +294,6 @@ export const ResourceOperationFrontendConfigSchema = z.object({
|
|
|
414
294
|
* Replaces the former `isAddressable` boolean — read via `isOperationAddressable()`.
|
|
415
295
|
*/
|
|
416
296
|
surface: z.enum(ResourceOperationFrontendSurface),
|
|
417
|
-
/** Who paints the page header's identity glyph — see {@link HeaderIconPlacement}. Omitted = AUTO. */
|
|
418
|
-
headerIconPlacement: z.enum(HeaderIconPlacement).optional(),
|
|
419
297
|
/**
|
|
420
298
|
* How this operation's action is surfaced — see {@link ActionVisibility}. Omitted
|
|
421
299
|
* (the common case) behaves as `ALWAYS`.
|
|
@@ -451,15 +329,6 @@ export const ResourceOperationFrontendConfigSchema = z.object({
|
|
|
451
329
|
* row id still rides the URL path too, which the handler may ignore.)
|
|
452
330
|
*/
|
|
453
331
|
rowTargetRequestField: z.string().optional(),
|
|
454
|
-
/**
|
|
455
|
-
* HOW this action collects its input — see {@link ResourceOperationActionPresentation}.
|
|
456
|
-
* Omitted derives from the operation (`resolveResourceOperationActionPresentation`): no input
|
|
457
|
-
* executes directly, a small field set opens a modal, complex input keeps its page.
|
|
458
|
-
*
|
|
459
|
-
* Display-only. An explicit `navigationOverrides` entry is the more specific instrument and wins
|
|
460
|
-
* over whatever this resolves to.
|
|
461
|
-
*/
|
|
462
|
-
actionPresentation: z.enum(ResourceOperationActionPresentation).optional(),
|
|
463
332
|
customView: z.any().optional(),
|
|
464
333
|
displayPresetOverride: z.object({
|
|
465
334
|
resourceLayoutPresetKey: z.string().optional(),
|
|
@@ -495,30 +364,6 @@ export const ResourceOperationFrontendConfigSchema = z.object({
|
|
|
495
364
|
* without a date heading rather than being dropped.
|
|
496
365
|
*/
|
|
497
366
|
temporalGroupField: z.string().optional(),
|
|
498
|
-
/**
|
|
499
|
-
* Group CARDS-mode rows into buckets by this ENUM field, rendering the
|
|
500
|
-
* enum value's own label as a heading between groups.
|
|
501
|
-
*
|
|
502
|
-
* Sibling of {@link temporalGroupField}, and deliberately NOT the same
|
|
503
|
-
* algorithm. Temporal grouping ADJACENT-MERGES in server order, because
|
|
504
|
-
* dates are open-ended and a page can legitimately revisit one. An enum is
|
|
505
|
-
* a CLOSED, ORDERED vocabulary, so its buckets are emitted in the enum's
|
|
506
|
-
* DECLARATION ORDER regardless of the order rows arrived in — the
|
|
507
|
-
* declaration is the authority for "which concern comes first", and a
|
|
508
|
-
* server sort cannot express it without a second, drifting copy of that
|
|
509
|
-
* order. Rows are therefore collected across the whole fetched page rather
|
|
510
|
-
* than merged adjacently, and no sort needs pairing with it.
|
|
511
|
-
*
|
|
512
|
-
* Headings resolve through `tResourceFieldEnumValue` — the SAME source the
|
|
513
|
-
* filters panel and the promoted quick-filter tabs use, so a bucket
|
|
514
|
-
* heading and its tab can never disagree.
|
|
515
|
-
*
|
|
516
|
-
* Ignored in TABLE mode (column sorting owns the ordering there). Rows
|
|
517
|
-
* whose value is absent, or outside the vocabulary, render in a trailing
|
|
518
|
-
* bucket with no heading rather than being dropped — the same fail-open
|
|
519
|
-
* the temporal grouping makes.
|
|
520
|
-
*/
|
|
521
|
-
enumGroupField: z.string().optional(),
|
|
522
367
|
/**
|
|
523
368
|
* CARDS-mode arrangement — a single-column bordered LIST (default) or an
|
|
524
369
|
* N-column responsive GRID. See {@link CardLayoutStyle}. `columns` (1–6) is
|
|
@@ -572,49 +417,6 @@ export const ResourceOperationFrontendConfigSchema = z.object({
|
|
|
572
417
|
* into a description via the `.describe()` decorator.
|
|
573
418
|
*/
|
|
574
419
|
hasDescription: z.boolean().optional(),
|
|
575
|
-
/**
|
|
576
|
-
* What happens to an ADJACENT zone (secondary / companion) this operation
|
|
577
|
-
* splits into, once that zone's last content is dismissed — overriding the
|
|
578
|
-
* zone's own `onEmpty` while this operation occupies primary.
|
|
579
|
-
*
|
|
580
|
-
* The zone-level `ZoneConfig.onEmpty` is one value for every destination that
|
|
581
|
-
* splits into that zone, and destinations legitimately disagree: a LIST wants
|
|
582
|
-
* the detail pane to stay put (`EMPTY_STATE`) so the layout does not reflow
|
|
583
|
-
* while a reviewer steps through rows, while a CANVAS wants its width back
|
|
584
|
-
* (`COLLAPSE`) the moment nothing is selected. Both share one secondary zone,
|
|
585
|
-
* so without this override one of them is always wrong.
|
|
586
|
-
*
|
|
587
|
-
* Declared on the SOURCE operation — the one occupying primary — not on the
|
|
588
|
-
* operation that lands in the pane: it answers "what should MY layout do when
|
|
589
|
-
* the detail closes", which is a property of the surface being returned to.
|
|
590
|
-
*
|
|
591
|
-
* Omitted (the common case) defers to the zone, which itself defaults to
|
|
592
|
-
* `ZoneEmptyBehavior.COLLAPSE`. Resolution order is destination → zone →
|
|
593
|
-
* COLLAPSE; see `resolveZoneEmptyBehavior`.
|
|
594
|
-
*/
|
|
595
|
-
adjacentZoneOnEmpty: z.enum(ZoneEmptyBehavior).optional(),
|
|
596
|
-
/**
|
|
597
|
-
* How wide this destination's content may grow in the zone, in the framework's shared width
|
|
598
|
-
* vocabulary — the SAME `ResponsiveMaxWidth` a Surface, a `DisplayLayout` and a `FormLayout` use.
|
|
599
|
-
*
|
|
600
|
-
* Omitted (the common case) is `'content'`: capped and centred at `var(--content-max-width, 80rem)`,
|
|
601
|
-
* right for a form, a list or a detail page and wrong only for content whose value IS the space it
|
|
602
|
-
* occupies — a board, a wide table, a canvas — which declare `'none'`.
|
|
603
|
-
*/
|
|
604
|
-
zoneContentMaxWidth: z.enum(RESPONSIVE_MAX_WIDTH_VALUES).optional(),
|
|
605
|
-
/**
|
|
606
|
-
* Whether this destination's content fills the zone's HEIGHT as well.
|
|
607
|
-
*
|
|
608
|
-
* `true` makes the zone's content boundary a definite-height flex column, so this view's root may use
|
|
609
|
-
* `flex-1 min-h-0` and resolve against something real. Without it a canvas has no intrinsic height
|
|
610
|
-
* and collapses to zero — which is why one had to hand-roll `h-[70vh]`, sizing against the WINDOW
|
|
611
|
-
* rather than the container it sits in. PRIMARY only: an adjacent zone scrolls, so a filling child
|
|
612
|
-
* and a scrolling parent contradict each other.
|
|
613
|
-
*
|
|
614
|
-
* Separate from the width above ON PURPOSE — see `zone-content-geometry.ts` for why the enum that
|
|
615
|
-
* fused them could not express a capped width with a definite height.
|
|
616
|
-
*/
|
|
617
|
-
zoneContentFillsHeight: z.boolean().optional(),
|
|
618
420
|
});
|
|
619
421
|
|
|
620
422
|
/**
|
|
@@ -296,6 +296,8 @@ export const ExternalDataPipelineDeclarationSchema = z.object({
|
|
|
296
296
|
gives up and the industry precedent.
|
|
297
297
|
- `references/pipeline-destination-schema.md` — the destination schema rules, and what each refusal
|
|
298
298
|
message is telling you.
|
|
299
|
+
- `references/framework-pipeline-admin-endpoints-api.md` — run a pipeline on demand while authoring
|
|
300
|
+
its mapping, and read what each one last did (`cursor`, `loadStatus`).
|
|
299
301
|
|
|
300
302
|
## Verification
|
|
301
303
|
|
package/dist/knowledge/skills/resource-external-data/references/framework-http-api-binding-api.md
CHANGED
|
@@ -35,9 +35,35 @@ the one sanctioned exception is the declared external-erasure call that a subjec
|
|
|
35
35
|
```typescript
|
|
36
36
|
export enum HttpApiTransportDialect {
|
|
37
37
|
/**
|
|
38
|
-
* OData v4
|
|
39
|
-
*
|
|
40
|
-
*
|
|
38
|
+
* OData **v4** — one generic client: mechanical pushdown of
|
|
39
|
+
* `$filter`/`$select`/`$top`/`$skip`/`$orderby`/`$count`, with a `$metadata` boot-time
|
|
40
|
+
* verification probe of the committed declaration.
|
|
41
|
+
*
|
|
42
|
+
* ⚠ **This member is v4 ONLY, and that excludes SAP's most-used API.** An earlier revision of
|
|
43
|
+
* this comment named "SAP S/4HANA, Microsoft Dataverse/Dynamics 365" here, which is half right
|
|
44
|
+
* and was load-bearing — it is why nobody looked:
|
|
45
|
+
*
|
|
46
|
+
* | Target | Version | Consumable today |
|
|
47
|
+
* |---|---|---|
|
|
48
|
+
* | Microsoft Dataverse / Dynamics 365 Web API (`/api/data/v9.2/`) | v4 | ✅ |
|
|
49
|
+
* | SAP S/4HANA OData **v4** services (`/sap/opu/odata4/…`) | v4 | ✅ |
|
|
50
|
+
* | SAP `API_BUSINESS_PARTNER` (`/sap/opu/odata/sap/API_BUSINESS_PARTNER`) | **v2** | ❌ |
|
|
51
|
+
*
|
|
52
|
+
* v2 is not a v4 variant with a different header. Its collection envelope is
|
|
53
|
+
* `{ "d": { "results": [...], "__next": …, "__count": … } }` rather than
|
|
54
|
+
* `{ "value": [...], "@odata.nextLink": … }`; `Edm.DateTime` serializes as `"/Date(<ticks>)/"`
|
|
55
|
+
* rather than ISO 8601; `Edm.Decimal` and `Edm.Int64` serialize as JSON STRINGS rather than
|
|
56
|
+
* numbers; and JSON must be requested (`$format=json`) because v2 defaults to Atom/XML. So it
|
|
57
|
+
* changes the envelope, the paging property, the count property AND the value encoding — a
|
|
58
|
+
* reader written for one cannot read the other, and the mapping layer needs coercions the way
|
|
59
|
+
* Odoo needs `ODOO_FALSE_AS_NULL`.
|
|
60
|
+
* spec-cite: OData Version 2.0 JSON Format
|
|
61
|
+
* (https://www.odata.org/documentation/odata-version-2-0/json-format/) — the `d`/`results`/
|
|
62
|
+
* `__next`/`__count` envelope, the `/Date(<ticks>)/` DateTime literal, and Edm.Decimal /
|
|
63
|
+
* Edm.Int64 "formatted as a JSON string".
|
|
64
|
+
*
|
|
65
|
+
* Supporting v2 is an OPEN decision, not an oversight. Until it lands, point an ODATA binding at
|
|
66
|
+
* a v4 service: for SAP that means the OData v4 edition of the API where one is published.
|
|
41
67
|
*/
|
|
42
68
|
ODATA = 'odata',
|
|
43
69
|
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
# Pipeline admin endpoints — run one now, and see what each last did
|
|
2
|
+
|
|
3
|
+
Read this when:
|
|
4
|
+
|
|
5
|
+
- you are authoring a pipeline's field mapping and do not want to wait for `scheduleCron`;
|
|
6
|
+
- a pipeline appears not to have run, and you need to know whether it is DECLARED but has never run
|
|
7
|
+
(no state at all) versus mid-pass (a non-null cursor);
|
|
8
|
+
- a sync reported success but a row did not change, and you need the load's own verdict.
|
|
9
|
+
|
|
10
|
+
The listing is declaration-first: a pipeline that has never run still appears, with a null state.
|
|
11
|
+
That is deliberate — a pipeline missing from a state-first listing is exactly the one you are
|
|
12
|
+
looking for.
|
|
13
|
+
|
|
14
|
+
Two fields decide most questions:
|
|
15
|
+
|
|
16
|
+
- **`cursor`** — non-null means a pass is IN FLIGHT. The next run continues it rather than starting
|
|
17
|
+
a fresh pass, and the orphan stage does not run, because "absent from a partial extraction" is not
|
|
18
|
+
evidence of remote deletion.
|
|
19
|
+
- **`loadStatus`** — the seed engine's verdict on the WRITE, which is a different axis from whether
|
|
20
|
+
the extraction pass completed. A full pass can still fail to write some of what it read; when this
|
|
21
|
+
is not `completed`, read the run ledger row named by `seedRunId` for the per-entry detail.
|
|
22
|
+
|
|
23
|
+
The endpoints are mounted only when the admin secret is configured, and answer `503` otherwise.
|
|
24
|
+
|
|
25
|
+
## Import Origins
|
|
26
|
+
|
|
27
|
+
- `@wildo-ai/saas-backend-lib`
|
|
28
|
+
|
|
29
|
+
## Source Excerpts
|
|
30
|
+
|
|
31
|
+
### Origin Package: `@wildo-ai/saas-backend-lib`
|
|
32
|
+
|
|
33
|
+
```typescript
|
|
34
|
+
/**
|
|
35
|
+
* Environment variable holding the secret these endpoints require. When unset or empty EVERY
|
|
36
|
+
* endpoint answers 503 — the safe default, so a fresh deployment never accidentally exposes an
|
|
37
|
+
* operator surface that can reach a third party's production system.
|
|
38
|
+
*
|
|
39
|
+
* Deliberately the SAME key data-seeding uses: an operator administering one app has one admin
|
|
40
|
+
* secret, and minting a second would mean two rotations to remember and one of them forgotten.
|
|
41
|
+
*/
|
|
42
|
+
export const ExternalDataAdminEndpointEnvKey = 'APPLICATION_ADMIN_SECRET' as const;
|
|
43
|
+
|
|
44
|
+
/** Header carrying the secret. Hash-then-`timingSafeEqual`, per the sibling controller. */
|
|
45
|
+
export const ExternalDataAdminEndpointHeaderKey = 'X-Admin-Secret' as const;
|
|
46
|
+
|
|
47
|
+
/**
|
|
48
|
+
* Root mount. Under `/internal/...` rather than `/api/v1/...` because this is an operator surface,
|
|
49
|
+
* not a consumer API — the convention `/health` and the data-seeding admin surface already follow.
|
|
50
|
+
*/
|
|
51
|
+
export const ExternalDataAdminEndpointMountBasePath = '/internal/admin/external-data' as const;
|
|
52
|
+
|
|
53
|
+
/** Sub-paths, relative to {@link ExternalDataAdminEndpointMountBasePath}. */
|
|
54
|
+
export const ExternalDataAdminEndpointPath = {
|
|
55
|
+
/** GET — every declared pipeline with its persisted cursor and last-run summary. */
|
|
56
|
+
PIPELINES: '/pipelines',
|
|
57
|
+
/**
|
|
58
|
+
* POST — run ONE pipeline now. `{ "resourceType": "externalCustomers" }`.
|
|
59
|
+
*
|
|
60
|
+
* This exists because a scheduled-only capability is undevelopable: authoring a mapping against
|
|
61
|
+
* SAP or Dynamics means change → sync → look, dozens of times, and an hourly cron makes that loop
|
|
62
|
+
* unusable. Verifying the first dogfood required either waiting an hour or editing committed app
|
|
63
|
+
* config, which is what proved the door was missing.
|
|
64
|
+
*/
|
|
65
|
+
RUN: '/run',
|
|
66
|
+
} as const;
|
|
67
|
+
|
|
68
|
+
export type ExternalDataAdminEndpointPathValue =
|
|
69
|
+
(typeof ExternalDataAdminEndpointPath)[keyof typeof ExternalDataAdminEndpointPath];
|
|
70
|
+
```
|
|
@@ -72,9 +72,7 @@ File: `shared-lib/src/modules/<module>/resources/<resource>/*.resources-config.t
|
|
|
72
72
|
`ORGANIZATION`- and `APPLICATION`-scoped resources are exposable — a machine token carries no
|
|
73
73
|
`userId`, so USER_SELF / ANONYMOUS operations are unreachable and are never advertised even if
|
|
74
74
|
you set `mcp.exposed`. Confirm the resource's `resourcePrimaryScope` before proceeding.
|
|
75
|
-
|
|
76
|
-
in the resource's own configuration under `shared-lib/` — the registry snapshot lists the
|
|
77
|
-
resources; the scope declaration lives in the config.
|
|
75
|
+
// TODO CLI COMMAND: wildo context resources --mcp-exposable
|
|
78
76
|
|
|
79
77
|
### Step 2: Choose which operations to expose (and classify instance vs collection)
|
|
80
78
|
Only **DEFAULT, non-bulk, URL-bearing** operations become tools (the standard `API_CALL`
|
|
@@ -92,14 +90,6 @@ tool description falls back to the resource specification's `purpose` / `whenToU
|
|
|
92
90
|
synthesized default — so either author it here or keep the spec prose agent-ready (and
|
|
93
91
|
reconciled: see `spec-resource-update`).
|
|
94
92
|
|
|
95
|
-
**File fields need nothing extra — but know what the agent sees.** An MCP tool call cannot carry
|
|
96
|
-
bytes, so a `z_file()` field advertises a `fileId` the agent has no way to invent. For every exposed
|
|
97
|
-
CREATE / UPDATE with a user-uploadable file field the engine ALSO advertises a derived tool,
|
|
98
|
-
`<resource>__<operation>.upload_grant.<field>`, that mints a single-use upload link, and it appends to
|
|
99
|
-
your operation's description where each field's id comes from. Do not describe the upload in your own
|
|
100
|
-
`description` — the engine's note is derived from the field and stays in step with it. See
|
|
101
|
-
`references/framework-file-upload-grant-contract.md`.
|
|
102
|
-
|
|
103
93
|
### Step 3b (OPTIONAL): Split the catalog across NAMED servers
|
|
104
94
|
One `/mcp` serves ONE flat tool list, so when different consumers need different capability
|
|
105
95
|
postures — a read-only support surface vs a destructive operations one — declare **named servers**
|
|
@@ -222,9 +212,6 @@ curl -X POST https://your-app.example.com/api/v1/mcp \
|
|
|
222
212
|
|
|
223
213
|
- `references/framework-resource-mcp-exposure-contract.md` — source-backed: the `mcp`
|
|
224
214
|
operation-config field (the opt-in contract, description fallback, scope constraints).
|
|
225
|
-
- `references/framework-file-upload-grant-contract.md` — source-backed: what the derived
|
|
226
|
-
`…upload_grant.<field>` tool returns and how an agent turns it into a `fileId`. Read when an exposed
|
|
227
|
-
CREATE / UPDATE carries a `z_file()` field.
|
|
228
215
|
- `references/framework-named-mcp-servers-contract.md` — source-backed: declaring NAMED MCP
|
|
229
216
|
servers (`resourceServerInstances`) when one catalog is not enough, and how per-server
|
|
230
217
|
audiences make the split a real boundary. Read only if you need more than one MCP surface.
|
|
@@ -263,10 +250,6 @@ curl -X POST https://your-app.example.com/api/v1/mcp \
|
|
|
263
250
|
Without it, the test passes identically when the whole resource was never exposed, and would keep
|
|
264
251
|
passing if the withdrawal logic were deleted. Grep your own tests:
|
|
265
252
|
`rg -n "not\.toContain\('.*__" ` — each hit needs a `toContain` for the same resource nearby.
|
|
266
|
-
- [ ] IF an exposed CREATE / UPDATE carries a `z_file()` field: `tools/list` shows the derived
|
|
267
|
-
`…upload_grant.<field>` tool beside it, and the parent's description ends with a `File fields:` note.
|
|
268
|
-
Grep the live catalogue: `rg "upload_grant\." <tools-list.json>` — one hit per uploadable field of
|
|
269
|
-
each exposed CREATE / UPDATE, none for a generated (PDF-template) field.
|
|
270
253
|
- [ ] No operation carrying an `unimplementedAcknowledgement` is relied on as a tool. You do NOT
|
|
271
254
|
need to retract its `mcp` block — the engine withdraws it — but do not build a workflow on a tool
|
|
272
255
|
that will not be there.
|
|
@@ -310,10 +293,6 @@ curl -X POST https://your-app.example.com/api/v1/mcp \
|
|
|
310
293
|
tool ships; catch with the `tools/list` diff in Verification.
|
|
311
294
|
- **Building an agent workflow on a verb that carries an `unimplementedAcknowledgement`** — it is
|
|
312
295
|
withdrawn, so the workflow's tool will simply not be there; catch with the acknowledgement row.
|
|
313
|
-
- **Describing a file upload in your own `mcp.description`, or expecting an agent to pass a
|
|
314
|
-
`fileId` it made up** — the engine derives an `…upload_grant.<field>` tool and appends the
|
|
315
|
-
`File fields:` note itself, and a fileId only ever comes from an upload; catch with the
|
|
316
|
-
`upload_grant.` grep on the live catalogue in Verification.
|
|
317
296
|
- **Treating named servers as cosmetic grouping** — each is a distinct RFC 8707 resource server,
|
|
318
297
|
so a token for one is REJECTED at another; that isolation is the reason to split, and it is
|
|
319
298
|
why a ref rename invalidates already-minted tokens.
|
|
@@ -77,13 +77,11 @@ export enum EngineCapability {
|
|
|
77
77
|
* extraction into `AI_LLM` would have made one `selection[AI_LLM].primary` decide all three,
|
|
78
78
|
* which is exactly the defect that split `AI_EMBEDDINGS` out of `AI_LLM`.
|
|
79
79
|
*
|
|
80
|
-
* ## Not to be confused with
|
|
80
|
+
* ## Not to be confused with `DOCUMENT_GENERATION`
|
|
81
81
|
*
|
|
82
|
-
* PDF generation — templates and data become bytes
|
|
83
|
-
*
|
|
84
|
-
*
|
|
85
|
-
* `EngineCapability.DOCUMENT_GENERATION` that this paragraph used to name; it was withdrawn
|
|
86
|
-
* because no provider capability could ever fill it.)
|
|
82
|
+
* `DOCUMENT_GENERATION` is PDF *generation* — templates and data become bytes. This is the
|
|
83
|
+
* opposite direction: bytes become text. The names are adjacent and the capabilities are
|
|
84
|
+
* unrelated; nothing routes between them.
|
|
87
85
|
*
|
|
88
86
|
* ## Absence is benign, and that is load-bearing
|
|
89
87
|
*
|
|
@@ -110,26 +108,8 @@ export enum EngineCapability {
|
|
|
110
108
|
*/
|
|
111
109
|
AI_CODING_AGENT = 'AI_CODING_AGENT',
|
|
112
110
|
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
* not any more. Neither could ever be filled — `PROVIDER_CAPABILITY_TO_ENGINE_CAPABILITY` had no
|
|
116
|
-
* entry pointing at either, so no provider capability token could claim the slot — while both were
|
|
117
|
-
* classified `SELECT_ONE`, which asserts that exactly one provider must be selected. Selecting one
|
|
118
|
-
* of zero candidates is not a resolution mode.
|
|
119
|
-
*
|
|
120
|
-
* Both capabilities are real and both are delivered elsewhere, which is why withdrawing the slots
|
|
121
|
-
* costs nothing: antivirus scanning is `InfraCapability.ANTIVIRUS_SCANNING`, fulfilled by ClamAV
|
|
122
|
-
* and consumed by `FileScanningBackendService`; PDF generation is the in-process `pdfTemplates`
|
|
123
|
-
* surface, with `InfraCapability.DOCUMENT_RENDERING` (Gotenberg) provisioned beside it. Neither
|
|
124
|
-
* has an external provider, and neither is planned to.
|
|
125
|
-
*
|
|
126
|
-
* Removing `ANTIVIRUS_SCANNING` also removes a collision: the identical spelling named an engine
|
|
127
|
-
* slot nothing could fill AND a live infra capability, in two packages, so a reader grepping the
|
|
128
|
-
* word landed in whichever they searched first.
|
|
129
|
-
*
|
|
130
|
-
* If a hosted AV or document-rendering vendor is ever adopted, the member comes back WITH its
|
|
131
|
-
* `PROVIDER_CAPABILITY_TO_ENGINE_CAPABILITY` entry and its own JSDoc in the same change.
|
|
132
|
-
*/
|
|
111
|
+
DOCUMENT_GENERATION = 'DOCUMENT_GENERATION',
|
|
112
|
+
ANTIVIRUS_SCANNING = 'ANTIVIRUS_SCANNING',
|
|
133
113
|
|
|
134
114
|
FRONTEND_ERROR_MONITORING = 'FRONTEND_ERROR_MONITORING',
|
|
135
115
|
FRONTEND_PRODUCT_ANALYTICS = 'FRONTEND_PRODUCT_ANALYTICS',
|
|
@@ -231,8 +211,8 @@ independent choices. Vendors are not equally good at all three and their pricing
|
|
|
231
211
|
a unit — OCR is billed per PAGE, embeddings per token — so fusing any two of them into one selection
|
|
232
212
|
would force a procurement decision nobody wants to make.
|
|
233
213
|
|
|
234
|
-
Not to be confused with
|
|
235
|
-
|
|
214
|
+
Not to be confused with `EngineCapability.DOCUMENT_GENERATION`, which is PDF *generation* and is the
|
|
215
|
+
opposite direction. Nothing routes between them.
|
|
236
216
|
|
|
237
217
|
### Selecting a provider is only HALF the wiring
|
|
238
218
|
|
|
@@ -246,7 +246,6 @@ shared schema declares the **truth**, the UI behavior file declares the
|
|
|
246
246
|
- `references/framework-schema-family-api.md` — source-backed `createSchemaFamily` contract
|
|
247
247
|
- `references/framework-polymorphic-resources-api.md` — source-backed `PolymorphicVariantDefinition` + `optOutPolymorphicAutoBusinessKey` contract
|
|
248
248
|
- `references/framework-decorator-vocabulary-api.md` — source-backed `ZodDecorator` enum + `SCHEMA_METADATA` symbol
|
|
249
|
-
- `references/framework-personal-data-category-api.md` — source-backed `.dataCategories()` + `PersonalDataCategory` vocabulary, for any field holding personal data
|
|
250
249
|
- `references/framework-zod-lifecycle-and-chainable-api.md` — lifecycle structural params + chainable runtime (`initZodDecorators` alignment)
|
|
251
250
|
- `examples/add-enum-field-with-ui.example.md` — worked three-layer example
|
|
252
251
|
- `examples/basic-resource-schema.example.md` — full from-scratch resource schema
|
|
@@ -32,23 +32,6 @@ When the answer is "shared schema", choose the next reference by need:
|
|
|
32
32
|
- `field-type-selection.md` -> whether the field should be primitive, enum, FK, or a domain factory
|
|
33
33
|
- `special-factories.md` -> when to use `z_money()`, `z_file()`, `z_range()`, and similar helpers
|
|
34
34
|
- `schema-variants-and-discriminators.md` -> discriminator and schema-family changes
|
|
35
|
-
- `framework-personal-data-category-api.md` -> the field holds data about a PERSON and needs a
|
|
36
|
-
`.dataCategories(...)` declaration
|
|
37
|
-
|
|
38
|
-
## Personal data is a shared-schema concern
|
|
39
|
-
|
|
40
|
-
If the field holds data about a person, the shared schema is where you say so — all four axes live
|
|
41
|
-
there and none of them is a UI or specification concern:
|
|
42
|
-
|
|
43
|
-
| Question | Declaration |
|
|
44
|
-
|---|---|
|
|
45
|
-
| What KIND of personal data? | `.dataCategories(PersonalDataCategory.…)` |
|
|
46
|
-
| What happens on ERASURE? | `.impersonalizeWith(RedactionType.…)` |
|
|
47
|
-
| Where did it come from (Art. 20)? | `.portabilityProvenance(DataPortabilityProvenance.…)` |
|
|
48
|
-
|
|
49
|
-
Declare the category on the same line you declare the scrub treatment. A field carrying one and not
|
|
50
|
-
the other is reported by name as an OUTSTANDING gap in every compliance document the application
|
|
51
|
-
produces — the application has said the field holds personal data and has not said what kind.
|
|
52
35
|
|
|
53
36
|
## Escalate Early
|
|
54
37
|
|
|
@@ -60,40 +60,6 @@ export enum ZodDecorator {
|
|
|
60
60
|
* `SUBJECT_PROVIDED` and masked on erasure.
|
|
61
61
|
*/
|
|
62
62
|
PORTABILITY_PROVENANCE = "portabilityProvenance",
|
|
63
|
-
/**
|
|
64
|
-
* Data categories: WHICH KINDS of personal data this field holds — one or more
|
|
65
|
-
* `PersonalDataCategory` values (strings), read by the compliance fact producer to answer the
|
|
66
|
-
* privacy-notice question "which categories of personal data do you process".
|
|
67
|
-
*
|
|
68
|
-
* Authored fluently: `email: z.email().dataCategories(PersonalDataCategory.CONTACT_DETAILS)`, or
|
|
69
|
-
* with an array when a field genuinely spans two —
|
|
70
|
-
* `.dataCategories([PersonalDataCategory.USER_CONTENT, PersonalDataCategory.SPECIAL_CATEGORY_HEALTH])`.
|
|
71
|
-
* The chokepoint normalizes either form to a deduped array, so every reader sees one shape.
|
|
72
|
-
* At least one category is REQUIRED and each must be a non-empty string: a blank declaration
|
|
73
|
-
* would read back as declared-but-meaningless, which is worse than absent, because absence is
|
|
74
|
-
* what the gap report is looking for. `addDataCategories(schema, categories)` is the equivalent
|
|
75
|
-
* programmatic escape hatch; read them back with `getDataCategories(schema)`.
|
|
76
|
-
*
|
|
77
|
-
* WHETHER each value is a real `PersonalDataCategory` member is checked by the resource factory's
|
|
78
|
-
* boot guard, which owns the enum — this layer knows only that non-empty strings were declared.
|
|
79
|
-
*
|
|
80
|
-
* ⚠️ Four adjacent axes, none of them this one. {@link ZodDecorator.IMPERSONALIZE_WITH} says what
|
|
81
|
-
* happens to the value on ERASURE; {@link ZodDecorator.PORTABILITY_PROVENANCE} says where it CAME
|
|
82
|
-
* FROM; `Compliance_DataClassification` is a SENSITIVITY ladder for flows-actors config; a
|
|
83
|
-
* retention class says HOW LONG it is kept. A single field is routinely all five at once, and
|
|
84
|
-
* none of the other four can answer "what kind of personal data is this".
|
|
85
|
-
*
|
|
86
|
-
* ⚠️ Do NOT declare a category on a field merely because its NAME suggests one. The decorator
|
|
87
|
-
* exists precisely so categories are never derived from identifiers: `email`, `phone` and
|
|
88
|
-
* `dateOfBirth` are suggestive while `notes` is not, and an inventory assembled by
|
|
89
|
-
* pattern-matching names is a guess whose misses are silently undisclosed. `CREDENTIALS` is the
|
|
90
|
-
* one category the producer derives, and it derives it from `.isPassword()` / `.isOtp()` /
|
|
91
|
-
* `.isWriteOnlySecret()` — markers the author wrote, not names it read.
|
|
92
|
-
*
|
|
93
|
-
* assurance-control: WILDO.PRIVACY.PERSONAL_DATA_INVENTORY — the application declares which
|
|
94
|
-
* categories of personal data each field holds
|
|
95
|
-
*/
|
|
96
|
-
DATA_CATEGORIES = "dataCategories",
|
|
97
63
|
/**
|
|
98
64
|
* Audit evidence: this field's BEFORE/AFTER VALUES are recorded when a resource operation
|
|
99
65
|
* mutates it, on the `resource_operation_performed` audit event.
|
|
@@ -266,12 +232,6 @@ export type ZodDecorator_ParamsType = {
|
|
|
266
232
|
* normalize; if a second axis is ever needed the chokepoint widens exactly as that one did.
|
|
267
233
|
*/
|
|
268
234
|
[ZodDecorator.PORTABILITY_PROVENANCE]: string;
|
|
269
|
-
/**
|
|
270
|
-
* The field's personal-data categories — `PersonalDataCategory` values, typed as plain strings at
|
|
271
|
-
* this layer (zod-decorators sits below saas-models and cannot import the enum). Accepts a single
|
|
272
|
-
* value (the common case) or an array; the chokepoint normalizes either to a deduped array.
|
|
273
|
-
*/
|
|
274
|
-
[ZodDecorator.DATA_CATEGORIES]: string | readonly string[];
|
|
275
235
|
// Audit-evidence marker — parameterless, like IS_BUSINESS_KEY. A field either is evidence or is
|
|
276
236
|
// not; there is no axis to parameterize, and adding one would invite per-field redaction policy
|
|
277
237
|
// to grow here instead of on the impersonalization decorator that owns it.
|
|
@@ -364,11 +324,6 @@ export type ZodDecorator_Types = {
|
|
|
364
324
|
* (zod-decorators sits below saas-models). Stored exactly as authored; the chokepoint only
|
|
365
325
|
* rejects blanks. */
|
|
366
326
|
[ZodDecorator.PORTABILITY_PROVENANCE]: string;
|
|
367
|
-
/** Personal-data categories — `PersonalDataCategory` values carried as opaque `string`s
|
|
368
|
-
* (zod-decorators sits below saas-models). ALWAYS the normalized array, deduped and non-empty:
|
|
369
|
-
* the chokepoint widens a bare single-value authoring form on the way in, so every reader sees
|
|
370
|
-
* one shape and `getDataCategories` can answer "is this field categorized?" by presence alone. */
|
|
371
|
-
[ZodDecorator.DATA_CATEGORIES]: readonly string[];
|
|
372
327
|
/** Audit-evidence marker — stored as the bare `true` sentinel (parameterless, like IS_BUSINESS_KEY). */
|
|
373
328
|
[ZodDecorator.IS_AUDIT_EVIDENCE]: true;
|
|
374
329
|
/** RAG-source config — ALWAYS the normalized object ( `{}` when authored with no argument): the
|
|
@@ -474,7 +429,6 @@ export interface CustomFieldMetadata {
|
|
|
474
429
|
[ZodDecorator.IS_WRITE_ONLY_SECRET]?: ZodDecorator_Types[ZodDecorator.IS_WRITE_ONLY_SECRET];
|
|
475
430
|
[ZodDecorator.IMPERSONALIZE_WITH]?: ZodDecorator_Types[ZodDecorator.IMPERSONALIZE_WITH];
|
|
476
431
|
[ZodDecorator.PORTABILITY_PROVENANCE]?: ZodDecorator_Types[ZodDecorator.PORTABILITY_PROVENANCE];
|
|
477
|
-
[ZodDecorator.DATA_CATEGORIES]?: ZodDecorator_Types[ZodDecorator.DATA_CATEGORIES];
|
|
478
432
|
[ZodDecorator.IS_AUDIT_EVIDENCE]?: ZodDecorator_Types[ZodDecorator.IS_AUDIT_EVIDENCE];
|
|
479
433
|
[ZodDecorator.RAG_SOURCE]?: ZodDecorator_Types[ZodDecorator.RAG_SOURCE];
|
|
480
434
|
[ZodDecorator.IS_VIRTUAL]?: ZodDecorator_Types[ZodDecorator.IS_VIRTUAL];
|
|
@@ -52,21 +52,6 @@ export interface ForeignKeyStructuralParams {
|
|
|
52
52
|
* (e.g. `referrerScopeType`). Without it, `polymorphicVariants` is rename-only.
|
|
53
53
|
*/
|
|
54
54
|
polymorphicDiscriminatorField?: string;
|
|
55
|
-
/**
|
|
56
|
-
* EXPLICIT target resource type, for an FK whose FIELD NAME cannot resolve it.
|
|
57
|
-
*
|
|
58
|
-
* The frontend resolves a reference field's target through the field-name → resource map
|
|
59
|
-
* (enriched from relationships' `foreignKeyField`). That works only when the field is named for
|
|
60
|
-
* its target (`assignedToUserId`) or a relationship declares it — and relationship FK names are
|
|
61
|
-
* held to the `Id`/`Ids` convention. A field that references a resource under its OWN vocabulary
|
|
62
|
-
* (`icpRefs` inside a specification document, a rename-only FK) has no honest entry in that map;
|
|
63
|
-
* declaring the target here lets the reference display resolve, label and navigate it without
|
|
64
|
-
* bending the field's name or the map's uniqueness.
|
|
65
|
-
*
|
|
66
|
-
* Takes precedence over the field-name map; polymorphic variants (above) still win over both,
|
|
67
|
-
* because a per-record discriminator is more specific than any static declaration.
|
|
68
|
-
*/
|
|
69
|
-
referencedResourceType?: string;
|
|
70
55
|
}
|
|
71
56
|
```
|
|
72
57
|
|
|
@@ -761,32 +761,6 @@ function applySingleDecorator<T extends z.ZodTypeAny>(
|
|
|
761
761
|
currentMetadata[ZodDecorator.PORTABILITY_PROVENANCE] = raw;
|
|
762
762
|
break;
|
|
763
763
|
}
|
|
764
|
-
case ZodDecorator.DATA_CATEGORIES: {
|
|
765
|
-
// NORMALIZE HERE, not in the doors — the impersonalizeWith discipline. A single value (the
|
|
766
|
-
// common case) and an array both store a deduped ARRAY, so every reader sees one shape and
|
|
767
|
-
// `getDataCategories` answers "is this field categorized?" by presence alone.
|
|
768
|
-
//
|
|
769
|
-
// Fail LOUD on an empty declaration. An UNCATEGORIZED field is a legitimate, common state —
|
|
770
|
-
// most fields are not personal data — and the gap report is built on ABSENCE. A stored empty
|
|
771
|
-
// array would read back as declared-with-no-categories, which is invisible to a report
|
|
772
|
-
// looking for absence: the field would be silently excluded from the notice while looking
|
|
773
|
-
// annotated to anyone reading the schema.
|
|
774
|
-
//
|
|
775
|
-
// WHETHER each value is a real `PersonalDataCategory` member is checked by the resource
|
|
776
|
-
// factory's boot guard, which owns the enum — this layer knows only that non-empty strings
|
|
777
|
-
// were declared.
|
|
778
|
-
const raw = p as unknown;
|
|
779
|
-
const authored: readonly unknown[] = Array.isArray(raw) ? raw : [raw];
|
|
780
|
-
if (authored.length === 0 || authored.some((value) => typeof value !== 'string' || value.trim().length === 0)) {
|
|
781
|
-
throw new Error(
|
|
782
|
-
`dataCategories(categories) requires at least one non-empty PersonalDataCategory value (received ${JSON.stringify(raw)}). ` +
|
|
783
|
-
`A field that holds no personal data carries NO declaration — absence is what a category gap report reads. ` +
|
|
784
|
-
`An empty declaration looks annotated and discloses nothing.`,
|
|
785
|
-
);
|
|
786
|
-
}
|
|
787
|
-
currentMetadata[ZodDecorator.DATA_CATEGORIES] = [...new Set(authored as readonly string[])];
|
|
788
|
-
break;
|
|
789
|
-
}
|
|
790
764
|
case ZodDecorator.IS_AUDIT_EVIDENCE:
|
|
791
765
|
currentMetadata[ZodDecorator.IS_AUDIT_EVIDENCE] = true;
|
|
792
766
|
break;
|