@salesforce/afv-skills 1.55.0 → 1.57.0
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/package.json +1 -1
- package/skills/agentforce-generate/SKILL.md +8 -0
- package/skills/agentforce-generate/references/actions-reference.md +2 -2
- package/skills/agentforce-generate/references/voice-modality-reference.md +51 -15
- package/skills/agentforce-generate/references/voice-telephony-cli.md +193 -0
- package/skills/agentforce-observe/SKILL.md +13 -9
- package/skills/agentforce-observe/references/ahm-alerts.md +193 -14
- package/skills/automation-sandbox-post-copy-config-generate/SKILL.md +24 -15
- package/skills/automation-sandbox-post-copy-config-generate/assets/config_template.json +11 -0
- package/skills/automation-sandbox-post-copy-config-generate/assets/json_schema.json +33 -1
- package/skills/automation-sandbox-post-copy-config-generate/references/configuration_catalog.md +32 -1
- package/skills/automation-sandbox-post-copy-configure/SKILL.md +75 -71
- package/skills/automation-sandbox-post-copy-configure/assets/scheduled_apex_template.apex +13 -0
- package/skills/automation-sandbox-post-copy-configure/examples/sample_scheduled_apex_config.json +13 -0
- package/skills/automation-sandbox-post-copy-configure/references/scheduled_apex_path.md +155 -0
- package/skills/automation-sandbox-post-copy-configure/scripts/build-scheduled-apex.mjs +62 -0
- package/skills/automation-sandbox-post-copy-configure/scripts/soql-escape-job-name.mjs +28 -0
- package/skills/commerce-b2b-open-code-components-integrate/SKILL.md +1 -1
- package/skills/commerce-b2b-open-code-components-replace/SKILL.md +16 -16
- package/skills/consumer-goods-accruals-datakit-deploy/SKILL.md +383 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/setup.js +324 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/00-check-prerequisites.js +63 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/01-download-static-resource.js +100 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/02-replace-org-id.js +46 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/03-deploy-metadata.js +46 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/04-deploy-engine.js +198 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/05-deploy-tpm-accruals.js +231 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/06-create-dataspace.js +82 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/07-deploy-accruals-reports.js +517 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/08-deploy-ui.js +416 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/09-completion.js +44 -0
- package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/utils.js +514 -0
- package/skills/consumer-goods-sync-management-configure/SKILL.md +137 -0
- package/skills/consumer-goods-sync-management-configure/examples/scenarios.md +294 -0
- package/skills/consumer-goods-sync-management-configure/references/act1-setup-sync.md +333 -0
- package/skills/consumer-goods-sync-management-configure/references/act2-assign-users.md +324 -0
- package/skills/consumer-goods-sync-management-configure/references/act3-plan-verify.md +113 -0
- package/skills/consumer-goods-sync-management-configure/references/readiness-and-enablement.md +164 -0
- package/skills/consumer-goods-sync-management-configure/references/sync-management-app-install-backbone.md +159 -0
- package/skills/consumer-goods-sync-management-configure/references/transports-and-namespace.md +220 -0
- package/skills/consumer-goods-sync-management-configure/references/verify-and-smoke.md +175 -0
- package/skills/dx-devops-project-manage/SKILL.md +1 -1
- package/skills/dx-org-analyze/SKILL.md +0 -1
- package/skills/dx-org-analyze/scripts/collect_org_data.py +2 -2
- package/skills/dx-org-analyze/scripts/compute_diff.py +2 -4
- package/skills/dx-org-analyze/scripts/introspect_org.py +4 -40
- package/skills/dx-org-manage/SKILL.md +6 -50
- package/skills/dx-org-manage/examples/README.md +10 -16
- package/skills/dx-org-manage/references/scratch-org-create.md +1 -1
- package/skills/dx-org-manage/references/scratch-org-operations.md +1 -1
- package/skills/dx-org-shape-manage/SKILL.md +4 -3
- package/skills/education-cloud-domain-configure/references/gotchas-extended.md +1 -0
- package/skills/experience-accessibility-validate/SKILL.md +8 -5
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-1-1-non-text-content.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-i-lists.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-ii-tables.md +20 -85
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-iii-form-labels.md +4 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-iv-regions.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-v-groups.md +2 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-5-identify-input.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-1-4-3-contrast.md +4 -14
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-1-1-keyboard.md +9 -5
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-4-4-link-purpose.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-4-6-headings-labels.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-5-1-pointer-gestures.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-5-2-pointer-cancellation.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-5-3-label-in-name.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-2-5-7-dragging-movement.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-3-2-1-on-focus.md +0 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-3-2-2-on-input.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-3-3-1-error-identification.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-3-3-2-labels-instructions.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-3-3-3-error-suggestion.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-4-1-2-i-name.md +4 -5
- package/skills/experience-accessibility-validate/references/reviewers/sc-4-1-2-ii-role.md +1 -4
- package/skills/experience-accessibility-validate/references/reviewers/sc-4-1-2-iii-value.md +0 -4
- package/skills/experience-cms-content-generate/SKILL.md +1 -1
- package/skills/experience-cms-content-render/SKILL.md +3 -3
- package/skills/experience-cms-content-render/assets/angular/MediaRenderer.component.ts +35 -7
- package/skills/experience-cms-content-render/assets/angular/cms-item.service.ts +13 -4
- package/skills/experience-cms-content-render/assets/react/MediaRenderer.tsx +30 -8
- package/skills/experience-cms-content-render/assets/react/useCmsItem.ts +14 -4
- package/skills/experience-cms-content-render/assets/shared/cmsCore.types.ts +11 -1
- package/skills/experience-cms-content-render/assets/shared/externalRefs.ts +1 -1
- package/skills/experience-cms-content-render/assets/shared/mediaLabels.ts +62 -0
- package/skills/experience-cms-content-render/references/init-scaffold.md +13 -6
- package/skills/experience-content-media-stock-image-search/SKILL.md +0 -1
- package/skills/experience-lwc-accessibility-jest-run/SKILL.md +104 -25
- package/skills/experience-lwc-accessibility-jest-run/assets/jest.config.js +4 -0
- package/skills/experience-lwc-accessibility-jest-run/assets/sa11y-jest-setup.js +5 -0
- package/skills/experience-lwc-design-generate/SKILL.md +1 -1
- package/skills/experience-lwc-legacy-migrate/SKILL.md +212 -0
- package/skills/experience-lwc-legacy-migrate/assets/lo20-host-page-template.html +192 -0
- package/skills/experience-lwc-legacy-migrate/references/aura-to-lwc-completeness-checklist.md +188 -0
- package/skills/experience-lwc-legacy-migrate/references/lightning-out-2-system-reference.md +495 -0
- package/skills/experience-lwc-legacy-migrate/references/lightning-out-beta-to-2-migration.md +824 -0
- package/skills/experience-lwc-legacy-migrate/scripts/convert-lo-names.py +94 -0
- package/skills/experience-lwc-legacy-migrate/scripts/validate-lo20-page.py +133 -0
- package/skills/experience-ui-bundle-app-coordinate/SKILL.md +5 -5
- package/skills/experience-ui-bundle-features-generate/SKILL.md +65 -36
- package/skills/experience-ui-bundle-features-generate/references/angular/features.md +74 -0
- package/skills/experience-ui-bundle-features-generate/references/react/features.md +59 -0
- package/skills/experience-ui-bundle-features-generate/scripts/detect-framework.sh +73 -0
- package/skills/experience-ui-bundle-frontend-generate/SKILL.md +2 -2
- package/skills/experience-ui-bundle-metadata-generate/SKILL.md +26 -14
- package/skills/experience-ui-bundle-metadata-generate/references/angular-metadata-generate.md +37 -0
- package/skills/experience-ui-bundle-metadata-generate/references/react-metadata-generate.md +32 -0
- package/skills/experience-ui-bundle-metadata-generate/scripts/detect-framework.sh +73 -0
- package/skills/experience-ui-bundle-metadata-generate/scripts/verify-bundle-location.sh +30 -8
- package/skills/experience-ui-bundle-project-generate/SKILL.md +1 -1
- package/skills/field-service-data-capture-migrate/SKILL.md +391 -0
- package/skills/field-service-data-capture-migrate/assets/sample-legacy-flow.flow-meta.xml +163 -0
- package/skills/field-service-data-capture-migrate/references/architecture-notes.md +40 -0
- package/skills/field-service-data-capture-migrate/references/component-mapping.md +278 -0
- package/skills/field-service-data-capture-migrate/references/converter-builder-contract.md +183 -0
- package/skills/field-service-data-capture-migrate/references/dc-platform-rules.md +130 -0
- package/skills/field-service-data-capture-migrate/references/fsm-dc-capability-catalog.md +215 -0
- package/skills/field-service-data-capture-migrate/references/known-deploy-errors.md +36 -0
- package/skills/field-service-data-capture-migrate/references/migration-checklist.md +121 -0
- package/skills/field-service-data-capture-migrate/references/transformer-rules.md +132 -0
- package/skills/field-service-data-capture-migrate/scripts/analyze_flow.py +277 -0
- package/skills/field-service-data-capture-migrate/scripts/convert_to_dc_spec.py +1311 -0
- package/skills/field-service-data-capture-migrate/scripts/cud_analysis.py +402 -0
- package/skills/field-service-data-capture-migrate/scripts/deploy_flow.sh +230 -0
- package/skills/field-service-data-capture-migrate/scripts/discover_subflow_tree.py +230 -0
- package/skills/field-service-data-capture-migrate/scripts/flow_input.py +186 -0
- package/skills/field-service-data-capture-migrate/scripts/flow_xml_utils.py +39 -0
- package/skills/field-service-data-capture-migrate/scripts/fsm_dc_catalog.py +413 -0
- package/skills/field-service-data-capture-migrate/scripts/generate_summary.py +199 -0
- package/skills/field-service-data-capture-migrate/scripts/json_to_flow_xml.py +146 -0
- package/skills/field-service-data-capture-migrate/scripts/manual_review_flags.py +42 -0
- package/skills/field-service-data-capture-migrate/scripts/retrieve_flow_rest.sh +155 -0
- package/skills/field-service-data-capture-migrate/scripts/subflow_names.py +49 -0
- package/skills/field-service-data-capture-migrate/scripts/transform_flow.py +1661 -0
- package/skills/field-service-data-capture-migrate/scripts/validate_flow.sh +147 -0
- package/skills/field-service-data-capture-migrate/scripts/vendor/build_flow.py +1258 -0
- package/skills/integration-connectivity-connected-app-configure/SKILL.md +5 -5
- package/skills/integration-connectivity-generate/SKILL.md +10 -10
- package/skills/integration-connectivity-generate/scripts/configure-named-credential.sh +2 -2
- package/skills/life-sciences-fieldsalesrep-coordinate/SKILL.md +1 -1
- package/skills/life-sciences-fieldsalesrep-coordinate/references/orchestration-flow.md +1 -1
- package/skills/life-sciences-kam-coordinate/references/stage-5-data-and-plan-templates-overview.md +14 -1
- package/skills/mobile-apps-create/SKILL.md +1 -1
- package/skills/{platform-agentsetup-categories-fetch → platform-agenticsetup-categories-get}/SKILL.md +7 -7
- package/skills/platform-apex-test-generate/SKILL.md +1 -1
- package/skills/platform-apex-test-run/SKILL.md +1 -1
- package/skills/platform-custom-field-generate/SKILL.md +1 -1
- package/skills/platform-custom-lightning-type-generate/SKILL.md +1 -1
- package/skills/platform-custom-metadata-type-generate/SKILL.md +1 -1
- package/skills/platform-custom-object-generate/SKILL.md +1 -1
- package/skills/platform-custom-report-type-generate/SKILL.md +1 -1
- package/skills/platform-custom-setting-generate/SKILL.md +1 -1
- package/skills/platform-data-and-tooling-api-context-get/SKILL.md +1 -1
- package/skills/platform-data-manage/SKILL.md +10 -10
- package/skills/platform-flexipage-generate/SKILL.md +1 -1
- package/skills/platform-lightning-app-coordinate/SKILL.md +1 -1
- package/skills/platform-metadata-api-context-get/SKILL.md +1 -1
- package/skills/platform-metadata-retrieve/SKILL.md +1 -1
- package/skills/platform-permission-set-generate/SKILL.md +1 -1
- package/skills/platform-report-generate/SKILL.md +1 -1
- package/skills/platform-salesforce-connect-adapter-generate/SKILL.md +4 -4
- package/skills/platform-sandbox-configure/SKILL.md +108 -133
- package/skills/platform-sandbox-configure/references/api-response-shapes.md +39 -0
- package/skills/platform-sandbox-configure/references/definition-file-approach.md +73 -0
- package/skills/platform-sharing-owd-configure/SKILL.md +1 -1
- package/skills/platform-sharing-rules-generate/SKILL.md +1 -1
- package/skills/platform-soql-query/SKILL.md +1 -1
- package/skills/platform-value-set-generate/SKILL.md +1 -1
- package/skills/platform-widget-generate/SKILL.md +26 -18
- package/skills/platform-widget-generate/examples/formulas.json +191 -0
- package/skills/platform-widget-generate/references/widget-formulas.md +123 -0
- package/skills/platform-widget-generate/references/widget-meta-directives.md +4 -4
- package/skills/sales-call-scoring-configure/SKILL.md +318 -0
- package/skills/sales-call-scoring-configure/assets/best-practice-competencies.json +67 -0
- package/skills/sales-call-scoring-configure/assets/ootb-competencies.json +58 -0
- package/skills/sales-call-scoring-configure/references/admin-communication.md +79 -0
- package/skills/sales-call-scoring-configure/references/competency-crud.md +130 -0
- package/skills/sales-call-scoring-configure/scripts/create-competency.sh +166 -0
- package/skills/sales-call-scoring-configure/scripts/create-custom-competency.sh +166 -0
- package/skills/sales-call-scoring-configure/scripts/edit-competency.sh +185 -0
- package/skills/sales-call-scoring-configure/scripts/edit-custom-competency.sh +190 -0
- package/skills/sales-call-scoring-configure/scripts/enable-call-scoring.sh +436 -0
- package/skills/sales-call-scoring-configure/scripts/get-competency.sh +72 -0
- package/skills/sales-call-scoring-configure/scripts/get-custom-competency.sh +78 -0
- package/skills/sales-call-scoring-configure/scripts/install-best-practice-competencies.sh +223 -0
- package/skills/sales-call-scoring-configure/scripts/install-ootb-competencies.sh +237 -0
- package/skills/sales-call-scoring-configure/scripts/list-competencies.sh +99 -0
- package/skills/sales-call-scoring-configure/scripts/shared/auth.sh +116 -0
- package/skills/sales-call-scoring-configure/scripts/shared/cap.sh +86 -0
- package/skills/sales-call-scoring-configure/scripts/shared/soap.sh +267 -0
- package/skills/sales-call-scoring-configure/scripts/shared/soql.sh +25 -0
- package/skills/sales-call-scoring-configure/scripts/toggle-competency.sh +112 -0
- package/skills/sales-call-scoring-configure/scripts/toggle-custom-competency.sh +125 -0
- package/skills/sales-call-scoring-configure/scripts/verify-ootb-competencies.sh +116 -0
- package/skills/service-agentforce-human-escalation-configure/SKILL.md +4 -0
- package/skills/service-agentforce-human-escalation-configure/scripts/tests/_bootstrap.py +26 -6
- package/skills/service-agentforce-human-escalation-configure/scripts/tests/test_escalation_contracts.py +5 -4
- package/skills/service-concierge-portal-generate/references/portal-deploy-runbook.md +1 -0
- package/skills/service-de-channel-activate/SKILL.md +6 -5
- package/skills/service-de-channel-create/SKILL.md +3 -3
- package/skills/service-de-channel-routing-configure/SKILL.md +3 -3
- package/skills/service-de-channel-settings-configure/SKILL.md +195 -0
- package/skills/service-de-channel-settings-configure/references/channel-settings-facets.md +152 -0
- package/skills/{service-de-channel-consent-configure → service-de-channel-settings-configure}/references/gotchas.md +3 -3
- package/skills/{service-de-channel-consent-configure → service-de-channel-settings-configure}/references/language-keywords.md +4 -4
- package/skills/{service-de-channel-consent-configure → service-de-channel-settings-configure}/references/worked-examples.md +14 -14
- package/skills/service-de-headless-channel-configure/SKILL.md +6 -6
- package/skills/service-de-headless-channel-configure/references/worked-examples.md +1 -1
- package/skills/service-de-waba-integrate/SKILL.md +2 -1
- package/skills/service-digital-engagement-deployment-configure/SKILL.md +2 -0
- package/skills/service-digital-engagement-deployment-configure/scripts/check-api-version.sh +29 -0
- package/skills/service-email-to-case-configure/SKILL.md +1 -1
- package/skills/service-helpagent-coordinate/SKILL.md +3 -2
- package/skills/service-helpagent-coordinate/references/channel-voice.md +15 -4
- package/skills/service-itsm-agentic-setup-agentforce-coordinate/SKILL.md +49 -31
- package/skills/service-itsm-agentic-setup-agentforce-coordinate/examples/output-templates.md +71 -6
- package/skills/service-itsm-agentic-setup-agentforce-coordinate/scripts/verify-child-verdict.mjs +26 -4
- package/skills/service-itsm-agentic-setup-cmdb-access-assign/SKILL.md +35 -10
- package/skills/service-itsm-agentic-setup-cmdb-access-assign/references/mcp-invocation.md +25 -5
- package/skills/service-itsm-agentic-setup-cmdb-bundle-deploy/SKILL.md +1 -1
- package/skills/service-itsm-agentic-setup-cmdb-configure/SKILL.md +5 -5
- package/skills/service-itsm-agentic-setup-cmdb-configure/references/mcp-invocation.md +1 -1
- package/skills/service-itsm-agentic-setup-cmdb-coordinate/SKILL.md +2 -2
- package/skills/service-itsm-agentic-setup-cmdb-coordinate/examples/output-templates.md +1 -1
- package/skills/service-itsm-agentic-setup-cmdb-discovery-configure/SKILL.md +25 -15
- package/skills/service-itsm-agentic-setup-employee-agent-configure/SKILL.md +8 -5
- package/skills/service-itsm-agentic-setup-employee-agent-configure/references/report-format.md +4 -2
- package/skills/service-itsm-agentic-setup-employee-agent-configure/references/workflow-detail.md +1 -1
- package/skills/service-itsm-agentic-setup-employee-agent-configure/scripts/render-report.mjs +29 -16
- package/skills/service-itsm-agentic-setup-fulfiller-agent-configure/SKILL.md +8 -5
- package/skills/service-itsm-agentic-setup-fulfiller-agent-configure/references/report-format.md +4 -2
- package/skills/service-itsm-agentic-setup-fulfiller-agent-configure/references/workflow-detail.md +1 -1
- package/skills/service-itsm-agentic-setup-fulfiller-agent-configure/scripts/render-report.mjs +29 -16
- package/skills/service-itsm-agentic-setup-incident-management/SKILL.md +138 -68
- package/skills/service-itsm-agentic-setup-incident-management/examples/output-templates.md +31 -15
- package/skills/service-itsm-agentic-setup-incident-management/references/incident-persona-psg.md +156 -0
- package/skills/service-itsm-agentic-setup-incident-management/references/incident-preferences.md +148 -0
- package/skills/service-itsm-agentic-setup-incident-management/references/major-incident-management.md +162 -0
- package/skills/service-itsm-agentic-setup-incident-management/references/service-mgmt-privilege.md +149 -0
- package/skills/service-itsm-agentic-setup-incident-sla-configure/SKILL.md +103 -89
- package/skills/service-itsm-agentic-setup-incident-sla-configure/assets/attach-milestone.json +2 -2
- package/skills/service-itsm-agentic-setup-incident-sla-configure/assets/predefined-incident-policy.json +21 -39
- package/skills/service-itsm-agentic-setup-incident-sla-configure/examples/milestone-patterns.md +3 -3
- package/skills/service-itsm-agentic-setup-incident-sla-configure/examples/output-templates.md +18 -1
- package/skills/service-itsm-agentic-setup-incident-sla-configure/references/mcp-invocation.md +63 -37
- package/skills/service-omni-attribute-routing-configure/SKILL.md +53 -0
- package/skills/service-omni-attribute-routing-configure/references/api-notes.md +7 -0
- package/skills/service-omni-attribute-routing-configure/scripts/configure-and-report.sh +224 -0
- package/skills/service-omni-attribute-routing-configure/scripts/tests/test_attribute_routing_contracts.py +137 -0
- package/skills/service-omni-channel-inventory-analyze/SKILL.md +96 -0
- package/skills/service-omni-channel-inventory-analyze/references/api-notes.md +52 -0
- package/skills/service-omni-channel-inventory-analyze/scripts/analyze.sh +185 -0
- package/skills/service-omni-channel-inventory-analyze/scripts/tests/_bootstrap.py +84 -0
- package/skills/service-omni-channel-inventory-analyze/scripts/tests/test_inventory_analyze_contracts.py +141 -0
- package/skills/service-omni-channel-limits-analyze/SKILL.md +70 -0
- package/skills/service-omni-channel-limits-analyze/references/api-notes.md +22 -0
- package/skills/service-omni-channel-limits-analyze/scripts/analyze.sh +159 -0
- package/skills/service-omni-channel-limits-analyze/scripts/tests/_bootstrap.py +87 -0
- package/skills/service-omni-channel-limits-analyze/scripts/tests/test_limits_analyze_contracts.py +99 -0
- package/skills/service-omni-channel-setup-coordinate/SKILL.md +12 -20
- package/skills/service-omni-channel-setup-coordinate/scripts/integration-driver.sh +55 -5
- package/skills/service-omni-channel-setup-coordinate/scripts/tests/test_omni_contracts.py +38 -0
- package/skills/service-omni-command-center-analyze/SKILL.md +2 -2
- package/skills/service-omni-command-center-analyze/scripts/analyze.sh +3 -3
- package/skills/dx-org-manage/examples/snapshots/error_output.json +0 -9
- package/skills/dx-org-manage/examples/snapshots/success_output.json +0 -15
- package/skills/dx-org-manage/references/cli_flags.md +0 -67
- package/skills/dx-org-manage/references/creating-snapshot.md +0 -103
- package/skills/dx-org-manage/references/snapshot_usage.md +0 -74
- package/skills/experience-accessibility-validate/scripts/contrast-ratio.py +0 -153
- package/skills/experience-lwc-accessibility-jest-run/references/running-sa11y-jest-tests.md +0 -205
- package/skills/experience-ui-bundle-features-generate/scripts/verify-react-bundle.sh +0 -14
- /package/skills/experience-ui-bundle-features-generate/references/{conflict-resolution-schema.json → common/conflict-resolution-schema.json} +0 -0
- /package/skills/{platform-agentsetup-categories-fetch → platform-agenticsetup-categories-get}/references/api-response-schema.md +0 -0
|
@@ -0,0 +1,383 @@
|
|
|
1
|
+
---
|
|
2
|
+
name: consumer-goods-accruals-datakit-deploy
|
|
3
|
+
description: "Use this skill to deploy the TPM Liability Accruals data kit end to end to a Salesforce org. Invoke when a customer or teammate wants to install the accrual engine, verify the Data Cloud connection, deploy the Data Kit components, and schedule the export and accrual calculation chain. Trigger phrases include: 'deploy the accrual data kit', 'set up liability accruals', 'install TPM accruals', 'headless accruals setup', 'configure the Data Cloud export connector', 'schedule the accrual chain'. Do NOT use for creating a Data Space alone (use platform-dataspace-access-configure), for generic Salesforce metadata deployment (use platform-metadata-deploy), for querying org data only (use platform-soql-query), or when setting up the data kit for the Trade Promotion Effectiveness (TPE) feature (use consumer-goods-tpe-datakit-deploy instead)."
|
|
4
|
+
metadata:
|
|
5
|
+
version: "1.0"
|
|
6
|
+
domains: ["Consumer Goods"]
|
|
7
|
+
relatedSkills:
|
|
8
|
+
- "consumer-goods-tpe-datakit-deploy"
|
|
9
|
+
- "platform-dataspace-access-configure"
|
|
10
|
+
- "platform-metadata-deploy"
|
|
11
|
+
- "platform-soql-query"
|
|
12
|
+
minApiVersion: "62.0"
|
|
13
|
+
cliTools:
|
|
14
|
+
- tool: ["node"]
|
|
15
|
+
semver: ">=22.0.0"
|
|
16
|
+
- tool: ["sf"]
|
|
17
|
+
semver: ">=2.0.0"
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
## MANDATORY: Always write the Phase 6 report
|
|
21
|
+
|
|
22
|
+
After completing all phases — including early stops, blocked phases, or error conditions — you MUST write the Phase 6 report to disk. Failure to write the report is always a test failure, regardless of how well you handled the scenario.
|
|
23
|
+
|
|
24
|
+
This applies to **ALL exit paths** without exception:
|
|
25
|
+
- Normal completion (all phases ran)
|
|
26
|
+
- Phase 1 stop (preflight failed, sales org not found, CGCloudAddons missing, Data Cloud not enabled)
|
|
27
|
+
- Phase 3 error (setup script non-zero exit)
|
|
28
|
+
- Phase 4 failure detection (DataKitDeploymentLog failures)
|
|
29
|
+
- Schedule conflict (Phase 5 guard triggered)
|
|
30
|
+
- Any other blocking condition (missing inputs, org unreachable, etc.)
|
|
31
|
+
|
|
32
|
+
Write the report to `${outputDir}/report.md` (the path from the `generatedFileLocationDirective` in the task). Do not print it as a chat message only — it must exist as a file on disk. If you handled a scenario correctly but never wrote the file, the eval will record `no_output` and score zero.
|
|
33
|
+
|
|
34
|
+
---
|
|
35
|
+
|
|
36
|
+
# Deploy the Accrual Data Kit
|
|
37
|
+
|
|
38
|
+
Installs the TPM Liability Accruals solution into a Salesforce org end to end.
|
|
39
|
+
Runs the full setup toolchain bundled in `scripts/`: checks the org is ready,
|
|
40
|
+
verifies the Data Cloud connection, downloads the `CGCloudAddons` static resource,
|
|
41
|
+
deploys the data kit, confirms the deployment, and schedules the Data Cloud export
|
|
42
|
+
and accrual calculation chain.
|
|
43
|
+
|
|
44
|
+
Designed for **headless delivery**: point it at an org and it runs the full install.
|
|
45
|
+
|
|
46
|
+
The namespace differs per build: `cgcloud` (released), `cgcloud_dev` (dev/beta), or no
|
|
47
|
+
prefix (source-only). The setup script auto-detects the prefix at runtime via the
|
|
48
|
+
`DataCloudExportScheduler` Apex class query. **Never hardcode `cgcloud.` or `cgcloud_dev.`.**
|
|
49
|
+
|
|
50
|
+
Reference: [TPM Accrual Engine concept](https://help.salesforce.com/s/articleView?id=ind.tpm_concept_accruals.htm&type=5)
|
|
51
|
+
|
|
52
|
+
Run the setup script from the skill root directory:
|
|
53
|
+
```bash
|
|
54
|
+
node scripts/setup.js --org <alias> [options]
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
---
|
|
58
|
+
|
|
59
|
+
## Inputs to collect
|
|
60
|
+
|
|
61
|
+
**Collect and validate ALL required inputs before running any Phase 1 checks.** Do not start Phase 1 until org alias and sales org name are both confirmed. If either is missing after asking, stop immediately and write the Phase 6 report.
|
|
62
|
+
|
|
63
|
+
Ask before starting — do not guess.
|
|
64
|
+
|
|
65
|
+
| Input | Default | Notes |
|
|
66
|
+
|---|---|---|
|
|
67
|
+
| **Org alias / username** | — | `sf` alias of the target org. Required. |
|
|
68
|
+
| **Sales org name** | — | Used to name the Data Space (`DataSpace_<salesOrg>`), its prefix (`DS<lastChar>_`), and the UI controller map key. **Required. Must be exactly 4 alphanumeric characters (e.g. `0001`, `AB12`). If the user has not provided it and cannot provide it, do NOT guess or use any default value — stop immediately, write the Phase 6 report with Phase 1 blocked ("sales org name not provided"), and end the session. Do not run any Phase 1 checks without it.** |
|
|
69
|
+
| **Skip Data Space?** | no | Yes only if the org has no Data Spaces (some demo orgs). |
|
|
70
|
+
| **Dry run?** | no | Prepares files; skips all deploys and scheduling. Offer this first. |
|
|
71
|
+
| **Namespace override** | auto-detected | Pass only if auto-detection would fail. Value WITHOUT trailing `__`. |
|
|
72
|
+
| **Export cron** | `0 0 2 * * ?` | Only prompt if user requests a different schedule. |
|
|
73
|
+
| **Accrual chain cron** | `0 0 3 * * ?` | Only prompt if user requests a different schedule. |
|
|
74
|
+
|
|
75
|
+
The dry-run flag is collected once here and honored through all phases — do not re-prompt.
|
|
76
|
+
|
|
77
|
+
---
|
|
78
|
+
|
|
79
|
+
## Phase 1 — Preflight
|
|
80
|
+
|
|
81
|
+
Stop on first failure. Do not continue past a failed check.
|
|
82
|
+
|
|
83
|
+
### 1.1 Local tooling
|
|
84
|
+
1. **Salesforce CLI present:** `sf --version`
|
|
85
|
+
2. **Node 22:** `node --version`
|
|
86
|
+
|
|
87
|
+
### 1.2 Org reachable
|
|
88
|
+
```bash
|
|
89
|
+
sf org display --target-org <alias> --json
|
|
90
|
+
```
|
|
91
|
+
Confirm `status` is `Active`. Capture `id` (org id), `instanceUrl`, `apiVersion`.
|
|
92
|
+
Non-zero exit or inactive status → stop, ask user to log in.
|
|
93
|
+
|
|
94
|
+
### 1.3 Data Cloud Data Kit framework present
|
|
95
|
+
```bash
|
|
96
|
+
sf data query --target-org <alias> \
|
|
97
|
+
--query "SELECT Id FROM DataKitDeploymentLog LIMIT 1"
|
|
98
|
+
```
|
|
99
|
+
`INVALID_TYPE` or `NOT_FOUND` → **stop immediately**: the Data Cloud Data Kit framework
|
|
100
|
+
is not enabled in this org. Tell the user they must enable Data Cloud and the Data Kit
|
|
101
|
+
feature before this skill can proceed. Write the Phase 6 report now with Phase 1 blocked
|
|
102
|
+
and the exact query error. Do NOT run any further queries, downloads, or deploys.
|
|
103
|
+
Zero rows is fine — the framework is present, continue to Phase 1.4.
|
|
104
|
+
|
|
105
|
+
### 1.4 CGCloudAddons static resource present
|
|
106
|
+
```bash
|
|
107
|
+
sf data query --target-org <alias> \
|
|
108
|
+
--query "SELECT Id FROM StaticResource WHERE Name='CGCloudAddons'"
|
|
109
|
+
```
|
|
110
|
+
Zero rows → **stop immediately**: the managed package is not installed (or this version
|
|
111
|
+
does not ship `CGCloudAddons`). Tell the user the package must be installed before
|
|
112
|
+
proceeding. Write the Phase 6 report now with Phase 1 blocked: `CGCloudAddons not found`.
|
|
113
|
+
Do NOT attempt to download, deploy, or schedule anything after this failure.
|
|
114
|
+
|
|
115
|
+
### 1.5 Sales org validation
|
|
116
|
+
```bash
|
|
117
|
+
sf data query --target-org <alias> --json \
|
|
118
|
+
--query "SELECT Id, Name FROM Sales_Organization__c WHERE Name = '<salesOrg>'"
|
|
119
|
+
```
|
|
120
|
+
Zero rows → **stop immediately**: the sales org name provided does not exist in this org.
|
|
121
|
+
Show the user the query and the zero-row result. Do NOT proceed to deploy or schedule.
|
|
122
|
+
Record Phase 1 as blocked: `Sales org '<salesOrg>' not found`.
|
|
123
|
+
|
|
124
|
+
### 1.6 Deployment baseline
|
|
125
|
+
```bash
|
|
126
|
+
sf data query --target-org <alias> --json \
|
|
127
|
+
--query "SELECT MAX(CreatedDate) maxCreated FROM DataKitDeploymentLog"
|
|
128
|
+
```
|
|
129
|
+
The aggregate query always returns exactly one row. `maxCreated` is `null` when the
|
|
130
|
+
table is empty (first-ever deployment). Store `DEPLOY_BASELINE_TIME = maxCreated ?? ''`
|
|
131
|
+
(treat null as empty string). Phase 4 uses `WHERE CreatedDate > DEPLOY_BASELINE_TIME`
|
|
132
|
+
only when `DEPLOY_BASELINE_TIME` is non-empty; omit the `WHERE` clause entirely when it
|
|
133
|
+
is empty — `WHERE CreatedDate > null` is an `INVALID_QUERY_FILTER_OPERATOR` error in
|
|
134
|
+
Salesforce SOQL and will abort the query.
|
|
135
|
+
|
|
136
|
+
### 1.7 Org-side manual prerequisites
|
|
137
|
+
The setup script (Step 0) displays the full prerequisites list and waits for user
|
|
138
|
+
confirmation before proceeding. If the user's prompt already confirms these, treat them
|
|
139
|
+
as confirmed — do **not** re-ask. Only ask for items the user has not already addressed:
|
|
140
|
+
- Data Cloud and Analytics Studio enabled (Setup → Data Cloud Setup)
|
|
141
|
+
- Connectors feature enabled (Data Cloud Setup → Feature Manager)
|
|
142
|
+
- A user assigned to the **Accrual Ingestion Process** in Processing Services Pairing
|
|
143
|
+
with the **Data Cloud Architect** permission set
|
|
144
|
+
- OAuth scope **`cdp_ingest_api`** configured on the integration app used by TPM Offcore.
|
|
145
|
+
This may be a **Connected App** or an **External Client App** depending on the org —
|
|
146
|
+
the app name varies by configuration. Verify via Setup → App Manager (Connected Apps)
|
|
147
|
+
or Setup → External Client Apps. Do NOT assume any specific app name.
|
|
148
|
+
- Permission sets assigned to the System Admin (and to the Accrual Ingestion Process user):
|
|
149
|
+
- **Data Cloud Architect**
|
|
150
|
+
- CRM Analytics must be enabled first (Setup → Feature Settings → Analytics → Analytics → Getting Started → "Enable CRM Analytics"), then assign to the admin:
|
|
151
|
+
- **CRM Analytics Plus Admin**
|
|
152
|
+
|
|
153
|
+
---
|
|
154
|
+
|
|
155
|
+
## Phase 2 — Verify the Data Cloud connection (best-effort)
|
|
156
|
+
|
|
157
|
+
The OAuth client used by TPM Offcore can be a **Connected App** or an **External Client
|
|
158
|
+
App**, and the app name varies by org configuration — it cannot be queried reliably by
|
|
159
|
+
name. Skip the programmatic check. Instead, if the user has not already confirmed
|
|
160
|
+
`cdp_ingest_api` as part of Phase 1.7, ask them to verify it manually:
|
|
161
|
+
|
|
162
|
+
> "Please confirm that `cdp_ingest_api` is in the selected OAuth scopes for the
|
|
163
|
+
> integration app used by TPM Offcore. You can check under Setup → App Manager
|
|
164
|
+
> (for Connected Apps) or Setup → External Client Apps."
|
|
165
|
+
|
|
166
|
+
Continue once the user confirms. Do not block on this — treat unconfirmed as WARN in
|
|
167
|
+
the Phase 6 report.
|
|
168
|
+
|
|
169
|
+
---
|
|
170
|
+
|
|
171
|
+
## Phase 3 — Run the setup script
|
|
172
|
+
|
|
173
|
+
Run the end-to-end setup script from the skill's own root directory. In dry-run mode, pass `--dry-run`.
|
|
174
|
+
|
|
175
|
+
```bash
|
|
176
|
+
node scripts/setup.js --org <alias> --sales-org <salesOrg> [--skip-dataspace] [--dry-run] [--namespace <ns>]
|
|
177
|
+
```
|
|
178
|
+
|
|
179
|
+
If `scripts/setup.js` is not accessible in the current working directory, record Phase 3 as
|
|
180
|
+
`not run — script path not accessible in this environment` in the Phase 6 report and
|
|
181
|
+
proceed directly to Phase 4 (query `DataKitDeploymentLog` for any rows after `DEPLOY_BASELINE_TIME`).
|
|
182
|
+
|
|
183
|
+
The script runs these steps in order:
|
|
184
|
+
|
|
185
|
+
- **Step 0** — Prerequisites confirmation (interactive prompt, skipped in dry-run)
|
|
186
|
+
- **Step 1** — Download `CGCloudAddons` static resource
|
|
187
|
+
- **Step 2** — Replace `__SF_ORG_ID__` placeholders in data kit metadata
|
|
188
|
+
- **Step 3** — Deploy TPM Accruals Data Kit metadata (`sf project deploy start`)
|
|
189
|
+
- **Step 4** — Deploy Liability Accruals Engine data kit via `sfdatakit__DeployDataKitComponents`
|
|
190
|
+
(skips already-deployed components; waits up to 30 min for completion)
|
|
191
|
+
- **Step 5** — Deploy TPM Accruals data kit via `sfdatakit__DeployDataKitComponents`
|
|
192
|
+
(same pattern; also waits for completion)
|
|
193
|
+
- **Step 6** — Create Data Space (manual prompt — see below; skipped with `--skip-dataspace`)
|
|
194
|
+
- **Step 7** — Deploy Accruals Reports metadata with Data Space placeholder replacements (two-pass)
|
|
195
|
+
- **Step 8** — Deploy `TPMAccrualTacticSummary` UI component with namespace and Data Space replacements
|
|
196
|
+
- **Step 9** — Print scheduling instructions
|
|
197
|
+
|
|
198
|
+
The script pauses at **Step 0** (prerequisites confirmation) and **Step 6** (Data Space
|
|
199
|
+
creation). When it pauses, capture the stdout block starting at `=== Step N:` and relay
|
|
200
|
+
it verbatim to the user. Wait for the user to complete the step before continuing.
|
|
201
|
+
|
|
202
|
+
Adding the `TPMAccrualTacticSummary` UI component to the Promotion page is a
|
|
203
|
+
post-run manual step — the script only prints the instruction. Track it as pending in
|
|
204
|
+
Phase 6.
|
|
205
|
+
|
|
206
|
+
On non-zero exit → stop and surface the last 50 lines of stdout. Do not proceed to
|
|
207
|
+
Phase 4 on a failed script.
|
|
208
|
+
|
|
209
|
+
---
|
|
210
|
+
|
|
211
|
+
## Phase 4 — Verify deployment
|
|
212
|
+
|
|
213
|
+
**Skip this entire phase in dry-run mode.** Record it as `pending — not run (dry-run)` in the report.
|
|
214
|
+
|
|
215
|
+
```bash
|
|
216
|
+
sf data query --target-org <alias> --json \
|
|
217
|
+
--query "SELECT ComponentName, DeploymentStatus, DeploymentError, CreatedDate
|
|
218
|
+
FROM DataKitDeploymentLog
|
|
219
|
+
WHERE CreatedDate > ${DEPLOY_BASELINE_TIME}
|
|
220
|
+
ORDER BY CreatedDate ASC
|
|
221
|
+
LIMIT 200"
|
|
222
|
+
```
|
|
223
|
+
(Omit `WHERE` clause if `DEPLOY_BASELINE_TIME` is empty. Always include `LIMIT 200`.)
|
|
224
|
+
|
|
225
|
+
Evaluate the rows:
|
|
226
|
+
|
|
227
|
+
- Any `DeploymentStatus = 'Failure'` or non-empty `DeploymentError` → **stop**, list every
|
|
228
|
+
failing component name and its `DeploymentError` value. Do not proceed to Phase 5.
|
|
229
|
+
Record Phase 5 as `not run — deployment failures unresolved` in the Phase 6 report.
|
|
230
|
+
- Any `InProgress` row → wait 60 s and re-query. **Do not advance to Phase 5 until all
|
|
231
|
+
rows are in a terminal state** (`Successful` or `Failure`). DataKit deployments on
|
|
232
|
+
production orgs typically take 60–90 minutes. The setup script (`node scripts/setup.js`)
|
|
233
|
+
has an internal 90-minute polling timeout — if the script exits with a timeout error,
|
|
234
|
+
**do not treat this as a failure**: query `DataKitDeploymentLog` directly in the agent
|
|
235
|
+
Phase 4 loop (as shown above) and continue polling until terminal state or a genuine
|
|
236
|
+
liveness signal is lost (org unreachable, explicit Failure rows). Surface live counts
|
|
237
|
+
periodically so the user can see progress.
|
|
238
|
+
- Zero rows → the deployment has not produced log entries yet; re-query every 60 s up to
|
|
239
|
+
30 minutes. Treat persistent zero rows as a deployment problem — stop and report.
|
|
240
|
+
- All rows `Successful` → proceed to Phase 5.
|
|
241
|
+
- Never advance to Phase 5 while any row is `InProgress`, `Failure`, or
|
|
242
|
+
while zero rows have been returned within the polling window.
|
|
243
|
+
|
|
244
|
+
---
|
|
245
|
+
|
|
246
|
+
## Phase 5 — Schedule
|
|
247
|
+
|
|
248
|
+
In dry-run mode: still run steps 5.1 (namespace detection — read-only) and 5.2 (cron
|
|
249
|
+
job check — read-only), print the fully-substituted Apex that would be run, but do NOT
|
|
250
|
+
execute `sf apex run`. Record Phase 5 as `pending — not run (dry-run)` in the report.
|
|
251
|
+
|
|
252
|
+
### 5.1 Detect namespace prefix
|
|
253
|
+
|
|
254
|
+
Query the installed class (same probe used by `scripts/steps/utils.js`):
|
|
255
|
+
|
|
256
|
+
```bash
|
|
257
|
+
sf data query --target-org <alias> --json \
|
|
258
|
+
--query "SELECT NamespacePrefix FROM ApexClass WHERE Name='DataCloudExportScheduler'"
|
|
259
|
+
```
|
|
260
|
+
|
|
261
|
+
| Query result | `NS_PREFIX` | Meaning |
|
|
262
|
+
|---|---|---|
|
|
263
|
+
| 0 rows | — | Scheduler class not deployed → **STOP**: Phase 3 did not complete |
|
|
264
|
+
| 1 row, null | `""` | Unmanaged source deploy |
|
|
265
|
+
| 1 row, any value | that value | Use whatever namespace the query returns |
|
|
266
|
+
| >1 row | — | Ambiguous → **STOP**, print all rows |
|
|
267
|
+
|
|
268
|
+
Compose the dotted prefix:
|
|
269
|
+
```bash
|
|
270
|
+
NS="${NS_PREFIX:+${NS_PREFIX}.}" # yields "cgcloud.", "cgcloud_dev.", or ""
|
|
271
|
+
```
|
|
272
|
+
|
|
273
|
+
Every Apex identifier below is written as `${NS}ClassName`.
|
|
274
|
+
|
|
275
|
+
### 5.2 Guard duplicate cron jobs
|
|
276
|
+
```bash
|
|
277
|
+
sf data query --target-org <alias> --json \
|
|
278
|
+
--query "SELECT Id, State, CronJobDetail.Name FROM CronTrigger
|
|
279
|
+
WHERE CronJobDetail.Name IN
|
|
280
|
+
('DataCloud Export Daily','TPM Accrual Process Chain')"
|
|
281
|
+
```
|
|
282
|
+
If any matching job exists:
|
|
283
|
+
1. Show the user the existing job `Id` and `State` for each conflicting job.
|
|
284
|
+
2. Ask explicitly: abort the existing jobs and reschedule, or skip scheduling?
|
|
285
|
+
3. Do NOT silently overwrite — wait for the user's answer before calling `System.schedule`.
|
|
286
|
+
4. If the user chooses to abort and reschedule: run `System.abortJob('<id>')` for each
|
|
287
|
+
conflicting job, then proceed with 5.3/5.4 and verify the new `CronTrigger` shows
|
|
288
|
+
`State = 'WAITING'` and non-null `NextFireTime`.
|
|
289
|
+
5. Record the conflict and its resolution in the Phase 6 report.
|
|
290
|
+
|
|
291
|
+
**Cron ordering requirement:** the export job (5.3) must fire **before** the accrual
|
|
292
|
+
chain job (5.4) so that Data Cloud data is available when the chain runs. The defaults
|
|
293
|
+
(`exportCron` = `0 0 2 * * ?`, `accrualCron` = `0 0 3 * * ?`) enforce a 1-hour gap.
|
|
294
|
+
When the user provides custom expressions, verify that the export cron precedes the
|
|
295
|
+
accrual cron — a gap of at least 1 hour is the recommended convention. Warn the user
|
|
296
|
+
if the two expressions conflict or are inverted; do not schedule without their
|
|
297
|
+
confirmation.
|
|
298
|
+
|
|
299
|
+
### 5.3 Schedule Data Cloud Connector Export
|
|
300
|
+
|
|
301
|
+
Write the following Apex to a temporary file (e.g. `/tmp/dc-export.apex`), run it,
|
|
302
|
+
then delete the file:
|
|
303
|
+
|
|
304
|
+
```apex
|
|
305
|
+
${NS}DataCloudExportScheduler scheduler = new ${NS}DataCloudExportScheduler(
|
|
306
|
+
new List<String>{ 'promotionmeasures', 'paymenttacticmeasures', 'dailymeasurereal' }
|
|
307
|
+
);
|
|
308
|
+
System.schedule('DataCloud Export Daily', '<exportCron>', scheduler);
|
|
309
|
+
```
|
|
310
|
+
```bash
|
|
311
|
+
# Write to temp file, run, clean up
|
|
312
|
+
cat > /tmp/dc-export.apex << 'EOF'
|
|
313
|
+
<filled-in Apex from above>
|
|
314
|
+
EOF
|
|
315
|
+
sf apex run --target-org <alias> --file /tmp/dc-export.apex
|
|
316
|
+
rm /tmp/dc-export.apex
|
|
317
|
+
```
|
|
318
|
+
Verify: `CronTrigger WHERE CronJobDetail.Name = 'DataCloud Export Daily'` → exactly one
|
|
319
|
+
row, `State = 'WAITING'`, non-null `NextFireTime`.
|
|
320
|
+
|
|
321
|
+
### 5.4 Schedule Accrual Calculation Chain
|
|
322
|
+
|
|
323
|
+
Write the following Apex to a temporary file (e.g. `/tmp/accrual-chain.apex`), run it,
|
|
324
|
+
then delete the file (see Rules — only `'partial'` or `'full'` are valid for `ingestionMode`):
|
|
325
|
+
|
|
326
|
+
```apex
|
|
327
|
+
${NS}ScheduleTPMAccrualProcessChain scheduler =
|
|
328
|
+
new ${NS}ScheduleTPMAccrualProcessChain();
|
|
329
|
+
System.schedule('TPM Accrual Process Chain', '<accrualCron>', scheduler);
|
|
330
|
+
```
|
|
331
|
+
```bash
|
|
332
|
+
# Write to temp file, run, clean up
|
|
333
|
+
cat > /tmp/accrual-chain.apex << 'EOF'
|
|
334
|
+
<filled-in Apex from above>
|
|
335
|
+
EOF
|
|
336
|
+
sf apex run --target-org <alias> --file /tmp/accrual-chain.apex
|
|
337
|
+
rm /tmp/accrual-chain.apex
|
|
338
|
+
```
|
|
339
|
+
Verify with the same `CronTrigger` pattern as 5.3.
|
|
340
|
+
|
|
341
|
+
References:
|
|
342
|
+
- [DataCloudExportScheduler](https://developer.salesforce.com/docs/atlas.en-us.retail_api.meta/retail_api/cg_tpm_apex_datacloudexportscheduler.htm)
|
|
343
|
+
- [ScheduleTPMAccrualProcessChain](https://developer.salesforce.com/docs/atlas.en-us.retail_api.meta/retail_api/global_tpm_accrual_process.htm)
|
|
344
|
+
|
|
345
|
+
---
|
|
346
|
+
|
|
347
|
+
## Phase 6 — Report
|
|
348
|
+
|
|
349
|
+
**Write this report after every run, including early stops.** If execution was blocked at Phase 1 (missing inputs, failed preflight, Data Cloud not enabled, sales org not found), write the report immediately after confirming the stop condition — do not skip it. A correctly handled early stop that produces no report.md file is scored as a failure. If you are in an agentic eval context with a file-output directive, that directive means "write the file when you are done", not "write the file instead of working".
|
|
350
|
+
|
|
351
|
+
Write the report to disk using a shell command (e.g. `Write` tool or `cat > <path>`). Do not just print it as a chat message — it must exist as a file at the path specified in the task directive.
|
|
352
|
+
|
|
353
|
+
**Keep early-stop reports short.** When execution is blocked before Phase 3 starts (missing input, failed preflight), the report only needs to cover what actually happened: the block reason, what was not run, and what the user must provide to retry. Do NOT pad an early-stop report with boilerplate sections for phases that never ran (detailed DataKit deployment rows, schedule conflict resolution, license warnings, manual steps). Those sections are only relevant when the corresponding phases executed. A 3–5 line report is the correct shape for a Phase 1 block.
|
|
354
|
+
|
|
355
|
+
```text
|
|
356
|
+
Deployment report — <org alias, or "not provided">
|
|
357
|
+
Sales org: <salesOrg, or "not provided">
|
|
358
|
+
Dry run: <yes|no>
|
|
359
|
+
Namespace prefix: <detected value, or "(not detected — execution blocked)">
|
|
360
|
+
Phase 1 preflight: <passed | blocked: <exact check that failed>>
|
|
361
|
+
DataKit deployments: <X succeeded / Y failed / Z in progress, or "not run — Phase 1 blocked">
|
|
362
|
+
Data Space: <created | skipped | not run — Phase 1 blocked>
|
|
363
|
+
Data Cloud Export: <scheduled | dry-run | not run — Phase 1 blocked>
|
|
364
|
+
Accrual Chain: <scheduled | dry-run | not run — Phase 1 blocked>
|
|
365
|
+
Pending manual steps: <list, or "none — execution did not complete">
|
|
366
|
+
License warnings: <unconfirmed licenses, or "none — not checked">
|
|
367
|
+
```
|
|
368
|
+
|
|
369
|
+
---
|
|
370
|
+
|
|
371
|
+
## Rules
|
|
372
|
+
|
|
373
|
+
- **Always execute before reporting.** Run every phase to completion (or to a documented stop condition) before writing the Phase 6 report. Never write the report as a substitute for executing the skill — a file-output directive means "write when done", not "write instead of working".
|
|
374
|
+
- **Re-run means re-run.** When asked to re-run or verify an existing deployment, always re-execute `node scripts/setup.js` and capture a fresh `DataKitDeploymentLog` baseline before doing so. Do not treat a prior successful run as sufficient — re-verify against fresh log rows from this run.
|
|
375
|
+
- Never claim success while any `DataKitDeploymentLog` row for this run has
|
|
376
|
+
`DeploymentStatus = 'Failure'` or a non-empty `DeploymentError`.
|
|
377
|
+
- Never claim a schedule succeeded until `CronTrigger` shows `State = 'WAITING'` and
|
|
378
|
+
non-null `NextFireTime`.
|
|
379
|
+
- Stop on the first failed preflight check; report the exact failure.
|
|
380
|
+
- Relay manual-step instructions verbatim from the setup script's stdout and wait for
|
|
381
|
+
the user.
|
|
382
|
+
- Never hardcode namespace prefixes in emitted Apex — always compose from `${NS}`.
|
|
383
|
+
- `ingestionMode` accepts only `'partial'` or `'full'`; `'initial'` throws.
|