@wildo-ai/saas-specifications 1.1.5 → 1.1.7
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/_catalogs/schema-org/_catalog-spec.shared.schemas.d.ts +10 -8
- package/dist/esm/_catalogs/schema-org/_catalog-spec.shared.schemas.d.ts.map +1 -1
- package/dist/esm/_catalogs/schema-org/_catalog-spec.shared.schemas.js +14 -13
- package/dist/esm/_catalogs/schema-org/_catalog-spec.shared.schemas.js.map +1 -1
- package/dist/esm/_catalogs/schema-org/aggregate-offer.catalog-spec.d.ts +3 -2
- package/dist/esm/_catalogs/schema-org/aggregate-offer.catalog-spec.d.ts.map +1 -1
- package/dist/esm/_catalogs/schema-org/aggregate-offer.catalog-spec.js +4 -3
- package/dist/esm/_catalogs/schema-org/aggregate-offer.catalog-spec.js.map +1 -1
- package/dist/esm/_catalogs/schema-org/index.d.ts +31 -15
- package/dist/esm/_catalogs/schema-org/index.d.ts.map +1 -1
- package/dist/esm/_catalogs/schema-org/index.js +34 -13
- package/dist/esm/_catalogs/schema-org/index.js.map +1 -1
- package/dist/esm/_catalogs/schema-org/product.catalog-spec.d.ts +2 -2
- package/dist/esm/_catalogs/schema-org/product.catalog-spec.js +4 -4
- package/dist/esm/_catalogs/schema-org/product.catalog-spec.js.map +1 -1
- package/dist/esm/_catalogs/schema-org/software-application.catalog-spec.d.ts +45 -0
- package/dist/esm/_catalogs/schema-org/software-application.catalog-spec.d.ts.map +1 -0
- package/dist/esm/_catalogs/schema-org/software-application.catalog-spec.js +58 -0
- package/dist/esm/_catalogs/schema-org/software-application.catalog-spec.js.map +1 -0
- package/dist/esm/_core/application-specification-family-identity.schemas.d.ts +3 -2
- package/dist/esm/_core/application-specification-family-identity.schemas.d.ts.map +1 -1
- package/dist/esm/_core/application-specification-family-identity.schemas.js +3 -2
- package/dist/esm/_core/application-specification-family-identity.schemas.js.map +1 -1
- package/dist/esm/_core/build-plan/build-plan-task-graph-generation.schemas.d.ts +18 -0
- 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-validation.d.ts +39 -13
- 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 +43 -13
- 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 +90 -2
- 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 +70 -6
- 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 +26 -4
- package/dist/esm/_core/build-plan/build-plan.family-aspects.js.map +1 -1
- package/dist/esm/_core/business-semantics.specifications.schemas.d.ts +14 -0
- package/dist/esm/_core/business-semantics.specifications.schemas.d.ts.map +1 -1
- package/dist/esm/_core/business-semantics.specifications.schemas.js.map +1 -1
- package/dist/esm/_core/capability-composition/capability-composition-validation.d.ts.map +1 -1
- package/dist/esm/_core/capability-composition/capability-composition-validation.js +1 -0
- package/dist/esm/_core/capability-composition/capability-composition-validation.js.map +1 -1
- package/dist/esm/_core/capability-composition/capability-composition.schemas.d.ts +21 -2
- package/dist/esm/_core/capability-composition/capability-composition.schemas.d.ts.map +1 -1
- package/dist/esm/_core/capability-composition/capability-composition.schemas.js +20 -1
- package/dist/esm/_core/capability-composition/capability-composition.schemas.js.map +1 -1
- package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.d.ts +11 -32
- 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 +70 -3
- package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.js.map +1 -1
- package/dist/esm/_core/compliance-documents/computed-document-facts.schemas.d.ts +142 -17
- package/dist/esm/_core/compliance-documents/computed-document-facts.schemas.d.ts.map +1 -1
- package/dist/esm/_core/compliance-documents/computed-document-facts.schemas.js +285 -30
- package/dist/esm/_core/compliance-documents/computed-document-facts.schemas.js.map +1 -1
- package/dist/esm/_core/compliance-documents/processor-register.schemas.d.ts +183 -18
- package/dist/esm/_core/compliance-documents/processor-register.schemas.d.ts.map +1 -1
- package/dist/esm/_core/compliance-documents/processor-register.schemas.js +165 -18
- package/dist/esm/_core/compliance-documents/processor-register.schemas.js.map +1 -1
- package/dist/esm/_core/compliance-documents/recipient-disclosures.schemas.d.ts +139 -0
- package/dist/esm/_core/compliance-documents/recipient-disclosures.schemas.d.ts.map +1 -0
- package/dist/esm/_core/compliance-documents/recipient-disclosures.schemas.js +172 -0
- package/dist/esm/_core/compliance-documents/recipient-disclosures.schemas.js.map +1 -0
- package/dist/esm/_core/compliance-documents/recipient-population.schemas.d.ts +306 -0
- package/dist/esm/_core/compliance-documents/recipient-population.schemas.d.ts.map +1 -0
- package/dist/esm/_core/compliance-documents/recipient-population.schemas.js +502 -0
- package/dist/esm/_core/compliance-documents/recipient-population.schemas.js.map +1 -0
- package/dist/esm/_core/compliance-documents/retention-enforcement-facts.schemas.d.ts +107 -0
- package/dist/esm/_core/compliance-documents/retention-enforcement-facts.schemas.d.ts.map +1 -0
- package/dist/esm/_core/compliance-documents/retention-enforcement-facts.schemas.js +118 -0
- package/dist/esm/_core/compliance-documents/retention-enforcement-facts.schemas.js.map +1 -0
- package/dist/esm/_core/compliance-documents/subject-data-recipients.schemas.d.ts +56 -0
- package/dist/esm/_core/compliance-documents/subject-data-recipients.schemas.d.ts.map +1 -0
- package/dist/esm/_core/compliance-documents/subject-data-recipients.schemas.js +100 -0
- package/dist/esm/_core/compliance-documents/subject-data-recipients.schemas.js.map +1 -0
- package/dist/esm/_core/composite-view-specification.schemas.js +8 -1
- package/dist/esm/_core/composite-view-specification.schemas.js.map +1 -1
- package/dist/esm/_core/domain-plan/domain-plan.family-aspects.d.ts +3 -2
- 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 +3 -2
- package/dist/esm/_core/domain-plan/domain-plan.family-aspects.js.map +1 -1
- package/dist/esm/_core/experience-plan/experience-plan.schemas.d.ts +16 -3
- package/dist/esm/_core/experience-plan/experience-plan.schemas.d.ts.map +1 -1
- package/dist/esm/_core/experience-plan/experience-plan.schemas.js +70 -5
- package/dist/esm/_core/experience-plan/experience-plan.schemas.js.map +1 -1
- package/dist/esm/_core/family-aspects.schemas.d.ts +10 -0
- 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 +2 -2
- package/dist/esm/_core/feature-drafts/capability-map-output-set.schemas.d.ts +1 -0
- package/dist/esm/_core/feature-drafts/capability-map-output-set.schemas.d.ts.map +1 -1
- package/dist/esm/_core/feature-drafts/feature-specification-drafts.schemas.d.ts +16 -0
- 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 +8 -0
- package/dist/esm/_core/feature-drafts/feature-specification-drafts.schemas.js.map +1 -1
- package/dist/esm/_core/index.d.ts +3 -0
- package/dist/esm/_core/index.d.ts.map +1 -1
- package/dist/esm/_core/index.js +3 -0
- package/dist/esm/_core/index.js.map +1 -1
- package/dist/esm/_core/integration-plan/integration-plan-generation.schemas.d.ts +5 -0
- package/dist/esm/_core/integration-plan/integration-plan-generation.schemas.d.ts.map +1 -1
- package/dist/esm/_core/integration-plan/integration-plan-generation.schemas.js +3 -1
- package/dist/esm/_core/integration-plan/integration-plan-generation.schemas.js.map +1 -1
- package/dist/esm/_core/integration-plan/integration-plan.family-aspects.d.ts.map +1 -1
- package/dist/esm/_core/integration-plan/integration-plan.family-aspects.js +12 -2
- package/dist/esm/_core/integration-plan/integration-plan.family-aspects.js.map +1 -1
- package/dist/esm/_core/integration-plan/integration-plan.schemas.d.ts +30 -2
- package/dist/esm/_core/integration-plan/integration-plan.schemas.d.ts.map +1 -1
- package/dist/esm/_core/integration-plan/integration-plan.schemas.js +32 -2
- package/dist/esm/_core/integration-plan/integration-plan.schemas.js.map +1 -1
- package/dist/esm/_core/market/feature-benefit.schemas.js +2 -2
- package/dist/esm/_core/market/feature-benefit.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-alternative.schemas.js +2 -2
- package/dist/esm/_core/market/market-alternative.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-buying-journey.schemas.js +2 -2
- package/dist/esm/_core/market/market-buying-journey.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-category.schemas.js +2 -2
- package/dist/esm/_core/market/market-category.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-channel.schemas.js +2 -2
- package/dist/esm/_core/market/market-channel.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-gain.schemas.js +2 -2
- package/dist/esm/_core/market/market-gain.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-icp.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-icp.schemas.js +2 -2
- package/dist/esm/_core/market/market-icp.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-job.schemas.js +2 -2
- package/dist/esm/_core/market/market-job.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-message-template.schemas.js +2 -2
- package/dist/esm/_core/market/market-message-template.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-objection.schemas.js +2 -2
- package/dist/esm/_core/market/market-objection.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-pain.schemas.js +2 -2
- package/dist/esm/_core/market/market-pain.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-persona.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-persona.schemas.js +2 -2
- package/dist/esm/_core/market/market-persona.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-positioning.schemas.js +2 -2
- package/dist/esm/_core/market/market-positioning.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-proof.schemas.js +2 -2
- package/dist/esm/_core/market/market-proof.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-references.schemas.d.ts +6 -0
- package/dist/esm/_core/market/market-references.schemas.d.ts.map +1 -1
- package/dist/esm/_core/market/market-references.schemas.js +6 -0
- package/dist/esm/_core/market/market-references.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-snapshot-generation.schemas.d.ts +4 -4
- package/dist/esm/_core/market/market-tone-of-voice.schemas.js +2 -2
- package/dist/esm/_core/market/market-tone-of-voice.schemas.js.map +1 -1
- package/dist/esm/_core/market/market-trigger.schemas.js +2 -2
- package/dist/esm/_core/market/market-trigger.schemas.js.map +1 -1
- package/dist/esm/_core/market/market.family-aspects.js +1 -1
- package/dist/esm/_core/market/market.family-aspects.js.map +1 -1
- package/dist/esm/_core/placement-plan/placement-plan.schemas.d.ts.map +1 -1
- package/dist/esm/_core/placement-plan/placement-plan.schemas.js +6 -1
- package/dist/esm/_core/placement-plan/placement-plan.schemas.js.map +1 -1
- package/dist/esm/_core/requirements/functional-requirement.schemas.d.ts +1 -0
- package/dist/esm/_core/requirements/functional-requirement.schemas.d.ts.map +1 -1
- package/dist/esm/_core/requirements/functional-requirement.schemas.js +8 -0
- package/dist/esm/_core/requirements/functional-requirement.schemas.js.map +1 -1
- package/dist/esm/_core/requirements/requirements-snapshot.schemas.d.ts +1 -0
- package/dist/esm/_core/requirements/requirements-snapshot.schemas.d.ts.map +1 -1
- package/dist/esm/_core/resource-specification.schemas.d.ts +86 -28
- package/dist/esm/_core/resource-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/resource-specification.schemas.js +110 -24
- package/dist/esm/_core/resource-specification.schemas.js.map +1 -1
- package/dist/esm/_core/utils/retention-clock-field-specs.d.ts +13 -0
- package/dist/esm/_core/utils/retention-clock-field-specs.d.ts.map +1 -0
- package/dist/esm/_core/utils/retention-clock-field-specs.js +26 -0
- package/dist/esm/_core/utils/retention-clock-field-specs.js.map +1 -0
- package/dist/esm/_core/website-plan/website-plan.schemas.d.ts +31 -6
- package/dist/esm/_core/website-plan/website-plan.schemas.d.ts.map +1 -1
- package/dist/esm/_core/website-plan/website-plan.schemas.js +35 -6
- package/dist/esm/_core/website-plan/website-plan.schemas.js.map +1 -1
- package/dist/esm/application-creation/application-creator-inputs.application-creation.schemas.d.ts +142 -3
- package/dist/esm/application-creation/application-creator-inputs.application-creation.schemas.d.ts.map +1 -1
- package/dist/esm/application-creation/application-creator-inputs.application-creation.schemas.js +148 -14
- package/dist/esm/application-creation/application-creator-inputs.application-creation.schemas.js.map +1 -1
- package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.d.ts +70 -10
- 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 +98 -11
- package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.js.map +1 -1
- package/dist/esm/application-creation/application-line.application-creation.schemas.d.ts +215 -0
- package/dist/esm/application-creation/application-line.application-creation.schemas.d.ts.map +1 -0
- package/dist/esm/application-creation/application-line.application-creation.schemas.js +253 -0
- package/dist/esm/application-creation/application-line.application-creation.schemas.js.map +1 -0
- package/dist/esm/application-creation/application-specification-family-decisions.application-creation.schemas.d.ts +39 -0
- package/dist/esm/application-creation/application-specification-family-decisions.application-creation.schemas.d.ts.map +1 -0
- package/dist/esm/application-creation/application-specification-family-decisions.application-creation.schemas.js +37 -0
- package/dist/esm/application-creation/application-specification-family-decisions.application-creation.schemas.js.map +1 -0
- package/dist/esm/application-creation/journey.application-creation.schemas.d.ts +5 -49
- package/dist/esm/application-creation/journey.application-creation.schemas.d.ts.map +1 -1
- package/dist/esm/application-creation/journey.application-creation.schemas.js +25 -60
- package/dist/esm/application-creation/journey.application-creation.schemas.js.map +1 -1
- package/dist/esm/application-creation/playbook-instance.application-creation.schemas.d.ts +28 -0
- package/dist/esm/application-creation/playbook-instance.application-creation.schemas.d.ts.map +1 -0
- package/dist/esm/application-creation/playbook-instance.application-creation.schemas.js +32 -0
- package/dist/esm/application-creation/playbook-instance.application-creation.schemas.js.map +1 -0
- package/dist/esm/application-creation/playbooks.application-creation.schemas.d.ts +26 -6
- package/dist/esm/application-creation/playbooks.application-creation.schemas.d.ts.map +1 -1
- package/dist/esm/application-creation/playbooks.application-creation.schemas.js +28 -1
- package/dist/esm/application-creation/playbooks.application-creation.schemas.js.map +1 -1
- package/dist/esm/application-creation.exports.d.ts +7 -0
- package/dist/esm/application-creation.exports.d.ts.map +1 -1
- package/dist/esm/application-creation.exports.js +7 -0
- package/dist/esm/application-creation.exports.js.map +1 -1
- package/dist/esm/assurance/__tests__/authority-evaluation-instant.fixture.d.ts +1 -1
- package/dist/esm/assurance/__tests__/authority-evaluation-instant.fixture.js +1 -1
- package/dist/esm/assurance/__tests__/authority-evaluation-instant.fixture.js.map +1 -1
- package/dist/esm/assurance/assurance-authority-basis.definitions.d.ts +24 -1
- package/dist/esm/assurance/assurance-authority-basis.definitions.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-authority-basis.definitions.js +75 -5
- package/dist/esm/assurance/assurance-authority-basis.definitions.js.map +1 -1
- package/dist/esm/assurance/assurance-authority-basis.schemas.d.ts +6 -0
- package/dist/esm/assurance/assurance-authority-basis.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-document-blueprint-selection.d.ts +11 -0
- package/dist/esm/assurance/assurance-document-blueprint-selection.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-document-blueprint-selection.js +22 -3
- 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 +39 -6
- package/dist/esm/assurance/assurance-document-system.definitions.js.map +1 -1
- package/dist/esm/assurance/assurance-document-system.schemas.d.ts +11 -0
- package/dist/esm/assurance/assurance-document-system.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-document-system.schemas.js +19 -0
- package/dist/esm/assurance/assurance-document-system.schemas.js.map +1 -1
- package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.js +295 -31
- package/dist/esm/assurance/assurance-evidence-requirement-bodies.definitions.js.map +1 -1
- package/dist/esm/assurance/assurance-foundation.schemas.d.ts +7 -0
- package/dist/esm/assurance/assurance-foundation.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-foundation.schemas.js +7 -0
- package/dist/esm/assurance/assurance-foundation.schemas.js.map +1 -1
- package/dist/esm/assurance/assurance-objective-catalog.definitions.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-objective-catalog.definitions.js +17 -0
- package/dist/esm/assurance/assurance-objective-catalog.definitions.js.map +1 -1
- package/dist/esm/assurance/assurance-program-generation.schemas.d.ts +5 -1
- package/dist/esm/assurance/assurance-program-generation.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-program-generation.schemas.js +6 -3
- package/dist/esm/assurance/assurance-program-generation.schemas.js.map +1 -1
- package/dist/esm/assurance/assurance-program.family-aspects.js +1 -1
- package/dist/esm/assurance/assurance-program.family-aspects.js.map +1 -1
- package/dist/esm/assurance/assurance-program.schemas.d.ts +232 -3
- package/dist/esm/assurance/assurance-program.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-program.schemas.js +107 -14
- 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 +77 -1
- package/dist/esm/assurance/assurance-source-registry.definitions.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 +23 -1
- package/dist/esm/assurance/assurance-verification-requirement-bodies.definitions.js.map +1 -1
- package/dist/esm/assurance/governed-document-release.d.ts +7 -0
- package/dist/esm/assurance/governed-document-release.d.ts.map +1 -1
- package/dist/esm/assurance/governed-document-release.js +11 -2
- package/dist/esm/assurance/governed-document-release.js.map +1 -1
- package/dist/esm/companion-exports.d.ts +6 -5
- package/dist/esm/companion-exports.d.ts.map +1 -1
- package/dist/esm/companion-exports.js.map +1 -1
- package/dist/esm/engine/applications/resources/application-api-keys.resource.specification.d.ts +1 -0
- package/dist/esm/engine/applications/resources/application-api-keys.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/applications/resources/application-api-keys.resource.specification.js +35 -33
- package/dist/esm/engine/applications/resources/application-api-keys.resource.specification.js.map +1 -1
- package/dist/esm/engine/applications/resources/application-metadata.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/applications/resources/application-metadata.resource.specification.js +6 -2
- 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.map +1 -1
- package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.js +13 -12
- 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.map +1 -1
- package/dist/esm/engine/applications/resources/application-versions.resource.specification.js +26 -2
- 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.map +1 -1
- package/dist/esm/engine/applications/resources/applications.resource.specification.js +4 -4
- package/dist/esm/engine/applications/resources/applications.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/application-access-grants.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/application-access-grants.resource.specification.js +11 -9
- package/dist/esm/engine/auth/resources/application-access-grants.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/oauth-consent-grants.resource.specification.js +2 -2
- package/dist/esm/engine/auth/resources/oauth-consent-grants.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/organization-api-keys.resource.specification.d.ts +1 -0
- package/dist/esm/engine/auth/resources/organization-api-keys.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/organization-api-keys.resource.specification.js +45 -32
- package/dist/esm/engine/auth/resources/organization-api-keys.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.d.ts +1 -23
- 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 +185 -31
- package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.d.ts +2 -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 +29 -7
- package/dist/esm/engine/auth/resources/organization-provider-credentials.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/platform-access-grants.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/platform-access-grants.resource.specification.js +7 -1
- package/dist/esm/engine/auth/resources/platform-access-grants.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 +9 -6
- package/dist/esm/engine/auth/resources/scim-provisioning-config.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/scim-tokens.resource.specification.d.ts +1 -0
- package/dist/esm/engine/auth/resources/scim-tokens.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/scim-tokens.resource.specification.js +11 -7
- package/dist/esm/engine/auth/resources/scim-tokens.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/siem-delivery-dlq.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/siem-delivery-dlq.resource.specification.js +18 -16
- package/dist/esm/engine/auth/resources/siem-delivery-dlq.resource.specification.js.map +1 -1
- 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 +9 -11
- 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.map +1 -1
- package/dist/esm/engine/auth/resources/sso-config.resource.specification.js +238 -219
- 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 +0 -24
- 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 +76 -16
- 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 +2 -1
- 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 +28 -6
- 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 +29 -11
- package/dist/esm/engine/billing/resources/billing-accounts.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/billing-provider-event-settlements.resource.specification.js +1 -1
- package/dist/esm/engine/billing/resources/billing-provider-event-settlements.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/credit-pools.resource.specification.d.ts +2 -0
- package/dist/esm/engine/billing/resources/credit-pools.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/credit-pools.resource.specification.js +13 -12
- package/dist/esm/engine/billing/resources/credit-pools.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/invoice-refs.resource.specification.js +5 -5
- package/dist/esm/engine/billing/resources/invoice-refs.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/prices.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/prices.resource.specification.js +12 -9
- package/dist/esm/engine/billing/resources/prices.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/products.resource.specification.d.ts +7 -4
- package/dist/esm/engine/billing/resources/products.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/products.resource.specification.js +36 -16
- package/dist/esm/engine/billing/resources/products.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/promotions.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/promotions.resource.specification.js +13 -10
- package/dist/esm/engine/billing/resources/promotions.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/referrals.resource.specification.d.ts +13 -8
- package/dist/esm/engine/billing/resources/referrals.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/referrals.resource.specification.js +54 -20
- package/dist/esm/engine/billing/resources/referrals.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/subscriptions.resource.specification.d.ts +30 -4
- package/dist/esm/engine/billing/resources/subscriptions.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/subscriptions.resource.specification.js +85 -25
- package/dist/esm/engine/billing/resources/subscriptions.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/usage-records.resource.specification.js +2 -2
- package/dist/esm/engine/billing/resources/usage-records.resource.specification.js.map +1 -1
- package/dist/esm/engine/compliance/resources/application-audit-logs.resource.specification.d.ts +15 -2
- package/dist/esm/engine/compliance/resources/application-audit-logs.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/compliance/resources/application-audit-logs.resource.specification.js +45 -10
- package/dist/esm/engine/compliance/resources/application-audit-logs.resource.specification.js.map +1 -1
- package/dist/esm/engine/compliance/resources/audit-logs.resource.specification.d.ts +15 -2
- package/dist/esm/engine/compliance/resources/audit-logs.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/compliance/resources/audit-logs.resource.specification.js +52 -12
- package/dist/esm/engine/compliance/resources/audit-logs.resource.specification.js.map +1 -1
- package/dist/esm/engine/compliance/resources/index.d.ts +1 -0
- package/dist/esm/engine/compliance/resources/index.d.ts.map +1 -1
- package/dist/esm/engine/compliance/resources/index.js +1 -0
- package/dist/esm/engine/compliance/resources/index.js.map +1 -1
- package/dist/esm/engine/compliance/resources/legal-holds.resource.specification.d.ts +39 -0
- package/dist/esm/engine/compliance/resources/legal-holds.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/compliance/resources/legal-holds.resource.specification.js +325 -0
- package/dist/esm/engine/compliance/resources/legal-holds.resource.specification.js.map +1 -0
- package/dist/esm/engine/compliance/resources/retention-enforcement-records.resource.specification.d.ts +23 -0
- package/dist/esm/engine/compliance/resources/retention-enforcement-records.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/compliance/resources/retention-enforcement-records.resource.specification.js +197 -0
- package/dist/esm/engine/compliance/resources/retention-enforcement-records.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 +59 -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 +69 -0
- package/dist/esm/engine/errors/error-messages.specification.js.map +1 -1
- package/dist/esm/engine/features/resources/application-features.resource.specification.d.ts +5 -5
- 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 +9 -10
- 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 +5 -5
- package/dist/esm/engine/features/resources/organization-features.resource.specification.js +11 -11
- 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 +5 -5
- package/dist/esm/engine/features/resources/user-features.resource.specification.js +3 -3
- 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 +7 -8
- package/dist/esm/engine/files/resources/files.resource.specification.js.map +1 -1
- package/dist/esm/engine/flows-actors/resources/a2a-push-delivery-log.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/flows-actors/resources/a2a-push-delivery-log.resource.specification.js +16 -4
- package/dist/esm/engine/flows-actors/resources/a2a-push-delivery-log.resource.specification.js.map +1 -1
- package/dist/esm/engine/flows-actors/resources/a2a-token-budget-state.resource.specification.js +1 -1
- package/dist/esm/engine/flows-actors/resources/a2a-token-budget-state.resource.specification.js.map +1 -1
- package/dist/esm/engine/flows-actors/resources/agent-work-decisions.resource.specification.d.ts +11 -0
- package/dist/esm/engine/flows-actors/resources/agent-work-decisions.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/flows-actors/resources/agent-work-decisions.resource.specification.js +382 -0
- package/dist/esm/engine/flows-actors/resources/agent-work-decisions.resource.specification.js.map +1 -0
- package/dist/esm/engine/flows-actors/resources/flow-actor-executions.resource.specification.d.ts +139 -1
- 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 +150 -4
- 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.map +1 -1
- package/dist/esm/engine/flows-actors/resources/flow-actor-tasks.resource.specification.js +9 -1
- package/dist/esm/engine/flows-actors/resources/flow-actor-tasks.resource.specification.js.map +1 -1
- package/dist/esm/engine/flows-actors/resources/model-call-attributions.resource.specification.d.ts +3 -0
- package/dist/esm/engine/flows-actors/resources/model-call-attributions.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/flows-actors/resources/model-call-attributions.resource.specification.js +162 -0
- package/dist/esm/engine/flows-actors/resources/model-call-attributions.resource.specification.js.map +1 -0
- package/dist/esm/engine/flows-actors/resources/model-cost-period-aggregates.resource.specification.d.ts +3 -0
- package/dist/esm/engine/flows-actors/resources/model-cost-period-aggregates.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/flows-actors/resources/model-cost-period-aggregates.resource.specification.js +158 -0
- package/dist/esm/engine/flows-actors/resources/model-cost-period-aggregates.resource.specification.js.map +1 -0
- package/dist/esm/engine/flows-actors/resources/provider-call-records.resource.specification.d.ts +2 -1
- package/dist/esm/engine/flows-actors/resources/provider-call-records.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/flows-actors/resources/provider-call-records.resource.specification.js +16 -9
- package/dist/esm/engine/flows-actors/resources/provider-call-records.resource.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/ai-elements/decision/ai-approval-queue.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/ai-elements/decision/ai-approval-queue.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/ai-elements/decision/ai-approval-request.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/ai-elements/decision/ai-approval-request.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/app/app-layout-agent-work-override-rate-settings.frontend-component.specification.d.ts +5 -0
- package/dist/esm/engine/frontend-components/app/app-layout-agent-work-override-rate-settings.frontend-component.specification.d.ts.map +1 -0
- package/dist/esm/engine/frontend-components/app/app-layout-agent-work-override-rate-settings.frontend-component.specification.js +79 -0
- package/dist/esm/engine/frontend-components/app/app-layout-agent-work-override-rate-settings.frontend-component.specification.js.map +1 -0
- package/dist/esm/engine/frontend-components/app/app-layout-appearance-settings.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/app/app-layout-appearance-settings.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/app/app-layout-billing-settings.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/app/app-layout-billing-settings.frontend-component.specification.js +3 -1
- package/dist/esm/engine/frontend-components/app/app-layout-billing-settings.frontend-component.specification.js.map +1 -1
- 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 +5 -4
- 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-invitations-settings.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/app/app-layout-invitations-settings.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/auth/admin-config/app-page-security-settings.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/auth/admin-config/app-page-security-settings.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/data-display/formatters/display-field-number.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/data-display/formatters/display-field-number.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/data-display/formatters/display-field-string.frontend-component.specification.js +2 -2
- package/dist/esm/engine/frontend-components/data-display/formatters/display-field-string.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/flows-actors/low-level-ai-decision.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/flows-actors/low-level-ai-decision.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/form/fields/form-field-address.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/form/fields/form-field-address.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/form/fields/form-field-address.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/form/fields/form-field-string.frontend-component.specification.js +2 -2
- package/dist/esm/engine/frontend-components/form/fields/form-field-string.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/index.d.ts +1 -0
- package/dist/esm/engine/frontend-components/index.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/index.js +3 -0
- package/dist/esm/engine/frontend-components/index.js.map +1 -1
- package/dist/esm/engine/frontend-components/resources/resource-layout-empty-state.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/resources/resource-layout-empty-state.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/resources/resources-fields-resource-reference-display.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/resources/resources-fields-resource-reference-display.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/resources/resources-fields-resource-reference-edit.frontend-component.specification.js +1 -1
- package/dist/esm/engine/frontend-components/resources/resources-fields-resource-reference-edit.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/sections/stepper.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/sections/stepper.frontend-component.specification.js +9 -4
- package/dist/esm/engine/frontend-components/sections/stepper.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/guidance/resources/guidance-state.resource.specification.js +4 -4
- package/dist/esm/engine/guidance/resources/guidance-state.resource.specification.js.map +1 -1
- package/dist/esm/engine/guidance/resources/lifecycle-state.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/guidance/resources/lifecycle-state.resource.specification.js +34 -0
- package/dist/esm/engine/guidance/resources/lifecycle-state.resource.specification.js.map +1 -1
- package/dist/esm/engine/guidance/resources/progression-state.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/guidance/resources/progression-state.resource.specification.js +26 -0
- package/dist/esm/engine/guidance/resources/progression-state.resource.specification.js.map +1 -1
- package/dist/esm/engine/infrastructure/resources/data-seed-runs.resource.specification.js +2 -2
- package/dist/esm/engine/infrastructure/resources/data-seed-runs.resource.specification.js.map +1 -1
- package/dist/esm/engine/infrastructure/resources/external-data-erasure-suppressions.resource.specification.d.ts +9 -0
- package/dist/esm/engine/infrastructure/resources/external-data-erasure-suppressions.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/infrastructure/resources/external-data-erasure-suppressions.resource.specification.js +122 -0
- package/dist/esm/engine/infrastructure/resources/external-data-erasure-suppressions.resource.specification.js.map +1 -0
- package/dist/esm/engine/infrastructure/resources/external-data-outbound-changes.resource.specification.d.ts +9 -0
- package/dist/esm/engine/infrastructure/resources/external-data-outbound-changes.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/infrastructure/resources/external-data-outbound-changes.resource.specification.js +152 -0
- package/dist/esm/engine/infrastructure/resources/external-data-outbound-changes.resource.specification.js.map +1 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pending-references.resource.specification.d.ts +10 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pending-references.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pending-references.resource.specification.js +94 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pending-references.resource.specification.js.map +1 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership-keys.resource.specification.d.ts +10 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership-keys.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership-keys.resource.specification.js +64 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership-keys.resource.specification.js.map +1 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership.resource.specification.d.ts +4 -1
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership.resource.specification.js +20 -16
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-membership.resource.specification.js.map +1 -1
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-run-records.resource.specification.d.ts +9 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-run-records.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-run-records.resource.specification.js +200 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-run-records.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 +19 -6
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-states.resource.specification.js.map +1 -1
- package/dist/esm/engine/infrastructure/resources/external-data-remote-versions.resource.specification.d.ts +9 -0
- package/dist/esm/engine/infrastructure/resources/external-data-remote-versions.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/infrastructure/resources/external-data-remote-versions.resource.specification.js +97 -0
- package/dist/esm/engine/infrastructure/resources/external-data-remote-versions.resource.specification.js.map +1 -0
- package/dist/esm/engine/infrastructure/resources/job-executions.resource.specification.d.ts +8 -0
- 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 +2 -2
- 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 +2 -2
- package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.js +1 -1
- 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.js +4 -4
- package/dist/esm/engine/infrastructure/resources/system-of-record-partition-assignments.resource.specification.js.map +1 -1
- package/dist/esm/engine/infrastructure/resources/system-of-record-write-admissions.resource.specification.d.ts +9 -0
- package/dist/esm/engine/infrastructure/resources/system-of-record-write-admissions.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/infrastructure/resources/system-of-record-write-admissions.resource.specification.js +153 -0
- package/dist/esm/engine/infrastructure/resources/system-of-record-write-admissions.resource.specification.js.map +1 -0
- package/dist/esm/engine/notifications/resources/conversation-threads.resource.specification.d.ts +81 -0
- package/dist/esm/engine/notifications/resources/conversation-threads.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/notifications/resources/conversation-threads.resource.specification.js +437 -0
- package/dist/esm/engine/notifications/resources/conversation-threads.resource.specification.js.map +1 -0
- package/dist/esm/engine/notifications/resources/inbound-deliveries.resource.specification.d.ts +112 -0
- package/dist/esm/engine/notifications/resources/inbound-deliveries.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/notifications/resources/inbound-deliveries.resource.specification.js +287 -0
- package/dist/esm/engine/notifications/resources/inbound-deliveries.resource.specification.js.map +1 -0
- package/dist/esm/engine/notifications/resources/inbound-email.resource.specification.d.ts +131 -0
- package/dist/esm/engine/notifications/resources/inbound-email.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/notifications/resources/inbound-email.resource.specification.js +594 -0
- package/dist/esm/engine/notifications/resources/inbound-email.resource.specification.js.map +1 -0
- package/dist/esm/engine/notifications/resources/index.d.ts +1 -0
- package/dist/esm/engine/notifications/resources/index.d.ts.map +1 -1
- package/dist/esm/engine/notifications/resources/index.js +1 -0
- package/dist/esm/engine/notifications/resources/index.js.map +1 -1
- package/dist/esm/engine/notifications/resources/m2m-webhook-delivery-log.resource.specification.d.ts +6 -3
- package/dist/esm/engine/notifications/resources/m2m-webhook-delivery-log.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/notifications/resources/m2m-webhook-delivery-log.resource.specification.js +20 -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.map +1 -1
- package/dist/esm/engine/notifications/resources/notification-badges.resource.specification.js +12 -2
- package/dist/esm/engine/notifications/resources/notification-badges.resource.specification.js.map +1 -1
- package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.d.ts +6 -6
- package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.js +8 -11
- package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.js.map +1 -1
- package/dist/esm/engine/notifications/system-emails/human-decision.system-emails.specification.d.ts +4 -0
- package/dist/esm/engine/notifications/system-emails/human-decision.system-emails.specification.d.ts.map +1 -0
- package/dist/esm/engine/notifications/system-emails/human-decision.system-emails.specification.js +62 -0
- package/dist/esm/engine/notifications/system-emails/human-decision.system-emails.specification.js.map +1 -0
- package/dist/esm/engine/notifications/system-emails/index.d.ts +2 -1
- package/dist/esm/engine/notifications/system-emails/index.d.ts.map +1 -1
- package/dist/esm/engine/notifications/system-emails/index.js +4 -2
- package/dist/esm/engine/notifications/system-emails/index.js.map +1 -1
- package/dist/esm/engine/organizations/resources/index.d.ts +2 -0
- package/dist/esm/engine/organizations/resources/index.d.ts.map +1 -1
- package/dist/esm/engine/organizations/resources/index.js +2 -0
- package/dist/esm/engine/organizations/resources/index.js.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-members.resource.specification.d.ts +3 -0
- package/dist/esm/engine/organizations/resources/organization-members.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-members.resource.specification.js +40 -12
- package/dist/esm/engine/organizations/resources/organization-members.resource.specification.js.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-notifications.resource.specification.js +2 -2
- package/dist/esm/engine/organizations/resources/organization-notifications.resource.specification.js.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-preferences.resource.specification.js +2 -2
- package/dist/esm/engine/organizations/resources/organization-preferences.resource.specification.js.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-profiles.resource.specification.d.ts +0 -1
- package/dist/esm/engine/organizations/resources/organization-profiles.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-profiles.resource.specification.js +4 -6
- package/dist/esm/engine/organizations/resources/organization-profiles.resource.specification.js.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-unit-members.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-unit-members.resource.specification.js +7 -3
- package/dist/esm/engine/organizations/resources/organization-unit-members.resource.specification.js.map +1 -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 +15 -8
- 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 +3 -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 +36 -21
- package/dist/esm/engine/organizations/resources/organizations.resource.specification.js.map +1 -1
- package/dist/esm/engine/organizations/resources/service-provider-activity-feed.resource.specification.d.ts +38 -0
- package/dist/esm/engine/organizations/resources/service-provider-activity-feed.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/organizations/resources/service-provider-activity-feed.resource.specification.js +152 -0
- package/dist/esm/engine/organizations/resources/service-provider-activity-feed.resource.specification.js.map +1 -0
- package/dist/esm/engine/organizations/resources/service-provider-relationships.resource.specification.d.ts +106 -0
- package/dist/esm/engine/organizations/resources/service-provider-relationships.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/organizations/resources/service-provider-relationships.resource.specification.js +417 -0
- package/dist/esm/engine/organizations/resources/service-provider-relationships.resource.specification.js.map +1 -0
- package/dist/esm/engine/providers/apple.provider.specification.js +1 -1
- package/dist/esm/engine/providers/apple.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/github.provider.specification.js +1 -1
- package/dist/esm/engine/providers/github.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/google-places.provider.specification.d.ts +6 -0
- package/dist/esm/engine/providers/google-places.provider.specification.d.ts.map +1 -0
- package/dist/esm/engine/providers/google-places.provider.specification.js +44 -0
- package/dist/esm/engine/providers/google-places.provider.specification.js.map +1 -0
- package/dist/esm/engine/providers/google.provider.specification.js +1 -1
- package/dist/esm/engine/providers/google.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/index.d.ts +2 -0
- package/dist/esm/engine/providers/index.d.ts.map +1 -1
- package/dist/esm/engine/providers/index.js +5 -1
- package/dist/esm/engine/providers/index.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 +10 -6
- package/dist/esm/engine/providers/microsoft.provider.specification.js.map +1 -1
- package/dist/esm/engine/providers/recaptcha.provider.specification.d.ts +6 -0
- package/dist/esm/engine/providers/recaptcha.provider.specification.d.ts.map +1 -0
- package/dist/esm/engine/providers/recaptcha.provider.specification.js +38 -0
- package/dist/esm/engine/providers/recaptcha.provider.specification.js.map +1 -0
- package/dist/esm/engine/providers/resend.provider.specification.d.ts.map +1 -1
- package/dist/esm/engine/providers/resend.provider.specification.js +3 -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 +3 -2
- package/dist/esm/engine/providers/stripe.provider.specification.js.map +1 -1
- package/dist/esm/engine/roles/app-billing-provider-events.role.specification.d.ts +2 -0
- package/dist/esm/engine/roles/app-billing-provider-events.role.specification.d.ts.map +1 -0
- package/dist/esm/engine/roles/app-billing-provider-events.role.specification.js +21 -0
- package/dist/esm/engine/roles/app-billing-provider-events.role.specification.js.map +1 -0
- package/dist/esm/engine/roles/app-email-inbound-intake.role.specification.d.ts +2 -0
- package/dist/esm/engine/roles/app-email-inbound-intake.role.specification.d.ts.map +1 -0
- package/dist/esm/engine/roles/app-email-inbound-intake.role.specification.js +21 -0
- package/dist/esm/engine/roles/app-email-inbound-intake.role.specification.js.map +1 -0
- package/dist/esm/engine/roles/index.d.ts +13 -5
- package/dist/esm/engine/roles/index.d.ts.map +1 -1
- package/dist/esm/engine/roles/index.js +19 -6
- package/dist/esm/engine/roles/index.js.map +1 -1
- package/dist/esm/engine/roles/org-billing-provider-events.role.specification.d.ts +2 -0
- package/dist/esm/engine/roles/org-billing-provider-events.role.specification.d.ts.map +1 -0
- package/dist/esm/engine/roles/org-billing-provider-events.role.specification.js +21 -0
- package/dist/esm/engine/roles/org-billing-provider-events.role.specification.js.map +1 -0
- package/dist/esm/engine/roles/org-delegated-capabilities.role.specification.d.ts +7 -0
- package/dist/esm/engine/roles/org-delegated-capabilities.role.specification.d.ts.map +1 -0
- package/dist/esm/engine/roles/org-delegated-capabilities.role.specification.js +72 -0
- package/dist/esm/engine/roles/org-delegated-capabilities.role.specification.js.map +1 -0
- package/dist/esm/engine/roles/org-service-provider.role.specification.d.ts +2 -0
- package/dist/esm/engine/roles/org-service-provider.role.specification.d.ts.map +1 -0
- package/dist/esm/engine/roles/org-service-provider.role.specification.js +22 -0
- package/dist/esm/engine/roles/org-service-provider.role.specification.js.map +1 -0
- 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.js +3 -3
- package/dist/esm/engine/users/resources/inbound-contacts.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/self-service-user-notifications.shared.d.ts +1 -1
- package/dist/esm/engine/users/resources/self-service-user-notifications.shared.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/self-service-user-notifications.shared.js +3 -6
- package/dist/esm/engine/users/resources/self-service-user-notifications.shared.js.map +1 -1
- package/dist/esm/engine/users/resources/user-credentials.resource.specification.js +2 -2
- package/dist/esm/engine/users/resources/user-credentials.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/user-identity-links.resource.specification.js +2 -2
- 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 +0 -4
- package/dist/esm/engine/users/resources/user-preferences-api-reference.examples.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/user-preferences-api-reference.examples.js +0 -3
- 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 +0 -3
- package/dist/esm/engine/users/resources/user-preferences.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/user-preferences.resource.specification.js +7 -7
- package/dist/esm/engine/users/resources/user-preferences.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/user-profiles.resource.specification.js +5 -5
- package/dist/esm/engine/users/resources/user-profiles.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.d.ts +0 -3
- package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.js +11 -18
- package/dist/esm/engine/users/resources/user-self-preferences.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/user-self-profiles.resource.specification.js +6 -6
- package/dist/esm/engine/users/resources/user-self-profiles.resource.specification.js.map +1 -1
- 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 +5 -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 +8 -5
- package/dist/esm/engine/users/resources/users.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/users.resource.specification.js +49 -16
- package/dist/esm/engine/users/resources/users.resource.specification.js.map +1 -1
- 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 +29 -10
- package/dist/esm/technical-documentation/engine-documentation-specification-catalog.companion.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -1
- package/package.json +8 -8
- package/dist/assurance/external-framework-mapping.json +0 -1228
package/dist/esm/engine/flows-actors/resources/a2a-token-budget-state.resource.specification.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"a2a-token-budget-state.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/flows-actors/resources/a2a-token-budget-state.resource.specification.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AACpE,OAAO,EACL,mBAAmB,EACnB,cAAc,EACd,uBAAuB,GACxB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,yBAAyB,EACzB,qBAAqB,IAAI,EAAE,EAC3B,gBAAgB,EAChB,oBAAoB,EACpB,uCAAuC,GACxC,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAmC,sBAAsB,EAAE,qBAAqB,EAAE,MAAM,6BAA6B,CAAC;AAC7H,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAqC3E,MAAM,mCAAmC,GAAwD;IAC/F,CAAC,gBAAgB,CAAC,2BAA2B,CAAC,EAAE,oBAAoB,CAAC,SAAS;IAC9E,CAAC,gBAAgB,CAAC,mCAAmC,CAAC,EAAE,oBAAoB,CAAC,aAAa;IAC1F,CAAC,gBAAgB,CAAC,kCAAkC,CAAC,EAAE,oBAAoB,CAAC,WAAW;CACxF,CAAC;AAQF;;;;GAIG;AACH,SAAS,gCAAgC,CAAC,YAAmC;IAC3E,QAAQ,YAAY,EAAE,CAAC;QACrB,KAAK,gBAAgB,CAAC,2BAA2B;YAC/C,OAAO,EAAE,aAAa,EAAE,EAAE,MAAM,EAAE,iBAAiB,EAAE,EAAE,UAAU,EAAE,MAAM,EAAE,CAAC;QAC9E,KAAK,gBAAgB,CAAC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ClH,gBAAgB,EAAE;oBAChB,EAAE,IAAI,EAAE,sBAAsB,CAAC,MAAM,EAAE,OAAO,EAAE,uiBAAuiB,EAAE;iBAC1lB;gBACD,cAAc,EAAE;oBACd,EAAE,IAAI,EAAE,sBAAsB,CAAC,aAAa,EAAE,IAAI,EAAE,yGAAyG,EAAE;oBAC/J,EAAE,IAAI,EAAE,sBAAsB,CAAC,aAAa,EAAE,IAAI,EAAE,qJAAqJ,EAAE;iBAC5M;gBACD,UAAU,EAAE,IAAI;aACjB;SACF;QAED,mBAAmB,EAAE;YACnB,yXAAyX;YACzX,0PAA0P;YAC1P,kaAAka;YACla,sLAAsL;YACtL,8SAA8S;YAC9S,kgBAAkgB;YAClgB,+yBAA+yB;YAC/yB,8hBAA8hB;YAC9hB,8OAA8O;SAC/O;KACF,CAAC;IACF,uFAAuF;IACvF,oFAAoF;IACpF,qFAAqF;IACrF,uFAAuF;IACvF,wEAAwE;IACxE,EAAE,oBAAoB,EAAE,mCAAmC,CAAC,YAAY,CAAC,EAAE,CAC5E,CAAC;AACJ,CAAC;AAED,MAAM,CAAC,MAAM,4CAA4C,GAAG,6CAA6C,CACvG,gBAAgB,CAAC,2BAA2B,EAC5C,6BAA6B,CAC9B,CAAC;AAEF,MAAM,CAAC,MAAM,oDAAoD,GAAG,6CAA6C,CAC/G,gBAAgB,CAAC,mCAAmC,EACpD,qCAAqC,CACtC,CAAC;AAEF,MAAM,CAAC,MAAM,mDAAmD,GAAG,6CAA6C,CAC9G,gBAAgB,CAAC,kCAAkC,EACnD,oCAAoC,CACrC,CAAC","sourcesContent":["import { LabelAudience } from '@wildo-ai/presets-components-models';\nimport {\n CodeDeclarationKind,\n CodeSymbolKind,\n FieldSemanticImportance,\n} from '@wildo-ai/zod-decorators';\nimport {\n A2ATokenBudgetStateSchema,\n CoreResourceOperation as Op,\n CoreResourceType,\n ResourcePrimaryScope,\n a2aTokenBudgetStatePolymorphicFactories,\n} from '@wildo-ai/saas-models';\nimport { type CoreResourceTypeMemberName, HttpResponseStatusCode, resourceSpecification } from '~wildo-specifications/_core';\nimport { EngineResourceSubDomain } from '../../engine-resource-sub-domain';\n\n/**\n * Framework-owned specification for the `a2aTokenBudgetState` POLYMORPHIC SINGLETON\n * family: the per-tenant LLM **token budget accumulator** that lets the inbound\n * Agent2Agent (A2A) transport fail-closed BEFORE dispatch once a tenant has spent its\n * plan-granted period allowance. One base envelope is stamped out as three genuine\n * single-scope variants, each owned by its injected owner FK:\n * - `userA2aTokenBudgetState` (USER_SELF — user-delegated A2A turns)\n * - `organizationA2aTokenBudgetState` (ORGANIZATIONS — org-machine A2A turns)\n * - `applicationA2aTokenBudgetState` (APPLICATION — app-machine A2A turns)\n *\n * This is INTERNAL ENFORCEMENT STATE, not user-authored data. The A2A runtime\n * (`A2ATokenBudgetBackendService`) is the only writer — it opens the singleton on the\n * first budgeted turn (CREATE, INTERNAL_CALL super-admin via `*AsSystem`) and then\n * advances the counter through an ATOMIC repository-tier increment rather than a\n * service-tier update, so concurrent turns cannot lose tokens to a read-modify-write\n * race. That is why NO `UPDATE` operation is declared. The tenant's own surface is READ\n * only: an owner-level \"how much of my allowance have I used?\" view. DELETE exists solely\n * as the cascade teardown and is INTERNAL_CALL — it gets NO HTTP route at all, because\n * zeroing this row would reset a tenant's recorded spend (see the DELETE operation prose).\n *\n * TWO HALVES, DELIBERATELY SEPARATED: the ALLOWANCE (the cap) is NOT stored here — it\n * is resolved live from the tenant's billing plan via the `a2a.llm.tokensPerPeriod`\n * LIMIT feature (`A2A_TOKEN_BUDGET_FEATURE_ID`), so a plan upgrade/downgrade applies\n * immediately with no copy to keep in sync. This row accumulates CONSUMPTION only.\n *\n * ONE spec covers all three variants (per the flow-actor-executions / billing / SSO\n * polymorphic-spec precedent).\n */\n\ntype A2ABudgetResourceType =\n | CoreResourceType.USER_A2A_TOKEN_BUDGET_STATE\n | CoreResourceType.ORGANIZATION_A2A_TOKEN_BUDGET_STATE\n | CoreResourceType.APPLICATION_A2A_TOKEN_BUDGET_STATE;\ntype A2ABudgetResourceTypeMember = CoreResourceTypeMemberName<A2ABudgetResourceType>;\n\nconst a2aBudgetPrimaryScopeByResourceType: Record<A2ABudgetResourceType, ResourcePrimaryScope> = {\n [CoreResourceType.USER_A2A_TOKEN_BUDGET_STATE]: ResourcePrimaryScope.USER_SELF,\n [CoreResourceType.ORGANIZATION_A2A_TOKEN_BUDGET_STATE]: ResourcePrimaryScope.ORGANIZATIONS,\n [CoreResourceType.APPLICATION_A2A_TOKEN_BUDGET_STATE]: ResourcePrimaryScope.APPLICATION,\n};\n\ninterface A2ATokenBudgetScopeExample {\n readonly scopeIdentity: Readonly<Record<string, string>>;\n /** Human-readable prose fragment for example titles, not a semantic vocabulary. */\n readonly scopeLabel: string;\n}\n\n/**\n * Owns the concrete path and response FK for each polymorphic budget contract.\n * The budget semantics are shared, but the public scope identity is not: an\n * example for one tenant type must never teach a sibling's URL parameter.\n */\nfunction createA2ATokenBudgetScopeExample(resourceType: A2ABudgetResourceType): A2ATokenBudgetScopeExample {\n switch (resourceType) {\n case CoreResourceType.USER_A2A_TOKEN_BUDGET_STATE:\n return { scopeIdentity: { userId: 'user_01JEXAMPLE' }, scopeLabel: 'user' };\n case CoreResourceType.ORGANIZATION_A2A_TOKEN_BUDGET_STATE:\n return { scopeIdentity: { organizationId: 'org_01JEXAMPLE' }, scopeLabel: 'organization' };\n case CoreResourceType.APPLICATION_A2A_TOKEN_BUDGET_STATE:\n return { scopeIdentity: { applicationId: 'app_01JEXAMPLE' }, scopeLabel: 'application' };\n default: {\n const exhaustiveResourceType: never = resourceType;\n throw new Error(`Unsupported A2A token-budget resource type: ${String(exhaustiveResourceType)}`);\n }\n }\n}\n\ntype Cfg = ReturnType<(typeof a2aTokenBudgetStatePolymorphicFactories)[CoreResourceType.USER_A2A_TOKEN_BUDGET_STATE]>;\ntype Core = Cfg['coreOperations'][number];\ntype Main = typeof A2ATokenBudgetStateSchema;\n\nfunction buildA2ATokenBudgetStateResourceSpecification(\n resourceType: A2ABudgetResourceType,\n resourceTypeMemberName: A2ABudgetResourceTypeMember,\n) {\n const exampleScope = createA2ATokenBudgetScopeExample(resourceType);\n const currentBudgetExample = {\n _id: `a2a_budget_${exampleScope.scopeLabel}_01JEXAMPLE`,\n periodKey: '2026-08',\n consumedTokens: 72_450,\n lastTurnAt: '2026-08-20T11:18:42.000Z',\n createdAt: '2026-08-02T08:15:00.000Z',\n updatedAt: '2026-08-20T11:18:42.000Z',\n ...exampleScope.scopeIdentity,\n };\n const currentBudgetSummaryExample = {\n _id: currentBudgetExample._id,\n periodKey: currentBudgetExample.periodKey,\n consumedTokens: currentBudgetExample.consumedTokens,\n lastTurnAt: currentBudgetExample.lastTurnAt,\n };\n\n return resourceSpecification<undefined, Core, Main>(\n a2aTokenBudgetStatePolymorphicFactories[resourceType],\n A2ATokenBudgetStateSchema,\n ({ schemaShape }) => ({\n purpose: 'Report how many LLM tokens this user, organization, or application has consumed through inbound A2A agent turns in the current budget period.',\n businessRole: 'Current-period A2A consumption used with the plan allowance to decide whether another agent turn may start; the allowance itself is resolved separately and is not part of this response.',\n lifecycleRole: 'Created after the first budgeted A2A turn, incremented after completed turns, and reset in place when the period changes; this resource does not retain prior-period history.',\n audience: LabelAudience.DEVELOPER,\n subDomain: EngineResourceSubDomain.FLOWS_ACTORS,\n codeHandling: {\n mainSchema: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'A2ATokenBudgetStateSchema',\n symbolKind: CodeSymbolKind.SCHEMA,\n declarationKind: CodeDeclarationKind.ZOD_SCHEMA,\n },\n resourceFactoryCollectionEntry: {\n collectionSymbol: { packageName: '@wildo-ai/saas-models', exportName: 'a2aTokenBudgetStatePolymorphicFactories', symbolKind: CodeSymbolKind.FACTORY },\n identifierField: 'collectionKey',\n identifierValue: resourceType,\n },\n resourceType: {\n enumDeclaration: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceType',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n memberName: resourceTypeMemberName,\n },\n operationVocabulary: {\n coreEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceOperation',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n },\n notes: [\n 'Three variants under `A2A_TOKEN_BUDGET_SCOPE_VARIANTS` — user row is `USER_SELF`; org/app rows are `ORGANIZATIONS`/`APPLICATION` (machine-owned A2A).',\n 'SINGLETON: the injected owner FK is the auto business key, so the declaration deliberately does NOT opt out of the singleton auto-business-key. NOTE the uniqueness is index-enforced on MongoDB only — the SQL planner leaves index creation to migrations, so on PostgreSQL the one-row invariant is upheld by the runtime rather than the database (see businessConstraints).',\n 'The allowance is NOT persisted here: it is resolved live from the `a2a.llm.tokensPerPeriod` LIMIT feature (`A2A_TOKEN_BUDGET_FEATURE_ID` in `@wildo-ai/saas-models`) via feature resolution for the owner scope.',\n 'Sole runtime reader/writer is `A2ATokenBudgetBackendService` (`@wildo-ai/saas-backend-lib`); CREATE and READ go through `*AsSystem` under the resource\\'s `systemAccessPolicy`, while the counter is advanced by the atomic repository-tier increment primitive (there is deliberately no UPDATE operation).',\n 'Runtime has no userNotifications / m2mNotifications — do not add communications.* (DF-1).',\n ],\n },\n\n fields: {\n _id: schemaShape._id.stringSpec({\n meaning: 'Document id of this tenant\\'s single A2A token-budget record.',\n semanticRole: 'identifier',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n\n periodKey: schemaShape.periodKey.stringSpec({\n meaning: 'Stable id of the budget WINDOW this counter currently covers — a UTC calendar month (`YYYY-MM`) in v1.',\n whyItMatters: 'It is the reset boundary: when the runtime resolves a different current period, the accumulator resets `consumedTokens` and advances this key in place, so a stale period reads as zero consumption rather than carrying spend forward.',\n semanticRole: 'identifier',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n\n consumedTokens: schemaShape.consumedTokens.numberSpec({\n meaning: 'Tokens (prompt + completion) this tenant\\'s A2A agent turns have consumed within `periodKey`.',\n whyItMatters: 'It is the single value the pre-dispatch gate compares against the plan allowance; once it reaches the allowance the transport denies further turns for the rest of the period.',\n unit: 'tokens',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n\n lastTurnAt: schemaShape.lastTurnAt.dateSpec({\n meaning: 'When the last A2A turn was recorded against this budget.',\n whyItMatters: 'Observability only — it lets an operator see whether a tenant is actively spending without reconstructing the turn log; nothing in the gate reads it.',\n temporalRole: 'occurred',\n }),\n\n createdAt: schemaShape.createdAt.dateSpec({\n meaning: 'When the tenant\\'s budget record was first opened (its first budgeted A2A turn).',\n temporalRole: 'creation',\n }),\n\n updatedAt: schemaShape.updatedAt.dateSpec({\n meaning: 'When the counter was last incremented or rolled to a new period.',\n temporalRole: 'modified',\n }),\n },\n\n operations: {\n [Op.CREATE]: {\n purpose: 'Open the tenant\\'s budget singleton on its first budgeted A2A turn.',\n outcome: 'The tenant has exactly one counter row, stamped with the current period and that first turn\\'s tokens, against which every later turn is measured.',\n responseStatuses: [\n { code: HttpResponseStatusCode.CREATED_201, meaning: 'The tenant\\'s single budget record was opened. Internal/system write path (INTERNAL_CALL, service-tier) — the A2A runtime writes on the tenant\\'s behalf via `createAsSystem`; there is no self-serve create surface.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The payload fails schema validation (e.g. a missing `periodKey` or the injected owner FK).', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'A concurrent turn already opened the tenant\\'s singleton — the injected owner FK is a unique business key, so only one racer creates. The accumulator swallows this and increments the winner\\'s row instead of surfacing the conflict to the turn.' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'A non-system caller attempts to create a budget row — the operation is INTERNAL_CALL with a super-admin floor, reachable only through the A2A runtime.' },\n ],\n idempotent: false,\n },\n\n [Op.READ]: {\n purpose: 'Read the current A2A token-consumption period, consumed-token count, and latest recorded turn for this scope.',\n outcome: 'The integration owner can monitor current-period A2A consumption without treating this state as the plan allowance or as historical usage.',\n importance: FieldSemanticImportance.PRIMARY,\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The current consumption state for this scope is returned, including its period key, consumed tokens, and latest recorded turn when available.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not allowed to inspect A2A consumption for this user, organization, or application scope.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No budgeted A2A turn has been recorded for this scope yet, or the requested scope belongs to another owner.' },\n ],\n idempotent: true,\n examples: [{\n title: `Inspect current ${exampleScope.scopeLabel} A2A consumption`,\n request: exampleScope.scopeIdentity,\n response: currentBudgetExample,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n context: {\n examples: [{\n title: `Inspect current ${exampleScope.scopeLabel} A2A consumption with context`,\n request: exampleScope.scopeIdentity,\n response: currentBudgetExample,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n summary: {\n examples: [{\n title: `Inspect the compact ${exampleScope.scopeLabel} A2A consumption summary`,\n request: exampleScope.scopeIdentity,\n response: currentBudgetSummaryExample,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n },\n\n // No UPDATE operation is declared, deliberately: advancing the counter after a turn\n // (increment, or roll the period in place) is an ATOMIC repository-tier increment, not a\n // service-tier update, precisely so concurrent turns cannot lose tokens to a\n // read-modify-write race. Documenting an UPDATE here would describe a write path that does\n // not exist and invite routing the counter through it.\n\n [Op.DELETE]: {\n purpose: 'Remove a tenant\\'s budget row — platform teardown, and the cleanup the owning user/org/app deletion cascades to.',\n outcome: 'The counter row is physically removed, so a deleted tenant leaves no orphaned enforcement state behind.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The budget record was removed. The role floor is deliberately PLATFORM-ONLY (`APP_ADMIN_SUPER_ADMIN`) — NOT the owner-read roles and NOT an org admin: deleting this record zeroes the tenant\\'s recorded consumption, which is a spend-cap bypass. Read-authority does not imply delete-authority here, because the counter is enforcement state ABOUT the tenant rather than data BELONGING to it. The same default op powers the composition onParentDelete cascade, which runs at the repository tier below role checks and is therefore unaffected by the floor.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No budget row exists for the targeted tenant (it never ran a budgeted turn, or it was already removed).' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'A caller below the platform super-admin floor — including the owning tenant\\'s own admin — attempts to delete the row and reset its recorded spend.' },\n ],\n idempotent: true,\n },\n },\n\n businessConstraints: [\n 'One row per tenant: the injected owner FK (`userId` / `organizationId` / `applicationId`) is the unique business key (database-enforced on MongoDB only — see the PostgreSQL caveat below). The period lives INSIDE the row and is rolled in place, so the resource holds current-period state only — per-period history and multi-budget-feature accounting are documented follow-ons.',\n 'The plan ALLOWANCE is never stored here. It is resolved live from the `a2a.llm.tokensPerPeriod` LIMIT feature for the owner scope, so a plan change takes effect on the next turn with no copy to reconcile. This resource is the CONSUMPTION half only.',\n 'This is internal enforcement state, not user-authored data: only the A2A runtime writes it. It CREATES the row via `*AsSystem` (INTERNAL_CALL, super-admin, under the resource\\'s `systemAccessPolicy`), then advances the counter through an ATOMIC repository-tier increment rather than an update operation — which is why no UPDATE operation is declared at all. The tenant\\'s only surface is reading its own consumption.',\n 'DELETE authority is strictly platform-level and intentionally diverges from read authority: zeroing recorded consumption would let a tenant admin reset their own spend cap at will.',\n 'The budget window is a UTC calendar month (`YYYY-MM`) in v1 — deterministic and free of a per-turn billing-account lookup on the hot path. Anchoring the window to the tenant\\'s actual subscription period is a documented follow-on, isolated to the single function that resolves the current period key.',\n 'Overage is bounded but is NOT a single turn: usage is only known AFTER a turn completes and recording is fire-and-forget, so every turn already in flight when the allowance is reached passes the gate on the same reading. The burst throttle that bounds it is per-PRINCIPAL while the budget is per-TENANT, so a tenant with many members or machine credentials can overshoot proportionally to how many act at once. Pre-charging an estimate was rejected because it would require a refund/reconcile path on every turn.',\n 'Accumulation is adapter-portable: the counter is advanced through a per-adapter atomic increment primitive (a single document update on MongoDB, a single `UPDATE … RETURNING` on PostgreSQL) rather than raw MongoDB operators, so a concurrent increment cannot be lost to a read-modify-write race on either backend. Both arms are covered by real-database integration tests, including the concurrent compare-and-set on a REAL PostgreSQL: a racing writer holds the row lock while a guarded reset blocks on it, and on resuming the reset correctly matches nothing rather than overwriting the racer\\'s accumulated total. The in-memory SQL engine also used in tests models neither MVCC nor the row-lock recheck, so it covers SQL shape and sequential semantics only — the concurrency proof comes from the real-engine suite.',\n 'Exactly one row per tenant is declared through the injected owner foreign key, but the unique index is emitted only by the MongoDB adapter — the SQL planner leaves index creation to migrations. On PostgreSQL the invariant is therefore NOT database-enforced today: the runtime repairs the common race (a rejected create falls through to an increment), but two truly simultaneous first-ever turns can leave two rows, splitting consumption and under-reporting spend until a unique constraint on the owner foreign key is added to the migration.',\n 'A budget row is owned by exactly ONE scope; the polymorphic owner FK is injected on each concrete variant schema, not on `A2ATokenBudgetStateSchema` itself, and the owner primary-scope filter must never expose another tenant\\'s counter.',\n ],\n }),\n // The owner is the injected scope FK, anchored by the `<SCOPE> → *A2aTokenBudgetState`\n // primary-scope COMPOSITION edge in `resources-registry.shared.core.definitions.ts`\n // (generated by `createPolymorphicScopeRelationships` with `childCardinality: ONE`).\n // The registry factory derives the scope from `isPrimaryScope: true`; this declaration\n // feeds the spec ↔ registry alignment guard and must match per variant.\n { resourcePrimaryScope: a2aBudgetPrimaryScopeByResourceType[resourceType] },\n );\n}\n\nexport const userA2aTokenBudgetStateResourceSpecification = buildA2ATokenBudgetStateResourceSpecification(\n CoreResourceType.USER_A2A_TOKEN_BUDGET_STATE,\n 'USER_A2A_TOKEN_BUDGET_STATE',\n);\n\nexport const organizationA2aTokenBudgetStateResourceSpecification = buildA2ATokenBudgetStateResourceSpecification(\n CoreResourceType.ORGANIZATION_A2A_TOKEN_BUDGET_STATE,\n 'ORGANIZATION_A2A_TOKEN_BUDGET_STATE',\n);\n\nexport const applicationA2aTokenBudgetStateResourceSpecification = buildA2ATokenBudgetStateResourceSpecification(\n CoreResourceType.APPLICATION_A2A_TOKEN_BUDGET_STATE,\n 'APPLICATION_A2A_TOKEN_BUDGET_STATE',\n);\n"]}
|
|
1
|
+
{"version":3,"file":"a2a-token-budget-state.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/flows-actors/resources/a2a-token-budget-state.resource.specification.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AACpE,OAAO,EACL,mBAAmB,EACnB,cAAc,EACd,uBAAuB,GACxB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,yBAAyB,EACzB,qBAAqB,IAAI,EAAE,EAC3B,gBAAgB,EAChB,oBAAoB,EACpB,uCAAuC,GACxC,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAAmC,sBAAsB,EAAE,qBAAqB,EAAE,MAAM,6BAA6B,CAAC;AAC7H,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAqC3E,MAAM,mCAAmC,GAAwD;IAC/F,CAAC,gBAAgB,CAAC,2BAA2B,CAAC,EAAE,oBAAoB,CAAC,SAAS;IAC9E,CAAC,gBAAgB,CAAC,mCAAmC,CAAC,EAAE,oBAAoB,CAAC,aAAa;IAC1F,CAAC,gBAAgB,CAAC,kCAAkC,CAAC,EAAE,oBAAoB,CAAC,WAAW;CACxF,CAAC;AAQF;;;;GAIG;AACH,SAAS,gCAAgC,CAAC,YAAmC;IAC3E,QAAQ,YAAY,EAAE,CAAC;QACrB,KAAK,gBAAgB,CAAC,2BAA2B;YAC/C,OAAO,EAAE,aAAa,EAAE,EAAE,MAAM,EAAE,iBAAiB,EAAE,EAAE,UAAU,EAAE,MAAM,EAAE,CAAC;QAC9E,KAAK,gBAAgB,CAAC,mCAAmC;YACvD,OAAO,EAAE,aAAa,EAAE,EAAE,cAAc,EAAE,gBAAgB,EAAE,EAAE,UAAU,EAAE,cAAc,E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AE;oBACd,EAAE,IAAI,EAAE,sBAAsB,CAAC,aAAa,EAAE,IAAI,EAAE,yGAAyG,EAAE;oBAC/J,EAAE,IAAI,EAAE,sBAAsB,CAAC,aAAa,EAAE,IAAI,EAAE,qJAAqJ,EAAE;iBAC5M;gBACD,UAAU,EAAE,IAAI;aACjB;SACF;QAED,mBAAmB,EAAE;YACnB,yXAAyX;YACzX,0PAA0P;YAC1P,kaAAka;YACla,sLAAsL;YACtL,8SAA8S;YAC9S,kgBAAkgB;YAClgB,+yBAA+yB;YAC/yB,8hBAA8hB;YAC9hB,8OAA8O;SAC/O;KACF,CAAC;IACF,uFAAuF;IACvF,oFAAoF;IACpF,qFAAqF;IACrF,uFAAuF;IACvF,wEAAwE;IACxE,EAAE,oBAAoB,EAAE,mCAAmC,CAAC,YAAY,CAAC,EAAE,CAC5E,CAAC;AACJ,CAAC;AAED,MAAM,CAAC,MAAM,4CAA4C,GAAG,6CAA6C,CACvG,gBAAgB,CAAC,2BAA2B,EAC5C,6BAA6B,CAC9B,CAAC;AAEF,MAAM,CAAC,MAAM,oDAAoD,GAAG,6CAA6C,CAC/G,gBAAgB,CAAC,mCAAmC,EACpD,qCAAqC,CACtC,CAAC;AAEF,MAAM,CAAC,MAAM,mDAAmD,GAAG,6CAA6C,CAC9G,gBAAgB,CAAC,kCAAkC,EACnD,oCAAoC,CACrC,CAAC","sourcesContent":["import { LabelAudience } from '@wildo-ai/presets-components-models';\nimport {\n CodeDeclarationKind,\n CodeSymbolKind,\n FieldSemanticImportance,\n} from '@wildo-ai/zod-decorators';\nimport {\n A2ATokenBudgetStateSchema,\n CoreResourceOperation as Op,\n CoreResourceType,\n ResourcePrimaryScope,\n a2aTokenBudgetStatePolymorphicFactories,\n} from '@wildo-ai/saas-models';\nimport { type CoreResourceTypeMemberName, HttpResponseStatusCode, resourceSpecification } from '~wildo-specifications/_core';\nimport { EngineResourceSubDomain } from '../../engine-resource-sub-domain';\n\n/**\n * Framework-owned specification for the `a2aTokenBudgetState` POLYMORPHIC SINGLETON\n * family: the per-tenant LLM **token budget accumulator** that lets the inbound\n * Agent2Agent (A2A) transport fail-closed BEFORE dispatch once a tenant has spent its\n * plan-granted period allowance. One base envelope is stamped out as three genuine\n * single-scope variants, each owned by its injected owner FK:\n * - `userA2aTokenBudgetState` (USER_SELF — user-delegated A2A turns)\n * - `organizationA2aTokenBudgetState` (ORGANIZATIONS — org-machine A2A turns)\n * - `applicationA2aTokenBudgetState` (APPLICATION — app-machine A2A turns)\n *\n * This is INTERNAL ENFORCEMENT STATE, not user-authored data. The A2A runtime\n * (`A2ATokenBudgetBackendService`) is the only writer — it opens the singleton on the\n * first budgeted turn (CREATE, INTERNAL_CALL super-admin via `*AsSystem`) and then\n * advances the counter through an ATOMIC repository-tier increment rather than a\n * service-tier update, so concurrent turns cannot lose tokens to a read-modify-write\n * race. That is why NO `UPDATE` operation is declared. The tenant's own surface is READ\n * only: an owner-level \"how much of my allowance have I used?\" view. DELETE exists solely\n * as the cascade teardown and is INTERNAL_CALL — it gets NO HTTP route at all, because\n * zeroing this row would reset a tenant's recorded spend (see the DELETE operation prose).\n *\n * TWO HALVES, DELIBERATELY SEPARATED: the ALLOWANCE (the cap) is NOT stored here — it\n * is resolved live from the tenant's billing plan via the `a2a.llm.tokensPerPeriod`\n * LIMIT feature (`A2A_TOKEN_BUDGET_FEATURE_ID`), so a plan upgrade/downgrade applies\n * immediately with no copy to keep in sync. This row accumulates CONSUMPTION only.\n *\n * ONE spec covers all three variants (per the flow-actor-executions / billing / SSO\n * polymorphic-spec precedent).\n */\n\ntype A2ABudgetResourceType =\n | CoreResourceType.USER_A2A_TOKEN_BUDGET_STATE\n | CoreResourceType.ORGANIZATION_A2A_TOKEN_BUDGET_STATE\n | CoreResourceType.APPLICATION_A2A_TOKEN_BUDGET_STATE;\ntype A2ABudgetResourceTypeMember = CoreResourceTypeMemberName<A2ABudgetResourceType>;\n\nconst a2aBudgetPrimaryScopeByResourceType: Record<A2ABudgetResourceType, ResourcePrimaryScope> = {\n [CoreResourceType.USER_A2A_TOKEN_BUDGET_STATE]: ResourcePrimaryScope.USER_SELF,\n [CoreResourceType.ORGANIZATION_A2A_TOKEN_BUDGET_STATE]: ResourcePrimaryScope.ORGANIZATIONS,\n [CoreResourceType.APPLICATION_A2A_TOKEN_BUDGET_STATE]: ResourcePrimaryScope.APPLICATION,\n};\n\ninterface A2ATokenBudgetScopeExample {\n readonly scopeIdentity: Readonly<Record<string, string>>;\n /** Human-readable prose fragment for example titles, not a semantic vocabulary. */\n readonly scopeLabel: string;\n}\n\n/**\n * Owns the concrete path and response FK for each polymorphic budget contract.\n * The budget semantics are shared, but the public scope identity is not: an\n * example for one tenant type must never teach a sibling's URL parameter.\n */\nfunction createA2ATokenBudgetScopeExample(resourceType: A2ABudgetResourceType): A2ATokenBudgetScopeExample {\n switch (resourceType) {\n case CoreResourceType.USER_A2A_TOKEN_BUDGET_STATE:\n return { scopeIdentity: { userId: 'user_01JEXAMPLE' }, scopeLabel: 'user' };\n case CoreResourceType.ORGANIZATION_A2A_TOKEN_BUDGET_STATE:\n return { scopeIdentity: { organizationId: 'org_01JEXAMPLE' }, scopeLabel: 'organization' };\n case CoreResourceType.APPLICATION_A2A_TOKEN_BUDGET_STATE:\n return { scopeIdentity: { applicationId: 'app_01JEXAMPLE' }, scopeLabel: 'application' };\n default: {\n const exhaustiveResourceType: never = resourceType;\n throw new Error(`Unsupported A2A token-budget resource type: ${String(exhaustiveResourceType)}`);\n }\n }\n}\n\ntype Cfg = ReturnType<(typeof a2aTokenBudgetStatePolymorphicFactories)[CoreResourceType.USER_A2A_TOKEN_BUDGET_STATE]>;\ntype Core = Cfg['coreOperations'][number];\ntype Main = typeof A2ATokenBudgetStateSchema;\n\nfunction buildA2ATokenBudgetStateResourceSpecification(\n resourceType: A2ABudgetResourceType,\n resourceTypeMemberName: A2ABudgetResourceTypeMember,\n) {\n const exampleScope = createA2ATokenBudgetScopeExample(resourceType);\n const currentBudgetExample = {\n _id: `a2a_budget_${exampleScope.scopeLabel}_01JEXAMPLE`,\n periodKey: '2026-08',\n consumedTokens: 72_450,\n lastTurnAt: '2026-08-20T11:18:42.000Z',\n createdAt: '2026-08-02T08:15:00.000Z',\n updatedAt: '2026-08-20T11:18:42.000Z',\n ...exampleScope.scopeIdentity,\n };\n const currentBudgetSummaryExample = {\n _id: currentBudgetExample._id,\n periodKey: currentBudgetExample.periodKey,\n consumedTokens: currentBudgetExample.consumedTokens,\n lastTurnAt: currentBudgetExample.lastTurnAt,\n };\n\n return resourceSpecification<undefined, Core, Main>(\n a2aTokenBudgetStatePolymorphicFactories[resourceType],\n A2ATokenBudgetStateSchema,\n ({ schemaShape }) => ({\n purpose: 'Report how many LLM tokens this user, organization, or application has consumed through inbound A2A agent turns in the current budget period.',\n businessRole: 'Current-period A2A consumption used with the plan allowance to decide whether another agent turn may start; the allowance itself is resolved separately and is not part of this response.',\n lifecycleRole: 'Created after the first budgeted A2A turn, incremented after completed turns, and reset in place when the period changes; this resource does not retain prior-period history.',\n audience: LabelAudience.DEVELOPER,\n subDomain: EngineResourceSubDomain.FLOWS_ACTORS,\n codeHandling: {\n mainSchema: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'A2ATokenBudgetStateSchema',\n symbolKind: CodeSymbolKind.SCHEMA,\n declarationKind: CodeDeclarationKind.ZOD_SCHEMA,\n },\n resourceFactoryCollectionEntry: {\n collectionSymbol: { packageName: '@wildo-ai/saas-models', exportName: 'a2aTokenBudgetStatePolymorphicFactories', symbolKind: CodeSymbolKind.FACTORY },\n identifierField: 'collectionKey',\n identifierValue: resourceType,\n },\n resourceType: {\n enumDeclaration: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceType',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n memberName: resourceTypeMemberName,\n },\n operationVocabulary: {\n coreEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'CoreResourceOperation',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n },\n notes: [\n 'Three variants under `A2A_TOKEN_BUDGET_SCOPE_VARIANTS` — user row is `USER_SELF`; org/app rows are `ORGANIZATIONS`/`APPLICATION` (machine-owned A2A).',\n 'SINGLETON: the injected owner FK is the auto business key, so the declaration deliberately does NOT opt out of the singleton auto-business-key. NOTE the uniqueness is index-enforced on MongoDB only — the SQL planner leaves index creation to migrations, so on PostgreSQL the one-row invariant is upheld by the runtime rather than the database (see businessConstraints).',\n 'The allowance is NOT persisted here: it is resolved live from the `a2a.llm.tokensPerPeriod` LIMIT feature (`A2A_TOKEN_BUDGET_FEATURE_ID` in `@wildo-ai/saas-models`) via feature resolution for the owner scope.',\n 'Sole runtime reader/writer is `A2ATokenBudgetBackendService` (`@wildo-ai/saas-backend-lib`); CREATE and READ go through `*AsSystem` under the resource\\'s `systemAccessPolicy`, while the counter is advanced by the atomic repository-tier increment primitive (there is deliberately no UPDATE operation).',\n 'Runtime has no userNotifications / m2mNotifications — do not add communications.* (DF-1).',\n ],\n },\n\n fields: {\n _id: schemaShape._id.stringSpec({\n meaning: 'Document id of this tenant\\'s single A2A token-budget record.',\n semanticRole: 'identifier',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n\n periodKey: schemaShape.periodKey.stringSpec({\n meaning: 'Stable id of the budget WINDOW this counter currently covers — a UTC calendar month (`YYYY-MM`) in v1.',\n whyItMatters: 'It is the reset boundary: when the runtime resolves a different current period, the accumulator resets `consumedTokens` and advances this key in place, so a stale period reads as zero consumption rather than carrying spend forward.',\n semanticRole: 'identifier',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n\n consumedTokens: schemaShape.consumedTokens.numberSpec({\n meaning: 'Tokens (prompt + completion) this tenant\\'s A2A agent turns have consumed within `periodKey`.',\n whyItMatters: 'It is the single value the pre-dispatch gate compares against the plan allowance; once it reaches the allowance the transport denies further turns for the rest of the period.',\n unit: 'tokens',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n\n lastTurnAt: schemaShape.lastTurnAt.dateSpec({\n meaning: 'When the last A2A turn was recorded against this budget.',\n whyItMatters: 'Observability only — it lets an operator see whether a tenant is actively spending without reconstructing the turn log; nothing in the gate reads it.',\n temporalRole: 'occurred',\n }),\n\n createdAt: schemaShape.createdAt.dateSpec({\n meaning: 'When the tenant\\'s budget record was first opened (its first budgeted A2A turn).',\n temporalRole: 'creation',\n }),\n\n updatedAt: schemaShape.updatedAt.dateSpec({\n meaning: 'When the counter was last incremented or rolled to a new period.',\n temporalRole: 'modified',\n }),\n },\n\n operations: {\n [Op.CREATE]: {\n purpose: 'Open the tenant\\'s budget singleton on its first budgeted A2A turn.',\n outcome: 'The tenant has exactly one counter row, stamped with the current period and that first turn\\'s tokens, against which every later turn is measured.',\n responseStatuses: [\n { code: HttpResponseStatusCode.CREATED_201, meaning: 'The tenant\\'s single budget record was opened. Internal/system write path (INTERNAL_CALL, service-tier) — the A2A runtime writes on the tenant\\'s behalf via `createAsSystem`; there is no self-serve create surface.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The payload fails schema validation (e.g. a missing `periodKey` or the injected owner FK).' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'A concurrent turn already opened the tenant\\'s singleton — the injected owner FK is a unique business key, so only one racer creates. The accumulator swallows this and increments the winner\\'s row instead of surfacing the conflict to the turn.' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'A non-system caller attempts to create a budget row — the operation is INTERNAL_CALL with a super-admin floor, reachable only through the A2A runtime.' },\n ],\n idempotent: false,\n },\n\n [Op.READ]: {\n purpose: 'Read the current A2A token-consumption period, consumed-token count, and latest recorded turn for this scope.',\n outcome: 'The integration owner can monitor current-period A2A consumption without treating this state as the plan allowance or as historical usage.',\n importance: FieldSemanticImportance.PRIMARY,\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The current consumption state for this scope is returned, including its period key, consumed tokens, and latest recorded turn when available.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not allowed to inspect A2A consumption for this user, organization, or application scope.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No budgeted A2A turn has been recorded for this scope yet, or the requested scope belongs to another owner.' },\n ],\n idempotent: true,\n examples: [{\n title: `Inspect current ${exampleScope.scopeLabel} A2A consumption`,\n request: exampleScope.scopeIdentity,\n response: currentBudgetExample,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n context: {\n examples: [{\n title: `Inspect current ${exampleScope.scopeLabel} A2A consumption with context`,\n request: exampleScope.scopeIdentity,\n response: currentBudgetExample,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n summary: {\n examples: [{\n title: `Inspect the compact ${exampleScope.scopeLabel} A2A consumption summary`,\n request: exampleScope.scopeIdentity,\n response: currentBudgetSummaryExample,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n },\n\n // No UPDATE operation is declared, deliberately: advancing the counter after a turn\n // (increment, or roll the period in place) is an ATOMIC repository-tier increment, not a\n // service-tier update, precisely so concurrent turns cannot lose tokens to a\n // read-modify-write race. Documenting an UPDATE here would describe a write path that does\n // not exist and invite routing the counter through it.\n\n [Op.DELETE]: {\n purpose: 'Remove a tenant\\'s budget row — platform teardown, and the cleanup the owning user/org/app deletion cascades to.',\n outcome: 'The counter row is physically removed, so a deleted tenant leaves no orphaned enforcement state behind.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The budget record was removed. The role floor is deliberately PLATFORM-ONLY (`APP_ADMIN_SUPER_ADMIN`) — NOT the owner-read roles and NOT an org admin: deleting this record zeroes the tenant\\'s recorded consumption, which is a spend-cap bypass. Read-authority does not imply delete-authority here, because the counter is enforcement state ABOUT the tenant rather than data BELONGING to it. The same default op powers the composition onParentDelete cascade, which runs at the repository tier below role checks and is therefore unaffected by the floor.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No budget row exists for the targeted tenant (it never ran a budgeted turn, or it was already removed).' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'A caller below the platform super-admin floor — including the owning tenant\\'s own admin — attempts to delete the row and reset its recorded spend.' },\n ],\n idempotent: true,\n },\n },\n\n businessConstraints: [\n 'One row per tenant: the injected owner FK (`userId` / `organizationId` / `applicationId`) is the unique business key (database-enforced on MongoDB only — see the PostgreSQL caveat below). The period lives INSIDE the row and is rolled in place, so the resource holds current-period state only — per-period history and multi-budget-feature accounting are documented follow-ons.',\n 'The plan ALLOWANCE is never stored here. It is resolved live from the `a2a.llm.tokensPerPeriod` LIMIT feature for the owner scope, so a plan change takes effect on the next turn with no copy to reconcile. This resource is the CONSUMPTION half only.',\n 'This is internal enforcement state, not user-authored data: only the A2A runtime writes it. It CREATES the row via `*AsSystem` (INTERNAL_CALL, super-admin, under the resource\\'s `systemAccessPolicy`), then advances the counter through an ATOMIC repository-tier increment rather than an update operation — which is why no UPDATE operation is declared at all. The tenant\\'s only surface is reading its own consumption.',\n 'DELETE authority is strictly platform-level and intentionally diverges from read authority: zeroing recorded consumption would let a tenant admin reset their own spend cap at will.',\n 'The budget window is a UTC calendar month (`YYYY-MM`) in v1 — deterministic and free of a per-turn billing-account lookup on the hot path. Anchoring the window to the tenant\\'s actual subscription period is a documented follow-on, isolated to the single function that resolves the current period key.',\n 'Overage is bounded but is NOT a single turn: usage is only known AFTER a turn completes and recording is fire-and-forget, so every turn already in flight when the allowance is reached passes the gate on the same reading. The burst throttle that bounds it is per-PRINCIPAL while the budget is per-TENANT, so a tenant with many members or machine credentials can overshoot proportionally to how many act at once. Pre-charging an estimate was rejected because it would require a refund/reconcile path on every turn.',\n 'Accumulation is adapter-portable: the counter is advanced through a per-adapter atomic increment primitive (a single document update on MongoDB, a single `UPDATE … RETURNING` on PostgreSQL) rather than raw MongoDB operators, so a concurrent increment cannot be lost to a read-modify-write race on either backend. Both arms are covered by real-database integration tests, including the concurrent compare-and-set on a REAL PostgreSQL: a racing writer holds the row lock while a guarded reset blocks on it, and on resuming the reset correctly matches nothing rather than overwriting the racer\\'s accumulated total. The in-memory SQL engine also used in tests models neither MVCC nor the row-lock recheck, so it covers SQL shape and sequential semantics only — the concurrency proof comes from the real-engine suite.',\n 'Exactly one row per tenant is declared through the injected owner foreign key, but the unique index is emitted only by the MongoDB adapter — the SQL planner leaves index creation to migrations. On PostgreSQL the invariant is therefore NOT database-enforced today: the runtime repairs the common race (a rejected create falls through to an increment), but two truly simultaneous first-ever turns can leave two rows, splitting consumption and under-reporting spend until a unique constraint on the owner foreign key is added to the migration.',\n 'A budget row is owned by exactly ONE scope; the polymorphic owner FK is injected on each concrete variant schema, not on `A2ATokenBudgetStateSchema` itself, and the owner primary-scope filter must never expose another tenant\\'s counter.',\n ],\n }),\n // The owner is the injected scope FK, anchored by the `<SCOPE> → *A2aTokenBudgetState`\n // primary-scope COMPOSITION edge in `resources-registry.shared.core.definitions.ts`\n // (generated by `createPolymorphicScopeRelationships` with `childCardinality: ONE`).\n // The registry factory derives the scope from `isPrimaryScope: true`; this declaration\n // feeds the spec ↔ registry alignment guard and must match per variant.\n { resourcePrimaryScope: a2aBudgetPrimaryScopeByResourceType[resourceType] },\n );\n}\n\nexport const userA2aTokenBudgetStateResourceSpecification = buildA2ATokenBudgetStateResourceSpecification(\n CoreResourceType.USER_A2A_TOKEN_BUDGET_STATE,\n 'USER_A2A_TOKEN_BUDGET_STATE',\n);\n\nexport const organizationA2aTokenBudgetStateResourceSpecification = buildA2ATokenBudgetStateResourceSpecification(\n CoreResourceType.ORGANIZATION_A2A_TOKEN_BUDGET_STATE,\n 'ORGANIZATION_A2A_TOKEN_BUDGET_STATE',\n);\n\nexport const applicationA2aTokenBudgetStateResourceSpecification = buildA2ATokenBudgetStateResourceSpecification(\n CoreResourceType.APPLICATION_A2A_TOKEN_BUDGET_STATE,\n 'APPLICATION_A2A_TOKEN_BUDGET_STATE',\n);\n"]}
|
package/dist/esm/engine/flows-actors/resources/agent-work-decisions.resource.specification.d.ts
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { type AnyResourceSpecificationConfig } from '../../../_core';
|
|
2
|
+
export declare const userAgentWorkDecisionsResourceSpecification: AnyResourceSpecificationConfig;
|
|
3
|
+
export declare const organizationAgentWorkDecisionsResourceSpecification: AnyResourceSpecificationConfig;
|
|
4
|
+
export declare const applicationAgentWorkDecisionsResourceSpecification: AnyResourceSpecificationConfig;
|
|
5
|
+
export declare const userAgentWorkDecisionContentsResourceSpecification: AnyResourceSpecificationConfig;
|
|
6
|
+
export declare const organizationAgentWorkDecisionContentsResourceSpecification: AnyResourceSpecificationConfig;
|
|
7
|
+
export declare const applicationAgentWorkDecisionContentsResourceSpecification: AnyResourceSpecificationConfig;
|
|
8
|
+
export declare const agentWorkCaptureSettingsResourceSpecification: AnyResourceSpecificationConfig;
|
|
9
|
+
export declare const evaluationExportAuthorizationsResourceSpecification: AnyResourceSpecificationConfig;
|
|
10
|
+
export declare const evaluationDatasetExportsResourceSpecification: AnyResourceSpecificationConfig;
|
|
11
|
+
//# sourceMappingURL=agent-work-decisions.resource.specification.d.ts.map
|
package/dist/esm/engine/flows-actors/resources/agent-work-decisions.resource.specification.d.ts.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agent-work-decisions.resource.specification.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/flows-actors/resources/agent-work-decisions.resource.specification.ts"],"names":[],"mappings":"AAqCA,OAAO,EAAE,KAAK,8BAA8B,EAAiD,MAAM,6BAA6B,CAAC;AAwNjI,eAAO,MAAM,2CAA2C,gCAAuG,CAAC;AAChK,eAAO,MAAM,mDAAmD,gCAAuH,CAAC;AACxL,eAAO,MAAM,kDAAkD,gCAAqH,CAAC;AACrL,eAAO,MAAM,kDAAkD,gCAAsH,CAAC;AACtL,eAAO,MAAM,0DAA0D,gCAAsI,CAAC;AAC9M,eAAO,MAAM,yDAAyD,gCAAoI,CAAC;AAE3M,eAAO,MAAM,6CAA6C,EAAE,8BAoD3D,CAAC;AAEF,eAAO,MAAM,mDAAmD,EAAE,8BAkEjE,CAAC;AAEF,eAAO,MAAM,6CAA6C,EAAE,8BA2D3D,CAAC"}
|
|
@@ -0,0 +1,382 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Resources of #1599 — experts' decisions on agents' proposals. Wildo SaaS engine specifications.
|
|
3
|
+
*
|
|
4
|
+
* - `agentWorkDecisions` (polymorphic: user / organization / application) — the metadata record, always written.
|
|
5
|
+
* - `agentWorkDecisionContents` (polymorphic) — the proposal, the final version and the diff, under the opt-in.
|
|
6
|
+
* - `agentWorkCaptureSettings` — one organization's content-capture choice.
|
|
7
|
+
* - `evaluationExportAuthorizations` — one organization's recorded basis to export evaluation data.
|
|
8
|
+
* - `evaluationDatasetExports` — the export ledger.
|
|
9
|
+
*
|
|
10
|
+
* Writers: `AgentWorkDecisionsBackendService` (saas-backend-lib) — the settle that won a decision, the repair sweep,
|
|
11
|
+
* `recordOutputReview`, the export. Settings and authorisations are written by the organization's administrator and
|
|
12
|
+
* audited by `agent-work-decisions.custom-impl.backend.service.ts`.
|
|
13
|
+
*/
|
|
14
|
+
import { LabelAudience } from '@wildo-ai/presets-components-models';
|
|
15
|
+
import { CodeDeclarationKind, CodeSymbolKind, FieldSemanticImportance } from '@wildo-ai/zod-decorators';
|
|
16
|
+
import { AgentWorkCaptureSettingsSchema, AgentWorkDecisionBaseSchema, AgentWorkDecisionContentBaseSchema, AgentWorkDecisionRecordSource, AgentWorkDecisionSurface, CoreResourceOperation as Op, CoreResourceType, CorrectionContentCapture, EvaluationDatasetExportSchema, EvaluationDatasetInvalidationReason, EvaluationExportAuthorizationSchema, EvaluationExportAuthorizationStatus, EvaluationExportBasis, HumanDecision_Outcome, ResourcePrimaryScope, agentWorkCaptureSettingsResourceConfiguration_InitializationFactory, agentWorkDecisionContentsPolymorphicFactories, agentWorkDecisionsPolymorphicFactories, evaluationDatasetExportsResourceConfiguration_InitializationFactory, evaluationExportAuthorizationsResourceConfiguration_InitializationFactory, } from '@wildo-ai/saas-models';
|
|
17
|
+
import { HttpResponseStatusCode, resourceSpecification } from '../../../_core/index.js';
|
|
18
|
+
import { EngineResourceSubDomain } from '../../engine-resource-sub-domain.js';
|
|
19
|
+
const enumDeclaration = (exportName) => ({
|
|
20
|
+
packageName: '@wildo-ai/saas-models',
|
|
21
|
+
exportName,
|
|
22
|
+
symbolKind: CodeSymbolKind.ENUM,
|
|
23
|
+
declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,
|
|
24
|
+
});
|
|
25
|
+
const schemaDeclaration = (exportName) => ({
|
|
26
|
+
packageName: '@wildo-ai/saas-models', exportName, symbolKind: CodeSymbolKind.SCHEMA, declarationKind: CodeDeclarationKind.ZOD_SCHEMA,
|
|
27
|
+
});
|
|
28
|
+
const factoryDeclaration = (exportName) => ({
|
|
29
|
+
packageName: '@wildo-ai/saas-models', exportName, symbolKind: CodeSymbolKind.FACTORY, declarationKind: CodeDeclarationKind.FUNCTION,
|
|
30
|
+
});
|
|
31
|
+
const OUTCOME_VALUES = {
|
|
32
|
+
[HumanDecision_Outcome.ACCEPTED]: { meaning: 'Accepted as proposed.' },
|
|
33
|
+
[HumanDecision_Outcome.ACCEPTED_WITH_MODIFICATIONS]: { meaning: 'Accepted after the expert changed it. Counts as an override.' },
|
|
34
|
+
[HumanDecision_Outcome.REJECTED]: { meaning: 'Declined. Counts as an override.' },
|
|
35
|
+
[HumanDecision_Outcome.LAPSED]: { meaning: 'Nobody answered in time. Not a decision anyone made: never in the override rate.' },
|
|
36
|
+
[HumanDecision_Outcome.WITHDRAWN]: { meaning: 'The work was cancelled before anyone answered. Never in the override rate.' },
|
|
37
|
+
[HumanDecision_Outcome.REQUESTER_AUTHORITY_LAPSED]: { meaning: 'Answered, but the work did not run: its requester lost their access. Never in the override rate.' },
|
|
38
|
+
};
|
|
39
|
+
const SCOPE_OF = {
|
|
40
|
+
[CoreResourceType.USER_AGENT_WORK_DECISIONS]: ResourcePrimaryScope.USER_SELF,
|
|
41
|
+
[CoreResourceType.ORGANIZATION_AGENT_WORK_DECISIONS]: ResourcePrimaryScope.ORGANIZATIONS,
|
|
42
|
+
[CoreResourceType.APPLICATION_AGENT_WORK_DECISIONS]: ResourcePrimaryScope.APPLICATION,
|
|
43
|
+
[CoreResourceType.USER_AGENT_WORK_DECISION_CONTENTS]: ResourcePrimaryScope.USER_SELF,
|
|
44
|
+
[CoreResourceType.ORGANIZATION_AGENT_WORK_DECISION_CONTENTS]: ResourcePrimaryScope.ORGANIZATIONS,
|
|
45
|
+
[CoreResourceType.APPLICATION_AGENT_WORK_DECISION_CONTENTS]: ResourcePrimaryScope.APPLICATION,
|
|
46
|
+
};
|
|
47
|
+
function buildDecisionsSpecification(resourceType, memberName) {
|
|
48
|
+
return resourceSpecification(agentWorkDecisionsPolymorphicFactories[resourceType], AgentWorkDecisionBaseSchema, ({ schemaShape }) => ({
|
|
49
|
+
purpose: 'Record one decision a person took on something an agent proposed: accepted, changed or rejected, by whom, when, and how much was changed.',
|
|
50
|
+
businessRole: 'The evidence that agent work was supervised, and the data behind the override rate a service firm tracks per agent, tool, case and expert. Metadata only: what changed, never what it changed to.',
|
|
51
|
+
lifecycleRole: 'Written once, by the settle that won the decision (or by the repair sweep after a crash), in the scope of the work the decision paused. Kept for the declared AUDIT_LOGS period; an erasure removes the decider and keeps the decision.',
|
|
52
|
+
audience: LabelAudience.DEVELOPER,
|
|
53
|
+
subDomain: EngineResourceSubDomain.FLOWS_ACTORS,
|
|
54
|
+
codeHandling: {
|
|
55
|
+
mainSchema: schemaDeclaration('AgentWorkDecisionBaseSchema'),
|
|
56
|
+
resourceFactoryCollectionEntry: {
|
|
57
|
+
collectionSymbol: { packageName: '@wildo-ai/saas-models', exportName: 'agentWorkDecisionsPolymorphicFactories', symbolKind: CodeSymbolKind.FACTORY },
|
|
58
|
+
identifierField: 'collectionKey',
|
|
59
|
+
identifierValue: resourceType,
|
|
60
|
+
},
|
|
61
|
+
resourceType: { enumDeclaration: enumDeclaration('CoreResourceType'), memberName },
|
|
62
|
+
operationVocabulary: { coreEnum: enumDeclaration('CoreResourceOperation') },
|
|
63
|
+
notes: [
|
|
64
|
+
'Three variants, one per owner scope of the paused work: a user\'s own thread, an organization\'s machine turn, the application\'s. An output review is recorded in its case\'s organization.',
|
|
65
|
+
'`decisionRef` is unique in every store, so the settle, the repair sweep and a retried output review converge on one record. On the actor plane the key is the decision id AND its suspension, because a host reuses its run id across questions.',
|
|
66
|
+
'Retention: `retentionBinding: { AUDIT_LOGS, CREATED }`, `retentionPolicy: RETAIN_AND_IMPERSONALIZE` (the decider is removed on erasure), `dataSubjectPolicy: NO_PRINCIPAL`. Writes are INTERNAL_CALL only; READ and LIST are the scope owner\'s (the user, the organization\'s administrator, the application super-administrator).',
|
|
67
|
+
'The override rate is served by `POST /agent-work/override-rate`, computed from these rows only.',
|
|
68
|
+
],
|
|
69
|
+
},
|
|
70
|
+
fields: {
|
|
71
|
+
_id: schemaShape._id.stringSpec({ meaning: 'Identity of the record.', semanticRole: 'identifier' }),
|
|
72
|
+
decisionRef: schemaShape.decisionRef.stringSpec({
|
|
73
|
+
meaning: 'The decision this records: the human decision\'s id, or the id the application gave an output review.',
|
|
74
|
+
whyItMatters: 'Unique, so a decision is recorded at most once however many writers reach it.',
|
|
75
|
+
semanticRole: 'identifier', importance: FieldSemanticImportance.PRIMARY,
|
|
76
|
+
}),
|
|
77
|
+
surface: schemaShape.surface.enumSpec({
|
|
78
|
+
meaning: 'Where the decision was taken.',
|
|
79
|
+
enumDeclaration: enumDeclaration('AgentWorkDecisionSurface'),
|
|
80
|
+
values: {
|
|
81
|
+
[AgentWorkDecisionSurface.TOOL_CALL_APPROVAL]: { meaning: 'A person approved, edited or denied a tool call the agent proposed.' },
|
|
82
|
+
[AgentWorkDecisionSurface.ACTOR_REVIEW]: { meaning: 'A person answered an actor-system question that asked them to review its work.' },
|
|
83
|
+
[AgentWorkDecisionSurface.OUTPUT_REVIEW]: { meaning: 'A person reviewed output an agent drafted into the application\'s own rows.' },
|
|
84
|
+
},
|
|
85
|
+
}),
|
|
86
|
+
outcome: schemaShape.outcome.enumSpec({
|
|
87
|
+
meaning: 'How the decision ended.', importance: FieldSemanticImportance.PRIMARY,
|
|
88
|
+
enumDeclaration: enumDeclaration('HumanDecision_Outcome'), values: OUTCOME_VALUES,
|
|
89
|
+
}),
|
|
90
|
+
workOrganizationId: schemaShape.workOrganizationId.stringSpec({
|
|
91
|
+
meaning: 'The organization the work was done for: the case row\'s organization, else the organization the decision was routed in.',
|
|
92
|
+
whyItMatters: 'The override rate and the evaluation export are per organization, whichever scope owned the thread.',
|
|
93
|
+
semanticRole: 'identifier',
|
|
94
|
+
}),
|
|
95
|
+
agentRef: schemaShape.agentRef.stringSpec({ meaning: 'The actor system or agent whose proposal was decided.', semanticRole: 'identifier', importance: FieldSemanticImportance.PRIMARY }),
|
|
96
|
+
agentVersion: schemaShape.agentVersion.stringSpec({ meaning: 'The agent\'s declared version, when it has one.' }),
|
|
97
|
+
toolName: schemaShape.toolName.stringSpec({ meaning: 'The tool whose call was decided, on a tool approval.', semanticRole: 'identifier' }),
|
|
98
|
+
caseRef: schemaShape.caseRef.objectSpec({ meaning: 'The case the work was for: a row of a resource the application declares a unit of work.' }),
|
|
99
|
+
executionRef: schemaShape.executionRef.objectSpec({ meaning: 'The run the decision paused.' }),
|
|
100
|
+
taskRef: schemaShape.taskRef.stringSpec({ meaning: 'The task within the run, when the host names one.', semanticRole: 'identifier' }),
|
|
101
|
+
finalWorkProductRef: schemaShape.finalWorkProductRef.objectSpec({
|
|
102
|
+
meaning: 'The application row the final version lives in.',
|
|
103
|
+
whyItMatters: 'The record points at the work product instead of copying it, so the row\'s own erasure and retention apply to it.',
|
|
104
|
+
}),
|
|
105
|
+
modifiedPaths: schemaShape.modifiedPaths.arraySpec({
|
|
106
|
+
meaning: 'What the expert changed: the paths of the proposal that differ in the final version (a top-level field reads as its name).',
|
|
107
|
+
elementMeaning: 'One changed path.',
|
|
108
|
+
}),
|
|
109
|
+
editDistance: schemaShape.editDistance.numberSpec({ meaning: 'How much was changed: the edit distance between the canonical proposal and the final version, when both are known.' }),
|
|
110
|
+
proposedDigest: schemaShape.proposedDigest.stringSpec({
|
|
111
|
+
meaning: 'A digest of the proposal, keyed per organization.',
|
|
112
|
+
whyItMatters: 'Keyed, never a bare hash: a bare hash of a short value is reversed by trying the candidates.',
|
|
113
|
+
}),
|
|
114
|
+
finalDigest: schemaShape.finalDigest.stringSpec({ meaning: 'A digest of the final version under the same key. Equal to the proposal\'s when it was accepted as proposed.' }),
|
|
115
|
+
reasonCode: schemaShape.reasonCode.stringSpec({ meaning: 'Why the expert changed or rejected it: a code from the application\'s declared list, chosen on the approval card while correcting the proposal. Never free text; its words live under `system_enums.AgentWorkReasonCode.<code>`.', semanticRole: 'code' }),
|
|
116
|
+
deciderUserId: schemaShape.deciderUserId.stringSpec({ meaning: 'The person who decided. Removed on their erasure; the decision stays.', semanticRole: 'identifier' }),
|
|
117
|
+
admittedByRole: schemaShape.admittedByRole.stringSpec({ meaning: 'The route role that admitted the decider, when a role route admitted them.' }),
|
|
118
|
+
presentedAt: schemaShape.presentedAt.dateSpec({
|
|
119
|
+
meaning: 'When the proposal was put before the decider: when the decision was claimed, else when it was asked.',
|
|
120
|
+
whyItMatters: 'Minus the decision instant, a proxy for the expert\'s review time, joined into the cost of a case.',
|
|
121
|
+
temporalRole: 'occurred',
|
|
122
|
+
}),
|
|
123
|
+
decidedAt: schemaShape.decidedAt.dateSpec({ meaning: 'When the decision was taken.', temporalRole: 'occurred', importance: FieldSemanticImportance.PRIMARY }),
|
|
124
|
+
recordSource: schemaShape.recordSource.enumSpec({
|
|
125
|
+
meaning: 'How the record was written.',
|
|
126
|
+
enumDeclaration: enumDeclaration('AgentWorkDecisionRecordSource'),
|
|
127
|
+
values: {
|
|
128
|
+
[AgentWorkDecisionRecordSource.SETTLEMENT]: { meaning: 'By the settle that won the decision.' },
|
|
129
|
+
[AgentWorkDecisionRecordSource.ROW_REPAIR]: { meaning: 'By the repair sweep after a crash, from the run\'s resolution columns. Metadata only.' },
|
|
130
|
+
},
|
|
131
|
+
}),
|
|
132
|
+
contentRecorded: schemaShape.contentRecorded.booleanSpec({ meaning: 'Whether the proposal and the final version were kept beside this record, under the organization\'s opt-in.' }),
|
|
133
|
+
createdAt: schemaShape.createdAt.dateSpec({ meaning: 'When the record was written.', temporalRole: 'creation' }),
|
|
134
|
+
},
|
|
135
|
+
operations: {
|
|
136
|
+
[Op.CREATE]: { purpose: 'Write one decision record. Written only by the engine.', outcome: 'The decision is recorded.', responseStatuses: [{ code: HttpResponseStatusCode.CREATED_201, meaning: 'Internal write path.' }] },
|
|
137
|
+
[Op.READ]: {
|
|
138
|
+
purpose: 'Read one decision record in its scope.', outcome: 'The record is returned.', idempotent: true,
|
|
139
|
+
responseStatuses: [{ code: HttpResponseStatusCode.OK_200, meaning: 'The record was found.' }],
|
|
140
|
+
errorScenarios: [{ code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not the scope\'s owner or administrator.' }],
|
|
141
|
+
},
|
|
142
|
+
[Op.LIST]: {
|
|
143
|
+
purpose: 'List the decisions recorded in a scope, by agent, tool, case, outcome or instant.', outcome: 'The matching records are returned.', idempotent: true,
|
|
144
|
+
responseStatuses: [{ code: HttpResponseStatusCode.OK_200, meaning: 'A possibly empty page of records.' }],
|
|
145
|
+
errorScenarios: [{ code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not the scope\'s owner or administrator.' }],
|
|
146
|
+
},
|
|
147
|
+
[Op.UPDATE_MANY]: { purpose: 'The erasure writer\'s door the retention policy requires: removes the decider. Route-less.', outcome: 'The decider is removed; the decision stays.', idempotent: true },
|
|
148
|
+
[Op.DELETE]: { purpose: 'The retention sweep\'s and the scope-deletion cascade\'s door. Route-less.', outcome: 'A record past its AUDIT_LOGS period, or of a deleted scope, is removed.', idempotent: true },
|
|
149
|
+
},
|
|
150
|
+
businessConstraints: [
|
|
151
|
+
'One record per decision.',
|
|
152
|
+
'Written only by the settle that won the decision, never by one that lost it.',
|
|
153
|
+
'Never holds content: what changed, not what it changed to.',
|
|
154
|
+
'Lapsed, withdrawn and authority-lapsed decisions are recorded and never counted in the override rate.',
|
|
155
|
+
],
|
|
156
|
+
}), { resourcePrimaryScope: SCOPE_OF[resourceType] });
|
|
157
|
+
}
|
|
158
|
+
function buildContentsSpecification(resourceType, memberName) {
|
|
159
|
+
return resourceSpecification(agentWorkDecisionContentsPolymorphicFactories[resourceType], AgentWorkDecisionContentBaseSchema, ({ schemaShape }) => ({
|
|
160
|
+
purpose: 'Keep what an agent proposed and what the expert kept, beside the decision record, when the organization chose to keep it.',
|
|
161
|
+
businessRole: 'The raw material of evaluation data: an organization that improves its own agents on its experts\' corrections keeps it, with a stated purpose; everyone else never stores it.',
|
|
162
|
+
lifecycleRole: 'Written with the decision record, only under the organization\'s WITH_CONTENT opt-in. Scrubbed when the case it is about is erased or deleted; the decision record survives.',
|
|
163
|
+
audience: LabelAudience.DEVELOPER,
|
|
164
|
+
subDomain: EngineResourceSubDomain.FLOWS_ACTORS,
|
|
165
|
+
codeHandling: {
|
|
166
|
+
mainSchema: schemaDeclaration('AgentWorkDecisionContentBaseSchema'),
|
|
167
|
+
resourceFactoryCollectionEntry: {
|
|
168
|
+
collectionSymbol: { packageName: '@wildo-ai/saas-models', exportName: 'agentWorkDecisionContentsPolymorphicFactories', symbolKind: CodeSymbolKind.FACTORY },
|
|
169
|
+
identifierField: 'collectionKey',
|
|
170
|
+
identifierValue: resourceType,
|
|
171
|
+
},
|
|
172
|
+
resourceType: { enumDeclaration: enumDeclaration('CoreResourceType'), memberName },
|
|
173
|
+
operationVocabulary: { coreEnum: enumDeclaration('CoreResourceOperation') },
|
|
174
|
+
notes: [
|
|
175
|
+
'Read by the scope\'s administrator; in an organization also by the role its capture setting names (`contentReaderRole`), enforced by a read gate on READ and LIST.',
|
|
176
|
+
'Every content field is personal data (USER_CONTENT) removed on erasure; `retentionPolicy: RETAIN_AND_IMPERSONALIZE`. Deleted with its owner scope by the composition cascade.',
|
|
177
|
+
],
|
|
178
|
+
},
|
|
179
|
+
fields: {
|
|
180
|
+
_id: schemaShape._id.stringSpec({ meaning: 'Identity of the content row.', semanticRole: 'identifier' }),
|
|
181
|
+
decisionRef: schemaShape.decisionRef.stringSpec({ meaning: 'The decision record this content belongs to.', semanticRole: 'identifier', importance: FieldSemanticImportance.PRIMARY }),
|
|
182
|
+
caseRef: schemaShape.caseRef.objectSpec({ meaning: 'The case the content is about; its erasure scrubs this content.' }),
|
|
183
|
+
workOrganizationId: schemaShape.workOrganizationId.stringSpec({ meaning: 'The organization the work was done for.', semanticRole: 'identifier' }),
|
|
184
|
+
proposalJson: schemaShape.proposalJson.stringSpec({ meaning: 'What the agent proposed, as canonical JSON.' }),
|
|
185
|
+
finalJson: schemaShape.finalJson.stringSpec({ meaning: 'What the expert kept, as canonical JSON.' }),
|
|
186
|
+
diffJson: schemaShape.diffJson.stringSpec({ meaning: 'The JSON Patch (RFC 6902) from the proposal to the final version.' }),
|
|
187
|
+
reasonText: schemaShape.reasonText.stringSpec({ meaning: 'The expert\'s own words about the decision, when they gave any.' }),
|
|
188
|
+
createdAt: schemaShape.createdAt.dateSpec({ meaning: 'When the content was written.', temporalRole: 'creation' }),
|
|
189
|
+
},
|
|
190
|
+
operations: {
|
|
191
|
+
[Op.CREATE]: { purpose: 'Write one decision\'s content. Written only by the engine, under the opt-in.', outcome: 'The content is kept.', responseStatuses: [{ code: HttpResponseStatusCode.CREATED_201, meaning: 'Internal write path.' }] },
|
|
192
|
+
[Op.READ]: {
|
|
193
|
+
purpose: 'Read one decision\'s content.', outcome: 'The content is returned.', idempotent: true,
|
|
194
|
+
responseStatuses: [{ code: HttpResponseStatusCode.OK_200, meaning: 'The content was found.' }],
|
|
195
|
+
errorScenarios: [{ code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is neither the scope\'s administrator nor holds the organization\'s reader role.' }],
|
|
196
|
+
},
|
|
197
|
+
[Op.LIST]: {
|
|
198
|
+
purpose: 'List the content kept in a scope.', outcome: 'The content rows are returned.', idempotent: true,
|
|
199
|
+
responseStatuses: [{ code: HttpResponseStatusCode.OK_200, meaning: 'A possibly empty page of content rows.' }],
|
|
200
|
+
errorScenarios: [{ code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is neither the scope\'s administrator nor holds the organization\'s reader role.' }],
|
|
201
|
+
},
|
|
202
|
+
[Op.UPDATE_MANY]: { purpose: 'The erasure writer\'s door: scrubs the content. Route-less.', outcome: 'The content is removed; the row marks that it was.', idempotent: true },
|
|
203
|
+
[Op.DELETE]: { purpose: 'The scope-deletion cascade\'s door. Route-less.', outcome: 'The content of a deleted scope is removed.', idempotent: true },
|
|
204
|
+
},
|
|
205
|
+
businessConstraints: [
|
|
206
|
+
'Written only when the organization keeps content, and only for the cases it narrowed to, if any.',
|
|
207
|
+
'Never exported without the organization\'s recorded authorisation.',
|
|
208
|
+
],
|
|
209
|
+
}), { resourcePrimaryScope: SCOPE_OF[resourceType] });
|
|
210
|
+
}
|
|
211
|
+
export const userAgentWorkDecisionsResourceSpecification = buildDecisionsSpecification(CoreResourceType.USER_AGENT_WORK_DECISIONS, 'USER_AGENT_WORK_DECISIONS');
|
|
212
|
+
export const organizationAgentWorkDecisionsResourceSpecification = buildDecisionsSpecification(CoreResourceType.ORGANIZATION_AGENT_WORK_DECISIONS, 'ORGANIZATION_AGENT_WORK_DECISIONS');
|
|
213
|
+
export const applicationAgentWorkDecisionsResourceSpecification = buildDecisionsSpecification(CoreResourceType.APPLICATION_AGENT_WORK_DECISIONS, 'APPLICATION_AGENT_WORK_DECISIONS');
|
|
214
|
+
export const userAgentWorkDecisionContentsResourceSpecification = buildContentsSpecification(CoreResourceType.USER_AGENT_WORK_DECISION_CONTENTS, 'USER_AGENT_WORK_DECISION_CONTENTS');
|
|
215
|
+
export const organizationAgentWorkDecisionContentsResourceSpecification = buildContentsSpecification(CoreResourceType.ORGANIZATION_AGENT_WORK_DECISION_CONTENTS, 'ORGANIZATION_AGENT_WORK_DECISION_CONTENTS');
|
|
216
|
+
export const applicationAgentWorkDecisionContentsResourceSpecification = buildContentsSpecification(CoreResourceType.APPLICATION_AGENT_WORK_DECISION_CONTENTS, 'APPLICATION_AGENT_WORK_DECISION_CONTENTS');
|
|
217
|
+
export const agentWorkCaptureSettingsResourceSpecification = resourceSpecification(agentWorkCaptureSettingsResourceConfiguration_InitializationFactory, AgentWorkCaptureSettingsSchema, ({ schemaShape }) => ({
|
|
218
|
+
purpose: 'Hold one organization\'s choice to keep the content of its experts\' corrections to agent work, and why.',
|
|
219
|
+
businessRole: 'Content capture is off unless the organization turns it on with a stated purpose: its clients\' material stays out of the record by default.',
|
|
220
|
+
lifecycleRole: 'Created METADATA_ONLY by the engine the first time its settings page is read (the default, not a decision, so not audited), then changed by the organization\'s administrator; every change is on the audit trail. No row means metadata only.',
|
|
221
|
+
audience: LabelAudience.DEVELOPER,
|
|
222
|
+
subDomain: EngineResourceSubDomain.FLOWS_ACTORS,
|
|
223
|
+
codeHandling: {
|
|
224
|
+
mainSchema: schemaDeclaration('AgentWorkCaptureSettingsSchema'),
|
|
225
|
+
resourceFactory: factoryDeclaration('agentWorkCaptureSettingsResourceConfiguration_InitializationFactory'),
|
|
226
|
+
resourceType: { enumDeclaration: enumDeclaration('CoreResourceType'), memberName: 'AGENT_WORK_CAPTURE_SETTINGS' },
|
|
227
|
+
operationVocabulary: { coreEnum: enumDeclaration('CoreResourceOperation') },
|
|
228
|
+
notes: ['One per organization (`organizationId` unique). `WITH_CONTENT` without a purpose is refused. Every CREATE and UPDATE emits CORRECTION_CAPTURE_SETTING_CHANGED after it commits.', 'Its READ is the settings page, and creates the METADATA_ONLY row through a route-less INTERNAL_CALL CREATE when the organization has none; that write passes neither the purpose guard nor the audit, because it records the default.'],
|
|
229
|
+
},
|
|
230
|
+
fields: {
|
|
231
|
+
_id: schemaShape._id.stringSpec({ meaning: 'Identity of the setting.', semanticRole: 'identifier' }),
|
|
232
|
+
organizationId: schemaShape.organizationId.foreignKeySpec({ meaning: 'The organization the setting is for.', importance: FieldSemanticImportance.PRIMARY }),
|
|
233
|
+
contentCapture: schemaShape.contentCapture.enumSpec({
|
|
234
|
+
meaning: 'Whether the proposal and the final version of each correction are kept.', importance: FieldSemanticImportance.PRIMARY,
|
|
235
|
+
enumDeclaration: enumDeclaration('CorrectionContentCapture'),
|
|
236
|
+
values: {
|
|
237
|
+
[CorrectionContentCapture.METADATA_ONLY]: { meaning: 'Only what changed is recorded, never what it changed to. The default.' },
|
|
238
|
+
[CorrectionContentCapture.WITH_CONTENT]: { meaning: 'The proposal, the final version and the diff are kept beside each record. Needs a purpose.' },
|
|
239
|
+
},
|
|
240
|
+
}),
|
|
241
|
+
purpose: schemaShape.purpose.stringSpec({ meaning: 'Why the organization keeps the content. Required to turn capture on.' }),
|
|
242
|
+
contentReaderRole: schemaShape.contentReaderRole.stringSpec({
|
|
243
|
+
meaning: 'The organization role that may read kept content, beside the administrator: one key of the organization role table (core or custom organization role). Picked from that table on the form and shown as the role\'s word, never typed (#1921).',
|
|
244
|
+
}),
|
|
245
|
+
narrowToCaseRefs: schemaShape.narrowToCaseRefs.arraySpec({ meaning: 'Keep content only for these cases; empty means every case.', elementMeaning: 'One case.' }),
|
|
246
|
+
createdAt: schemaShape.createdAt.dateSpec({ meaning: 'When the setting was created.', temporalRole: 'creation' }),
|
|
247
|
+
updatedAt: schemaShape.updatedAt.dateSpec({ meaning: 'When the setting was last changed.', temporalRole: 'modified' }),
|
|
248
|
+
},
|
|
249
|
+
operations: {
|
|
250
|
+
[Op.READ]: { purpose: 'Read the organization\'s setting: its settings page.', outcome: 'The setting is returned; an organization with none gets its METADATA_ONLY row, created on this read.', idempotent: true, responseStatuses: [{ code: HttpResponseStatusCode.OK_200, meaning: 'The setting was found or created in its default state.' }] },
|
|
251
|
+
[Op.CREATE]: {
|
|
252
|
+
purpose: 'Record the organization\'s content-capture choice.', outcome: 'The choice is recorded and audited.',
|
|
253
|
+
responseStatuses: [{ code: HttpResponseStatusCode.CREATED_201, meaning: 'The setting was created.' }],
|
|
254
|
+
errorScenarios: [{ code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'Content capture is turned on with no stated purpose.' }],
|
|
255
|
+
},
|
|
256
|
+
[Op.UPDATE]: {
|
|
257
|
+
purpose: 'Change the organization\'s content-capture choice.', outcome: 'The new choice applies to decisions from now on, and the change is audited.',
|
|
258
|
+
responseStatuses: [{ code: HttpResponseStatusCode.OK_200, meaning: 'The setting was changed.' }],
|
|
259
|
+
errorScenarios: [{ code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'Content capture is left on with no stated purpose.' }],
|
|
260
|
+
},
|
|
261
|
+
[Op.DELETE]: { purpose: 'The organization-deletion cascade\'s door. Route-less.', outcome: 'The setting of a deleted organization is removed.', idempotent: true },
|
|
262
|
+
},
|
|
263
|
+
businessConstraints: ['One setting per organization.', 'Content capture needs a stated purpose.', 'Every change is audited.'],
|
|
264
|
+
}), { resourcePrimaryScope: ResourcePrimaryScope.ORGANIZATIONS });
|
|
265
|
+
export const evaluationExportAuthorizationsResourceSpecification = resourceSpecification(evaluationExportAuthorizationsResourceConfiguration_InitializationFactory, EvaluationExportAuthorizationSchema, ({ schemaShape }) => ({
|
|
266
|
+
purpose: 'Hold one organization\'s recorded basis for exporting its experts\' corrections as evaluation data.',
|
|
267
|
+
businessRole: 'Improving a firm\'s own agents on its clients\' work is a purpose of its own: an export needs a documented instruction or a compatibility assessment, and a privileged case its client\'s consent.',
|
|
268
|
+
lifecycleRole: 'Created NOT_GRANTED by the engine the first time its page is read (not a decision, so not audited); granted, changed and revoked by the organization\'s administrator, every change audited. Revoking it stops every export at once.',
|
|
269
|
+
audience: LabelAudience.DEVELOPER,
|
|
270
|
+
subDomain: EngineResourceSubDomain.FLOWS_ACTORS,
|
|
271
|
+
codeHandling: {
|
|
272
|
+
mainSchema: schemaDeclaration('EvaluationExportAuthorizationSchema'),
|
|
273
|
+
resourceFactory: factoryDeclaration('evaluationExportAuthorizationsResourceConfiguration_InitializationFactory'),
|
|
274
|
+
resourceType: { enumDeclaration: enumDeclaration('CoreResourceType'), memberName: 'EVALUATION_EXPORT_AUTHORIZATIONS' },
|
|
275
|
+
operationVocabulary: { coreEnum: enumDeclaration('CoreResourceOperation') },
|
|
276
|
+
notes: ['One per organization. Every CREATE and UPDATE emits EVALUATION_EXPORT_AUTHORIZATION_CHANGED after it commits. An export with no ACTIVE authorisation is refused and emits EVALUATION_DATASET_EXPORT_REFUSED.', 'A write leaving it ACTIVE (the CREATE default) without `basis` and `basisReference` is refused, and so is one returning a granted row to NOT_GRANTED: withdrawing is REVOKED, which marks the datasets exported under it.', 'Its READ is the page, and creates the NOT_GRANTED row through a route-less INTERNAL_CALL CREATE when the organization has none.'],
|
|
277
|
+
},
|
|
278
|
+
fields: {
|
|
279
|
+
_id: schemaShape._id.stringSpec({ meaning: 'Identity of the authorisation.', semanticRole: 'identifier' }),
|
|
280
|
+
organizationId: schemaShape.organizationId.foreignKeySpec({ meaning: 'The organization whose data it authorises exporting.', importance: FieldSemanticImportance.PRIMARY }),
|
|
281
|
+
status: schemaShape.status.enumSpec({
|
|
282
|
+
meaning: 'Whether exports are authorised now.', importance: FieldSemanticImportance.PRIMARY,
|
|
283
|
+
enumDeclaration: enumDeclaration('EvaluationExportAuthorizationStatus'),
|
|
284
|
+
values: {
|
|
285
|
+
[EvaluationExportAuthorizationStatus.NOT_GRANTED]: { meaning: 'Nobody granted one; every export is refused. Only a row that was never granted holds it, and it leaves only by being granted.' },
|
|
286
|
+
[EvaluationExportAuthorizationStatus.ACTIVE]: { meaning: 'Exports are authorised on the recorded basis.' },
|
|
287
|
+
[EvaluationExportAuthorizationStatus.REVOKED]: { meaning: 'Every export is refused.' },
|
|
288
|
+
},
|
|
289
|
+
}),
|
|
290
|
+
basis: schemaShape.basis.enumSpec({
|
|
291
|
+
meaning: 'The legal basis the organization relies on. Required when ACTIVE.',
|
|
292
|
+
enumDeclaration: enumDeclaration('EvaluationExportBasis'),
|
|
293
|
+
values: {
|
|
294
|
+
[EvaluationExportBasis.PROCESSOR_DOCUMENTED_INSTRUCTION]: { meaning: 'The firm processes for its client, and the client instructed it in writing.' },
|
|
295
|
+
[EvaluationExportBasis.CONTROLLER_COMPATIBILITY_ASSESSED]: { meaning: 'The firm is the controller and assessed the further use as compatible.' },
|
|
296
|
+
},
|
|
297
|
+
}),
|
|
298
|
+
basisReference: schemaShape.basisReference.stringSpec({ meaning: 'Where the basis is documented: a reference, never the document. Required when ACTIVE.' }),
|
|
299
|
+
clientConsents: schemaShape.clientConsents.arraySpec({ meaning: 'Per-case client consents, for cases of a privileged kind.', elementMeaning: 'One case\'s consent, by reference.' }),
|
|
300
|
+
excludedCaseRefs: schemaShape.excludedCaseRefs.arraySpec({ meaning: 'Ethical walls and client opt-outs: cases never exported.', elementMeaning: 'One excluded case.' }),
|
|
301
|
+
createdAt: schemaShape.createdAt.dateSpec({ meaning: 'When the authorisation was created.', temporalRole: 'creation' }),
|
|
302
|
+
updatedAt: schemaShape.updatedAt.dateSpec({ meaning: 'When it was last changed.', temporalRole: 'modified' }),
|
|
303
|
+
},
|
|
304
|
+
operations: {
|
|
305
|
+
[Op.READ]: { purpose: 'Read the organization\'s authorisation: its page.', outcome: 'The authorisation is returned; an organization with none gets its NOT_GRANTED row, created on this read.', idempotent: true, responseStatuses: [{ code: HttpResponseStatusCode.OK_200, meaning: 'The authorisation was found or created NOT_GRANTED.' }] },
|
|
306
|
+
[Op.CREATE]: {
|
|
307
|
+
purpose: 'Record the organization\'s authorisation to export evaluation data.', outcome: 'Exports are authorised on the stated basis; the change is audited.',
|
|
308
|
+
responseStatuses: [{ code: HttpResponseStatusCode.CREATED_201, meaning: 'The authorisation was recorded.' }],
|
|
309
|
+
errorScenarios: [
|
|
310
|
+
{ code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'It would be ACTIVE without a basis and its reference.' },
|
|
311
|
+
{ code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'It would be created REVOKED: nothing was granted, so there is nothing to withdraw.' },
|
|
312
|
+
],
|
|
313
|
+
},
|
|
314
|
+
[Op.UPDATE]: {
|
|
315
|
+
purpose: 'Grant, change or revoke the authorisation, its consents or its exclusions.', outcome: 'Later exports follow it; the change is audited.',
|
|
316
|
+
responseStatuses: [{ code: HttpResponseStatusCode.OK_200, meaning: 'The authorisation was changed.' }],
|
|
317
|
+
errorScenarios: [
|
|
318
|
+
{ code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'It would be ACTIVE without a basis and its reference.' },
|
|
319
|
+
{ code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'A granted authorisation would go back to NOT_GRANTED; withdrawing it is REVOKED.' },
|
|
320
|
+
{ code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'An authorisation that was never granted would be REVOKED: there is nothing to withdraw.' },
|
|
321
|
+
],
|
|
322
|
+
},
|
|
323
|
+
[Op.DELETE]: { purpose: 'The organization-deletion cascade\'s door. Route-less.', outcome: 'The authorisation of a deleted organization is removed.', idempotent: true },
|
|
324
|
+
},
|
|
325
|
+
businessConstraints: ['One authorisation per organization.', 'No export without it; a revoked one refuses every export.', 'A privileged case leaves only with its client\'s recorded consent.'],
|
|
326
|
+
}), { resourcePrimaryScope: ResourcePrimaryScope.ORGANIZATIONS });
|
|
327
|
+
export const evaluationDatasetExportsResourceSpecification = resourceSpecification(evaluationDatasetExportsResourceConfiguration_InitializationFactory, EvaluationDatasetExportSchema, ({ schemaShape }) => ({
|
|
328
|
+
purpose: 'Record every evaluation dataset an organization exported: who, when, under which authorisation, which records, and where it went.',
|
|
329
|
+
businessRole: 'The ledger an auditor reads to answer where a client\'s corrections went, and the index an erasure uses to mark every dataset that carried an erased case.',
|
|
330
|
+
lifecycleRole: 'Written by the engine at each export; marked when a case it contains is erased; kept for the declared AUDIT_LOGS period.',
|
|
331
|
+
audience: LabelAudience.DEVELOPER,
|
|
332
|
+
subDomain: EngineResourceSubDomain.FLOWS_ACTORS,
|
|
333
|
+
codeHandling: {
|
|
334
|
+
mainSchema: schemaDeclaration('EvaluationDatasetExportSchema'),
|
|
335
|
+
resourceFactory: factoryDeclaration('evaluationDatasetExportsResourceConfiguration_InitializationFactory'),
|
|
336
|
+
resourceType: { enumDeclaration: enumDeclaration('CoreResourceType'), memberName: 'EVALUATION_DATASET_EXPORTS' },
|
|
337
|
+
operationVocabulary: { coreEnum: enumDeclaration('CoreResourceOperation') },
|
|
338
|
+
notes: ['Written by `POST /agent-work/evaluation-exports`. Retention: AUDIT_LOGS from creation; RETAIN_AND_IMPERSONALIZE (the exporter is removed on erasure). The exported file itself is regenerated rather than kept.'],
|
|
339
|
+
},
|
|
340
|
+
fields: {
|
|
341
|
+
_id: schemaShape._id.stringSpec({ meaning: 'Identity of the export.', semanticRole: 'identifier' }),
|
|
342
|
+
organizationId: schemaShape.organizationId.foreignKeySpec({ meaning: 'The organization whose data was exported.', importance: FieldSemanticImportance.PRIMARY }),
|
|
343
|
+
exportedByUserId: schemaShape.exportedByUserId.stringSpec({ meaning: 'Who exported it. Removed on their erasure.', semanticRole: 'identifier' }),
|
|
344
|
+
exportedAt: schemaShape.exportedAt.dateSpec({ meaning: 'When it was exported.', temporalRole: 'occurred', importance: FieldSemanticImportance.PRIMARY }),
|
|
345
|
+
authorizationId: schemaShape.authorizationId.stringSpec({ meaning: 'The authorisation it was exported under.', semanticRole: 'identifier' }),
|
|
346
|
+
basis: schemaShape.basis.enumSpec({
|
|
347
|
+
meaning: 'The basis that authorisation stated at the time.',
|
|
348
|
+
enumDeclaration: enumDeclaration('EvaluationExportBasis'),
|
|
349
|
+
values: {
|
|
350
|
+
[EvaluationExportBasis.PROCESSOR_DOCUMENTED_INSTRUCTION]: { meaning: 'A documented instruction of the client.' },
|
|
351
|
+
[EvaluationExportBasis.CONTROLLER_COMPATIBILITY_ASSESSED]: { meaning: 'A compatibility assessment of the controller.' },
|
|
352
|
+
},
|
|
353
|
+
}),
|
|
354
|
+
agentRef: schemaShape.agentRef.stringSpec({ meaning: 'The agent whose decisions were exported.', semanticRole: 'identifier' }),
|
|
355
|
+
windowFrom: schemaShape.windowFrom.dateSpec({ meaning: 'Start of the exported window, inclusive.', temporalRole: 'occurred' }),
|
|
356
|
+
windowTo: schemaShape.windowTo.dateSpec({ meaning: 'End of the exported window, exclusive.', temporalRole: 'occurred' }),
|
|
357
|
+
decisionRefs: schemaShape.decisionRefs.arraySpec({ meaning: 'Every decision record the dataset contains.', elementMeaning: 'One decision.' }),
|
|
358
|
+
caseKeys: schemaShape.caseKeys.arraySpec({ meaning: 'The cases the dataset contains, so a case\'s erasure finds it.', elementMeaning: 'One case, as `resourceType:resourceId`.' }),
|
|
359
|
+
recordCount: schemaShape.recordCount.numberSpec({ meaning: 'How many records the dataset holds.' }),
|
|
360
|
+
pseudonymisationVersion: schemaShape.pseudonymisationVersion.stringSpec({ meaning: 'The scheme the identifiers were pseudonymised under.', semanticRole: 'code' }),
|
|
361
|
+
destination: schemaShape.destination.stringSpec({ meaning: 'Where the dataset was delivered, as the exporter named it.' }),
|
|
362
|
+
invalidatedAt: schemaShape.invalidatedAt.dateSpec({ meaning: 'When a case it contains was erased (or a consent withdrawn): the dataset must be regenerated.', temporalRole: 'occurred' }),
|
|
363
|
+
invalidationReason: schemaShape.invalidationReason.enumSpec({
|
|
364
|
+
meaning: 'Why the dataset was marked.',
|
|
365
|
+
enumDeclaration: enumDeclaration('EvaluationDatasetInvalidationReason'),
|
|
366
|
+
values: {
|
|
367
|
+
[EvaluationDatasetInvalidationReason.SUBJECT_ERASURE]: { meaning: 'A case it contains was erased or deleted.' },
|
|
368
|
+
[EvaluationDatasetInvalidationReason.CONSENT_WITHDRAWN]: { meaning: 'A client withdrew the consent it relied on.' },
|
|
369
|
+
},
|
|
370
|
+
}),
|
|
371
|
+
createdAt: schemaShape.createdAt.dateSpec({ meaning: 'When the ledger row was written.', temporalRole: 'creation' }),
|
|
372
|
+
},
|
|
373
|
+
operations: {
|
|
374
|
+
[Op.CREATE]: { purpose: 'Record one export. Written only by the engine.', outcome: 'The export is on the ledger.', responseStatuses: [{ code: HttpResponseStatusCode.CREATED_201, meaning: 'Internal write path.' }] },
|
|
375
|
+
[Op.READ]: { purpose: 'Read one export of the organization.', outcome: 'The ledger row is returned.', idempotent: true, responseStatuses: [{ code: HttpResponseStatusCode.OK_200, meaning: 'The export was found.' }] },
|
|
376
|
+
[Op.LIST]: { purpose: 'List the organization\'s exports.', outcome: 'The ledger rows are returned.', idempotent: true, responseStatuses: [{ code: HttpResponseStatusCode.OK_200, meaning: 'A possibly empty page of exports.' }] },
|
|
377
|
+
[Op.UPDATE_MANY]: { purpose: 'The erasure writer\'s door, and the marking of datasets that carried an erased case. Route-less.', outcome: 'The exporter is removed, or the dataset is marked.', idempotent: true },
|
|
378
|
+
[Op.DELETE]: { purpose: 'The retention sweep\'s and the organization-deletion cascade\'s door. Route-less.', outcome: 'An export past its AUDIT_LOGS period is removed.', idempotent: true },
|
|
379
|
+
},
|
|
380
|
+
businessConstraints: ['Every export is on the ledger.', 'An erased case marks every dataset that carried it.'],
|
|
381
|
+
}), { resourcePrimaryScope: ResourcePrimaryScope.ORGANIZATIONS });
|
|
382
|
+
//# sourceMappingURL=agent-work-decisions.resource.specification.js.map
|