@wildo-ai/saas-specifications 1.1.1 → 1.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assurance/external-framework-mapping.json +980 -0
- package/dist/esm/_core/brand/brand.family-aspects.d.ts +3 -0
- package/dist/esm/_core/brand/brand.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/brand/brand.family-aspects.js +51 -0
- package/dist/esm/_core/brand/brand.family-aspects.js.map +1 -0
- package/dist/esm/_core/build-plan/build-plan.family-aspects.d.ts +3 -0
- package/dist/esm/_core/build-plan/build-plan.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/build-plan/build-plan.family-aspects.js +28 -0
- package/dist/esm/_core/build-plan/build-plan.family-aspects.js.map +1 -0
- package/dist/esm/_core/business-model-lite/business-model.family-aspects.d.ts +3 -0
- package/dist/esm/_core/business-model-lite/business-model.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/business-model-lite/business-model.family-aspects.js +21 -0
- package/dist/esm/_core/business-model-lite/business-model.family-aspects.js.map +1 -0
- package/dist/esm/_core/chart-view-specification.schemas.d.ts +11 -0
- package/dist/esm/_core/chart-view-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/chart-view-specification.schemas.js.map +1 -1
- package/dist/esm/_core/compliance-documents/compliance-document-candidate-generation.schemas.d.ts +85 -0
- package/dist/esm/_core/compliance-documents/compliance-document-candidate-generation.schemas.d.ts.map +1 -1
- package/dist/esm/_core/compliance-documents/compliance-document-candidate-generation.schemas.js +41 -0
- package/dist/esm/_core/compliance-documents/compliance-document-candidate-generation.schemas.js.map +1 -1
- package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.d.ts +168 -2
- 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 +98 -9
- package/dist/esm/_core/compliance-documents/compliance-document-candidate.schemas.js.map +1 -1
- package/dist/esm/_core/compliance-documents/compliance-documents.family-aspects.d.ts +12 -0
- package/dist/esm/_core/compliance-documents/compliance-documents.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/compliance-documents/compliance-documents.family-aspects.js +47 -0
- package/dist/esm/_core/compliance-documents/compliance-documents.family-aspects.js.map +1 -0
- package/dist/esm/_core/compliance-documents/document-fact-specification-generation.schemas.d.ts.map +1 -1
- package/dist/esm/_core/compliance-documents/document-fact-specification-generation.schemas.js +8 -3
- package/dist/esm/_core/compliance-documents/document-fact-specification-generation.schemas.js.map +1 -1
- package/dist/esm/_core/compliance-documents/processor-register.family-aspects.d.ts +21 -0
- package/dist/esm/_core/compliance-documents/processor-register.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/compliance-documents/processor-register.family-aspects.js +40 -0
- package/dist/esm/_core/compliance-documents/processor-register.family-aspects.js.map +1 -0
- package/dist/esm/_core/composite-view-specification.schemas.d.ts +11 -0
- package/dist/esm/_core/composite-view-specification.schemas.d.ts.map +1 -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 -0
- package/dist/esm/_core/domain-plan/domain-plan.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/domain-plan/domain-plan.family-aspects.js +32 -0
- package/dist/esm/_core/domain-plan/domain-plan.family-aspects.js.map +1 -0
- package/dist/esm/_core/execution-view-specification.schemas.d.ts +11 -0
- package/dist/esm/_core/execution-view-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/execution-view-specification.schemas.js.map +1 -1
- package/dist/esm/_core/family-aspects.registry.d.ts +18 -0
- package/dist/esm/_core/family-aspects.registry.d.ts.map +1 -0
- package/dist/esm/_core/family-aspects.registry.js +60 -0
- package/dist/esm/_core/family-aspects.registry.js.map +1 -0
- package/dist/esm/_core/family-aspects.schemas.d.ts +122 -0
- package/dist/esm/_core/family-aspects.schemas.d.ts.map +1 -0
- package/dist/esm/_core/family-aspects.schemas.js +15 -0
- package/dist/esm/_core/family-aspects.schemas.js.map +1 -0
- package/dist/esm/_core/feature-drafts/capability-map-output-set-generation.schemas.d.ts +11 -11
- package/dist/esm/_core/feature-drafts/feature-drafts.family-aspects.d.ts +3 -0
- package/dist/esm/_core/feature-drafts/feature-drafts.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/feature-drafts/feature-drafts.family-aspects.js +25 -0
- package/dist/esm/_core/feature-drafts/feature-drafts.family-aspects.js.map +1 -0
- package/dist/esm/_core/flows-actors-view-specification.schemas.d.ts +11 -0
- package/dist/esm/_core/flows-actors-view-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/flows-actors-view-specification.schemas.js.map +1 -1
- package/dist/esm/_core/frontend-component-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/frontend-component-specification.schemas.js +19 -1
- package/dist/esm/_core/frontend-component-specification.schemas.js.map +1 -1
- package/dist/esm/_core/full-custom-view-specification.schemas.d.ts +11 -0
- package/dist/esm/_core/full-custom-view-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/full-custom-view-specification.schemas.js.map +1 -1
- package/dist/esm/_core/guidance-flow-specification.schemas.d.ts +11 -0
- package/dist/esm/_core/guidance-flow-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/guidance-flow-specification.schemas.js +14 -0
- package/dist/esm/_core/guidance-flow-specification.schemas.js.map +1 -1
- package/dist/esm/_core/index.d.ts +2 -0
- package/dist/esm/_core/index.d.ts.map +1 -1
- package/dist/esm/_core/index.js +2 -0
- package/dist/esm/_core/index.js.map +1 -1
- package/dist/esm/_core/market/market-snapshot-generation.schemas.d.ts +22 -22
- package/dist/esm/_core/market/market.family-aspects.d.ts +9 -0
- package/dist/esm/_core/market/market.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/market/market.family-aspects.js +227 -0
- package/dist/esm/_core/market/market.family-aspects.js.map +1 -0
- package/dist/esm/_core/onboarding-view-specification.schemas.d.ts +11 -0
- package/dist/esm/_core/onboarding-view-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/onboarding-view-specification.schemas.js +14 -0
- package/dist/esm/_core/onboarding-view-specification.schemas.js.map +1 -1
- package/dist/esm/_core/placement-plan/placement-plan.family-aspects.d.ts +3 -0
- package/dist/esm/_core/placement-plan/placement-plan.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/placement-plan/placement-plan.family-aspects.js +31 -0
- package/dist/esm/_core/placement-plan/placement-plan.family-aspects.js.map +1 -0
- package/dist/esm/_core/requirements/requirements.family-aspects.d.ts +9 -0
- package/dist/esm/_core/requirements/requirements.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/requirements/requirements.family-aspects.js +40 -0
- package/dist/esm/_core/requirements/requirements.family-aspects.js.map +1 -0
- package/dist/esm/_core/resource-specification.schemas.d.ts +22 -0
- package/dist/esm/_core/resource-specification.schemas.d.ts.map +1 -1
- package/dist/esm/_core/resource-specification.schemas.js.map +1 -1
- package/dist/esm/_core/roadmap/roadmap.family-aspects.d.ts +3 -0
- package/dist/esm/_core/roadmap/roadmap.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/roadmap/roadmap.family-aspects.js +26 -0
- package/dist/esm/_core/roadmap/roadmap.family-aspects.js.map +1 -0
- package/dist/esm/_core/vision/vision.family-aspects.d.ts +11 -0
- package/dist/esm/_core/vision/vision.family-aspects.d.ts.map +1 -0
- package/dist/esm/_core/vision/vision.family-aspects.js +63 -0
- package/dist/esm/_core/vision/vision.family-aspects.js.map +1 -0
- package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.d.ts +188 -33
- 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 +158 -57
- package/dist/esm/application-creation/application-document-fact-specification.application-creation.schemas.js.map +1 -1
- package/dist/esm/application-creation/application-specification-family-identity.application-creation.schemas.d.ts +38 -4
- package/dist/esm/application-creation/application-specification-family-identity.application-creation.schemas.d.ts.map +1 -1
- package/dist/esm/application-creation/application-specification-family-identity.application-creation.schemas.js +37 -3
- package/dist/esm/application-creation/application-specification-family-identity.application-creation.schemas.js.map +1 -1
- package/dist/esm/application-creation/document-facts.family-aspects.d.ts +12 -0
- package/dist/esm/application-creation/document-facts.family-aspects.d.ts.map +1 -0
- package/dist/esm/application-creation/document-facts.family-aspects.js +37 -0
- package/dist/esm/application-creation/document-facts.family-aspects.js.map +1 -0
- package/dist/esm/application-creation/document-release-policy.family-aspects.d.ts +3 -0
- package/dist/esm/application-creation/document-release-policy.family-aspects.d.ts.map +1 -0
- package/dist/esm/application-creation/document-release-policy.family-aspects.js +23 -0
- package/dist/esm/application-creation/document-release-policy.family-aspects.js.map +1 -0
- package/dist/esm/application-creation/playbooks.application-creation.schemas.d.ts +93 -62
- package/dist/esm/application-creation/playbooks.application-creation.schemas.d.ts.map +1 -1
- package/dist/esm/application-creation/playbooks.application-creation.schemas.js +114 -59
- package/dist/esm/application-creation/playbooks.application-creation.schemas.js.map +1 -1
- package/dist/esm/application-creation/structured-artifact-landing.application-creation.schemas.d.ts +2 -0
- package/dist/esm/application-creation/structured-artifact-landing.application-creation.schemas.d.ts.map +1 -1
- package/dist/esm/application-creation/structured-artifact-landing.application-creation.schemas.js +2 -0
- package/dist/esm/application-creation/structured-artifact-landing.application-creation.schemas.js.map +1 -1
- package/dist/esm/application-creation.exports.d.ts +11 -0
- package/dist/esm/application-creation.exports.d.ts.map +1 -1
- package/dist/esm/application-creation.exports.js +11 -0
- package/dist/esm/application-creation.exports.js.map +1 -1
- package/dist/esm/assurance/assurance-authority-basis.definitions.d.ts +976 -2
- package/dist/esm/assurance/assurance-authority-basis.definitions.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-authority-basis.definitions.js +2026 -61
- package/dist/esm/assurance/assurance-authority-basis.definitions.js.map +1 -1
- package/dist/esm/assurance/assurance-authority-basis.schemas.d.ts +1 -0
- package/dist/esm/assurance/assurance-authority-basis.schemas.d.ts.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 +18 -3
- package/dist/esm/assurance/assurance-document-system.definitions.js.map +1 -1
- package/dist/esm/assurance/assurance-document-system.schemas.d.ts +32 -2
- package/dist/esm/assurance/assurance-document-system.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-document-system.schemas.js +32 -2
- package/dist/esm/assurance/assurance-document-system.schemas.js.map +1 -1
- package/dist/esm/assurance/assurance-external-framework-mapping.d.ts +90 -0
- package/dist/esm/assurance/assurance-external-framework-mapping.d.ts.map +1 -0
- package/dist/esm/assurance/assurance-external-framework-mapping.js +134 -0
- package/dist/esm/assurance/assurance-external-framework-mapping.js.map +1 -0
- package/dist/esm/assurance/assurance-objective-catalog.definitions.d.ts +71 -1
- package/dist/esm/assurance/assurance-objective-catalog.definitions.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-objective-catalog.definitions.js +545 -5
- package/dist/esm/assurance/assurance-objective-catalog.definitions.js.map +1 -1
- package/dist/esm/assurance/assurance-program-generation.schemas.d.ts +141 -0
- package/dist/esm/assurance/assurance-program-generation.schemas.d.ts.map +1 -0
- package/dist/esm/assurance/assurance-program-generation.schemas.js +377 -0
- package/dist/esm/assurance/assurance-program-generation.schemas.js.map +1 -0
- package/dist/esm/assurance/assurance-program.family-aspects.d.ts +13 -0
- package/dist/esm/assurance/assurance-program.family-aspects.d.ts.map +1 -0
- package/dist/esm/assurance/assurance-program.family-aspects.js +16 -0
- package/dist/esm/assurance/assurance-program.family-aspects.js.map +1 -0
- package/dist/esm/assurance/assurance-program.schemas.d.ts +30 -6
- package/dist/esm/assurance/assurance-program.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-program.schemas.js +29 -6
- package/dist/esm/assurance/assurance-program.schemas.js.map +1 -1
- package/dist/esm/assurance/assurance-source-registry.definitions.d.ts +1 -0
- package/dist/esm/assurance/assurance-source-registry.definitions.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-source-registry.definitions.js +12 -0
- package/dist/esm/assurance/assurance-source-registry.definitions.js.map +1 -1
- package/dist/esm/assurance/assurance-sources.schemas.d.ts +76 -0
- package/dist/esm/assurance/assurance-sources.schemas.d.ts.map +1 -1
- package/dist/esm/assurance/assurance-sources.schemas.js +59 -0
- package/dist/esm/assurance/assurance-sources.schemas.js.map +1 -1
- package/dist/esm/assurance/document-publication.family-aspects.d.ts +29 -0
- package/dist/esm/assurance/document-publication.family-aspects.d.ts.map +1 -0
- package/dist/esm/assurance/document-publication.family-aspects.js +48 -0
- package/dist/esm/assurance/document-publication.family-aspects.js.map +1 -0
- package/dist/esm/assurance.exports.d.ts +2 -0
- package/dist/esm/assurance.exports.d.ts.map +1 -1
- package/dist/esm/assurance.exports.js +2 -0
- package/dist/esm/assurance.exports.js.map +1 -1
- package/dist/esm/companion-exports.d.ts +19 -2
- 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.map +1 -1
- package/dist/esm/engine/applications/resources/application-api-keys.resource.specification.js +2 -0
- 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 +3 -1
- package/dist/esm/engine/applications/resources/application-metadata.resource.specification.js.map +1 -1
- package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/applications/resources/application-oauth-clients.resource.specification.js +3 -1
- 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 +3 -1
- package/dist/esm/engine/applications/resources/application-versions.resource.specification.js.map +1 -1
- package/dist/esm/engine/applications/resources/applications.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/applications/resources/applications.resource.specification.js +3 -1
- package/dist/esm/engine/applications/resources/applications.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/consumable-tokens.resource.specification.d.ts +36 -0
- package/dist/esm/engine/auth/resources/consumable-tokens.resource.specification.d.ts.map +1 -0
- package/dist/esm/engine/auth/resources/consumable-tokens.resource.specification.js +193 -0
- package/dist/esm/engine/auth/resources/consumable-tokens.resource.specification.js.map +1 -0
- package/dist/esm/engine/auth/resources/oauth-consent-grants.resource.specification.d.ts +1 -1
- package/dist/esm/engine/auth/resources/oauth-consent-grants.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/auth/resources/oauth-consent-grants.resource.specification.js +2 -0
- 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.map +1 -1
- package/dist/esm/engine/auth/resources/organization-api-keys.resource.specification.js +2 -0
- 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.map +1 -1
- package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.js +3 -1
- package/dist/esm/engine/auth/resources/organization-oauth-clients.resource.specification.js.map +1 -1
- package/dist/esm/engine/auth/resources/platform-access-grants.resource.specification.d.ts +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 +2 -0
- 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 +2 -0
- 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.map +1 -1
- package/dist/esm/engine/auth/resources/scim-tokens.resource.specification.js +2 -0
- 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 +2 -0
- 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 +6 -4
- 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 +2 -0
- 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.map +1 -1
- package/dist/esm/engine/auth/resources/sso-connections.resource.specification.js +2 -0
- package/dist/esm/engine/auth/resources/sso-connections.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/billing-accounts.resource.specification.d.ts +2 -2
- 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 +2 -0
- package/dist/esm/engine/billing/resources/billing-accounts.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/credit-pools.resource.specification.d.ts +8 -8
- 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 +2 -0
- package/dist/esm/engine/billing/resources/credit-pools.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/invoice-refs.resource.specification.d.ts +2 -2
- package/dist/esm/engine/billing/resources/invoice-refs.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/invoice-refs.resource.specification.js +2 -0
- 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 +3 -1
- package/dist/esm/engine/billing/resources/prices.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/products.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/products.resource.specification.js +3 -1
- 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 +2 -0
- package/dist/esm/engine/billing/resources/promotions.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/referrals.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/referrals.resource.specification.js +3 -1
- package/dist/esm/engine/billing/resources/referrals.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/subscriptions.resource.specification.d.ts +6 -6
- package/dist/esm/engine/billing/resources/subscriptions.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/subscriptions.resource.specification.js +2 -0
- package/dist/esm/engine/billing/resources/subscriptions.resource.specification.js.map +1 -1
- package/dist/esm/engine/billing/resources/usage-records.resource.specification.d.ts +6 -6
- package/dist/esm/engine/billing/resources/usage-records.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/billing/resources/usage-records.resource.specification.js +2 -0
- package/dist/esm/engine/billing/resources/usage-records.resource.specification.js.map +1 -1
- 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 +2 -0
- package/dist/esm/engine/compliance/resources/audit-logs.resource.specification.js.map +1 -1
- package/dist/esm/engine/engine-resource-specifications.registry.d.ts.map +1 -1
- package/dist/esm/engine/engine-resource-specifications.registry.js +5 -0
- package/dist/esm/engine/engine-resource-specifications.registry.js.map +1 -1
- package/dist/esm/engine/engine-resource-sub-domain.d.ts +63 -0
- package/dist/esm/engine/engine-resource-sub-domain.d.ts.map +1 -0
- package/dist/esm/engine/engine-resource-sub-domain.js +87 -0
- package/dist/esm/engine/engine-resource-sub-domain.js.map +1 -0
- package/dist/esm/engine/errors/error-messages.specification.d.ts.map +1 -1
- package/dist/esm/engine/errors/error-messages.specification.js +30 -1
- package/dist/esm/engine/errors/error-messages.specification.js.map +1 -1
- package/dist/esm/engine/features/resources/application-features.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/features/resources/application-features.resource.specification.js +2 -0
- package/dist/esm/engine/features/resources/application-features.resource.specification.js.map +1 -1
- package/dist/esm/engine/features/resources/organization-features.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/features/resources/organization-features.resource.specification.js +2 -0
- package/dist/esm/engine/features/resources/organization-features.resource.specification.js.map +1 -1
- package/dist/esm/engine/features/resources/user-features.resource.specification.d.ts +1 -1
- package/dist/esm/engine/features/resources/user-features.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/features/resources/user-features.resource.specification.js +2 -0
- 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 +2 -0
- 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 +3 -3
- 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 +12 -0
- 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.d.ts +3 -3
- package/dist/esm/engine/flows-actors/resources/a2a-token-budget-state.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/flows-actors/resources/a2a-token-budget-state.resource.specification.js +2 -0
- package/dist/esm/engine/flows-actors/resources/a2a-token-budget-state.resource.specification.js.map +1 -1
- package/dist/esm/engine/flows-actors/resources/flow-actor-executions.resource.specification.d.ts +3 -3
- 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 +2 -0
- package/dist/esm/engine/flows-actors/resources/flow-actor-executions.resource.specification.js.map +1 -1
- package/dist/esm/engine/flows-actors/resources/flow-actor-tasks.resource.specification.d.ts +3 -3
- package/dist/esm/engine/flows-actors/resources/flow-actor-tasks.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/flows-actors/resources/flow-actor-tasks.resource.specification.js +3 -1
- package/dist/esm/engine/flows-actors/resources/flow-actor-tasks.resource.specification.js.map +1 -1
- package/dist/esm/engine/frontend-components/app/public-layout-main-container.frontend-component.specification.d.ts.map +1 -1
- package/dist/esm/engine/frontend-components/app/public-layout-main-container.frontend-component.specification.js +8 -3
- package/dist/esm/engine/frontend-components/app/public-layout-main-container.frontend-component.specification.js.map +1 -1
- package/dist/esm/engine/guidance/resources/guidance-state.resource.specification.d.ts +1 -1
- package/dist/esm/engine/guidance/resources/guidance-state.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/guidance/resources/guidance-state.resource.specification.js +3 -0
- 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 +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 +3 -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 +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 +3 -0
- package/dist/esm/engine/guidance/resources/progression-state.resource.specification.js.map +1 -1
- package/dist/esm/engine/index.d.ts +1 -0
- package/dist/esm/engine/index.d.ts.map +1 -1
- package/dist/esm/engine/index.js +1 -0
- package/dist/esm/engine/index.js.map +1 -1
- package/dist/esm/engine/infrastructure/resources/data-seed-runs.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/infrastructure/resources/data-seed-runs.resource.specification.js +2 -0
- package/dist/esm/engine/infrastructure/resources/data-seed-runs.resource.specification.js.map +1 -1
- 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 +2 -0
- package/dist/esm/engine/infrastructure/resources/external-data-pipeline-states.resource.specification.js.map +1 -1
- package/dist/esm/engine/infrastructure/resources/job-executions.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/infrastructure/resources/job-executions.resource.specification.js +2 -0
- 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.map +1 -1
- package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.js +2 -0
- package/dist/esm/engine/infrastructure/resources/job-payload-storage.resource.specification.js.map +1 -1
- 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 +2 -0
- package/dist/esm/engine/notifications/resources/m2m-webhook-delivery-log.resource.specification.js.map +1 -1
- package/dist/esm/engine/notifications/resources/notification-badges.resource.specification.d.ts +1 -1
- package/dist/esm/engine/notifications/resources/notification-badges.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/notifications/resources/notification-badges.resource.specification.js +3 -0
- 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.map +1 -1
- package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.js +2 -0
- package/dist/esm/engine/notifications/resources/webhook-config.resource.specification.js.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-members.resource.specification.d.ts +1 -1
- package/dist/esm/engine/organizations/resources/organization-members.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-members.resource.specification.js +2 -0
- package/dist/esm/engine/organizations/resources/organization-members.resource.specification.js.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-notifications.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-notifications.resource.specification.js +2 -0
- package/dist/esm/engine/organizations/resources/organization-notifications.resource.specification.js.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-preferences.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-preferences.resource.specification.js +2 -0
- 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.map +1 -1
- package/dist/esm/engine/organizations/resources/organization-profiles.resource.specification.js +2 -0
- 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 +2 -0
- 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 +2 -0
- 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.map +1 -1
- package/dist/esm/engine/organizations/resources/organizations.resource.specification.js +2 -0
- package/dist/esm/engine/organizations/resources/organizations.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/anonymous-users.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/anonymous-users.resource.specification.js +2 -0
- package/dist/esm/engine/users/resources/anonymous-users.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/inbound-contacts.resource.specification.d.ts +1 -1
- package/dist/esm/engine/users/resources/inbound-contacts.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/inbound-contacts.resource.specification.js +2 -0
- package/dist/esm/engine/users/resources/inbound-contacts.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/user-credentials.resource.specification.d.ts +1 -1
- package/dist/esm/engine/users/resources/user-credentials.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/user-credentials.resource.specification.js +2 -0
- 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.d.ts +1 -1
- package/dist/esm/engine/users/resources/user-identity-links.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/user-identity-links.resource.specification.js +2 -0
- package/dist/esm/engine/users/resources/user-identity-links.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/user-preferences.resource.specification.d.ts +1 -1
- 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 +2 -0
- package/dist/esm/engine/users/resources/user-preferences.resource.specification.js.map +1 -1
- package/dist/esm/engine/users/resources/user-profiles.resource.specification.d.ts +1 -1
- package/dist/esm/engine/users/resources/user-profiles.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/user-profiles.resource.specification.js +2 -0
- 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 +1 -1
- 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 +2 -0
- 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.d.ts +1 -1
- package/dist/esm/engine/users/resources/user-self-profiles.resource.specification.d.ts.map +1 -1
- package/dist/esm/engine/users/resources/user-self-profiles.resource.specification.js +2 -0
- 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 +3 -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.map +1 -1
- package/dist/esm/engine/users/resources/users.resource.specification.js +2 -0
- 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 +5 -0
- package/dist/esm/technical-documentation/engine-documentation-specification-catalog.companion.d.ts.map +1 -1
- package/dist/esm/technical-documentation/engine-documentation-specification-catalog.companion.js +385 -9
- package/dist/esm/technical-documentation/engine-documentation-specification-catalog.companion.js.map +1 -1
- package/dist/esm/technical-documentation/technical-documentation-units.schemas.js +1 -1
- package/dist/esm/technical-documentation/technical-documentation-units.schemas.js.map +1 -1
- package/dist/tsconfig.build.tsbuildinfo +1 -0
- package/package.json +8 -8
- package/dist/esm/.builder.pid +0 -9
- package/dist/esm/_core/business-coverage/coverage-findings-validation.d.ts +0 -0
- package/dist/esm/_core/business-coverage/coverage-findings-validation.d.ts.map +0 -0
- package/dist/esm/_core/business-coverage/coverage-findings-validation.js.map +0 -0
- package/dist/esm/_core/business-coverage/coverage-findings.schemas.d.ts +0 -0
- package/dist/esm/_core/business-coverage/coverage-findings.schemas.d.ts.map +0 -0
- package/dist/esm/_core/business-coverage/coverage-findings.schemas.js.map +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"platform-access-grants.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/auth/resources/platform-access-grants.resource.specification.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AACpE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CAA6C;YACtD,OAAO,EAAE,sHAAsH;YAC/H,SAAS,EAAE,yIAAyI;YACpJ,gBAAgB,EAAE;gBAChB,EAAE,IAAI,EAAE,sBAAsB,CAAC,MAAM,EAAE,OAAO,EAAE,0EAA0E,EAAE;aAC7H;YACD,cAAc,EAAE;gBACd,EAAE,IAAI,EAAE,sBAAsB,CAAC,aAAa,EAAE,IAAI,EAAE,8GAA8G,EAAE;gBACpK,EAAE,IAAI,EAAE,sBAAsB,CAAC,aAAa,EAAE,IAAI,EAAE,2DAA2D,EAAE;gBACjH,EAAE,IAAI,EAAE,sBAAsB,CAAC,YAAY,EAAE,IAAI,EAAE,kHAAkH,EAAE;aACxK;YACD,UAAU,EAAE,KAAK;YACjB,QAAQ,EAAE,CAAC;oBACT,KAAK,EAAE,8CAA8C;oBACrD,OAAO,EAAE;wBACP,cAAc,EAAE,uCAAuC;wBACvD,qBAAqB,EAAE,+BAA+B;wBACtD,cAAc,EAAE,oCAAoC;qBACrD;oBACD,QAAQ,EAAE;wBACR,GAAG,gCAAgC;wBACnC,MAAM,EAAE,yBAAyB,CAAC,OAAO;wBACzC,cAAc,EAAE,oCAAoC;wBACpD,SAAS,EAAE,0BAA0B;qBACtC;oBACD,SAAS,EAAE,sBAAsB,CAAC,MAAM;iBACzC,CAAC;SACH;KACF;IAED,mBAAmB,EAAE;QACnB,8VAA8V;QAC9V,4cAA4c;QAC5c,mXAAmX;QACnX,yQAAyQ;QACzQ,sLAAsL;QACtL,2kBAA2kB;QAC3kB,kTAAkT;KACnT;CACF,CAAC,EACF,EAAE,oBAAoB,EAAE,oBAAoB,CAAC,aAAa,EAAE,CAC7D,CAAC","sourcesContent":["/**\n * Resource: `platformAccessGrants` — Wildo SaaS engine specification (backend-only, organization-scoped).\n *\n * Inputs:\n * - Schema: engine/saas-models/src/security/authorizations/platform-access-grants.shared.schemas.ts\n * → `PlatformAccessGrantSchema`\n * - Factory: engine/saas-models/src/security/authorizations/platform-access-grants.shared.resources-config.schemas.ts\n * → `platformAccessGrantsResourceConfiguration_InitializationFactory`\n * - Custom operations: `PlatformAccessGrants_Operations` (co-located with the VOCABULARY, in the\n * schemas module rather than the resources-config module — the authorization layer needs\n * `REQUEST_ACCESS` by name, and importing it from the config would drag resource-configuration\n * evaluation into the authorizer's module graph). Both modules are re-exported from the package\n * root, so this spec imports every symbol from `@wildo-ai/saas-models` and is unaffected either way.\n *\n * Why backend-only: there is NO entry for `[CoreResourceType.PLATFORM_ACCESS_GRANTS]` in any preset\n * under engine/presets-components/src/config/resources/. The tenant-facing approval surface is not\n * built yet; today the resource is consumed by the authorizer's admission predicate and by the\n * platform/tenant API.\n *\n * Why `ORGANIZATIONS` scope: the grant belongs to the tenant being reached INTO, not to the operator\n * who asked. That is what lets the tenant read, approve and revoke elevations raised against it — a\n * consent record the consenting party cannot see would defeat the purpose of modelling consent. The\n * scope is expressed once, in the registry relationship ORGANIZATIONS → PLATFORM_ACCESS_GRANTS\n * carrying `isPrimaryScope: true`; the runtime config deliberately does not restate it.\n */\n\nimport { LabelAudience } from '@wildo-ai/presets-components-models';\nimport {\n CodeDeclarationKind,\n CodeSymbolKind,\n FieldSemanticImportance,\n} from '@wildo-ai/zod-decorators';\nimport {\n CoreResourceOperation as Op,\n CoreUserNotificationTarget,\n PlatformAccessGrantAutoApprovalReason,\n PlatformAccessGrantSchema,\n PlatformAccessGrantStatus,\n PlatformAccessGrants_Operations,\n ResourcePrimaryScope,\n platformAccessGrantsResourceConfiguration_InitializationFactory,\n} from '@wildo-ai/saas-models';\nimport { HttpResponseStatusCode, resourceSpecification } from '~wildo-specifications/_core';\n\nconst TENANT_CONSENT_AUDIENCE = 'Administrators of the TARGET tenant — the party whose data is about to be reached into, and the only party who can refuse.';\nconst TENANT_CONSENT_TONE = 'Direct and factual, and never reassuring by omission: name the operator, the reason they gave, and the window they asked for, so the recipient can decide rather than merely be informed.';\n\nconst PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID = 'org_01J4P8F1M2N3Q4R5S6T7V8W9XY';\nconst PLATFORM_ACCESS_PENDING_GRANT_ID = 'platform_access_grant_01J4P8K2N3Q4R5S6T7V8W9X0YZ';\nconst PLATFORM_ACCESS_ACTIVE_GRANT_ID = 'platform_access_grant_01J4P8M3Q4R5S6T7V8W9X0Y1ZA';\nconst PLATFORM_ACCESS_OPERATOR_USER_ID = 'user_01J4P8P4R5S6T7V8W9X0Y1Z2AB';\nconst PLATFORM_ACCESS_APPROVER_USER_ID = 'user_01J4P8R5S6T7V8W9X0Y1Z2A3BC';\n\nconst platformAccessPendingGrantExample = {\n _id: PLATFORM_ACCESS_PENDING_GRANT_ID,\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n operatorUserId: PLATFORM_ACCESS_OPERATOR_USER_ID,\n justification: 'Investigate failed SCIM provisioning for support case INC-4821.',\n status: PlatformAccessGrantStatus.PENDING_APPROVAL,\n expiresAt: '2026-08-20T14:00:00.000Z',\n createdAt: '2026-08-20T12:00:00.000Z',\n updatedAt: '2026-08-20T12:00:00.000Z',\n};\n\nconst platformAccessActiveGrantExample = {\n ...platformAccessPendingGrantExample,\n _id: PLATFORM_ACCESS_ACTIVE_GRANT_ID,\n status: PlatformAccessGrantStatus.ACTIVE,\n approvedByUserId: PLATFORM_ACCESS_APPROVER_USER_ID,\n approvedAt: '2026-08-20T12:08:00.000Z',\n updatedAt: '2026-08-20T12:08:00.000Z',\n};\n\nconst platformAccessPendingGrantSummaryExample = {\n _id: platformAccessPendingGrantExample._id,\n organizationId: platformAccessPendingGrantExample.organizationId,\n operatorUserId: platformAccessPendingGrantExample.operatorUserId,\n justification: platformAccessPendingGrantExample.justification,\n status: platformAccessPendingGrantExample.status,\n expiresAt: platformAccessPendingGrantExample.expiresAt,\n};\n\nconst platformAccessActiveGrantSummaryExample = {\n ...platformAccessPendingGrantSummaryExample,\n _id: platformAccessActiveGrantExample._id,\n status: platformAccessActiveGrantExample.status,\n};\n\nconst PLATFORM_ACCESS_PAGE_REQUEST = {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n page: 1,\n limit: 20,\n sort: 'createdAt:desc',\n};\n\nfunction platformAccessGrantPage<T>(data: readonly T[]) {\n return {\n data,\n pagination: {\n page: 1,\n limit: 20,\n total: data.length,\n totalPages: data.length === 0 ? 0 : 1,\n },\n };\n}\n\nexport const platformAccessGrantsResourceSpecification = resourceSpecification(\n platformAccessGrantsResourceConfiguration_InitializationFactory,\n PlatformAccessGrantSchema,\n ({ schemaShape }) => ({\n purpose: 'Give an application support team a justified, time-limited way to request access to an organization while keeping that organization informed and in control of the decision.',\n businessRole: 'The organization\\'s support-access ledger. It answers who requested access, why they requested it, how long the window lasts, whether an administrator approved it and when access ended.',\n lifecycleRole: 'An authorized support operator creates a request. It waits for an organization administrator when approval is required, or becomes active immediately with an explicit automatic-approval reason. An administrator can approve or deny a pending request; either side can revoke pending or active access; expiry ends access automatically. Completed requests remain available as access-review history.',\n audience: LabelAudience.ADMIN,\n\n codeHandling: {\n mainSchema: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'PlatformAccessGrantSchema',\n symbolKind: CodeSymbolKind.SCHEMA,\n declarationKind: CodeDeclarationKind.ZOD_SCHEMA,\n },\n resourceFactory: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'platformAccessGrantsResourceConfiguration_InitializationFactory',\n symbolKind: CodeSymbolKind.FACTORY,\n declarationKind: CodeDeclarationKind.FUNCTION,\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: 'PLATFORM_ACCESS_GRANTS',\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 customEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'PlatformAccessGrants_Operations',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n },\n notes: [\n 'No public CREATE or UPDATE. `requestAccess` is the only writer of a new row, and `approve` / `deny` / `revoke` are the only status transitions. A generic UPDATE would be a second, ungated path to those transitions; a generic CREATE would let a caller author `status`, `expiresAt` and `operatorUserId`, which are precisely the fields whose SERVER authorship is the control.',\n 'DELETE exists but has NO client door — its single variant is INTERNAL_CALL, mirroring `organizations.delete`\\'s own default. It is present only so the ORGANIZATIONS composition cascade (`onParentDelete`) has a verb it can call; a cascade declared but unable to run fails the registry\\'s composition-cascade-deletability guard, and would otherwise leave grant rows behind after their tenant was purged.',\n 'The runtime declares exactly ONE `userNotifications[]` entry, on `requestAccess` (target=ORGANIZATION_USERS, channel=EMAIL). There are no `m2mNotifications` anywhere in this family, so no `communications.m2m` block appears on any operation (DF-1 strict parity).',\n 'The grant LIFECYCLE audit events (requested / approved / denied / revoked) are not emitted yet — see `.claude/plans/platform-access-grants-jit-elevation.md` R7. The crossing itself is already audited by `CoreAuditableEventType.CROSS_TENANT_ADMINISTRATIVE_ACCESS`, emitted from the authorizer rather than from this resource.',\n ],\n },\n\n fields: {\n _id: schemaShape._id.stringSpec({\n meaning: 'Identifier for one elevation request.',\n whyItMatters: 'The address of every subsequent decision — approve, deny and revoke all target this row, and the audit trail names it.',\n semanticRole: 'identifier',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n organizationId: schemaShape.organizationId.foreignKeySpec({\n meaning: 'The TARGET tenant — the organization being reached into, never the operator\\'s own.',\n whyItMatters: 'The scope anchor. It makes the grant an organization-scoped row, which is what lets the tenant see, approve and revoke elevations raised against it, and it is the tenant the admission predicate matches a crossing against.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n operatorUserId: schemaShape.operatorUserId.foreignKeySpec({\n meaning: 'The platform operator who requested the elevation.',\n whyItMatters: 'Server-authored from the session, never client-supplied — an elevation whose subject the caller could choose would let one operator mint access for another. Together with `organizationId` it forms the pair the admission predicate matches: this operator, into this tenant.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n justification: schemaShape.justification.stringSpec({\n meaning: 'Why the operator needs access, in their own words.',\n whyItMatters: 'Required everywhere in the flow and deliberately never optional. An elevation record without a reason answers \"who\" and \"when\" but not \"why\", which is the only question a reviewer or a customer actually asks; NIST SP 800-53 AC-2(7) wants privileged assignment MONITORED, and an unexplained monitored assignment is a log line rather than a control.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n status: schemaShape.status.enumSpec({\n meaning: 'Where this elevation is in its lifecycle.',\n whyItMatters: 'Read together with `expiresAt`, never alone: the admission predicate accepts ACTIVE and then re-checks the window, so a grant whose window elapsed stops working whether or not anything has relabelled it.',\n importance: FieldSemanticImportance.PRIMARY,\n enumDeclaration: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'PlatformAccessGrantStatus',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n values: {\n [PlatformAccessGrantStatus.PENDING_APPROVAL]: { meaning: 'Awaiting a decision from an administrator of the target tenant — the Lockbox posture. The elevation does NOT work in this state.' },\n [PlatformAccessGrantStatus.ACTIVE]: { meaning: 'Usable now, and only while unexpired. The one status the admission predicate accepts.' },\n [PlatformAccessGrantStatus.DENIED]: { meaning: 'The tenant refused. Terminal — a fresh request must be raised rather than this one retried.' },\n [PlatformAccessGrantStatus.EXPIRED]: { meaning: 'The window elapsed. Terminal, and reached WITHOUT a writer: this label is bookkeeping for humans and reporting, never the control that stops the access.' },\n [PlatformAccessGrantStatus.REVOKED]: { meaning: 'Withdrawn before expiry, by either the tenant or the platform. Terminal.' },\n },\n }),\n expiresAt: schemaShape.expiresAt.dateSpec({\n meaning: 'When the elevation stops working.',\n whyItMatters: 'The actual control, and the reason this is a time-bound grant rather than a renamed standing privilege. Server-authored from the requested duration and clamped to a 4-hour ceiling, so a client cannot mint a long-lived elevation by asking for one. The admission predicate compares against it directly, which is why expiry needs no sweeper to take effect.',\n temporalRole: 'expiration',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n approvedByUserId: schemaShape.approvedByUserId.foreignKeySpec({\n meaning: 'The tenant administrator who approved, when a human in the tenant did.',\n whyItMatters: 'Absent on an auto-approved grant, which is what makes its presence meaningful: it distinguishes \"someone here agreed\" from \"nobody needed to\". Written only by `approve` — `deny` and `revoke` deliberately leave it alone, because writing a refusal into the approver field would corrupt the one field an audit reads.',\n }),\n approvedAt: schemaShape.approvedAt.dateSpec({\n meaning: 'When the tenant administrator approved.',\n whyItMatters: 'Fixes the consent moment relative to the access that followed — a reviewer needs to see that approval preceded use, not merely that both happened.',\n temporalRole: 'occurred',\n }),\n autoApprovalReason: schemaShape.autoApprovalReason.enumSpec({\n meaning: 'Why this grant became ACTIVE with no tenant administrator acting.',\n whyItMatters: 'Present exactly when nobody in the tenant consented, so its ABSENCE on an ACTIVE grant is itself evidence that a human approved. That distinction is what a customer audit asks for, and precisely what a single `approved: true` boolean would erase.',\n enumDeclaration: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'PlatformAccessGrantAutoApprovalReason',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n values: {\n [PlatformAccessGrantAutoApprovalReason.TENANT_APPROVAL_NOT_REQUIRED]: { meaning: 'The tenant has not opted into approval — the default posture, matching Lockbox being opt-in so a tenant that never staffed an approver can still receive support.' },\n [PlatformAccessGrantAutoApprovalReason.TENANT_CANNOT_APPROVE]: { meaning: 'The tenant has NO administratively usable owner, so no principal exists who could approve. Recorded at high severity: this is the one path where operator access proceeds against a tenant that never consented and never could.' },\n },\n }),\n decisionReason: schemaShape.decisionReason.stringSpec({\n meaning: 'The tenant\\'s reason for refusing, or the revoker\\'s reason for withdrawing.',\n whyItMatters: 'Optional, unlike `justification`: a refusal owes no explanation, whereas a request does. When supplied it is the tenant\\'s side of the record.',\n }),\n createdAt: schemaShape.createdAt.dateSpec({\n meaning: 'When the elevation was requested.',\n whyItMatters: 'The start of the window a reviewer reconstructs, and the ordering key for a tenant listing its elevation history.',\n temporalRole: 'creation',\n }),\n updatedAt: schemaShape.updatedAt.dateSpec({\n meaning: 'When the row last changed — that is, when it was last decided upon.',\n whyItMatters: 'On this resource an update is always a lifecycle decision, since there is no generic UPDATE door.',\n temporalRole: 'modified',\n }),\n },\n\n operations: {\n [Op.READ]: {\n purpose: 'Inspect one temporary support-access request for your organization.',\n outcome: 'The response identifies who requested access, their justification, the requested window and the current decision state.',\n whenToUse: 'An organization administrator is reviewing a pending request or reconstructing an earlier support-access decision.',\n importance: FieldSemanticImportance.PRIMARY,\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The support-access request was found and returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller does not hold the organization-administrator authority required to review support access.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No request with the supplied id is visible in the caller\\'s organization. Missing and other organizations\\' requests are indistinguishable.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Inspect a pending support-access request',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n platformAccessGrantId: PLATFORM_ACCESS_PENDING_GRANT_ID,\n },\n response: platformAccessPendingGrantExample,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n context: {\n examples: [{\n title: 'Inspect a request with its organization context',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n platformAccessGrantId: PLATFORM_ACCESS_PENDING_GRANT_ID,\n },\n response: {\n ...platformAccessPendingGrantExample,\n organization: { _id: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID },\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n summary: {\n examples: [{\n title: 'Inspect the compact request summary',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n platformAccessGrantId: PLATFORM_ACCESS_PENDING_GRANT_ID,\n },\n response: platformAccessPendingGrantSummaryExample,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n },\n [Op.LIST]: {\n purpose: 'List temporary support-access requests for your organization.',\n outcome: 'The response provides the organization\\'s support-access history and the current state of each request.',\n whenToUse: 'An access-review screen, approval queue or audit preparation workflow needs the organization\\'s request inventory.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'A possibly empty page of the organization\\'s support-access requests.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller does not hold the organization-administrator authority required to review support access.' },\n ],\n idempotent: true,\n examples: [{\n title: 'List pending and active support-access requests',\n request: PLATFORM_ACCESS_PAGE_REQUEST,\n response: platformAccessGrantPage([\n platformAccessPendingGrantExample,\n platformAccessActiveGrantExample,\n ]),\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n context: {\n examples: [{\n title: 'List requests with organization context',\n request: PLATFORM_ACCESS_PAGE_REQUEST,\n response: platformAccessGrantPage([\n {\n ...platformAccessPendingGrantExample,\n organization: { _id: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID },\n },\n {\n ...platformAccessActiveGrantExample,\n organization: { _id: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID },\n },\n ]),\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n summary: {\n examples: [{\n title: 'List compact support-access summaries',\n request: PLATFORM_ACCESS_PAGE_REQUEST,\n response: platformAccessGrantPage([\n platformAccessPendingGrantSummaryExample,\n platformAccessActiveGrantSummaryExample,\n ]),\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n },\n [Op.COUNT]: {\n purpose: 'Count temporary support-access requests for your organization.',\n outcome: 'The response returns the matching request total without transferring the request records.',\n whenToUse: 'Dashboards and access reviews that need a current tally rather than request details.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The number of support-access requests matching the caller\\'s organization and filters.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller does not hold the organization-administrator authority required to review support access.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Count support-access requests',\n request: { organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID },\n response: { count: 2 },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n [Op.DELETE]: {\n purpose: 'PURGE ONLY — remove grant rows when their tenant is destroyed. There is deliberately no client door.',\n outcome: 'The row is hard-deleted. Reachable exclusively by the ORGANIZATIONS `onParentDelete` cascade during a tenant purge; its single variant is INTERNAL_CALL, so it has no HTTP route and no client — of either party — can invoke it.',\n whenToUse: 'Never directly. It exists so the composition cascade has a verb it can call: a child declaring `onParentDelete` while omitting DELETE fails the registry\\'s composition-cascade-deletability guard, and at runtime would abort the parent tenant\\'s deletion the moment a grant row existed.',\n responseStatuses: [\n { code: HttpResponseStatusCode.NO_CONTENT_204, meaning: 'The grant row was removed as part of its tenant\\'s purge. Not observable over HTTP — the operation has no route.' },\n ],\n idempotent: true,\n },\n [PlatformAccessGrants_Operations.REQUEST_ACCESS]: {\n operationId: PlatformAccessGrants_Operations.REQUEST_ACCESS,\n purpose: 'Request time-boxed support access to one organization.',\n outcome: 'A request is recorded with the authenticated support operator as requester and a maximum four-hour window. Its status is `pending_approval` when the organization requires approval, otherwise `active` with an explicit automatic-approval reason. The organization is notified by email.',\n whenToUse: 'An authorized application support operator needs temporary access for support, incident response or administrative recovery.',\n importance: FieldSemanticImportance.PRIMARY,\n responseStatuses: [\n { code: HttpResponseStatusCode.CREATED_201, meaning: 'The support-access request was recorded. Its `status` tells the operator whether access is active or awaiting an organization administrator\\'s decision.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The request body omits a non-empty `justification` or supplies a non-positive `requestedDurationMinutes`. The target organization is the required URL path parameter, not a duplicated body field. Durations above four hours are accepted but capped at four hours.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller does not hold the application super-administrator authority required to request support access.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No organization exists for the supplied `organizationId`.' },\n ],\n idempotent: false,\n examples: [{\n title: 'Request two hours of support access',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n justification: platformAccessPendingGrantExample.justification,\n requestedDurationMinutes: 120,\n },\n response: platformAccessPendingGrantExample,\n forStatus: HttpResponseStatusCode.CREATED_201,\n }],\n communications: {\n email: {\n purpose: 'Tell the target tenant that a platform operator has asked to reach into their organization — before it happens, not after.',\n tone: TENANT_CONSENT_TONE,\n useWhen: 'An operator requests an elevation against this tenant, whether or not the tenant has opted into approval.',\n avoidWhen: 'Never suppressed. Under the approval posture this message IS the request, so withholding it would give a tenant a decision it never hears about; under the default posture it is the only notice the tenant gets that access was taken.',\n textSlots: {\n subject: {\n purpose: 'State in the subject line that a platform operator has requested access to this organization, and whether a decision is being asked for.',\n },\n },\n eventData: {\n purpose: 'Carry the operator\\'s identity, the justification they supplied verbatim, the window they were granted, and whether the tenant must approve before the access becomes usable.',\n },\n deliveries: [\n {\n audience: TENANT_CONSENT_AUDIENCE,\n targetRef: CoreUserNotificationTarget.ORGANIZATION_USERS,\n },\n ],\n notes: [\n 'Mirrors the single `userNotifications[]` entry declared on the runtime `requestAccess` operation (target=ORGANIZATION_USERS, channel=EMAIL). It is the only communication this resource emits — `approve`, `deny` and `revoke` declare none.',\n ],\n },\n },\n },\n [PlatformAccessGrants_Operations.APPROVE]: {\n operationId: PlatformAccessGrants_Operations.APPROVE,\n purpose: 'Approve a pending support-access request.',\n outcome: 'The request becomes `active`; the response records the approving administrator and decision time. Access remains usable only until it expires or is revoked.',\n whenToUse: 'An administrator of the requested organization has reviewed the requester, justification and time window and agrees to grant access.',\n importance: FieldSemanticImportance.PRIMARY,\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The support-access request is now active, and its updated state is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not an administrator of the organization the request targets. A support operator cannot approve their own request.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No request with the supplied id is visible in the caller\\'s organization.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'The request is no longer `pending_approval`; an approved, denied, revoked or expired request cannot be approved again.' },\n ],\n idempotent: false,\n examples: [{\n title: 'Approve a reviewed support request',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n platformAccessGrantId: PLATFORM_ACCESS_PENDING_GRANT_ID,\n decisionReason: 'Approved for support case INC-4821.',\n },\n response: platformAccessActiveGrantExample,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n [PlatformAccessGrants_Operations.DENY]: {\n operationId: PlatformAccessGrants_Operations.DENY,\n purpose: 'Deny a pending support-access request.',\n outcome: 'The request becomes `denied` and cannot be retried. Any later support need requires a new request.',\n whenToUse: 'An administrator of the requested organization has reviewed the request and declines access.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The support-access request was denied, and its final state is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not an administrator of the organization the request targets. A support operator cannot decide their own request.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No request with the supplied id is visible in the caller\\'s organization.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'The request is no longer `pending_approval`; it was already approved, denied, revoked or has expired.' },\n ],\n idempotent: false,\n examples: [{\n title: 'Deny a support request',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n platformAccessGrantId: PLATFORM_ACCESS_PENDING_GRANT_ID,\n decisionReason: 'The requested investigation is no longer required.',\n },\n response: {\n ...platformAccessPendingGrantExample,\n status: PlatformAccessGrantStatus.DENIED,\n decisionReason: 'The requested investigation is no longer required.',\n updatedAt: '2026-08-20T12:06:00.000Z',\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n [PlatformAccessGrants_Operations.REVOKE]: {\n operationId: PlatformAccessGrants_Operations.REVOKE,\n purpose: 'End pending or active support access early.',\n outcome: 'The request becomes `revoked` and access stops immediately instead of remaining available until the recorded expiry.',\n whenToUse: 'An organization withdraws access it approved, or an application support operator closes access as soon as the support work is complete.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The support-access request was revoked, and its final state is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is neither an administrator of the requested organization nor an application super-administrator.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No request with the supplied id is visible to the caller.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'The request is already denied, revoked or expired. Only a `pending_approval` or `active` request can be revoked.' },\n ],\n idempotent: false,\n examples: [{\n title: 'Close support access after the investigation',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n platformAccessGrantId: PLATFORM_ACCESS_ACTIVE_GRANT_ID,\n decisionReason: 'Support case INC-4821 is resolved.',\n },\n response: {\n ...platformAccessActiveGrantExample,\n status: PlatformAccessGrantStatus.REVOKED,\n decisionReason: 'Support case INC-4821 is resolved.',\n updatedAt: '2026-08-20T12:42:00.000Z',\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n\n businessConstraints: [\n 'A grant is required IN ADDITION to the operation variant\\'s `admitsCrossTenantPlatformAdministration` declaration, never instead of it. The declaration says \"this verb MAY cross\"; the grant says \"this operator MAY cross into THIS tenant, until THIS time, for THIS reason\". Neither is sufficient alone, and the roles gate runs independently of both.',\n '`requestAccess` is EXEMPT from the grant requirement it bootstraps. Gating it would be circular — an operator would need an elevation in order to ask for one — and the mechanism could never start. The exemption is safe because requesting is not accessing: the verb writes one row in the target tenant and touches nothing else, so the blast radius of an abused request is a notification, an audit row naming the operator, and a decision the tenant can refuse.',\n 'Usability is EVALUATED, never read off `status`. A grant counts only when it is ACTIVE and its `expiresAt` is still in the future, checked through the single shared predicate. A background transition to EXPIRED is bookkeeping for humans; if usability were read from the label alone, an outage in whatever performs that transition would silently restore standing access.',\n 'The 4-hour ceiling is enforced server-side by CLAMPING, not by refusing. A caller asking for longer simply gets the ceiling — being told \"ask again with a smaller number\" mid-incident is friction with no security benefit, since the ceiling is what actually binds.',\n 'Tenant approval is opt-in PER TENANT, matching Lockbox rather than a deployment-wide posture, so a tenant that has not staffed an approver is not thereby unable to receive support.',\n 'A tenant with no administratively usable owner cannot be required to approve its own repair — that is circular, and the administrative-continuity floors exist precisely because a tenant can reach that state. It is resolved by MEASUREMENT rather than exception: the grant is auto-approved with `TENANT_CANNOT_APPROVE`, evaluated with the SAME predicate the owner floor uses to refuse writes, so the two subsystems can never disagree about whether a tenant can administer itself. An operator cannot manufacture the condition either — stranding a tenant is exactly what the floors refuse.',\n 'Terminal statuses are how a grant ends. DENIED, EXPIRED and REVOKED are never edited back to life, and the row is never erased by either party: an elevation record either side could delete is not evidence. The only removal path is the tenant purge cascade, which destroys the tenant the record was about.',\n ],\n }),\n { resourcePrimaryScope: ResourcePrimaryScope.ORGANIZATIONS },\n);\n"]}
|
|
1
|
+
{"version":3,"file":"platform-access-grants.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/auth/resources/platform-access-grants.resource.specification.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;GAwBG;AAEH,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AACpE,OAAO,EACL,mBAAmB,EACnB,cAAc,EACd,uBAAuB,GACxB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EACL,qBAAqB,IAAI,EAAE,EAC3B,0BAA0B,EAC1B,qCAAqC,EACrC,yBAAyB,EACzB,yBAAyB,EACzB,+BAA+B,EAC/B,oBAAoB,EACpB,+DA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,CAAC,MAAM,EAAE,OAAO,EAAE,0EAA0E,EAAE;aAC7H;YACD,cAAc,EAAE;gBACd,EAAE,IAAI,EAAE,sBAAsB,CAAC,aAAa,EAAE,IAAI,EAAE,8GAA8G,EAAE;gBACpK,EAAE,IAAI,EAAE,sBAAsB,CAAC,aAAa,EAAE,IAAI,EAAE,2DAA2D,EAAE;gBACjH,EAAE,IAAI,EAAE,sBAAsB,CAAC,YAAY,EAAE,IAAI,EAAE,kHAAkH,EAAE;aACxK;YACD,UAAU,EAAE,KAAK;YACjB,QAAQ,EAAE,CAAC;oBACT,KAAK,EAAE,8CAA8C;oBACrD,OAAO,EAAE;wBACP,cAAc,EAAE,uCAAuC;wBACvD,qBAAqB,EAAE,+BAA+B;wBACtD,cAAc,EAAE,oCAAoC;qBACrD;oBACD,QAAQ,EAAE;wBACR,GAAG,gCAAgC;wBACnC,MAAM,EAAE,yBAAyB,CAAC,OAAO;wBACzC,cAAc,EAAE,oCAAoC;wBACpD,SAAS,EAAE,0BAA0B;qBACtC;oBACD,SAAS,EAAE,sBAAsB,CAAC,MAAM;iBACzC,CAAC;SACH;KACF;IAED,mBAAmB,EAAE;QACnB,8VAA8V;QAC9V,4cAA4c;QAC5c,mXAAmX;QACnX,yQAAyQ;QACzQ,sLAAsL;QACtL,2kBAA2kB;QAC3kB,kTAAkT;KACnT;CACF,CAAC,EACF,EAAE,oBAAoB,EAAE,oBAAoB,CAAC,aAAa,EAAE,CAC7D,CAAC","sourcesContent":["/**\n * Resource: `platformAccessGrants` — Wildo SaaS engine specification (backend-only, organization-scoped).\n *\n * Inputs:\n * - Schema: engine/saas-models/src/security/authorizations/platform-access-grants.shared.schemas.ts\n * → `PlatformAccessGrantSchema`\n * - Factory: engine/saas-models/src/security/authorizations/platform-access-grants.shared.resources-config.schemas.ts\n * → `platformAccessGrantsResourceConfiguration_InitializationFactory`\n * - Custom operations: `PlatformAccessGrants_Operations` (co-located with the VOCABULARY, in the\n * schemas module rather than the resources-config module — the authorization layer needs\n * `REQUEST_ACCESS` by name, and importing it from the config would drag resource-configuration\n * evaluation into the authorizer's module graph). Both modules are re-exported from the package\n * root, so this spec imports every symbol from `@wildo-ai/saas-models` and is unaffected either way.\n *\n * Why backend-only: there is NO entry for `[CoreResourceType.PLATFORM_ACCESS_GRANTS]` in any preset\n * under engine/presets-components/src/config/resources/. The tenant-facing approval surface is not\n * built yet; today the resource is consumed by the authorizer's admission predicate and by the\n * platform/tenant API.\n *\n * Why `ORGANIZATIONS` scope: the grant belongs to the tenant being reached INTO, not to the operator\n * who asked. That is what lets the tenant read, approve and revoke elevations raised against it — a\n * consent record the consenting party cannot see would defeat the purpose of modelling consent. The\n * scope is expressed once, in the registry relationship ORGANIZATIONS → PLATFORM_ACCESS_GRANTS\n * carrying `isPrimaryScope: true`; the runtime config deliberately does not restate it.\n */\n\nimport { LabelAudience } from '@wildo-ai/presets-components-models';\nimport {\n CodeDeclarationKind,\n CodeSymbolKind,\n FieldSemanticImportance,\n} from '@wildo-ai/zod-decorators';\nimport {\n CoreResourceOperation as Op,\n CoreUserNotificationTarget,\n PlatformAccessGrantAutoApprovalReason,\n PlatformAccessGrantSchema,\n PlatformAccessGrantStatus,\n PlatformAccessGrants_Operations,\n ResourcePrimaryScope,\n platformAccessGrantsResourceConfiguration_InitializationFactory,\n} from '@wildo-ai/saas-models';\nimport { HttpResponseStatusCode, resourceSpecification } from '~wildo-specifications/_core';\nimport { EngineResourceSubDomain } from '../../engine-resource-sub-domain';\n\nconst TENANT_CONSENT_AUDIENCE = 'Administrators of the TARGET tenant — the party whose data is about to be reached into, and the only party who can refuse.';\nconst TENANT_CONSENT_TONE = 'Direct and factual, and never reassuring by omission: name the operator, the reason they gave, and the window they asked for, so the recipient can decide rather than merely be informed.';\n\nconst PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID = 'org_01J4P8F1M2N3Q4R5S6T7V8W9XY';\nconst PLATFORM_ACCESS_PENDING_GRANT_ID = 'platform_access_grant_01J4P8K2N3Q4R5S6T7V8W9X0YZ';\nconst PLATFORM_ACCESS_ACTIVE_GRANT_ID = 'platform_access_grant_01J4P8M3Q4R5S6T7V8W9X0Y1ZA';\nconst PLATFORM_ACCESS_OPERATOR_USER_ID = 'user_01J4P8P4R5S6T7V8W9X0Y1Z2AB';\nconst PLATFORM_ACCESS_APPROVER_USER_ID = 'user_01J4P8R5S6T7V8W9X0Y1Z2A3BC';\n\nconst platformAccessPendingGrantExample = {\n _id: PLATFORM_ACCESS_PENDING_GRANT_ID,\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n operatorUserId: PLATFORM_ACCESS_OPERATOR_USER_ID,\n justification: 'Investigate failed SCIM provisioning for support case INC-4821.',\n status: PlatformAccessGrantStatus.PENDING_APPROVAL,\n expiresAt: '2026-08-20T14:00:00.000Z',\n createdAt: '2026-08-20T12:00:00.000Z',\n updatedAt: '2026-08-20T12:00:00.000Z',\n};\n\nconst platformAccessActiveGrantExample = {\n ...platformAccessPendingGrantExample,\n _id: PLATFORM_ACCESS_ACTIVE_GRANT_ID,\n status: PlatformAccessGrantStatus.ACTIVE,\n approvedByUserId: PLATFORM_ACCESS_APPROVER_USER_ID,\n approvedAt: '2026-08-20T12:08:00.000Z',\n updatedAt: '2026-08-20T12:08:00.000Z',\n};\n\nconst platformAccessPendingGrantSummaryExample = {\n _id: platformAccessPendingGrantExample._id,\n organizationId: platformAccessPendingGrantExample.organizationId,\n operatorUserId: platformAccessPendingGrantExample.operatorUserId,\n justification: platformAccessPendingGrantExample.justification,\n status: platformAccessPendingGrantExample.status,\n expiresAt: platformAccessPendingGrantExample.expiresAt,\n};\n\nconst platformAccessActiveGrantSummaryExample = {\n ...platformAccessPendingGrantSummaryExample,\n _id: platformAccessActiveGrantExample._id,\n status: platformAccessActiveGrantExample.status,\n};\n\nconst PLATFORM_ACCESS_PAGE_REQUEST = {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n page: 1,\n limit: 20,\n sort: 'createdAt:desc',\n};\n\nfunction platformAccessGrantPage<T>(data: readonly T[]) {\n return {\n data,\n pagination: {\n page: 1,\n limit: 20,\n total: data.length,\n totalPages: data.length === 0 ? 0 : 1,\n },\n };\n}\n\nexport const platformAccessGrantsResourceSpecification = resourceSpecification(\n platformAccessGrantsResourceConfiguration_InitializationFactory,\n PlatformAccessGrantSchema,\n ({ schemaShape }) => ({\n purpose: 'Give an application support team a justified, time-limited way to request access to an organization while keeping that organization informed and in control of the decision.',\n businessRole: 'The organization\\'s support-access ledger. It answers who requested access, why they requested it, how long the window lasts, whether an administrator approved it and when access ended.',\n lifecycleRole: 'An authorized support operator creates a request. It waits for an organization administrator when approval is required, or becomes active immediately with an explicit automatic-approval reason. An administrator can approve or deny a pending request; either side can revoke pending or active access; expiry ends access automatically. Completed requests remain available as access-review history.',\n audience: LabelAudience.ADMIN,\n subDomain: EngineResourceSubDomain.AUTH,\n\n codeHandling: {\n mainSchema: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'PlatformAccessGrantSchema',\n symbolKind: CodeSymbolKind.SCHEMA,\n declarationKind: CodeDeclarationKind.ZOD_SCHEMA,\n },\n resourceFactory: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'platformAccessGrantsResourceConfiguration_InitializationFactory',\n symbolKind: CodeSymbolKind.FACTORY,\n declarationKind: CodeDeclarationKind.FUNCTION,\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: 'PLATFORM_ACCESS_GRANTS',\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 customEnum: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'PlatformAccessGrants_Operations',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n },\n notes: [\n 'No public CREATE or UPDATE. `requestAccess` is the only writer of a new row, and `approve` / `deny` / `revoke` are the only status transitions. A generic UPDATE would be a second, ungated path to those transitions; a generic CREATE would let a caller author `status`, `expiresAt` and `operatorUserId`, which are precisely the fields whose SERVER authorship is the control.',\n 'DELETE exists but has NO client door — its single variant is INTERNAL_CALL, mirroring `organizations.delete`\\'s own default. It is present only so the ORGANIZATIONS composition cascade (`onParentDelete`) has a verb it can call; a cascade declared but unable to run fails the registry\\'s composition-cascade-deletability guard, and would otherwise leave grant rows behind after their tenant was purged.',\n 'The runtime declares exactly ONE `userNotifications[]` entry, on `requestAccess` (target=ORGANIZATION_USERS, channel=EMAIL). There are no `m2mNotifications` anywhere in this family, so no `communications.m2m` block appears on any operation (DF-1 strict parity).',\n 'The grant LIFECYCLE audit events (requested / approved / denied / revoked) are not emitted yet — see `.claude/plans/platform-access-grants-jit-elevation.md` R7. The crossing itself is already audited by `CoreAuditableEventType.CROSS_TENANT_ADMINISTRATIVE_ACCESS`, emitted from the authorizer rather than from this resource.',\n ],\n },\n\n fields: {\n _id: schemaShape._id.stringSpec({\n meaning: 'Identifier for one elevation request.',\n whyItMatters: 'The address of every subsequent decision — approve, deny and revoke all target this row, and the audit trail names it.',\n semanticRole: 'identifier',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n organizationId: schemaShape.organizationId.foreignKeySpec({\n meaning: 'The TARGET tenant — the organization being reached into, never the operator\\'s own.',\n whyItMatters: 'The scope anchor. It makes the grant an organization-scoped row, which is what lets the tenant see, approve and revoke elevations raised against it, and it is the tenant the admission predicate matches a crossing against.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n operatorUserId: schemaShape.operatorUserId.foreignKeySpec({\n meaning: 'The platform operator who requested the elevation.',\n whyItMatters: 'Server-authored from the session, never client-supplied — an elevation whose subject the caller could choose would let one operator mint access for another. Together with `organizationId` it forms the pair the admission predicate matches: this operator, into this tenant.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n justification: schemaShape.justification.stringSpec({\n meaning: 'Why the operator needs access, in their own words.',\n whyItMatters: 'Required everywhere in the flow and deliberately never optional. An elevation record without a reason answers \"who\" and \"when\" but not \"why\", which is the only question a reviewer or a customer actually asks; NIST SP 800-53 AC-2(7) wants privileged assignment MONITORED, and an unexplained monitored assignment is a log line rather than a control.',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n status: schemaShape.status.enumSpec({\n meaning: 'Where this elevation is in its lifecycle.',\n whyItMatters: 'Read together with `expiresAt`, never alone: the admission predicate accepts ACTIVE and then re-checks the window, so a grant whose window elapsed stops working whether or not anything has relabelled it.',\n importance: FieldSemanticImportance.PRIMARY,\n enumDeclaration: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'PlatformAccessGrantStatus',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n values: {\n [PlatformAccessGrantStatus.PENDING_APPROVAL]: { meaning: 'Awaiting a decision from an administrator of the target tenant — the Lockbox posture. The elevation does NOT work in this state.' },\n [PlatformAccessGrantStatus.ACTIVE]: { meaning: 'Usable now, and only while unexpired. The one status the admission predicate accepts.' },\n [PlatformAccessGrantStatus.DENIED]: { meaning: 'The tenant refused. Terminal — a fresh request must be raised rather than this one retried.' },\n [PlatformAccessGrantStatus.EXPIRED]: { meaning: 'The window elapsed. Terminal, and reached WITHOUT a writer: this label is bookkeeping for humans and reporting, never the control that stops the access.' },\n [PlatformAccessGrantStatus.REVOKED]: { meaning: 'Withdrawn before expiry, by either the tenant or the platform. Terminal.' },\n },\n }),\n expiresAt: schemaShape.expiresAt.dateSpec({\n meaning: 'When the elevation stops working.',\n whyItMatters: 'The actual control, and the reason this is a time-bound grant rather than a renamed standing privilege. Server-authored from the requested duration and clamped to a 4-hour ceiling, so a client cannot mint a long-lived elevation by asking for one. The admission predicate compares against it directly, which is why expiry needs no sweeper to take effect.',\n temporalRole: 'expiration',\n importance: FieldSemanticImportance.PRIMARY,\n }),\n approvedByUserId: schemaShape.approvedByUserId.foreignKeySpec({\n meaning: 'The tenant administrator who approved, when a human in the tenant did.',\n whyItMatters: 'Absent on an auto-approved grant, which is what makes its presence meaningful: it distinguishes \"someone here agreed\" from \"nobody needed to\". Written only by `approve` — `deny` and `revoke` deliberately leave it alone, because writing a refusal into the approver field would corrupt the one field an audit reads.',\n }),\n approvedAt: schemaShape.approvedAt.dateSpec({\n meaning: 'When the tenant administrator approved.',\n whyItMatters: 'Fixes the consent moment relative to the access that followed — a reviewer needs to see that approval preceded use, not merely that both happened.',\n temporalRole: 'occurred',\n }),\n autoApprovalReason: schemaShape.autoApprovalReason.enumSpec({\n meaning: 'Why this grant became ACTIVE with no tenant administrator acting.',\n whyItMatters: 'Present exactly when nobody in the tenant consented, so its ABSENCE on an ACTIVE grant is itself evidence that a human approved. That distinction is what a customer audit asks for, and precisely what a single `approved: true` boolean would erase.',\n enumDeclaration: {\n packageName: '@wildo-ai/saas-models',\n exportName: 'PlatformAccessGrantAutoApprovalReason',\n symbolKind: CodeSymbolKind.ENUM,\n declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM,\n },\n values: {\n [PlatformAccessGrantAutoApprovalReason.TENANT_APPROVAL_NOT_REQUIRED]: { meaning: 'The tenant has not opted into approval — the default posture, matching Lockbox being opt-in so a tenant that never staffed an approver can still receive support.' },\n [PlatformAccessGrantAutoApprovalReason.TENANT_CANNOT_APPROVE]: { meaning: 'The tenant has NO administratively usable owner, so no principal exists who could approve. Recorded at high severity: this is the one path where operator access proceeds against a tenant that never consented and never could.' },\n },\n }),\n decisionReason: schemaShape.decisionReason.stringSpec({\n meaning: 'The tenant\\'s reason for refusing, or the revoker\\'s reason for withdrawing.',\n whyItMatters: 'Optional, unlike `justification`: a refusal owes no explanation, whereas a request does. When supplied it is the tenant\\'s side of the record.',\n }),\n createdAt: schemaShape.createdAt.dateSpec({\n meaning: 'When the elevation was requested.',\n whyItMatters: 'The start of the window a reviewer reconstructs, and the ordering key for a tenant listing its elevation history.',\n temporalRole: 'creation',\n }),\n updatedAt: schemaShape.updatedAt.dateSpec({\n meaning: 'When the row last changed — that is, when it was last decided upon.',\n whyItMatters: 'On this resource an update is always a lifecycle decision, since there is no generic UPDATE door.',\n temporalRole: 'modified',\n }),\n },\n\n operations: {\n [Op.READ]: {\n purpose: 'Inspect one temporary support-access request for your organization.',\n outcome: 'The response identifies who requested access, their justification, the requested window and the current decision state.',\n whenToUse: 'An organization administrator is reviewing a pending request or reconstructing an earlier support-access decision.',\n importance: FieldSemanticImportance.PRIMARY,\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The support-access request was found and returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller does not hold the organization-administrator authority required to review support access.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No request with the supplied id is visible in the caller\\'s organization. Missing and other organizations\\' requests are indistinguishable.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Inspect a pending support-access request',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n platformAccessGrantId: PLATFORM_ACCESS_PENDING_GRANT_ID,\n },\n response: platformAccessPendingGrantExample,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n context: {\n examples: [{\n title: 'Inspect a request with its organization context',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n platformAccessGrantId: PLATFORM_ACCESS_PENDING_GRANT_ID,\n },\n response: {\n ...platformAccessPendingGrantExample,\n organization: { _id: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID },\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n summary: {\n examples: [{\n title: 'Inspect the compact request summary',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n platformAccessGrantId: PLATFORM_ACCESS_PENDING_GRANT_ID,\n },\n response: platformAccessPendingGrantSummaryExample,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n },\n [Op.LIST]: {\n purpose: 'List temporary support-access requests for your organization.',\n outcome: 'The response provides the organization\\'s support-access history and the current state of each request.',\n whenToUse: 'An access-review screen, approval queue or audit preparation workflow needs the organization\\'s request inventory.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'A possibly empty page of the organization\\'s support-access requests.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller does not hold the organization-administrator authority required to review support access.' },\n ],\n idempotent: true,\n examples: [{\n title: 'List pending and active support-access requests',\n request: PLATFORM_ACCESS_PAGE_REQUEST,\n response: platformAccessGrantPage([\n platformAccessPendingGrantExample,\n platformAccessActiveGrantExample,\n ]),\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n context: {\n examples: [{\n title: 'List requests with organization context',\n request: PLATFORM_ACCESS_PAGE_REQUEST,\n response: platformAccessGrantPage([\n {\n ...platformAccessPendingGrantExample,\n organization: { _id: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID },\n },\n {\n ...platformAccessActiveGrantExample,\n organization: { _id: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID },\n },\n ]),\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n summary: {\n examples: [{\n title: 'List compact support-access summaries',\n request: PLATFORM_ACCESS_PAGE_REQUEST,\n response: platformAccessGrantPage([\n platformAccessPendingGrantSummaryExample,\n platformAccessActiveGrantSummaryExample,\n ]),\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n },\n [Op.COUNT]: {\n purpose: 'Count temporary support-access requests for your organization.',\n outcome: 'The response returns the matching request total without transferring the request records.',\n whenToUse: 'Dashboards and access reviews that need a current tally rather than request details.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The number of support-access requests matching the caller\\'s organization and filters.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller does not hold the organization-administrator authority required to review support access.' },\n ],\n idempotent: true,\n examples: [{\n title: 'Count support-access requests',\n request: { organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID },\n response: { count: 2 },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n [Op.DELETE]: {\n purpose: 'PURGE ONLY — remove grant rows when their tenant is destroyed. There is deliberately no client door.',\n outcome: 'The row is hard-deleted. Reachable exclusively by the ORGANIZATIONS `onParentDelete` cascade during a tenant purge; its single variant is INTERNAL_CALL, so it has no HTTP route and no client — of either party — can invoke it.',\n whenToUse: 'Never directly. It exists so the composition cascade has a verb it can call: a child declaring `onParentDelete` while omitting DELETE fails the registry\\'s composition-cascade-deletability guard, and at runtime would abort the parent tenant\\'s deletion the moment a grant row existed.',\n responseStatuses: [\n { code: HttpResponseStatusCode.NO_CONTENT_204, meaning: 'The grant row was removed as part of its tenant\\'s purge. Not observable over HTTP — the operation has no route.' },\n ],\n idempotent: true,\n },\n [PlatformAccessGrants_Operations.REQUEST_ACCESS]: {\n operationId: PlatformAccessGrants_Operations.REQUEST_ACCESS,\n purpose: 'Request time-boxed support access to one organization.',\n outcome: 'A request is recorded with the authenticated support operator as requester and a maximum four-hour window. Its status is `pending_approval` when the organization requires approval, otherwise `active` with an explicit automatic-approval reason. The organization is notified by email.',\n whenToUse: 'An authorized application support operator needs temporary access for support, incident response or administrative recovery.',\n importance: FieldSemanticImportance.PRIMARY,\n responseStatuses: [\n { code: HttpResponseStatusCode.CREATED_201, meaning: 'The support-access request was recorded. Its `status` tells the operator whether access is active or awaiting an organization administrator\\'s decision.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The request body omits a non-empty `justification` or supplies a non-positive `requestedDurationMinutes`. The target organization is the required URL path parameter, not a duplicated body field. Durations above four hours are accepted but capped at four hours.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller does not hold the application super-administrator authority required to request support access.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No organization exists for the supplied `organizationId`.' },\n ],\n idempotent: false,\n examples: [{\n title: 'Request two hours of support access',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n justification: platformAccessPendingGrantExample.justification,\n requestedDurationMinutes: 120,\n },\n response: platformAccessPendingGrantExample,\n forStatus: HttpResponseStatusCode.CREATED_201,\n }],\n communications: {\n email: {\n purpose: 'Tell the target tenant that a platform operator has asked to reach into their organization — before it happens, not after.',\n tone: TENANT_CONSENT_TONE,\n useWhen: 'An operator requests an elevation against this tenant, whether or not the tenant has opted into approval.',\n avoidWhen: 'Never suppressed. Under the approval posture this message IS the request, so withholding it would give a tenant a decision it never hears about; under the default posture it is the only notice the tenant gets that access was taken.',\n textSlots: {\n subject: {\n purpose: 'State in the subject line that a platform operator has requested access to this organization, and whether a decision is being asked for.',\n },\n },\n eventData: {\n purpose: 'Carry the operator\\'s identity, the justification they supplied verbatim, the window they were granted, and whether the tenant must approve before the access becomes usable.',\n },\n deliveries: [\n {\n audience: TENANT_CONSENT_AUDIENCE,\n targetRef: CoreUserNotificationTarget.ORGANIZATION_USERS,\n },\n ],\n notes: [\n 'Mirrors the single `userNotifications[]` entry declared on the runtime `requestAccess` operation (target=ORGANIZATION_USERS, channel=EMAIL). It is the only communication this resource emits — `approve`, `deny` and `revoke` declare none.',\n ],\n },\n },\n },\n [PlatformAccessGrants_Operations.APPROVE]: {\n operationId: PlatformAccessGrants_Operations.APPROVE,\n purpose: 'Approve a pending support-access request.',\n outcome: 'The request becomes `active`; the response records the approving administrator and decision time. Access remains usable only until it expires or is revoked.',\n whenToUse: 'An administrator of the requested organization has reviewed the requester, justification and time window and agrees to grant access.',\n importance: FieldSemanticImportance.PRIMARY,\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The support-access request is now active, and its updated state is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not an administrator of the organization the request targets. A support operator cannot approve their own request.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No request with the supplied id is visible in the caller\\'s organization.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'The request is no longer `pending_approval`; an approved, denied, revoked or expired request cannot be approved again.' },\n ],\n idempotent: false,\n examples: [{\n title: 'Approve a reviewed support request',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n platformAccessGrantId: PLATFORM_ACCESS_PENDING_GRANT_ID,\n decisionReason: 'Approved for support case INC-4821.',\n },\n response: platformAccessActiveGrantExample,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n [PlatformAccessGrants_Operations.DENY]: {\n operationId: PlatformAccessGrants_Operations.DENY,\n purpose: 'Deny a pending support-access request.',\n outcome: 'The request becomes `denied` and cannot be retried. Any later support need requires a new request.',\n whenToUse: 'An administrator of the requested organization has reviewed the request and declines access.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The support-access request was denied, and its final state is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not an administrator of the organization the request targets. A support operator cannot decide their own request.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No request with the supplied id is visible in the caller\\'s organization.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'The request is no longer `pending_approval`; it was already approved, denied, revoked or has expired.' },\n ],\n idempotent: false,\n examples: [{\n title: 'Deny a support request',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n platformAccessGrantId: PLATFORM_ACCESS_PENDING_GRANT_ID,\n decisionReason: 'The requested investigation is no longer required.',\n },\n response: {\n ...platformAccessPendingGrantExample,\n status: PlatformAccessGrantStatus.DENIED,\n decisionReason: 'The requested investigation is no longer required.',\n updatedAt: '2026-08-20T12:06:00.000Z',\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n [PlatformAccessGrants_Operations.REVOKE]: {\n operationId: PlatformAccessGrants_Operations.REVOKE,\n purpose: 'End pending or active support access early.',\n outcome: 'The request becomes `revoked` and access stops immediately instead of remaining available until the recorded expiry.',\n whenToUse: 'An organization withdraws access it approved, or an application support operator closes access as soon as the support work is complete.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The support-access request was revoked, and its final state is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is neither an administrator of the requested organization nor an application super-administrator.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No request with the supplied id is visible to the caller.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'The request is already denied, revoked or expired. Only a `pending_approval` or `active` request can be revoked.' },\n ],\n idempotent: false,\n examples: [{\n title: 'Close support access after the investigation',\n request: {\n organizationId: PLATFORM_ACCESS_EXAMPLE_ORGANIZATION_ID,\n platformAccessGrantId: PLATFORM_ACCESS_ACTIVE_GRANT_ID,\n decisionReason: 'Support case INC-4821 is resolved.',\n },\n response: {\n ...platformAccessActiveGrantExample,\n status: PlatformAccessGrantStatus.REVOKED,\n decisionReason: 'Support case INC-4821 is resolved.',\n updatedAt: '2026-08-20T12:42:00.000Z',\n },\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n\n businessConstraints: [\n 'A grant is required IN ADDITION to the operation variant\\'s `admitsCrossTenantPlatformAdministration` declaration, never instead of it. The declaration says \"this verb MAY cross\"; the grant says \"this operator MAY cross into THIS tenant, until THIS time, for THIS reason\". Neither is sufficient alone, and the roles gate runs independently of both.',\n '`requestAccess` is EXEMPT from the grant requirement it bootstraps. Gating it would be circular — an operator would need an elevation in order to ask for one — and the mechanism could never start. The exemption is safe because requesting is not accessing: the verb writes one row in the target tenant and touches nothing else, so the blast radius of an abused request is a notification, an audit row naming the operator, and a decision the tenant can refuse.',\n 'Usability is EVALUATED, never read off `status`. A grant counts only when it is ACTIVE and its `expiresAt` is still in the future, checked through the single shared predicate. A background transition to EXPIRED is bookkeeping for humans; if usability were read from the label alone, an outage in whatever performs that transition would silently restore standing access.',\n 'The 4-hour ceiling is enforced server-side by CLAMPING, not by refusing. A caller asking for longer simply gets the ceiling — being told \"ask again with a smaller number\" mid-incident is friction with no security benefit, since the ceiling is what actually binds.',\n 'Tenant approval is opt-in PER TENANT, matching Lockbox rather than a deployment-wide posture, so a tenant that has not staffed an approver is not thereby unable to receive support.',\n 'A tenant with no administratively usable owner cannot be required to approve its own repair — that is circular, and the administrative-continuity floors exist precisely because a tenant can reach that state. It is resolved by MEASUREMENT rather than exception: the grant is auto-approved with `TENANT_CANNOT_APPROVE`, evaluated with the SAME predicate the owner floor uses to refuse writes, so the two subsystems can never disagree about whether a tenant can administer itself. An operator cannot manufacture the condition either — stranding a tenant is exactly what the floors refuse.',\n 'Terminal statuses are how a grant ends. DENIED, EXPIRED and REVOKED are never edited back to life, and the row is never erased by either party: an elevation record either side could delete is not evidence. The only removal path is the tenant purge cascade, which destroys the tenant the record was about.',\n ],\n }),\n { resourcePrimaryScope: ResourcePrimaryScope.ORGANIZATIONS },\n);\n"]}
|
package/dist/esm/engine/auth/resources/scim-provisioning-config.resource.specification.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scim-provisioning-config.resource.specification.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/auth/resources/scim-provisioning-config.resource.specification.ts"],"names":[],"mappings":"AAIA,OAAO,EACL,qBAAqB,IAAI,EAAE,EAK5B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAML,KAAK,2BAA2B,EACjC,MAAM,6BAA6B,CAAC;
|
|
1
|
+
{"version":3,"file":"scim-provisioning-config.resource.specification.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/auth/resources/scim-provisioning-config.resource.specification.ts"],"names":[],"mappings":"AAIA,OAAO,EACL,qBAAqB,IAAI,EAAE,EAK5B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAML,KAAK,2BAA2B,EACjC,MAAM,6BAA6B,CAAC;AAuOrC,eAAO,MAAM,uDAAuD;;;;;;;;;;;;;;;;;;;;;iCAGnE,CAAC;AACF,eAAO,MAAM,sDAAsD;;;;;;;;;;;;;;;;;;;;;iCAGlE,CAAC"}
|
|
@@ -3,6 +3,7 @@ import { LabelAudience } from '@wildo-ai/presets-components-models';
|
|
|
3
3
|
import { CodeDeclarationKind, CodeSymbolKind, FieldSemanticImportance } from '@wildo-ai/zod-decorators';
|
|
4
4
|
import { CoreResourceOperation as Op, CoreResourceType, ResourcePrimaryScope, ScimProvisioningConfigBaseSchema, scimProvisioningConfigPolymorphicFactories, } from '@wildo-ai/saas-models';
|
|
5
5
|
import { HttpResponseStatusCode, mergeResourceFrontendConfigurations, resourceFrontendConfiguration, resourceSpecification, resourceSpecificationFromFrontendConfiguration, } from '../../../_core/index.js';
|
|
6
|
+
import { EngineResourceSubDomain } from '../../engine-resource-sub-domain.js';
|
|
6
7
|
function r(source, rt, name) {
|
|
7
8
|
const u = source[rt];
|
|
8
9
|
if (!u)
|
|
@@ -64,6 +65,7 @@ function buildBase(rt, member) {
|
|
|
64
65
|
businessRole: 'Controls how identity-provider directory data becomes application users and memberships, including the authorization defaults applied during provisioning.',
|
|
65
66
|
lifecycleRole: 'Configure it while connecting the identity provider, then review it whenever directory attributes, role policy, or user-lifecycle policy changes.',
|
|
66
67
|
audience: LabelAudience.DEVELOPER,
|
|
68
|
+
subDomain: EngineResourceSubDomain.AUTH,
|
|
67
69
|
codeHandling: {
|
|
68
70
|
mainSchema: { packageName: '@wildo-ai/saas-models', exportName: 'ScimProvisioningConfigBaseSchema', symbolKind: CodeSymbolKind.SCHEMA, declarationKind: CodeDeclarationKind.ZOD_SCHEMA },
|
|
69
71
|
resourceFactoryCollectionEntry: { collectionSymbol: { packageName: '@wildo-ai/saas-models', exportName: 'scimProvisioningConfigPolymorphicFactories', symbolKind: CodeSymbolKind.FACTORY }, identifierField: 'collectionKey', identifierValue: rt },
|
package/dist/esm/engine/auth/resources/scim-provisioning-config.resource.specification.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scim-provisioning-config.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/auth/resources/scim-provisioning-config.resource.specification.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AACzF,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAEpE,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,uBAAuB,EAAE,MAAM,0BAA0B,CAAC;AACxG,OAAO,EACL,qBAAqB,IAAI,EAAE,EAC3B,gBAAgB,EAChB,oBAAoB,EACpB,gCAAgC,EAChC,0CAA0C,GAC3C,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,sBAAsB,EACtB,mCAAmC,EACnC,6BAA6B,EAC7B,qBAAqB,EACrB,8CAA8C,GAE/C,MAAM,6BAA6B,CAAC;AAUrC,SAAS,CAAC,CAAC,MAAwC,EAAE,EAAS,EAAE,IAAY;IAC1E,MAAM,CAAC,GAAG,MAAM,CAAC,EAAE,CAAkB,CAAC;IACtC,IAAI,CAAC,CAAC;QAAE,MAAM,IAAI,KAAK,CAAC,YAAY,EAAE,QAAQ,IAAI,GAAG,CAAC,CAAC;IACvD,OAAO,CAAC,CAAC;AACX,CAAC;AACD,MAAM,KAAK,GAAwC;IACjD,CAAC,gBAAgB,CAAC,qCAAqC,CAAC,EAAE,oBAAoB,CAAC,aAAa;IAC5F,CAAC,gBAAgB,CAAC,oCAAoC,CAAC,EAAE,oBAAoB,CAAC,WAAW;CAC1F,CAAC;AAEF,MAAM,0BAA0B,GAAG,sBAAsB,CAAC;AAE1D;;;;;GAKG;AACH,SAAS,oCAAoC,CAAC,EAAS;IACrD,MAAM,cAAc,GAAG,EAAE,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E,gCAAgC,EAAE,EAAE,WAAW,EAAE,EAAE,OAAO,EAAE,qDAAqD,EAAE,EAAE,EAAE;aAC3W;SACF;QACD,KAAK,EAAE;YACL,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,EAAE,OAAO,EAAE,+IAA+I,EAAE,SAAS,EAAE,2DAA2D,EAAE;SAChP;KACF,CAAC,CACH,CAAC;AACJ,CAAC;AAED,MAAM,CAAC,MAAM,uDAAuD,GAAG,KAAK,CAC1E,gBAAgB,CAAC,qCAAqC,EACtD,uCAAuC,CACxC,CAAC;AACF,MAAM,CAAC,MAAM,sDAAsD,GAAG,KAAK,CACzE,gBAAgB,CAAC,oCAAoC,EACrD,sCAAsC,CACvC,CAAC","sourcesContent":["import { securityAdminPresets, securityMainPresets } from '@wildo-ai/presets-components';\nimport { LabelAudience } from '@wildo-ai/presets-components-models';\nimport type { ResourceUIBehaviorConfig } from '@wildo-ai/saas-frontend-lib/companion';\nimport { CodeDeclarationKind, CodeSymbolKind, FieldSemanticImportance } from '@wildo-ai/zod-decorators';\nimport {\n CoreResourceOperation as Op,\n CoreResourceType,\n ResourcePrimaryScope,\n ScimProvisioningConfigBaseSchema,\n scimProvisioningConfigPolymorphicFactories,\n} from '@wildo-ai/saas-models';\nimport {\n HttpResponseStatusCode,\n mergeResourceFrontendConfigurations,\n resourceFrontendConfiguration,\n resourceSpecification,\n resourceSpecificationFromFrontendConfiguration,\n type ResourceSpecificationConfig,\n} from '~wildo-specifications/_core';\n\ntype RType = CoreResourceType.ORGANIZATION_SCIM_PROVISIONING_CONFIG | CoreResourceType.APPLICATION_SCIM_PROVISIONING_CONFIG;\ntype RMember = 'ORGANIZATION_SCIM_PROVISIONING_CONFIG' | 'APPLICATION_SCIM_PROVISIONING_CONFIG';\ntype Cfg = ReturnType<(typeof scimProvisioningConfigPolymorphicFactories)[CoreResourceType.ORGANIZATION_SCIM_PROVISIONING_CONFIG]>;\ntype Custom = undefined;\ntype Core = Cfg['coreOperations'][number];\ntype Main = typeof ScimProvisioningConfigBaseSchema;\ntype F = ResourceUIBehaviorConfig<Custom, Core, Main>;\n\nfunction r(source: Partial<Record<string, unknown>>, rt: RType, name: string): F {\n const u = source[rt] as F | undefined;\n if (!u) throw new Error(`Missing \"${rt}\" in ${name}.`);\n return u;\n}\nconst scope: Record<RType, ResourcePrimaryScope> = {\n [CoreResourceType.ORGANIZATION_SCIM_PROVISIONING_CONFIG]: ResourcePrimaryScope.ORGANIZATIONS,\n [CoreResourceType.APPLICATION_SCIM_PROVISIONING_CONFIG]: ResourcePrimaryScope.APPLICATION,\n};\n\nconst SCIM_CONFIG_DOMAIN_EXAMPLE = 'identity.example.com';\n\n/**\n * Builds all public READ representations from one directory-provisioning policy\n * snapshot. The scope identifier and context relation differ between the two\n * polymorphic resources, while the SCIM endpoint and mapping semantics remain\n * framework-owned. No bearer token or other credential belongs in this config.\n */\nfunction createScimProvisioningConfigExamples(rt: RType) {\n const isOrganization = rt === CoreResourceType.ORGANIZATION_SCIM_PROVISIONING_CONFIG;\n const scopeId = isOrganization ? 'org_01JSCIMEXAMPLE' : 'app_01JSCIMEXAMPLE';\n const scopeIdentifier = isOrganization ? { organizationId: scopeId } : { applicationId: scopeId };\n const scopeContext = isOrganization ? { organization: { _id: scopeId } } : { application: { _id: scopeId } };\n const response = {\n _id: 'scimcfg_01JSCIMEXAMPLE',\n autoCreateUsers: true,\n autoVerifyEmail: true,\n autoDeactivateUsers: true,\n defaultRole: isOrganization ? 'organization-member' : 'application-user',\n attributeMapping: {\n email: 'emails[primary eq true].value',\n firstName: 'name.givenName',\n lastName: 'name.familyName',\n displayName: 'displayName',\n },\n organizationUnitMapping: [{\n directoryValue: 'Engineering',\n organizationUnitId: 'unit_01JSCIMENGINEERING',\n }],\n defaultUnitRole: 'member',\n scimEndpointUrl: '/api/v1/scim/v2',\n allowedDomains: [SCIM_CONFIG_DOMAIN_EXAMPLE],\n createdAt: '2026-08-20T08:00:00.000Z',\n updatedAt: '2026-08-20T08:15:00.000Z',\n ...scopeIdentifier,\n };\n\n return {\n response,\n contextResponse: { ...response, ...scopeContext },\n summaryResponse: {\n _id: response._id,\n autoCreateUsers: response.autoCreateUsers,\n },\n };\n}\n\nfunction buildBase(rt: RType, member: RMember): ResourceSpecificationConfig<Custom, Core, Main> {\n const examples = createScimProvisioningConfigExamples(rt);\n\n return resourceSpecification<Custom, Core, Main>(\n scimProvisioningConfigPolymorphicFactories[rt],\n ScimProvisioningConfigBaseSchema,\n ({ schemaShape }) => ({\n purpose: 'SCIM provisioning behavior for directory-managed users: default roles, attribute mappings, and automatic create and deactivate handling. This resource governs what happens after an authenticated SCIM request; organization-scoped SCIM bearer credentials authenticate the identity provider, while SSO sign-in and just-in-time provisioning are a separate channel.',\n businessRole: 'Controls how identity-provider directory data becomes application users and memberships, including the authorization defaults applied during provisioning.',\n lifecycleRole: 'Configure it while connecting the identity provider, then review it whenever directory attributes, role policy, or user-lifecycle policy changes.',\n audience: LabelAudience.DEVELOPER,\n codeHandling: {\n mainSchema: { packageName: '@wildo-ai/saas-models', exportName: 'ScimProvisioningConfigBaseSchema', symbolKind: CodeSymbolKind.SCHEMA, declarationKind: CodeDeclarationKind.ZOD_SCHEMA },\n resourceFactoryCollectionEntry: { collectionSymbol: { packageName: '@wildo-ai/saas-models', exportName: 'scimProvisioningConfigPolymorphicFactories', symbolKind: CodeSymbolKind.FACTORY }, identifierField: 'collectionKey', identifierValue: rt },\n resourceType: { enumDeclaration: { packageName: '@wildo-ai/saas-models', exportName: 'CoreResourceType', symbolKind: CodeSymbolKind.ENUM, declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM }, memberName: member },\n operationVocabulary: {\n coreEnum: { packageName: '@wildo-ai/saas-models', exportName: 'CoreResourceOperation', symbolKind: CodeSymbolKind.ENUM, declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM },\n },\n frontendConfigurationSourceEntries: [\n { collectionSymbol: { packageName: '@wildo-ai/presets-components', exportName: 'securityMainPresets', symbolKind: CodeSymbolKind.UI_BEHAVIOR }, identifierField: 'collectionKey', identifierValue: rt },\n { collectionSymbol: { packageName: '@wildo-ai/presets-components', exportName: 'securityAdminPresets', symbolKind: CodeSymbolKind.UI_BEHAVIOR }, identifierField: 'collectionKey', identifierValue: rt },\n ],\n },\n fields: {\n autoCreateUsers: schemaShape.autoCreateUsers.booleanSpec({ meaning: 'Whether SCIM `POST /Users` can create new users during directory synchronization. When false, creation requests for users who do not already exist are rejected.', importance: FieldSemanticImportance.PRIMARY }),\n autoVerifyEmail: schemaShape.autoVerifyEmail.booleanSpec({ meaning: 'Whether a trusted SCIM assertion marks a newly provisioned email as verified. When false, the new user remains in the application email-verification journey instead of becoming verified from the directory assertion.' }),\n autoDeactivateUsers: schemaShape.autoDeactivateUsers.booleanSpec({ meaning: 'Whether SCIM `DELETE /Users/{id}` and updates with `active: false` deactivate the user and their membership. When false, directory removals leave the application account active.' }),\n defaultRole: schemaShape.defaultRole.stringSpec({ meaning: 'Fallback role for newly provisioned members when the IdP payload does not supply a stronger mapping.' }),\n attributeMapping: schemaShape.attributeMapping.objectSpec({ meaning: 'Path expressions that map the incoming SCIM document to email, name, and profile fields. Supports dotted paths, array indexes such as `emails[0].value`, and SCIM filters such as `emails[primary eq true].value`. A malformed or unmatched expression produces no value instead of a validation error, so test every custom mapping with a representative identity-provider payload.' }),\n organizationUnitMapping: schemaShape.organizationUnitMapping.arraySpec({\n meaning: 'Explicit mappings from the directory’s SCIM Enterprise User `department` value to organization-unit identifiers. Unmapped values are ignored and never create units. When this list is non-empty and `defaultUnitRole` is set, supported user creation and full-replacement requests make SCIM authoritative for unit assignments: the mapped set replaces existing assignments, including assignments made manually. SCIM PATCH and Bulk requests do not currently reconcile organization units.',\n elementMeaning: 'One case-sensitive mapping from the trimmed directory department value to an existing organization-unit identifier.',\n }),\n defaultUnitRole: schemaShape.defaultUnitRole.stringSpec({ meaning: 'Role granted on every organization-unit assignment created through SCIM. It is separate from `defaultRole`, which controls organization-wide membership. Changing this setting changes the access granted to subsequently reconciled directory-managed users.' }),\n scimEndpointUrl: schemaShape.scimEndpointUrl.stringSpec({ meaning: 'Read-only API-relative base path for the SCIM service, for example `/api/v1/scim/v2`. Combine it with the deployment’s API base URL when configuring the identity provider. Tenant selection comes from the SCIM bearer credential, not from the URL path.' }),\n allowedDomains: schemaShape.allowedDomains.arraySpec({\n meaning: 'Read-only email domains accepted by SCIM provisioning. The list reflects the scope’s currently verified SSO domains. An empty list means no verified-domain restriction is configured; an absent value means domain policy could not be determined.',\n elementMeaning: 'One DNS-verified email domain accepted by SCIM provisioning.',\n }),\n },\n operations: {\n [Op.READ]: {\n purpose: 'Read the current SCIM provisioning behavior for this scope.',\n outcome: 'Administrators can review user-creation, deactivation, attribute-mapping, domain, and role policy before connecting or changing an identity provider.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The SCIM provisioning config for this scope was found and its gating/mapping is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the admin role required to inspect SCIM provisioning settings.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM provisioning config has been provisioned for this org/app scope yet.' },\n ],\n examples: [{\n title: 'Read the complete SCIM provisioning policy',\n response: examples.response,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n context: {\n examples: [{\n title: 'Read the SCIM policy with its owning scope context',\n response: examples.contextResponse,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n summary: {\n examples: [{\n title: 'Read the SCIM account-creation summary',\n response: examples.summaryResponse,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n idempotent: true,\n },\n [Op.CREATE]: {\n purpose: 'Provision the initial SCIM config document for a scope (INTERNAL_CALL create — no public HTTP route; seed / system-context lazy-create only; HIGH risk).',\n outcome: 'A new settings row; combined with `ScimTokens` for a working endpoint when enabled.',\n responseStatuses: [\n { code: HttpResponseStatusCode.CREATED_201, meaning: 'A SCIM provisioning config row was provisioned for the scope with the supplied gating and mapping.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The config payload fails schema validation, for example because a typed setting or role value is invalid. Attribute-mapping expressions are strings and must be behavior-tested separately.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not a platform/security admin; this is a HIGH-risk internal-only (INTERNAL_CALL) provisioning path.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'A SCIM provisioning config already exists for this org/app scope — the resource is one-per-scope, so a second create collides.' },\n ],\n idempotent: false,\n examples: [\n {\n title: 'Provision SCIM provisioning config for a scope',\n request: {\n autoCreateUsers: true,\n autoDeactivateUsers: true,\n defaultRole: 'member',\n attributeMapping: {\n email: 'emails[primary eq true].value',\n displayName: 'displayName',\n },\n },\n response: {\n _id: 'scimcfg_01HX2…',\n autoCreateUsers: true,\n defaultRole: 'member',\n },\n forStatus: HttpResponseStatusCode.CREATED_201,\n },\n ],\n },\n [Op.UPDATE]: {\n purpose: 'Change mapping, toggles, and defaults as the IdP app evolves (INTERNAL_CALL update — no public HTTP route; reached through `AuthOrganizationConfigurationService.saveScimProvisioningConfig` on the admin’s execution context, preserving admin audit attribution; HIGH risk).',\n outcome: 'Subsequent sync runs follow the new mapping; expect eventual consistency, not instant retroactive rewrite of all users in general.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The SCIM gating, mapping, and defaults were updated; subsequent sync runs follow the new mapping.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The patched mapping or toggles fail schema validation.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the HIGH-risk admin role required to change SCIM provisioning settings.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM provisioning config exists for this scope to update.' },\n ],\n idempotent: true,\n },\n [Op.DELETE]: {\n purpose: 'Repository-only teardown of the SCIM provisioning config row when its owning org/app is deleted (composition `onParentDelete` cascade).',\n outcome: 'The one-per-scope config row is removed together with its parent — the composition part does not outlive its whole.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The SCIM provisioning config row was deleted as part of the deletion cascade of its owning scope.' },\n ],\n // REPOSITORY_ONLY variant (org/app admin) — invoked by the onParentDelete cascade, not a public HTTP endpoint, so no client-facing 400/403/404 are documented.\n idempotent: true,\n },\n },\n businessConstraints: [\n 'Organization-scoped SCIM bearer credentials authenticate the identity provider. This resource governs what accepted SCIM events do to users and memberships.',\n ],\n }),\n { resourcePrimaryScope: scope[rt] },\n );\n}\n\nfunction build(rt: RType, member: RMember): ResourceSpecificationConfig<Custom, Core, Main> {\n return resourceSpecificationFromFrontendConfiguration(\n mergeResourceFrontendConfigurations(\n resourceFrontendConfiguration(r(securityMainPresets as Partial<Record<string, unknown>>, rt, 'securityMainPresets')),\n resourceFrontendConfiguration(r(securityAdminPresets as Partial<Record<string, unknown>>, rt, 'securityAdminPresets')),\n ),\n buildBase(rt, member),\n () => ({\n layout: {\n purpose: 'Sections `overview`, `mapping`, and `lifecycle` in `security` templates for the SCIM provisioning config editor and read views.',\n displayPurpose: 'Read vs edit: edit focuses on boolean gates and string maps; read surfaces the same in display layout components in the preset file.',\n sections: {\n overview: { purpose: 'High-level auto-create / deactivate / verify-email lifecycle toggles for the push. (Enablement itself lives on the org-type config, not here.)', whenToUse: 'Tuning what SCIM does to users once it is enabled for the org type.', textSlots: { title: { purpose: 'SCIM overview.' }, description: { purpose: 'Mention that whether SCIM is on is an org-type setting, and that tokens are managed in the sibling SCIM token resource — not in this form.' } } },\n mapping: { purpose: 'Attribute mapping and default role; ties IdP field paths to internal profile fields when defined.', whenToUse: 'IdP schema differences require mapping changes.', textSlots: { title: { purpose: 'Attribute mapping block.' }, description: { purpose: 'Explain that unmatched or malformed expressions can resolve to no value and therefore must be tested against the real IdP payload.' } } },\n lifecycle: { purpose: 'Create/update metadata timestamps for the config row; not user lifecycle, which is event-driven on SCIM traffic.', whenToUse: 'Support proving when the mapping last changed in incidents.', textSlots: { title: { purpose: 'Config lifecycle / timestamps.' }, description: { purpose: 'Distinguish from user lifecycle in domain language.' } } },\n },\n },\n views: {\n [Op.READ]: { purpose: 'Addressable read for the security SCIM page in org (app scope may use empty `views` in main `variantOverrides`—factory op exists regardless).', whenToUse: 'Admins review SCIM gating and mapping in merged consoles.' },\n },\n }),\n );\n}\n\nexport const organizationScimProvisioningConfigResourceSpecification = build(\n CoreResourceType.ORGANIZATION_SCIM_PROVISIONING_CONFIG,\n 'ORGANIZATION_SCIM_PROVISIONING_CONFIG',\n);\nexport const applicationScimProvisioningConfigResourceSpecification = build(\n CoreResourceType.APPLICATION_SCIM_PROVISIONING_CONFIG,\n 'APPLICATION_SCIM_PROVISIONING_CONFIG',\n);\n"]}
|
|
1
|
+
{"version":3,"file":"scim-provisioning-config.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/auth/resources/scim-provisioning-config.resource.specification.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AACzF,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAEpE,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,uBAAuB,EAAE,MAAM,0BAA0B,CAAC;AACxG,OAAO,EACL,qBAAqB,IAAI,EAAE,EAC3B,gBAAgB,EAChB,oBAAoB,EACpB,gCAAgC,EAChC,0CAA0C,GAC3C,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,sBAAsB,EACtB,mCAAmC,EACnC,6BAA6B,EAC7B,qBAAqB,EACrB,8CAA8C,GAE/C,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAU3E,SAAS,CAAC,CAAC,MAAwC,EAAE,EAAS,EAAE,IAAY;IAC1E,MAAM,CAAC,GAAG,MAAM,CAAC,EAAE,CA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,EAAE,qEAAqE,EAAE,SAAS,EAAE,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,gBAAgB,EAAE,EAAE,WAAW,EAAE,EAAE,OAAO,EAAE,4IAA4I,EAAE,EAAE,EAAE;gBACtd,OAAO,EAAE,EAAE,OAAO,EAAE,mGAAmG,EAAE,SAAS,EAAE,iDAAiD,EAAE,SAAS,EAAE,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,0BAA0B,EAAE,EAAE,WAAW,EAAE,EAAE,OAAO,EAAE,oIAAoI,EAAE,EAAE,EAAE;gBACtZ,SAAS,EAAE,EAAE,OAAO,EAAE,kHAAkH,EAAE,SAAS,EAAE,6DAA6D,EAAE,SAAS,EAAE,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,gCAAgC,EAAE,EAAE,WAAW,EAAE,EAAE,OAAO,EAAE,qDAAqD,EAAE,EAAE,EAAE;aAC3W;SACF;QACD,KAAK,EAAE;YACL,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,EAAE,OAAO,EAAE,+IAA+I,EAAE,SAAS,EAAE,2DAA2D,EAAE;SAChP;KACF,CAAC,CACH,CAAC;AACJ,CAAC;AAED,MAAM,CAAC,MAAM,uDAAuD,GAAG,KAAK,CAC1E,gBAAgB,CAAC,qCAAqC,EACtD,uCAAuC,CACxC,CAAC;AACF,MAAM,CAAC,MAAM,sDAAsD,GAAG,KAAK,CACzE,gBAAgB,CAAC,oCAAoC,EACrD,sCAAsC,CACvC,CAAC","sourcesContent":["import { securityAdminPresets, securityMainPresets } from '@wildo-ai/presets-components';\nimport { LabelAudience } from '@wildo-ai/presets-components-models';\nimport type { ResourceUIBehaviorConfig } from '@wildo-ai/saas-frontend-lib/companion';\nimport { CodeDeclarationKind, CodeSymbolKind, FieldSemanticImportance } from '@wildo-ai/zod-decorators';\nimport {\n CoreResourceOperation as Op,\n CoreResourceType,\n ResourcePrimaryScope,\n ScimProvisioningConfigBaseSchema,\n scimProvisioningConfigPolymorphicFactories,\n} from '@wildo-ai/saas-models';\nimport {\n HttpResponseStatusCode,\n mergeResourceFrontendConfigurations,\n resourceFrontendConfiguration,\n resourceSpecification,\n resourceSpecificationFromFrontendConfiguration,\n type ResourceSpecificationConfig,\n} from '~wildo-specifications/_core';\nimport { EngineResourceSubDomain } from '../../engine-resource-sub-domain';\n\ntype RType = CoreResourceType.ORGANIZATION_SCIM_PROVISIONING_CONFIG | CoreResourceType.APPLICATION_SCIM_PROVISIONING_CONFIG;\ntype RMember = 'ORGANIZATION_SCIM_PROVISIONING_CONFIG' | 'APPLICATION_SCIM_PROVISIONING_CONFIG';\ntype Cfg = ReturnType<(typeof scimProvisioningConfigPolymorphicFactories)[CoreResourceType.ORGANIZATION_SCIM_PROVISIONING_CONFIG]>;\ntype Custom = undefined;\ntype Core = Cfg['coreOperations'][number];\ntype Main = typeof ScimProvisioningConfigBaseSchema;\ntype F = ResourceUIBehaviorConfig<Custom, Core, Main>;\n\nfunction r(source: Partial<Record<string, unknown>>, rt: RType, name: string): F {\n const u = source[rt] as F | undefined;\n if (!u) throw new Error(`Missing \"${rt}\" in ${name}.`);\n return u;\n}\nconst scope: Record<RType, ResourcePrimaryScope> = {\n [CoreResourceType.ORGANIZATION_SCIM_PROVISIONING_CONFIG]: ResourcePrimaryScope.ORGANIZATIONS,\n [CoreResourceType.APPLICATION_SCIM_PROVISIONING_CONFIG]: ResourcePrimaryScope.APPLICATION,\n};\n\nconst SCIM_CONFIG_DOMAIN_EXAMPLE = 'identity.example.com';\n\n/**\n * Builds all public READ representations from one directory-provisioning policy\n * snapshot. The scope identifier and context relation differ between the two\n * polymorphic resources, while the SCIM endpoint and mapping semantics remain\n * framework-owned. No bearer token or other credential belongs in this config.\n */\nfunction createScimProvisioningConfigExamples(rt: RType) {\n const isOrganization = rt === CoreResourceType.ORGANIZATION_SCIM_PROVISIONING_CONFIG;\n const scopeId = isOrganization ? 'org_01JSCIMEXAMPLE' : 'app_01JSCIMEXAMPLE';\n const scopeIdentifier = isOrganization ? { organizationId: scopeId } : { applicationId: scopeId };\n const scopeContext = isOrganization ? { organization: { _id: scopeId } } : { application: { _id: scopeId } };\n const response = {\n _id: 'scimcfg_01JSCIMEXAMPLE',\n autoCreateUsers: true,\n autoVerifyEmail: true,\n autoDeactivateUsers: true,\n defaultRole: isOrganization ? 'organization-member' : 'application-user',\n attributeMapping: {\n email: 'emails[primary eq true].value',\n firstName: 'name.givenName',\n lastName: 'name.familyName',\n displayName: 'displayName',\n },\n organizationUnitMapping: [{\n directoryValue: 'Engineering',\n organizationUnitId: 'unit_01JSCIMENGINEERING',\n }],\n defaultUnitRole: 'member',\n scimEndpointUrl: '/api/v1/scim/v2',\n allowedDomains: [SCIM_CONFIG_DOMAIN_EXAMPLE],\n createdAt: '2026-08-20T08:00:00.000Z',\n updatedAt: '2026-08-20T08:15:00.000Z',\n ...scopeIdentifier,\n };\n\n return {\n response,\n contextResponse: { ...response, ...scopeContext },\n summaryResponse: {\n _id: response._id,\n autoCreateUsers: response.autoCreateUsers,\n },\n };\n}\n\nfunction buildBase(rt: RType, member: RMember): ResourceSpecificationConfig<Custom, Core, Main> {\n const examples = createScimProvisioningConfigExamples(rt);\n\n return resourceSpecification<Custom, Core, Main>(\n scimProvisioningConfigPolymorphicFactories[rt],\n ScimProvisioningConfigBaseSchema,\n ({ schemaShape }) => ({\n purpose: 'SCIM provisioning behavior for directory-managed users: default roles, attribute mappings, and automatic create and deactivate handling. This resource governs what happens after an authenticated SCIM request; organization-scoped SCIM bearer credentials authenticate the identity provider, while SSO sign-in and just-in-time provisioning are a separate channel.',\n businessRole: 'Controls how identity-provider directory data becomes application users and memberships, including the authorization defaults applied during provisioning.',\n lifecycleRole: 'Configure it while connecting the identity provider, then review it whenever directory attributes, role policy, or user-lifecycle policy changes.',\n audience: LabelAudience.DEVELOPER,\n subDomain: EngineResourceSubDomain.AUTH,\n codeHandling: {\n mainSchema: { packageName: '@wildo-ai/saas-models', exportName: 'ScimProvisioningConfigBaseSchema', symbolKind: CodeSymbolKind.SCHEMA, declarationKind: CodeDeclarationKind.ZOD_SCHEMA },\n resourceFactoryCollectionEntry: { collectionSymbol: { packageName: '@wildo-ai/saas-models', exportName: 'scimProvisioningConfigPolymorphicFactories', symbolKind: CodeSymbolKind.FACTORY }, identifierField: 'collectionKey', identifierValue: rt },\n resourceType: { enumDeclaration: { packageName: '@wildo-ai/saas-models', exportName: 'CoreResourceType', symbolKind: CodeSymbolKind.ENUM, declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM }, memberName: member },\n operationVocabulary: {\n coreEnum: { packageName: '@wildo-ai/saas-models', exportName: 'CoreResourceOperation', symbolKind: CodeSymbolKind.ENUM, declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM },\n },\n frontendConfigurationSourceEntries: [\n { collectionSymbol: { packageName: '@wildo-ai/presets-components', exportName: 'securityMainPresets', symbolKind: CodeSymbolKind.UI_BEHAVIOR }, identifierField: 'collectionKey', identifierValue: rt },\n { collectionSymbol: { packageName: '@wildo-ai/presets-components', exportName: 'securityAdminPresets', symbolKind: CodeSymbolKind.UI_BEHAVIOR }, identifierField: 'collectionKey', identifierValue: rt },\n ],\n },\n fields: {\n autoCreateUsers: schemaShape.autoCreateUsers.booleanSpec({ meaning: 'Whether SCIM `POST /Users` can create new users during directory synchronization. When false, creation requests for users who do not already exist are rejected.', importance: FieldSemanticImportance.PRIMARY }),\n autoVerifyEmail: schemaShape.autoVerifyEmail.booleanSpec({ meaning: 'Whether a trusted SCIM assertion marks a newly provisioned email as verified. When false, the new user remains in the application email-verification journey instead of becoming verified from the directory assertion.' }),\n autoDeactivateUsers: schemaShape.autoDeactivateUsers.booleanSpec({ meaning: 'Whether SCIM `DELETE /Users/{id}` and updates with `active: false` deactivate the user and their membership. When false, directory removals leave the application account active.' }),\n defaultRole: schemaShape.defaultRole.stringSpec({ meaning: 'Fallback role for newly provisioned members when the IdP payload does not supply a stronger mapping.' }),\n attributeMapping: schemaShape.attributeMapping.objectSpec({ meaning: 'Path expressions that map the incoming SCIM document to email, name, and profile fields. Supports dotted paths, array indexes such as `emails[0].value`, and SCIM filters such as `emails[primary eq true].value`. A malformed or unmatched expression produces no value instead of a validation error, so test every custom mapping with a representative identity-provider payload.' }),\n organizationUnitMapping: schemaShape.organizationUnitMapping.arraySpec({\n meaning: 'Explicit mappings from the directory’s SCIM Enterprise User `department` value to organization-unit identifiers. Unmapped values are ignored and never create units. When this list is non-empty and `defaultUnitRole` is set, supported user creation and full-replacement requests make SCIM authoritative for unit assignments: the mapped set replaces existing assignments, including assignments made manually. SCIM PATCH and Bulk requests do not currently reconcile organization units.',\n elementMeaning: 'One case-sensitive mapping from the trimmed directory department value to an existing organization-unit identifier.',\n }),\n defaultUnitRole: schemaShape.defaultUnitRole.stringSpec({ meaning: 'Role granted on every organization-unit assignment created through SCIM. It is separate from `defaultRole`, which controls organization-wide membership. Changing this setting changes the access granted to subsequently reconciled directory-managed users.' }),\n scimEndpointUrl: schemaShape.scimEndpointUrl.stringSpec({ meaning: 'Read-only API-relative base path for the SCIM service, for example `/api/v1/scim/v2`. Combine it with the deployment’s API base URL when configuring the identity provider. Tenant selection comes from the SCIM bearer credential, not from the URL path.' }),\n allowedDomains: schemaShape.allowedDomains.arraySpec({\n meaning: 'Read-only email domains accepted by SCIM provisioning. The list reflects the scope’s currently verified SSO domains. An empty list means no verified-domain restriction is configured; an absent value means domain policy could not be determined.',\n elementMeaning: 'One DNS-verified email domain accepted by SCIM provisioning.',\n }),\n },\n operations: {\n [Op.READ]: {\n purpose: 'Read the current SCIM provisioning behavior for this scope.',\n outcome: 'Administrators can review user-creation, deactivation, attribute-mapping, domain, and role policy before connecting or changing an identity provider.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The SCIM provisioning config for this scope was found and its gating/mapping is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the admin role required to inspect SCIM provisioning settings.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM provisioning config has been provisioned for this org/app scope yet.' },\n ],\n examples: [{\n title: 'Read the complete SCIM provisioning policy',\n response: examples.response,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n variants: {\n context: {\n examples: [{\n title: 'Read the SCIM policy with its owning scope context',\n response: examples.contextResponse,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n summary: {\n examples: [{\n title: 'Read the SCIM account-creation summary',\n response: examples.summaryResponse,\n forStatus: HttpResponseStatusCode.OK_200,\n }],\n },\n },\n idempotent: true,\n },\n [Op.CREATE]: {\n purpose: 'Provision the initial SCIM config document for a scope (INTERNAL_CALL create — no public HTTP route; seed / system-context lazy-create only; HIGH risk).',\n outcome: 'A new settings row; combined with `ScimTokens` for a working endpoint when enabled.',\n responseStatuses: [\n { code: HttpResponseStatusCode.CREATED_201, meaning: 'A SCIM provisioning config row was provisioned for the scope with the supplied gating and mapping.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The config payload fails schema validation, for example because a typed setting or role value is invalid. Attribute-mapping expressions are strings and must be behavior-tested separately.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not a platform/security admin; this is a HIGH-risk internal-only (INTERNAL_CALL) provisioning path.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'A SCIM provisioning config already exists for this org/app scope — the resource is one-per-scope, so a second create collides.' },\n ],\n idempotent: false,\n examples: [\n {\n title: 'Provision SCIM provisioning config for a scope',\n request: {\n autoCreateUsers: true,\n autoDeactivateUsers: true,\n defaultRole: 'member',\n attributeMapping: {\n email: 'emails[primary eq true].value',\n displayName: 'displayName',\n },\n },\n response: {\n _id: 'scimcfg_01HX2…',\n autoCreateUsers: true,\n defaultRole: 'member',\n },\n forStatus: HttpResponseStatusCode.CREATED_201,\n },\n ],\n },\n [Op.UPDATE]: {\n purpose: 'Change mapping, toggles, and defaults as the IdP app evolves (INTERNAL_CALL update — no public HTTP route; reached through `AuthOrganizationConfigurationService.saveScimProvisioningConfig` on the admin’s execution context, preserving admin audit attribution; HIGH risk).',\n outcome: 'Subsequent sync runs follow the new mapping; expect eventual consistency, not instant retroactive rewrite of all users in general.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The SCIM gating, mapping, and defaults were updated; subsequent sync runs follow the new mapping.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The patched mapping or toggles fail schema validation.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the HIGH-risk admin role required to change SCIM provisioning settings.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM provisioning config exists for this scope to update.' },\n ],\n idempotent: true,\n },\n [Op.DELETE]: {\n purpose: 'Repository-only teardown of the SCIM provisioning config row when its owning org/app is deleted (composition `onParentDelete` cascade).',\n outcome: 'The one-per-scope config row is removed together with its parent — the composition part does not outlive its whole.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The SCIM provisioning config row was deleted as part of the deletion cascade of its owning scope.' },\n ],\n // REPOSITORY_ONLY variant (org/app admin) — invoked by the onParentDelete cascade, not a public HTTP endpoint, so no client-facing 400/403/404 are documented.\n idempotent: true,\n },\n },\n businessConstraints: [\n 'Organization-scoped SCIM bearer credentials authenticate the identity provider. This resource governs what accepted SCIM events do to users and memberships.',\n ],\n }),\n { resourcePrimaryScope: scope[rt] },\n );\n}\n\nfunction build(rt: RType, member: RMember): ResourceSpecificationConfig<Custom, Core, Main> {\n return resourceSpecificationFromFrontendConfiguration(\n mergeResourceFrontendConfigurations(\n resourceFrontendConfiguration(r(securityMainPresets as Partial<Record<string, unknown>>, rt, 'securityMainPresets')),\n resourceFrontendConfiguration(r(securityAdminPresets as Partial<Record<string, unknown>>, rt, 'securityAdminPresets')),\n ),\n buildBase(rt, member),\n () => ({\n layout: {\n purpose: 'Sections `overview`, `mapping`, and `lifecycle` in `security` templates for the SCIM provisioning config editor and read views.',\n displayPurpose: 'Read vs edit: edit focuses on boolean gates and string maps; read surfaces the same in display layout components in the preset file.',\n sections: {\n overview: { purpose: 'High-level auto-create / deactivate / verify-email lifecycle toggles for the push. (Enablement itself lives on the org-type config, not here.)', whenToUse: 'Tuning what SCIM does to users once it is enabled for the org type.', textSlots: { title: { purpose: 'SCIM overview.' }, description: { purpose: 'Mention that whether SCIM is on is an org-type setting, and that tokens are managed in the sibling SCIM token resource — not in this form.' } } },\n mapping: { purpose: 'Attribute mapping and default role; ties IdP field paths to internal profile fields when defined.', whenToUse: 'IdP schema differences require mapping changes.', textSlots: { title: { purpose: 'Attribute mapping block.' }, description: { purpose: 'Explain that unmatched or malformed expressions can resolve to no value and therefore must be tested against the real IdP payload.' } } },\n lifecycle: { purpose: 'Create/update metadata timestamps for the config row; not user lifecycle, which is event-driven on SCIM traffic.', whenToUse: 'Support proving when the mapping last changed in incidents.', textSlots: { title: { purpose: 'Config lifecycle / timestamps.' }, description: { purpose: 'Distinguish from user lifecycle in domain language.' } } },\n },\n },\n views: {\n [Op.READ]: { purpose: 'Addressable read for the security SCIM page in org (app scope may use empty `views` in main `variantOverrides`—factory op exists regardless).', whenToUse: 'Admins review SCIM gating and mapping in merged consoles.' },\n },\n }),\n );\n}\n\nexport const organizationScimProvisioningConfigResourceSpecification = build(\n CoreResourceType.ORGANIZATION_SCIM_PROVISIONING_CONFIG,\n 'ORGANIZATION_SCIM_PROVISIONING_CONFIG',\n);\nexport const applicationScimProvisioningConfigResourceSpecification = build(\n CoreResourceType.APPLICATION_SCIM_PROVISIONING_CONFIG,\n 'APPLICATION_SCIM_PROVISIONING_CONFIG',\n);\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scim-tokens.resource.specification.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/auth/resources/scim-tokens.resource.specification.ts"],"names":[],"mappings":"AAIA,OAAO,EACL,qBAAqB,IAAI,EAAE,EAG3B,qBAAqB,EAGtB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAML,KAAK,2BAA2B,EACjC,MAAM,6BAA6B,CAAC;
|
|
1
|
+
{"version":3,"file":"scim-tokens.resource.specification.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/auth/resources/scim-tokens.resource.specification.ts"],"names":[],"mappings":"AAIA,OAAO,EACL,qBAAqB,IAAI,EAAE,EAG3B,qBAAqB,EAGtB,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAML,KAAK,2BAA2B,EACjC,MAAM,6BAA6B,CAAC;AA8SrC,eAAO,MAAM,2CAA2C;;;;;;;;;;iCAA+E,CAAC"}
|
|
@@ -3,6 +3,7 @@ import { LabelAudience } from '@wildo-ai/presets-components-models';
|
|
|
3
3
|
import { CodeDeclarationKind, CodeSymbolKind, FieldSemanticImportance } from '@wildo-ai/zod-decorators';
|
|
4
4
|
import { CoreResourceOperation as Op, CoreResourceType, ResourcePrimaryScope, ScimTokens_Operations, ScimTokenBaseSchema, scimTokensPolymorphicFactories, } from '@wildo-ai/saas-models';
|
|
5
5
|
import { HttpResponseStatusCode, mergeResourceFrontendConfigurations, resourceFrontendConfiguration, resourceSpecification, resourceSpecificationFromFrontendConfiguration, } from '../../../_core/index.js';
|
|
6
|
+
import { EngineResourceSubDomain } from '../../engine-resource-sub-domain.js';
|
|
6
7
|
function r(source, rt, name) {
|
|
7
8
|
const u = source[rt];
|
|
8
9
|
if (!u)
|
|
@@ -45,6 +46,7 @@ function buildBase(rt, member) {
|
|
|
45
46
|
businessRole: 'Long-lived or expiring credentials dedicated to directory synchronization, with issuance, inventory, revocation, and immediate-cutover rotation distinct from general platform API keys.',
|
|
46
47
|
lifecycleRole: 'Generate a credential, monitor its use and expiry, then revoke or rotate it. Rotation cuts over immediately, so update the identity provider with the returned token before making another SCIM request.',
|
|
47
48
|
audience: LabelAudience.DEVELOPER,
|
|
49
|
+
subDomain: EngineResourceSubDomain.AUTH,
|
|
48
50
|
codeHandling: {
|
|
49
51
|
mainSchema: { packageName: '@wildo-ai/saas-models', exportName: 'ScimTokenBaseSchema', symbolKind: CodeSymbolKind.SCHEMA, declarationKind: CodeDeclarationKind.ZOD_SCHEMA },
|
|
50
52
|
resourceFactoryCollectionEntry: { collectionSymbol: { packageName: '@wildo-ai/saas-models', exportName: 'scimTokensPolymorphicFactories', symbolKind: CodeSymbolKind.FACTORY }, identifierField: 'collectionKey', identifierValue: rt },
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"scim-tokens.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/auth/resources/scim-tokens.resource.specification.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AACzF,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAEpE,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,uBAAuB,EAAE,MAAM,0BAA0B,CAAC;AACxG,OAAO,EACL,qBAAqB,IAAI,EAAE,EAC3B,gBAAgB,EAChB,oBAAoB,EACpB,qBAAqB,EACrB,mBAAmB,EACnB,8BAA8B,GAC/B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,sBAAsB,EACtB,mCAAmC,EACnC,6BAA6B,EAC7B,qBAAqB,EACrB,8CAA8C,GAE/C,MAAM,6BAA6B,CAAC;AAUrC,SAAS,CAAC,CAAC,MAAwC,EAAE,EAAS,EAAE,IAAY;IAC1E,MAAM,CAAC,GAAG,MAAM,CAAC,EAAE,CAAkB,CAAC;IACtC,IAAI,CAAC,CAAC;QAAE,MAAM,IAAI,KAAK,CAAC,YAAY,EAAE,QAAQ,IAAI,GAAG,CAAC,CAAC;IACvD,OAAO,CAAC,CAAC;AACX,CAAC;AACD,MAAM,KAAK,GAAwC;IACjD,CAAC,gBAAgB,CAAC,wBAAwB,CAAC,EAAE,oBAAoB,CAAC,aAAa;CAChF,CAAC;AAEF,SAAS,SA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,EAAE,EAAE,EAAE;gBAChS,SAAS,EAAE,EAAE,OAAO,EAAE,4FAA4F,EAAE,SAAS,EAAE,uDAAuD,EAAE,SAAS,EAAE,EAAE,KAAK,EAAE,EAAE,OAAO,EAAE,sBAAsB,EAAE,EAAE,WAAW,EAAE,EAAE,OAAO,EAAE,+EAA+E,EAAE,EAAE,EAAE;aAC/V;SACF;QACD,KAAK,EAAE;YACL,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,EAAE,OAAO,EAAE,iGAAiG,EAAE,SAAS,EAAE,sEAAsE,EAAE;YAC5M,CAAC,qBAAqB,CAAC,cAAc,CAAC,EAAE,EAAE,OAAO,EAAE,2HAA2H,EAAE,SAAS,EAAE,8FAA8F,EAAE;YAC3R,CAAC,qBAAqB,CAAC,YAAY,CAAC,EAAE,EAAE,OAAO,EAAE,8GAA8G,EAAE,SAAS,EAAE,sEAAsE,EAAE;YACpP,CAAC,qBAAqB,CAAC,YAAY,CAAC,EAAE,EAAE,OAAO,EAAE,+LAA+L,EAAE,SAAS,EAAE,8DAA8D,EAAE;SAC9T;KACF,CAAC,CACH,CAAC;AACJ,CAAC;AAED,MAAM,CAAC,MAAM,2CAA2C,GAAG,KAAK,CAAC,gBAAgB,CAAC,wBAAwB,EAAE,0BAA0B,CAAC,CAAC","sourcesContent":["import { securityAdminPresets, securityMainPresets } from '@wildo-ai/presets-components';\nimport { LabelAudience } from '@wildo-ai/presets-components-models';\nimport type { ResourceUIBehaviorConfig } from '@wildo-ai/saas-frontend-lib/companion';\nimport { CodeDeclarationKind, CodeSymbolKind, FieldSemanticImportance } from '@wildo-ai/zod-decorators';\nimport {\n CoreResourceOperation as Op,\n CoreResourceType,\n ResourcePrimaryScope,\n ScimTokens_Operations,\n ScimTokenBaseSchema,\n scimTokensPolymorphicFactories,\n} from '@wildo-ai/saas-models';\nimport {\n HttpResponseStatusCode,\n mergeResourceFrontendConfigurations,\n resourceFrontendConfiguration,\n resourceSpecification,\n resourceSpecificationFromFrontendConfiguration,\n type ResourceSpecificationConfig,\n} from '~wildo-specifications/_core';\n\ntype RType = CoreResourceType.ORGANIZATION_SCIM_TOKENS;\ntype RMember = 'ORGANIZATION_SCIM_TOKENS';\ntype Cfg = ReturnType<(typeof scimTokensPolymorphicFactories)[CoreResourceType.ORGANIZATION_SCIM_TOKENS]>;\ntype Custom = NonNullable<Cfg['customOperation']>;\ntype Core = Cfg['coreOperations'][number];\ntype Main = typeof ScimTokenBaseSchema;\ntype F = ResourceUIBehaviorConfig<Custom, Core, Main>;\n\nfunction r(source: Partial<Record<string, unknown>>, rt: RType, name: string): F {\n const u = source[rt] as F | undefined;\n if (!u) throw new Error(`Missing \"${rt}\" in ${name}.`);\n return u;\n}\nconst scope: Record<RType, ResourcePrimaryScope> = {\n [CoreResourceType.ORGANIZATION_SCIM_TOKENS]: ResourcePrimaryScope.ORGANIZATIONS,\n};\n\nfunction buildBase(rt: RType, member: RMember): ResourceSpecificationConfig<Custom, Core, Main> {\n const scopeId = 'organization_01HX2EXAMPLE';\n const tokenId = 'scim_token_org_01HX2EXAMPLE';\n const scopeOwnership = { organizationId: scopeId } as const;\n const scopeRelationship = { organization: { _id: scopeId } } as const;\n const pagination = { page: 1, limit: 20, total: 1, totalPages: 1 } as const;\n const tokenRecordExample = {\n _id: tokenId,\n displayName: 'Production identity provider',\n createdByUserId: 'user_security_admin_01HX2EXAMPLE',\n lastUsedAt: '2026-08-17T15:30:00.000Z',\n expiresAt: '2099-01-01T00:00:00.000Z',\n isActive: true,\n createdAt: '2026-08-01T10:00:00.000Z',\n updatedAt: '2026-08-17T15:30:00.000Z',\n ...scopeOwnership,\n } as const;\n const tokenSummaryExample = {\n _id: tokenRecordExample._id,\n displayName: tokenRecordExample.displayName,\n isActive: tokenRecordExample.isActive,\n } as const;\n const tokenPageExample = { data: [tokenRecordExample], pagination } as const;\n const tokenContextPageExample = {\n data: [{ data: [tokenRecordExample], pagination, ...scopeRelationship }],\n pagination,\n } as const;\n const tokenSummaryPageExample = { data: [tokenSummaryExample], pagination } as const;\n\n return resourceSpecification<Custom, Core, Main>(\n scimTokensPolymorphicFactories[rt],\n ScimTokenBaseSchema,\n ({ schemaShape }) => ({\n purpose: 'SCIM bearer credentials used by the organization’s identity provider to provision and deactivate users through the SCIM API.',\n businessRole: 'Long-lived or expiring credentials dedicated to directory synchronization, with issuance, inventory, revocation, and immediate-cutover rotation distinct from general platform API keys.',\n lifecycleRole: 'Generate a credential, monitor its use and expiry, then revoke or rotate it. Rotation cuts over immediately, so update the identity provider with the returned token before making another SCIM request.',\n audience: LabelAudience.DEVELOPER,\n codeHandling: {\n mainSchema: { packageName: '@wildo-ai/saas-models', exportName: 'ScimTokenBaseSchema', symbolKind: CodeSymbolKind.SCHEMA, declarationKind: CodeDeclarationKind.ZOD_SCHEMA },\n resourceFactoryCollectionEntry: { collectionSymbol: { packageName: '@wildo-ai/saas-models', exportName: 'scimTokensPolymorphicFactories', symbolKind: CodeSymbolKind.FACTORY }, identifierField: 'collectionKey', identifierValue: rt },\n resourceType: { enumDeclaration: { packageName: '@wildo-ai/saas-models', exportName: 'CoreResourceType', symbolKind: CodeSymbolKind.ENUM, declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM }, memberName: member },\n operationVocabulary: {\n coreEnum: { packageName: '@wildo-ai/saas-models', exportName: 'CoreResourceOperation', symbolKind: CodeSymbolKind.ENUM, declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM },\n customEnum: { packageName: '@wildo-ai/saas-models', exportName: 'ScimTokens_Operations', symbolKind: CodeSymbolKind.ENUM, declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM },\n },\n frontendConfigurationSourceEntries: [\n { collectionSymbol: { packageName: '@wildo-ai/presets-components', exportName: 'securityMainPresets', symbolKind: CodeSymbolKind.UI_BEHAVIOR }, identifierField: 'collectionKey', identifierValue: rt },\n { collectionSymbol: { packageName: '@wildo-ai/presets-components', exportName: 'securityAdminPresets', symbolKind: CodeSymbolKind.UI_BEHAVIOR }, identifierField: 'collectionKey', identifierValue: rt },\n ],\n notes: [\n '`tokenHash` is backend-only: UI shows labels and last-use — never a recoverable token from READ in secure deployments.',\n ],\n },\n fields: {\n tokenHash: schemaShape.tokenHash.stringSpec({\n meaning: 'Persisted SHA-256 lookup hash returned as `tokenHash` only by GENERATE_TOKEN for creation correlation. ROTATE_TOKEN names its acknowledgement field `newTokenHash`; inventory never returns either hash. A hash is not a bearer credential.',\n }),\n displayName: schemaShape.displayName.stringSpec({ meaning: 'Admin-given name for the token in UI (what “Prod IdP” vs “Staging”).', importance: FieldSemanticImportance.PRIMARY }),\n isActive: schemaShape.isActive.booleanSpec({ meaning: 'Whether this token should still authenticate SCIM traffic when not expired or revoked in implementation.' }),\n createdByUserId: schemaShape.createdByUserId.stringSpec({ meaning: 'Administrator who minted the token row, retained for support and audit accountability.' }),\n lastUsedAt: schemaShape.lastUsedAt.dateSpec({ meaning: 'Last SCIM request that passed bearer, status, expiry, rate-limit, and feature checks before dispatch.' }),\n expiresAt: schemaShape.expiresAt.dateSpec({ meaning: 'Optional end time after which the token must be rotated or a new one issued even if not revoked early.' }),\n },\n operations: {\n [Op.READ]: {\n purpose: 'Internal-call (service-transport, no HTTP surface) read in factory defaults; the SCIM bearer-auth middleware resolves an inbound token by `tokenHash` on every /scim/v2/* request via a system-context read, so READ opts into `systemAccessPolicy.read = ALLOWED`. Not a member fetch.',\n outcome: 'Detail templates show display name, active flag, and lifecycle without raw secret or hash.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The SCIM token row’s metadata (display name, active flag, lifecycle) is returned without the secret or hash.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the internal/admin role required to inspect SCIM token rows.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM token exists for the supplied id in the caller’s scope.' },\n ],\n idempotent: true,\n },\n [Op.LIST]: {\n purpose: 'List the organization’s SCIM credentials and their current status, expiry, and last-use metadata.',\n outcome: 'A paginated credential inventory suitable for security review and rotation planning.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'A (possibly empty) page of SCIM credentials, labeled by `displayName`.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the admin role required to view the SCIM token inventory for this scope.' },\n ],\n idempotent: true,\n examples: [\n {\n title: 'Browse organization SCIM tokens',\n request: { page: 1, limit: 20, sort: 'createdAt:desc' },\n response: tokenPageExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n variants: {\n context: {\n examples: [\n {\n title: 'Browse organization SCIM tokens with scope context',\n request: { page: 1, limit: 20, sort: 'createdAt:desc' },\n response: tokenContextPageExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n summary: {\n examples: [\n {\n title: 'Browse compact organization SCIM token summaries',\n request: { page: 1, limit: 20, sort: 'createdAt:desc' },\n response: tokenSummaryPageExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n },\n },\n [Op.CREATE]: {\n purpose: 'Row creation path for a new token record (REPOSITORY_ONLY in factory, HIGH risk).',\n outcome: 'A new id; any plaintext handshake follows factory DTOs for the generate custom op, not this bare create in typical UX.',\n responseStatuses: [\n { code: HttpResponseStatusCode.CREATED_201, meaning: 'A SCIM token row was created; the bare create returns the row id, not plaintext bearer material (see GENERATE_TOKEN for the secret handshake).' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The token payload fails schema validation (e.g. missing `displayName` or a malformed `expiresAt`).', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not a platform/security admin; this is a HIGH-risk REPOSITORY_ONLY create.' },\n ],\n idempotent: false,\n rateLimitNote: 'Creating SCIM credential rows is a credential-management path and may be rate-limited per scope.',\n },\n [Op.UPDATE]: {\n purpose: 'Internal-call (service-transport, no HTTP surface) metadata update; the SCIM bearer-auth middleware stamps `lastUsedAt` on the resolved token on every /scim/v2/* request via a system-context write. Operators rotate/revoke via the dedicated custom ops, not this bare update.',\n outcome: 'The token row’s `lastUsedAt` (and other non-secret metadata) is refreshed; the secret/hash are never mutated here.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The SCIM token row’s metadata was updated (e.g. `lastUsedAt`).' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the internal/admin role required to mutate SCIM token rows.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM token exists for the supplied id in the caller’s scope.' },\n ],\n idempotent: false,\n },\n [Op.DELETE]: {\n purpose: 'Remove a token document when a credential should disappear entirely; REPOSITORY_ONLY in factory, HIGH risk.',\n outcome: 'The IdP can no longer authenticate SCIM with that id when enforcement is live.',\n responseStatuses: [\n { code: HttpResponseStatusCode.NO_CONTENT_204, meaning: 'The SCIM token row was deleted; the IdP can no longer authenticate SCIM with it. No body is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the HIGH-risk admin role required to purge SCIM token rows.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM token exists for the supplied id (or it was already deleted).' },\n ],\n idempotent: true,\n },\n [ScimTokens_Operations.GENERATE_TOKEN]: {\n operationId: ScimTokens_Operations.GENERATE_TOKEN,\n purpose: 'Generate a new SCIM bearer credential for an identity-provider connection.',\n outcome: 'The plaintext token is returned exactly once together with its metadata. Store it securely and configure it in the identity provider before dismissing the response.',\n responseStatuses: [\n { code: HttpResponseStatusCode.CREATED_201, meaning: 'The credential was created; the response includes its metadata and the one-time plaintext `token`, which cannot be retrieved again.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The generate payload fails schema validation (e.g. missing `displayName` or an invalid `expiresAt`).', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the admin role required to mint SCIM bearer credentials.' },\n ],\n idempotent: false,\n rateLimitNote: 'Bearer-token issuance is a credential-minting path and may be rate-limited per scope to slow credential sprawl.',\n examples: [\n {\n title: 'Generate an organization SCIM bearer token',\n request: {\n displayName: tokenRecordExample.displayName,\n expiresAt: tokenRecordExample.expiresAt,\n },\n response: {\n _id: tokenRecordExample._id,\n displayName: tokenRecordExample.displayName,\n createdByUserId: tokenRecordExample.createdByUserId,\n expiresAt: tokenRecordExample.expiresAt,\n isActive: tokenRecordExample.isActive,\n createdAt: tokenRecordExample.createdAt,\n updatedAt: tokenRecordExample.updatedAt,\n tokenHash: '29a6c2c70d069455f9e439e3cf0eb3755e221cabd6cfa4403ae340b9a5c42db5',\n token: '5c6cc59416d664aaab4b3a79e977e8ac19de2cd0518753107080c6af310f72c2',\n },\n forStatus: HttpResponseStatusCode.CREATED_201,\n },\n ],\n },\n [ScimTokens_Operations.REVOKE_TOKEN]: {\n operationId: ScimTokens_Operations.REVOKE_TOKEN,\n purpose: 'Revoke an active SCIM token without deleting its administrative history.',\n outcome: 'SCIM requests using the revoked token fail authentication, while its metadata remains available for audit and incident review.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The token is invalidated; subsequent SCIM calls presenting it fail authentication, while the row is retained for audit.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The request body contains any property; revocation accepts only an empty JSON object.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the admin role required to revoke SCIM credentials.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM token exists for the supplied id in the caller’s scope.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'The token is already revoked or inactive, so there is nothing to invalidate.' },\n ],\n idempotent: false,\n examples: [\n {\n title: 'Revoke a compromised SCIM token while retaining its audit history',\n request: {},\n response: {\n isActive: false,\n revokedAt: '2026-08-18T10:45:00.000Z',\n message: 'Token revoked',\n },\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n [ScimTokens_Operations.ROTATE_TOKEN]: {\n operationId: ScimTokens_Operations.ROTATE_TOKEN,\n purpose: 'Replace the token’s bearer secret with immediate cutover. The request body must be an empty JSON object.',\n outcome: 'A new plaintext bearer is returned once and immediately authenticates; the prior material stops authenticating at once.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'A new bearer secret is issued and returned once; it authenticates immediately and the prior material is invalidated at once.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The request body contains any property; immediate-cutover rotation accepts only an empty JSON object.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the admin role required to rotate SCIM credentials.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM token exists for the supplied id in the caller’s scope.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'The token is revoked/expired and cannot be rotated, so issuing a new period is an illegal transition.' },\n ],\n idempotent: false,\n rateLimitNote: 'Rotation issues fresh bearer material and may be rate-limited to prevent rapid churn of live SCIM credentials.',\n examples: [\n {\n title: 'Rotate a SCIM token with immediate cutover',\n request: {},\n response: {\n newToken: '2770f399e8eeb9dc16a8e4d44e39b1097ae02cd397814007c30b80d34a334f41',\n newTokenId: tokenRecordExample._id,\n newTokenHash: 'e2b223c12b1f3e249e5f4cc332654423822613579113218de8e6bdc491fa6e6f',\n message: 'Token rotated',\n },\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n },\n businessConstraints: [\n 'Do not conflate with `ORG_API_KEYS` / `APPLICATION_API_KEYS` — these tokens are for SCIM HTTP endpoints, not general platform API use.',\n ],\n }),\n { resourcePrimaryScope: scope[rt] },\n );\n}\n\nfunction build(rt: RType, member: RMember): ResourceSpecificationConfig<Custom, Core, Main> {\n return resourceSpecificationFromFrontendConfiguration(\n mergeResourceFrontendConfigurations(\n resourceFrontendConfiguration(r(securityMainPresets as Partial<Record<string, unknown>>, rt, 'securityMainPresets')),\n resourceFrontendConfiguration(r(securityAdminPresets as Partial<Record<string, unknown>>, rt, 'securityAdminPresets')),\n ),\n buildBase(rt, member),\n () => ({\n label: { purpose: 'Preset `getFrontendResourceLabel` returns `displayName` — the primary list/title for a SCIM token card.' },\n layout: {\n purpose: 'Sections `overview` (name, active, creator) and `lifecycle` (last use, expiry, timestamps) in the SCIM token templates.',\n displayPurpose: 'Display layout mirrors list semantics: compact name + status in summary, full lifecycle in the detail read template.',\n sections: {\n overview: { purpose: 'Identity and active flag for a SCIM token without exposing the secret or hash.', whenToUse: 'Any card or panel listing tokens.', textSlots: { title: { purpose: 'Token name.' }, description: { purpose: 'Tie the label to a single IdP or environment, not a user.' } } },\n lifecycle: { purpose: 'Last used, created, expiry, and support-oriented timestamps to drive rotation and cleanup.', whenToUse: 'Security review of stale tokens and expiring windows.', textSlots: { title: { purpose: 'Lifecycle and usage.' }, description: { purpose: 'Mention that “never used” may mean network path blocked, not a bug by itself.' } } },\n },\n },\n views: {\n [Op.LIST]: { purpose: 'Addressable organization-token inventory and primary navigation in the tenant SCIM security UI.', whenToUse: 'Administrators see all SCIM credentials for the tenant in one table.' },\n [ScimTokens_Operations.GENERATE_TOKEN]: { purpose: 'Create-with-secret custom op; not addressable in the default `views` array, invoked as an action from an empty/CTA state.', whenToUse: 'Onboarding a new IdP or rotating after compromise without deleting history rows immediately.' },\n [ScimTokens_Operations.REVOKE_TOKEN]: { purpose: 'Revocation action; not addressable in the default `views` array from row kebab/inline when wired in product.', whenToUse: 'Kill a single compromised token with audit trail of revocation time.' },\n [ScimTokens_Operations.ROTATE_TOKEN]: { purpose: 'Immediate-cutover rotation that re-mints the secret in place from a strict-empty request with no grace window; not addressable in the default `views` array, triggered from a rotation modal.', whenToUse: 'Planned key rotation when the IdP can be updated atomically.' },\n },\n }),\n );\n}\n\nexport const organizationScimTokensResourceSpecification = build(CoreResourceType.ORGANIZATION_SCIM_TOKENS, 'ORGANIZATION_SCIM_TOKENS');\n"]}
|
|
1
|
+
{"version":3,"file":"scim-tokens.resource.specification.js","sourceRoot":"","sources":["../../../../../../src/engine/auth/resources/scim-tokens.resource.specification.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,oBAAoB,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AACzF,OAAO,EAAE,aAAa,EAAE,MAAM,qCAAqC,CAAC;AAEpE,OAAO,EAAE,mBAAmB,EAAE,cAAc,EAAE,uBAAuB,EAAE,MAAM,0BAA0B,CAAC;AACxG,OAAO,EACL,qBAAqB,IAAI,EAAE,EAC3B,gBAAgB,EAChB,oBAAoB,EACpB,qBAAqB,EACrB,mBAAmB,EACnB,8BAA8B,GAC/B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EACL,sBAAsB,EACtB,mCAAmC,EACnC,6BAA6B,EAC7B,qBAAqB,EACrB,8CAA8C,GAE/C,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,uBAAuB,EAAE,MAAM,kCAAkC,CAAC;AAU3E,SAAS,CAAC,CAAC,MAAwC,EAAE,EAAS,EAAE,IAAY;IAC1E,MAAM,CAAC,GAAG,MAAM,CAAC,EAAE,CAAkB,CAAC;IACtC,IAAI,CAAC,CAAC;QAAE,MAAM,IAAI,KAAK,CAAC,YAAY,EAAE,QAAQ,IAAI,GAAG,CAAC,CAAC;IACvD,OAAO,CAAC,CAAC;AACX,CAAC;AACD,MAAM,KAAK,GAAwC;IACjD,CAAC,gBAAgB,CAAC,wBAAwB,CAAC,EAAE,oBAAoB,CAAC,aAAa;CAChF,CAAC;AAEF,SAAS,SAAS,CAAC,EAAS,EAAE,MAAe;IAC3C,MAAM,OAAO,GAAG,2BAA2B,CAAC;IAC5C,MAAM,OAAO,GAAG,6BAA6B,CAAC;IAC9C,MAAM,cAAc,GAAG,EAAE,cAAc,EAAE,OAAO,EAAW,CAAC;IAC5D,MAAM,iBAAiB,GAAG,EAAE,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E,WAAW,EAAE,EAAE,OAAO,EAAE,+EAA+E,EAAE,EAAE,EAAE;aAC/V;SACF;QACD,KAAK,EAAE;YACL,CAAC,EAAE,CAAC,IAAI,CAAC,EAAE,EAAE,OAAO,EAAE,iGAAiG,EAAE,SAAS,EAAE,sEAAsE,EAAE;YAC5M,CAAC,qBAAqB,CAAC,cAAc,CAAC,EAAE,EAAE,OAAO,EAAE,2HAA2H,EAAE,SAAS,EAAE,8FAA8F,EAAE;YAC3R,CAAC,qBAAqB,CAAC,YAAY,CAAC,EAAE,EAAE,OAAO,EAAE,8GAA8G,EAAE,SAAS,EAAE,sEAAsE,EAAE;YACpP,CAAC,qBAAqB,CAAC,YAAY,CAAC,EAAE,EAAE,OAAO,EAAE,+LAA+L,EAAE,SAAS,EAAE,8DAA8D,EAAE;SAC9T;KACF,CAAC,CACH,CAAC;AACJ,CAAC;AAED,MAAM,CAAC,MAAM,2CAA2C,GAAG,KAAK,CAAC,gBAAgB,CAAC,wBAAwB,EAAE,0BAA0B,CAAC,CAAC","sourcesContent":["import { securityAdminPresets, securityMainPresets } from '@wildo-ai/presets-components';\nimport { LabelAudience } from '@wildo-ai/presets-components-models';\nimport type { ResourceUIBehaviorConfig } from '@wildo-ai/saas-frontend-lib/companion';\nimport { CodeDeclarationKind, CodeSymbolKind, FieldSemanticImportance } from '@wildo-ai/zod-decorators';\nimport {\n CoreResourceOperation as Op,\n CoreResourceType,\n ResourcePrimaryScope,\n ScimTokens_Operations,\n ScimTokenBaseSchema,\n scimTokensPolymorphicFactories,\n} from '@wildo-ai/saas-models';\nimport {\n HttpResponseStatusCode,\n mergeResourceFrontendConfigurations,\n resourceFrontendConfiguration,\n resourceSpecification,\n resourceSpecificationFromFrontendConfiguration,\n type ResourceSpecificationConfig,\n} from '~wildo-specifications/_core';\nimport { EngineResourceSubDomain } from '../../engine-resource-sub-domain';\n\ntype RType = CoreResourceType.ORGANIZATION_SCIM_TOKENS;\ntype RMember = 'ORGANIZATION_SCIM_TOKENS';\ntype Cfg = ReturnType<(typeof scimTokensPolymorphicFactories)[CoreResourceType.ORGANIZATION_SCIM_TOKENS]>;\ntype Custom = NonNullable<Cfg['customOperation']>;\ntype Core = Cfg['coreOperations'][number];\ntype Main = typeof ScimTokenBaseSchema;\ntype F = ResourceUIBehaviorConfig<Custom, Core, Main>;\n\nfunction r(source: Partial<Record<string, unknown>>, rt: RType, name: string): F {\n const u = source[rt] as F | undefined;\n if (!u) throw new Error(`Missing \"${rt}\" in ${name}.`);\n return u;\n}\nconst scope: Record<RType, ResourcePrimaryScope> = {\n [CoreResourceType.ORGANIZATION_SCIM_TOKENS]: ResourcePrimaryScope.ORGANIZATIONS,\n};\n\nfunction buildBase(rt: RType, member: RMember): ResourceSpecificationConfig<Custom, Core, Main> {\n const scopeId = 'organization_01HX2EXAMPLE';\n const tokenId = 'scim_token_org_01HX2EXAMPLE';\n const scopeOwnership = { organizationId: scopeId } as const;\n const scopeRelationship = { organization: { _id: scopeId } } as const;\n const pagination = { page: 1, limit: 20, total: 1, totalPages: 1 } as const;\n const tokenRecordExample = {\n _id: tokenId,\n displayName: 'Production identity provider',\n createdByUserId: 'user_security_admin_01HX2EXAMPLE',\n lastUsedAt: '2026-08-17T15:30:00.000Z',\n expiresAt: '2099-01-01T00:00:00.000Z',\n isActive: true,\n createdAt: '2026-08-01T10:00:00.000Z',\n updatedAt: '2026-08-17T15:30:00.000Z',\n ...scopeOwnership,\n } as const;\n const tokenSummaryExample = {\n _id: tokenRecordExample._id,\n displayName: tokenRecordExample.displayName,\n isActive: tokenRecordExample.isActive,\n } as const;\n const tokenPageExample = { data: [tokenRecordExample], pagination } as const;\n const tokenContextPageExample = {\n data: [{ data: [tokenRecordExample], pagination, ...scopeRelationship }],\n pagination,\n } as const;\n const tokenSummaryPageExample = { data: [tokenSummaryExample], pagination } as const;\n\n return resourceSpecification<Custom, Core, Main>(\n scimTokensPolymorphicFactories[rt],\n ScimTokenBaseSchema,\n ({ schemaShape }) => ({\n purpose: 'SCIM bearer credentials used by the organization’s identity provider to provision and deactivate users through the SCIM API.',\n businessRole: 'Long-lived or expiring credentials dedicated to directory synchronization, with issuance, inventory, revocation, and immediate-cutover rotation distinct from general platform API keys.',\n lifecycleRole: 'Generate a credential, monitor its use and expiry, then revoke or rotate it. Rotation cuts over immediately, so update the identity provider with the returned token before making another SCIM request.',\n audience: LabelAudience.DEVELOPER,\n subDomain: EngineResourceSubDomain.AUTH,\n codeHandling: {\n mainSchema: { packageName: '@wildo-ai/saas-models', exportName: 'ScimTokenBaseSchema', symbolKind: CodeSymbolKind.SCHEMA, declarationKind: CodeDeclarationKind.ZOD_SCHEMA },\n resourceFactoryCollectionEntry: { collectionSymbol: { packageName: '@wildo-ai/saas-models', exportName: 'scimTokensPolymorphicFactories', symbolKind: CodeSymbolKind.FACTORY }, identifierField: 'collectionKey', identifierValue: rt },\n resourceType: { enumDeclaration: { packageName: '@wildo-ai/saas-models', exportName: 'CoreResourceType', symbolKind: CodeSymbolKind.ENUM, declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM }, memberName: member },\n operationVocabulary: {\n coreEnum: { packageName: '@wildo-ai/saas-models', exportName: 'CoreResourceOperation', symbolKind: CodeSymbolKind.ENUM, declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM },\n customEnum: { packageName: '@wildo-ai/saas-models', exportName: 'ScimTokens_Operations', symbolKind: CodeSymbolKind.ENUM, declarationKind: CodeDeclarationKind.TYPESCRIPT_ENUM },\n },\n frontendConfigurationSourceEntries: [\n { collectionSymbol: { packageName: '@wildo-ai/presets-components', exportName: 'securityMainPresets', symbolKind: CodeSymbolKind.UI_BEHAVIOR }, identifierField: 'collectionKey', identifierValue: rt },\n { collectionSymbol: { packageName: '@wildo-ai/presets-components', exportName: 'securityAdminPresets', symbolKind: CodeSymbolKind.UI_BEHAVIOR }, identifierField: 'collectionKey', identifierValue: rt },\n ],\n notes: [\n '`tokenHash` is backend-only: UI shows labels and last-use — never a recoverable token from READ in secure deployments.',\n ],\n },\n fields: {\n tokenHash: schemaShape.tokenHash.stringSpec({\n meaning: 'Persisted SHA-256 lookup hash returned as `tokenHash` only by GENERATE_TOKEN for creation correlation. ROTATE_TOKEN names its acknowledgement field `newTokenHash`; inventory never returns either hash. A hash is not a bearer credential.',\n }),\n displayName: schemaShape.displayName.stringSpec({ meaning: 'Admin-given name for the token in UI (what “Prod IdP” vs “Staging”).', importance: FieldSemanticImportance.PRIMARY }),\n isActive: schemaShape.isActive.booleanSpec({ meaning: 'Whether this token should still authenticate SCIM traffic when not expired or revoked in implementation.' }),\n createdByUserId: schemaShape.createdByUserId.stringSpec({ meaning: 'Administrator who minted the token row, retained for support and audit accountability.' }),\n lastUsedAt: schemaShape.lastUsedAt.dateSpec({ meaning: 'Last SCIM request that passed bearer, status, expiry, rate-limit, and feature checks before dispatch.' }),\n expiresAt: schemaShape.expiresAt.dateSpec({ meaning: 'Optional end time after which the token must be rotated or a new one issued even if not revoked early.' }),\n },\n operations: {\n [Op.READ]: {\n purpose: 'Internal-call (service-transport, no HTTP surface) read in factory defaults; the SCIM bearer-auth middleware resolves an inbound token by `tokenHash` on every /scim/v2/* request via a system-context read, so READ opts into `systemAccessPolicy.read = ALLOWED`. Not a member fetch.',\n outcome: 'Detail templates show display name, active flag, and lifecycle without raw secret or hash.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The SCIM token row’s metadata (display name, active flag, lifecycle) is returned without the secret or hash.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the internal/admin role required to inspect SCIM token rows.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM token exists for the supplied id in the caller’s scope.' },\n ],\n idempotent: true,\n },\n [Op.LIST]: {\n purpose: 'List the organization’s SCIM credentials and their current status, expiry, and last-use metadata.',\n outcome: 'A paginated credential inventory suitable for security review and rotation planning.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'A (possibly empty) page of SCIM credentials, labeled by `displayName`.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the admin role required to view the SCIM token inventory for this scope.' },\n ],\n idempotent: true,\n examples: [\n {\n title: 'Browse organization SCIM tokens',\n request: { page: 1, limit: 20, sort: 'createdAt:desc' },\n response: tokenPageExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n variants: {\n context: {\n examples: [\n {\n title: 'Browse organization SCIM tokens with scope context',\n request: { page: 1, limit: 20, sort: 'createdAt:desc' },\n response: tokenContextPageExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n summary: {\n examples: [\n {\n title: 'Browse compact organization SCIM token summaries',\n request: { page: 1, limit: 20, sort: 'createdAt:desc' },\n response: tokenSummaryPageExample,\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n },\n },\n [Op.CREATE]: {\n purpose: 'Row creation path for a new token record (REPOSITORY_ONLY in factory, HIGH risk).',\n outcome: 'A new id; any plaintext handshake follows factory DTOs for the generate custom op, not this bare create in typical UX.',\n responseStatuses: [\n { code: HttpResponseStatusCode.CREATED_201, meaning: 'A SCIM token row was created; the bare create returns the row id, not plaintext bearer material (see GENERATE_TOKEN for the secret handshake).' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The token payload fails schema validation (e.g. missing `displayName` or a malformed `expiresAt`).', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller is not a platform/security admin; this is a HIGH-risk REPOSITORY_ONLY create.' },\n ],\n idempotent: false,\n rateLimitNote: 'Creating SCIM credential rows is a credential-management path and may be rate-limited per scope.',\n },\n [Op.UPDATE]: {\n purpose: 'Internal-call (service-transport, no HTTP surface) metadata update; the SCIM bearer-auth middleware stamps `lastUsedAt` on the resolved token on every /scim/v2/* request via a system-context write. Operators rotate/revoke via the dedicated custom ops, not this bare update.',\n outcome: 'The token row’s `lastUsedAt` (and other non-secret metadata) is refreshed; the secret/hash are never mutated here.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The SCIM token row’s metadata was updated (e.g. `lastUsedAt`).' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the internal/admin role required to mutate SCIM token rows.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM token exists for the supplied id in the caller’s scope.' },\n ],\n idempotent: false,\n },\n [Op.DELETE]: {\n purpose: 'Remove a token document when a credential should disappear entirely; REPOSITORY_ONLY in factory, HIGH risk.',\n outcome: 'The IdP can no longer authenticate SCIM with that id when enforcement is live.',\n responseStatuses: [\n { code: HttpResponseStatusCode.NO_CONTENT_204, meaning: 'The SCIM token row was deleted; the IdP can no longer authenticate SCIM with it. No body is returned.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the HIGH-risk admin role required to purge SCIM token rows.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM token exists for the supplied id (or it was already deleted).' },\n ],\n idempotent: true,\n },\n [ScimTokens_Operations.GENERATE_TOKEN]: {\n operationId: ScimTokens_Operations.GENERATE_TOKEN,\n purpose: 'Generate a new SCIM bearer credential for an identity-provider connection.',\n outcome: 'The plaintext token is returned exactly once together with its metadata. Store it securely and configure it in the identity provider before dismissing the response.',\n responseStatuses: [\n { code: HttpResponseStatusCode.CREATED_201, meaning: 'The credential was created; the response includes its metadata and the one-time plaintext `token`, which cannot be retrieved again.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The generate payload fails schema validation (e.g. missing `displayName` or an invalid `expiresAt`).', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the admin role required to mint SCIM bearer credentials.' },\n ],\n idempotent: false,\n rateLimitNote: 'Bearer-token issuance is a credential-minting path and may be rate-limited per scope to slow credential sprawl.',\n examples: [\n {\n title: 'Generate an organization SCIM bearer token',\n request: {\n displayName: tokenRecordExample.displayName,\n expiresAt: tokenRecordExample.expiresAt,\n },\n response: {\n _id: tokenRecordExample._id,\n displayName: tokenRecordExample.displayName,\n createdByUserId: tokenRecordExample.createdByUserId,\n expiresAt: tokenRecordExample.expiresAt,\n isActive: tokenRecordExample.isActive,\n createdAt: tokenRecordExample.createdAt,\n updatedAt: tokenRecordExample.updatedAt,\n tokenHash: '29a6c2c70d069455f9e439e3cf0eb3755e221cabd6cfa4403ae340b9a5c42db5',\n token: '5c6cc59416d664aaab4b3a79e977e8ac19de2cd0518753107080c6af310f72c2',\n },\n forStatus: HttpResponseStatusCode.CREATED_201,\n },\n ],\n },\n [ScimTokens_Operations.REVOKE_TOKEN]: {\n operationId: ScimTokens_Operations.REVOKE_TOKEN,\n purpose: 'Revoke an active SCIM token without deleting its administrative history.',\n outcome: 'SCIM requests using the revoked token fail authentication, while its metadata remains available for audit and incident review.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'The token is invalidated; subsequent SCIM calls presenting it fail authentication, while the row is retained for audit.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The request body contains any property; revocation accepts only an empty JSON object.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the admin role required to revoke SCIM credentials.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM token exists for the supplied id in the caller’s scope.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'The token is already revoked or inactive, so there is nothing to invalidate.' },\n ],\n idempotent: false,\n examples: [\n {\n title: 'Revoke a compromised SCIM token while retaining its audit history',\n request: {},\n response: {\n isActive: false,\n revokedAt: '2026-08-18T10:45:00.000Z',\n message: 'Token revoked',\n },\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n [ScimTokens_Operations.ROTATE_TOKEN]: {\n operationId: ScimTokens_Operations.ROTATE_TOKEN,\n purpose: 'Replace the token’s bearer secret with immediate cutover. The request body must be an empty JSON object.',\n outcome: 'A new plaintext bearer is returned once and immediately authenticates; the prior material stops authenticating at once.',\n responseStatuses: [\n { code: HttpResponseStatusCode.OK_200, meaning: 'A new bearer secret is issued and returned once; it authenticates immediately and the prior material is invalidated at once.' },\n ],\n errorScenarios: [\n { code: HttpResponseStatusCode.BAD_REQUEST_400, when: 'The request body contains any property; immediate-cutover rotation accepts only an empty JSON object.', errorCode: 'VALIDATION_FAILED' },\n { code: HttpResponseStatusCode.FORBIDDEN_403, when: 'The caller lacks the admin role required to rotate SCIM credentials.' },\n { code: HttpResponseStatusCode.NOT_FOUND_404, when: 'No SCIM token exists for the supplied id in the caller’s scope.' },\n { code: HttpResponseStatusCode.CONFLICT_409, when: 'The token is revoked/expired and cannot be rotated, so issuing a new period is an illegal transition.' },\n ],\n idempotent: false,\n rateLimitNote: 'Rotation issues fresh bearer material and may be rate-limited to prevent rapid churn of live SCIM credentials.',\n examples: [\n {\n title: 'Rotate a SCIM token with immediate cutover',\n request: {},\n response: {\n newToken: '2770f399e8eeb9dc16a8e4d44e39b1097ae02cd397814007c30b80d34a334f41',\n newTokenId: tokenRecordExample._id,\n newTokenHash: 'e2b223c12b1f3e249e5f4cc332654423822613579113218de8e6bdc491fa6e6f',\n message: 'Token rotated',\n },\n forStatus: HttpResponseStatusCode.OK_200,\n },\n ],\n },\n },\n businessConstraints: [\n 'Do not conflate with `ORG_API_KEYS` / `APPLICATION_API_KEYS` — these tokens are for SCIM HTTP endpoints, not general platform API use.',\n ],\n }),\n { resourcePrimaryScope: scope[rt] },\n );\n}\n\nfunction build(rt: RType, member: RMember): ResourceSpecificationConfig<Custom, Core, Main> {\n return resourceSpecificationFromFrontendConfiguration(\n mergeResourceFrontendConfigurations(\n resourceFrontendConfiguration(r(securityMainPresets as Partial<Record<string, unknown>>, rt, 'securityMainPresets')),\n resourceFrontendConfiguration(r(securityAdminPresets as Partial<Record<string, unknown>>, rt, 'securityAdminPresets')),\n ),\n buildBase(rt, member),\n () => ({\n label: { purpose: 'Preset `getFrontendResourceLabel` returns `displayName` — the primary list/title for a SCIM token card.' },\n layout: {\n purpose: 'Sections `overview` (name, active, creator) and `lifecycle` (last use, expiry, timestamps) in the SCIM token templates.',\n displayPurpose: 'Display layout mirrors list semantics: compact name + status in summary, full lifecycle in the detail read template.',\n sections: {\n overview: { purpose: 'Identity and active flag for a SCIM token without exposing the secret or hash.', whenToUse: 'Any card or panel listing tokens.', textSlots: { title: { purpose: 'Token name.' }, description: { purpose: 'Tie the label to a single IdP or environment, not a user.' } } },\n lifecycle: { purpose: 'Last used, created, expiry, and support-oriented timestamps to drive rotation and cleanup.', whenToUse: 'Security review of stale tokens and expiring windows.', textSlots: { title: { purpose: 'Lifecycle and usage.' }, description: { purpose: 'Mention that “never used” may mean network path blocked, not a bug by itself.' } } },\n },\n },\n views: {\n [Op.LIST]: { purpose: 'Addressable organization-token inventory and primary navigation in the tenant SCIM security UI.', whenToUse: 'Administrators see all SCIM credentials for the tenant in one table.' },\n [ScimTokens_Operations.GENERATE_TOKEN]: { purpose: 'Create-with-secret custom op; not addressable in the default `views` array, invoked as an action from an empty/CTA state.', whenToUse: 'Onboarding a new IdP or rotating after compromise without deleting history rows immediately.' },\n [ScimTokens_Operations.REVOKE_TOKEN]: { purpose: 'Revocation action; not addressable in the default `views` array from row kebab/inline when wired in product.', whenToUse: 'Kill a single compromised token with audit trail of revocation time.' },\n [ScimTokens_Operations.ROTATE_TOKEN]: { purpose: 'Immediate-cutover rotation that re-mints the secret in place from a strict-empty request with no grace window; not addressable in the default `views` array, triggered from a rotation modal.', whenToUse: 'Planned key rotation when the IdP can be updated atomically.' },\n },\n }),\n );\n}\n\nexport const organizationScimTokensResourceSpecification = build(CoreResourceType.ORGANIZATION_SCIM_TOKENS, 'ORGANIZATION_SCIM_TOKENS');\n"]}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"siem-delivery-dlq.resource.specification.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/auth/resources/siem-delivery-dlq.resource.specification.ts"],"names":[],"mappings":"AAQA,OAAO,EACL,qBAAqB,IAAI,EAAE,EAM3B,0BAA0B,EAI3B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAML,KAAK,2BAA2B,EACjC,MAAM,6BAA6B,CAAC;
|
|
1
|
+
{"version":3,"file":"siem-delivery-dlq.resource.specification.d.ts","sourceRoot":"","sources":["../../../../../../src/engine/auth/resources/siem-delivery-dlq.resource.specification.ts"],"names":[],"mappings":"AAQA,OAAO,EACL,qBAAqB,IAAI,EAAE,EAM3B,0BAA0B,EAI3B,MAAM,uBAAuB,CAAC;AAC/B,OAAO,EAML,KAAK,2BAA2B,EACjC,MAAM,6BAA6B,CAAC;AAocrC,eAAO,MAAM,gDAAgD;;;;;;;;;;;;;;;iCAG5D,CAAC;AACF,eAAO,MAAM,+CAA+C;;;;;;;;;;;;;;;iCAG3D,CAAC"}
|
|
@@ -3,6 +3,7 @@ import { LabelAudience } from '@wildo-ai/presets-components-models';
|
|
|
3
3
|
import { CodeDeclarationKind, CodeSymbolKind, FieldSemanticImportance, } from '@wildo-ai/zod-decorators';
|
|
4
4
|
import { CoreResourceOperation as Op, CoreResourceType, ErrorCustomMessageReference, ErrorSeverity, ErrorType, ResourcePrimaryScope, SiemDeliveryDlq_Operations, SiemDeliveryDlqBaseSchema, SiemDeliveryDlqStatus, siemDeliveryDlqPolymorphicFactories, } from '@wildo-ai/saas-models';
|
|
5
5
|
import { HttpResponseStatusCode, mergeResourceFrontendConfigurations, resourceFrontendConfiguration, resourceSpecification, resourceSpecificationFromFrontendConfiguration, } from '../../../_core/index.js';
|
|
6
|
+
import { EngineResourceSubDomain } from '../../engine-resource-sub-domain.js';
|
|
6
7
|
function r(source, rt, name) {
|
|
7
8
|
const u = source[rt];
|
|
8
9
|
if (!u)
|
|
@@ -123,6 +124,7 @@ function buildBase(rt, member) {
|
|
|
123
124
|
businessRole: 'Operator-facing queue for data that could not be pushed to a customer’s SIEM endpoint in time, with a clear failure reason and retry state.',
|
|
124
125
|
lifecycleRole: 'Progresses from pending retry to exhausted or eventually delivered; custom ops requeue or clear entries in bulk.',
|
|
125
126
|
audience: LabelAudience.DEVELOPER,
|
|
127
|
+
subDomain: EngineResourceSubDomain.AUTH,
|
|
126
128
|
codeHandling: {
|
|
127
129
|
mainSchema: {
|
|
128
130
|
packageName: '@wildo-ai/saas-models',
|