@salesforce/afv-skills 1.55.0 → 1.56.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.
Files changed (220) hide show
  1. package/package.json +1 -1
  2. package/skills/agentforce-generate/SKILL.md +8 -0
  3. package/skills/agentforce-generate/references/actions-reference.md +2 -2
  4. package/skills/agentforce-generate/references/voice-modality-reference.md +51 -15
  5. package/skills/agentforce-generate/references/voice-telephony-cli.md +193 -0
  6. package/skills/agentforce-observe/SKILL.md +13 -9
  7. package/skills/agentforce-observe/references/ahm-alerts.md +193 -14
  8. package/skills/automation-sandbox-post-copy-config-generate/SKILL.md +24 -15
  9. package/skills/automation-sandbox-post-copy-config-generate/assets/config_template.json +11 -0
  10. package/skills/automation-sandbox-post-copy-config-generate/assets/json_schema.json +33 -1
  11. package/skills/automation-sandbox-post-copy-config-generate/references/configuration_catalog.md +32 -1
  12. package/skills/automation-sandbox-post-copy-configure/SKILL.md +75 -71
  13. package/skills/automation-sandbox-post-copy-configure/assets/scheduled_apex_template.apex +13 -0
  14. package/skills/automation-sandbox-post-copy-configure/examples/sample_scheduled_apex_config.json +13 -0
  15. package/skills/automation-sandbox-post-copy-configure/references/scheduled_apex_path.md +155 -0
  16. package/skills/automation-sandbox-post-copy-configure/scripts/build-scheduled-apex.mjs +62 -0
  17. package/skills/automation-sandbox-post-copy-configure/scripts/soql-escape-job-name.mjs +28 -0
  18. package/skills/consumer-goods-accruals-datakit-deploy/SKILL.md +383 -0
  19. package/skills/consumer-goods-accruals-datakit-deploy/scripts/setup.js +324 -0
  20. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/00-check-prerequisites.js +63 -0
  21. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/01-download-static-resource.js +100 -0
  22. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/02-replace-org-id.js +46 -0
  23. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/03-deploy-metadata.js +46 -0
  24. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/04-deploy-engine.js +198 -0
  25. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/05-deploy-tpm-accruals.js +231 -0
  26. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/06-create-dataspace.js +82 -0
  27. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/07-deploy-accruals-reports.js +517 -0
  28. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/08-deploy-ui.js +416 -0
  29. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/09-completion.js +44 -0
  30. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/utils.js +514 -0
  31. package/skills/consumer-goods-sync-management-configure/SKILL.md +137 -0
  32. package/skills/consumer-goods-sync-management-configure/examples/scenarios.md +294 -0
  33. package/skills/consumer-goods-sync-management-configure/references/act1-setup-sync.md +333 -0
  34. package/skills/consumer-goods-sync-management-configure/references/act2-assign-users.md +324 -0
  35. package/skills/consumer-goods-sync-management-configure/references/act3-plan-verify.md +113 -0
  36. package/skills/consumer-goods-sync-management-configure/references/readiness-and-enablement.md +164 -0
  37. package/skills/consumer-goods-sync-management-configure/references/sync-management-app-install-backbone.md +159 -0
  38. package/skills/consumer-goods-sync-management-configure/references/transports-and-namespace.md +220 -0
  39. package/skills/consumer-goods-sync-management-configure/references/verify-and-smoke.md +175 -0
  40. package/skills/dx-org-analyze/SKILL.md +0 -1
  41. package/skills/dx-org-analyze/scripts/collect_org_data.py +2 -2
  42. package/skills/dx-org-analyze/scripts/compute_diff.py +2 -4
  43. package/skills/dx-org-analyze/scripts/introspect_org.py +4 -40
  44. package/skills/dx-org-manage/SKILL.md +6 -50
  45. package/skills/dx-org-manage/examples/README.md +10 -16
  46. package/skills/dx-org-manage/references/scratch-org-create.md +1 -1
  47. package/skills/dx-org-manage/references/scratch-org-operations.md +1 -1
  48. package/skills/dx-org-shape-manage/SKILL.md +4 -3
  49. package/skills/education-cloud-domain-configure/references/gotchas-extended.md +1 -0
  50. package/skills/experience-accessibility-validate/SKILL.md +8 -5
  51. package/skills/experience-accessibility-validate/references/reviewers/sc-1-1-1-non-text-content.md +1 -4
  52. package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-i-lists.md +0 -4
  53. package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-ii-tables.md +20 -85
  54. package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-iii-form-labels.md +4 -4
  55. package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-iv-regions.md +0 -4
  56. package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-1-v-groups.md +2 -4
  57. package/skills/experience-accessibility-validate/references/reviewers/sc-1-3-5-identify-input.md +0 -4
  58. package/skills/experience-accessibility-validate/references/reviewers/sc-1-4-3-contrast.md +4 -14
  59. package/skills/experience-accessibility-validate/references/reviewers/sc-2-1-1-keyboard.md +9 -5
  60. package/skills/experience-accessibility-validate/references/reviewers/sc-2-4-4-link-purpose.md +1 -4
  61. package/skills/experience-accessibility-validate/references/reviewers/sc-2-4-6-headings-labels.md +0 -4
  62. package/skills/experience-accessibility-validate/references/reviewers/sc-2-5-1-pointer-gestures.md +0 -4
  63. package/skills/experience-accessibility-validate/references/reviewers/sc-2-5-2-pointer-cancellation.md +0 -4
  64. package/skills/experience-accessibility-validate/references/reviewers/sc-2-5-3-label-in-name.md +0 -4
  65. package/skills/experience-accessibility-validate/references/reviewers/sc-2-5-7-dragging-movement.md +0 -4
  66. package/skills/experience-accessibility-validate/references/reviewers/sc-3-2-1-on-focus.md +0 -4
  67. package/skills/experience-accessibility-validate/references/reviewers/sc-3-2-2-on-input.md +1 -4
  68. package/skills/experience-accessibility-validate/references/reviewers/sc-3-3-1-error-identification.md +1 -4
  69. package/skills/experience-accessibility-validate/references/reviewers/sc-3-3-2-labels-instructions.md +1 -4
  70. package/skills/experience-accessibility-validate/references/reviewers/sc-3-3-3-error-suggestion.md +1 -4
  71. package/skills/experience-accessibility-validate/references/reviewers/sc-4-1-2-i-name.md +4 -5
  72. package/skills/experience-accessibility-validate/references/reviewers/sc-4-1-2-ii-role.md +1 -4
  73. package/skills/experience-accessibility-validate/references/reviewers/sc-4-1-2-iii-value.md +0 -4
  74. package/skills/experience-lwc-accessibility-jest-run/SKILL.md +104 -25
  75. package/skills/experience-lwc-accessibility-jest-run/assets/jest.config.js +4 -0
  76. package/skills/experience-lwc-accessibility-jest-run/assets/sa11y-jest-setup.js +5 -0
  77. package/skills/experience-ui-bundle-app-coordinate/SKILL.md +5 -5
  78. package/skills/experience-ui-bundle-features-generate/SKILL.md +65 -36
  79. package/skills/experience-ui-bundle-features-generate/references/angular/features.md +74 -0
  80. package/skills/experience-ui-bundle-features-generate/references/react/features.md +59 -0
  81. package/skills/experience-ui-bundle-features-generate/scripts/detect-framework.sh +73 -0
  82. package/skills/experience-ui-bundle-frontend-generate/SKILL.md +2 -2
  83. package/skills/experience-ui-bundle-metadata-generate/SKILL.md +26 -14
  84. package/skills/experience-ui-bundle-metadata-generate/references/angular-metadata-generate.md +37 -0
  85. package/skills/experience-ui-bundle-metadata-generate/references/react-metadata-generate.md +32 -0
  86. package/skills/experience-ui-bundle-metadata-generate/scripts/detect-framework.sh +73 -0
  87. package/skills/experience-ui-bundle-metadata-generate/scripts/verify-bundle-location.sh +30 -8
  88. package/skills/field-service-data-capture-migrate/SKILL.md +391 -0
  89. package/skills/field-service-data-capture-migrate/assets/sample-legacy-flow.flow-meta.xml +163 -0
  90. package/skills/field-service-data-capture-migrate/references/architecture-notes.md +40 -0
  91. package/skills/field-service-data-capture-migrate/references/component-mapping.md +278 -0
  92. package/skills/field-service-data-capture-migrate/references/converter-builder-contract.md +183 -0
  93. package/skills/field-service-data-capture-migrate/references/dc-platform-rules.md +130 -0
  94. package/skills/field-service-data-capture-migrate/references/fsm-dc-capability-catalog.md +215 -0
  95. package/skills/field-service-data-capture-migrate/references/known-deploy-errors.md +36 -0
  96. package/skills/field-service-data-capture-migrate/references/migration-checklist.md +121 -0
  97. package/skills/field-service-data-capture-migrate/references/transformer-rules.md +132 -0
  98. package/skills/field-service-data-capture-migrate/scripts/analyze_flow.py +277 -0
  99. package/skills/field-service-data-capture-migrate/scripts/convert_to_dc_spec.py +1311 -0
  100. package/skills/field-service-data-capture-migrate/scripts/cud_analysis.py +402 -0
  101. package/skills/field-service-data-capture-migrate/scripts/deploy_flow.sh +230 -0
  102. package/skills/field-service-data-capture-migrate/scripts/discover_subflow_tree.py +230 -0
  103. package/skills/field-service-data-capture-migrate/scripts/flow_input.py +186 -0
  104. package/skills/field-service-data-capture-migrate/scripts/flow_xml_utils.py +39 -0
  105. package/skills/field-service-data-capture-migrate/scripts/fsm_dc_catalog.py +413 -0
  106. package/skills/field-service-data-capture-migrate/scripts/generate_summary.py +199 -0
  107. package/skills/field-service-data-capture-migrate/scripts/json_to_flow_xml.py +146 -0
  108. package/skills/field-service-data-capture-migrate/scripts/manual_review_flags.py +42 -0
  109. package/skills/field-service-data-capture-migrate/scripts/retrieve_flow_rest.sh +155 -0
  110. package/skills/field-service-data-capture-migrate/scripts/subflow_names.py +49 -0
  111. package/skills/field-service-data-capture-migrate/scripts/transform_flow.py +1661 -0
  112. package/skills/field-service-data-capture-migrate/scripts/validate_flow.sh +147 -0
  113. package/skills/field-service-data-capture-migrate/scripts/vendor/build_flow.py +1258 -0
  114. package/skills/life-sciences-fieldsalesrep-coordinate/SKILL.md +1 -1
  115. package/skills/life-sciences-fieldsalesrep-coordinate/references/orchestration-flow.md +1 -1
  116. package/skills/life-sciences-kam-coordinate/references/stage-5-data-and-plan-templates-overview.md +14 -1
  117. package/skills/mobile-apps-create/SKILL.md +1 -1
  118. package/skills/{platform-agentsetup-categories-fetch → platform-agenticsetup-categories-get}/SKILL.md +7 -7
  119. package/skills/platform-sandbox-configure/SKILL.md +108 -133
  120. package/skills/platform-sandbox-configure/references/api-response-shapes.md +39 -0
  121. package/skills/platform-sandbox-configure/references/definition-file-approach.md +73 -0
  122. package/skills/platform-widget-generate/SKILL.md +26 -18
  123. package/skills/platform-widget-generate/examples/formulas.json +191 -0
  124. package/skills/platform-widget-generate/references/widget-formulas.md +123 -0
  125. package/skills/platform-widget-generate/references/widget-meta-directives.md +4 -4
  126. package/skills/sales-call-scoring-configure/SKILL.md +318 -0
  127. package/skills/sales-call-scoring-configure/assets/best-practice-competencies.json +67 -0
  128. package/skills/sales-call-scoring-configure/assets/ootb-competencies.json +58 -0
  129. package/skills/sales-call-scoring-configure/references/admin-communication.md +79 -0
  130. package/skills/sales-call-scoring-configure/references/competency-crud.md +130 -0
  131. package/skills/sales-call-scoring-configure/scripts/create-competency.sh +166 -0
  132. package/skills/sales-call-scoring-configure/scripts/create-custom-competency.sh +166 -0
  133. package/skills/sales-call-scoring-configure/scripts/edit-competency.sh +185 -0
  134. package/skills/sales-call-scoring-configure/scripts/edit-custom-competency.sh +190 -0
  135. package/skills/sales-call-scoring-configure/scripts/enable-call-scoring.sh +436 -0
  136. package/skills/sales-call-scoring-configure/scripts/get-competency.sh +72 -0
  137. package/skills/sales-call-scoring-configure/scripts/get-custom-competency.sh +78 -0
  138. package/skills/sales-call-scoring-configure/scripts/install-best-practice-competencies.sh +223 -0
  139. package/skills/sales-call-scoring-configure/scripts/install-ootb-competencies.sh +237 -0
  140. package/skills/sales-call-scoring-configure/scripts/list-competencies.sh +99 -0
  141. package/skills/sales-call-scoring-configure/scripts/shared/auth.sh +116 -0
  142. package/skills/sales-call-scoring-configure/scripts/shared/cap.sh +86 -0
  143. package/skills/sales-call-scoring-configure/scripts/shared/soap.sh +267 -0
  144. package/skills/sales-call-scoring-configure/scripts/shared/soql.sh +25 -0
  145. package/skills/sales-call-scoring-configure/scripts/toggle-competency.sh +112 -0
  146. package/skills/sales-call-scoring-configure/scripts/toggle-custom-competency.sh +125 -0
  147. package/skills/sales-call-scoring-configure/scripts/verify-ootb-competencies.sh +116 -0
  148. package/skills/service-concierge-portal-generate/references/portal-deploy-runbook.md +1 -0
  149. package/skills/service-de-channel-activate/SKILL.md +6 -5
  150. package/skills/service-de-channel-create/SKILL.md +3 -3
  151. package/skills/service-de-channel-routing-configure/SKILL.md +3 -3
  152. package/skills/service-de-channel-settings-configure/SKILL.md +195 -0
  153. package/skills/service-de-channel-settings-configure/references/channel-settings-facets.md +152 -0
  154. package/skills/{service-de-channel-consent-configure → service-de-channel-settings-configure}/references/gotchas.md +3 -3
  155. package/skills/{service-de-channel-consent-configure → service-de-channel-settings-configure}/references/language-keywords.md +4 -4
  156. package/skills/{service-de-channel-consent-configure → service-de-channel-settings-configure}/references/worked-examples.md +14 -14
  157. package/skills/service-de-headless-channel-configure/SKILL.md +6 -6
  158. package/skills/service-de-headless-channel-configure/references/worked-examples.md +1 -1
  159. package/skills/service-helpagent-coordinate/SKILL.md +3 -2
  160. package/skills/service-helpagent-coordinate/references/channel-voice.md +15 -4
  161. package/skills/service-itsm-agentic-setup-agentforce-coordinate/SKILL.md +49 -31
  162. package/skills/service-itsm-agentic-setup-agentforce-coordinate/examples/output-templates.md +71 -6
  163. package/skills/service-itsm-agentic-setup-agentforce-coordinate/scripts/verify-child-verdict.mjs +26 -4
  164. package/skills/service-itsm-agentic-setup-cmdb-access-assign/SKILL.md +35 -10
  165. package/skills/service-itsm-agentic-setup-cmdb-access-assign/references/mcp-invocation.md +25 -5
  166. package/skills/service-itsm-agentic-setup-cmdb-bundle-deploy/SKILL.md +1 -1
  167. package/skills/service-itsm-agentic-setup-cmdb-configure/SKILL.md +5 -5
  168. package/skills/service-itsm-agentic-setup-cmdb-configure/references/mcp-invocation.md +1 -1
  169. package/skills/service-itsm-agentic-setup-cmdb-coordinate/SKILL.md +2 -2
  170. package/skills/service-itsm-agentic-setup-cmdb-coordinate/examples/output-templates.md +1 -1
  171. package/skills/service-itsm-agentic-setup-cmdb-discovery-configure/SKILL.md +25 -15
  172. package/skills/service-itsm-agentic-setup-employee-agent-configure/SKILL.md +8 -5
  173. package/skills/service-itsm-agentic-setup-employee-agent-configure/references/report-format.md +4 -2
  174. package/skills/service-itsm-agentic-setup-employee-agent-configure/references/workflow-detail.md +1 -1
  175. package/skills/service-itsm-agentic-setup-employee-agent-configure/scripts/render-report.mjs +29 -16
  176. package/skills/service-itsm-agentic-setup-fulfiller-agent-configure/SKILL.md +8 -5
  177. package/skills/service-itsm-agentic-setup-fulfiller-agent-configure/references/report-format.md +4 -2
  178. package/skills/service-itsm-agentic-setup-fulfiller-agent-configure/references/workflow-detail.md +1 -1
  179. package/skills/service-itsm-agentic-setup-fulfiller-agent-configure/scripts/render-report.mjs +29 -16
  180. package/skills/service-itsm-agentic-setup-incident-management/SKILL.md +138 -68
  181. package/skills/service-itsm-agentic-setup-incident-management/examples/output-templates.md +31 -15
  182. package/skills/service-itsm-agentic-setup-incident-management/references/incident-persona-psg.md +156 -0
  183. package/skills/service-itsm-agentic-setup-incident-management/references/incident-preferences.md +148 -0
  184. package/skills/service-itsm-agentic-setup-incident-management/references/major-incident-management.md +162 -0
  185. package/skills/service-itsm-agentic-setup-incident-management/references/service-mgmt-privilege.md +149 -0
  186. package/skills/service-itsm-agentic-setup-incident-sla-configure/SKILL.md +103 -89
  187. package/skills/service-itsm-agentic-setup-incident-sla-configure/assets/attach-milestone.json +2 -2
  188. package/skills/service-itsm-agentic-setup-incident-sla-configure/assets/predefined-incident-policy.json +21 -39
  189. package/skills/service-itsm-agentic-setup-incident-sla-configure/examples/milestone-patterns.md +3 -3
  190. package/skills/service-itsm-agentic-setup-incident-sla-configure/examples/output-templates.md +18 -1
  191. package/skills/service-itsm-agentic-setup-incident-sla-configure/references/mcp-invocation.md +63 -37
  192. package/skills/service-omni-attribute-routing-configure/SKILL.md +53 -0
  193. package/skills/service-omni-attribute-routing-configure/references/api-notes.md +7 -0
  194. package/skills/service-omni-attribute-routing-configure/scripts/configure-and-report.sh +224 -0
  195. package/skills/service-omni-attribute-routing-configure/scripts/tests/test_attribute_routing_contracts.py +137 -0
  196. package/skills/service-omni-channel-inventory-analyze/SKILL.md +96 -0
  197. package/skills/service-omni-channel-inventory-analyze/references/api-notes.md +52 -0
  198. package/skills/service-omni-channel-inventory-analyze/scripts/analyze.sh +185 -0
  199. package/skills/service-omni-channel-inventory-analyze/scripts/tests/_bootstrap.py +84 -0
  200. package/skills/service-omni-channel-inventory-analyze/scripts/tests/test_inventory_analyze_contracts.py +141 -0
  201. package/skills/service-omni-channel-limits-analyze/SKILL.md +70 -0
  202. package/skills/service-omni-channel-limits-analyze/references/api-notes.md +22 -0
  203. package/skills/service-omni-channel-limits-analyze/scripts/analyze.sh +159 -0
  204. package/skills/service-omni-channel-limits-analyze/scripts/tests/_bootstrap.py +87 -0
  205. package/skills/service-omni-channel-limits-analyze/scripts/tests/test_limits_analyze_contracts.py +99 -0
  206. package/skills/service-omni-channel-setup-coordinate/SKILL.md +12 -20
  207. package/skills/service-omni-channel-setup-coordinate/scripts/integration-driver.sh +55 -5
  208. package/skills/service-omni-channel-setup-coordinate/scripts/tests/test_omni_contracts.py +38 -0
  209. package/skills/service-omni-command-center-analyze/SKILL.md +2 -2
  210. package/skills/service-omni-command-center-analyze/scripts/analyze.sh +3 -3
  211. package/skills/dx-org-manage/examples/snapshots/error_output.json +0 -9
  212. package/skills/dx-org-manage/examples/snapshots/success_output.json +0 -15
  213. package/skills/dx-org-manage/references/cli_flags.md +0 -67
  214. package/skills/dx-org-manage/references/creating-snapshot.md +0 -103
  215. package/skills/dx-org-manage/references/snapshot_usage.md +0 -74
  216. package/skills/experience-accessibility-validate/scripts/contrast-ratio.py +0 -153
  217. package/skills/experience-lwc-accessibility-jest-run/references/running-sa11y-jest-tests.md +0 -205
  218. package/skills/experience-ui-bundle-features-generate/scripts/verify-react-bundle.sh +0 -14
  219. /package/skills/experience-ui-bundle-features-generate/references/{conflict-resolution-schema.json → common/conflict-resolution-schema.json} +0 -0
  220. /package/skills/{platform-agentsetup-categories-fetch → platform-agenticsetup-categories-get}/references/api-response-schema.md +0 -0
@@ -1,15 +0,0 @@
1
- {
2
- "status": 0,
3
- "result": {
4
- "Id": "0Oo5g00000001ABCAA",
5
- "Status": "Pending",
6
- "SourceOrg": "00D5g00000001XyEAI",
7
- "SnapshotName": "MySnapshot",
8
- "Description": "Baseline configuration with Package v1.2.0",
9
- "Content": "metadatadata",
10
- "CreatedDate": "2026-06-04T20:00:00.000+0000",
11
- "CreatedBy": "0055g00000001UserEAA",
12
- "LastModifiedDate": "2026-06-04T20:00:00.000+0000",
13
- "LastModifiedBy": "0055g00000001UserEAA"
14
- }
15
- }
@@ -1,67 +0,0 @@
1
- # CLI Flags Reference
2
-
3
- Complete reference for `sf org create snapshot` command flags.
4
-
5
- ## Required Flags
6
-
7
- | Flag | Alias | Description | Example |
8
- |------|-------|-------------|---------|
9
- | `--source-org` | `-o` | ID or authenticated username/alias of scratch org to snapshot | `--source-org my-scratch` |
10
- | `--name` | `-n` | Unique name for the snapshot | `--name MySnapshot` |
11
- | `--target-dev-hub` | `-v` | Dev Hub org username or alias (required unless default is set) | `--target-dev-hub DevHub` |
12
-
13
- ## Optional Flags
14
-
15
- | Flag | Alias | Description | Example |
16
- |------|-------|-------------|---------|
17
- | `--description` | `-d` | Description of snapshot contents | `--description "Package v1.2.0"` |
18
- | `--api-version` | | Override the API version used for API requests | `--api-version 66.0` |
19
-
20
- ## Global Flags
21
-
22
- | Flag | Description |
23
- |------|-------------|
24
- | `--json` | Format output as JSON (ALWAYS use this) |
25
-
26
- ## Usage Patterns
27
-
28
- ### Basic Snapshot Creation
29
-
30
- ```bash
31
- sf org create snapshot --source-org my-scratch --name MySnapshot --json
32
- ```
33
-
34
- ### With Description
35
-
36
- ```bash
37
- sf org create snapshot \
38
- --source-org my-scratch \
39
- --name MySnapshot \
40
- --description "Baseline with Package v1.2.0" \
41
- --json
42
- ```
43
-
44
- ### Using Org ID Instead of Alias
45
-
46
- ```bash
47
- sf org create snapshot \
48
- --source-org 00D5g00000001XyEAI \
49
- --name MySnapshot \
50
- --json
51
- ```
52
-
53
- ### Specify Dev Hub Explicitly
54
-
55
- ```bash
56
- sf org create snapshot \
57
- --source-org my-scratch \
58
- --name MySnapshot \
59
- --target-dev-hub MyDevHub \
60
- --json
61
- ```
62
-
63
- ## Important Notes
64
-
65
- - **Source org auto-resolution**: Accepts org ID (starts with 00D) or username/alias — aliases are automatically resolved to org IDs
66
- - **Description best practice**: Include version control reference (git tag, commit SHA) to track snapshot contents
67
- - **Asynchronous creation**: Snapshot creation happens asynchronously — use `sf org get snapshot` to check status
@@ -1,103 +0,0 @@
1
- # Creating Snapshots
2
-
3
- Creates a point-in-time snapshot of a scratch org using `sf org create snapshot`. Snapshots preserve scratch org state and configuration for reuse in scratch org definition files.
4
-
5
- ---
6
-
7
- ## Required Inputs
8
-
9
- Infer from the user's request:
10
-
11
- - **Source org**: Scratch org ID (starts with 00D) or username/alias to snapshot
12
- - **Snapshot name**: Unique name for the snapshot (required)
13
- - **Dev Hub**: Dev Hub org alias/username (uses default if not specified)
14
- - **Description** (optional): Document snapshot contents, version control reference
15
-
16
- ---
17
-
18
- ## Workflow
19
-
20
- 1. **Gather inputs** — get source org, snapshot name, and optional description
21
- 2. **Build command** — construct `sf org create snapshot` with appropriate flags
22
- 3. **Execute via Bash tool** — run command with `--json` flag
23
- 4. **Return result** — report snapshot ID and status
24
-
25
- ### Command Patterns
26
-
27
- | User intent | Execute via Bash tool |
28
- |-------------|---------|
29
- | Create snapshot with name only | `sf org create snapshot --source-org <orgId or alias> --name <SnapshotName> --json` |
30
- | Create snapshot with description | `sf org create snapshot --source-org <orgId or alias> --name <SnapshotName> --description "<desc>" --json` |
31
- | Specify Dev Hub explicitly | `sf org create snapshot --source-org <orgId or alias> --name <SnapshotName> --target-dev-hub <devHubAlias> --json` |
32
-
33
- ---
34
-
35
- ## Rules / Constraints
36
-
37
- | Constraint | Rationale |
38
- |-----------|-----------|
39
- | Always use `--json` flag | Provides structured output for reliable parsing and error handling |
40
- | Snapshot names must be unique in the Dev Hub | Duplicate names cause creation to fail |
41
- | Source org must be a scratch org | Snapshots only work with scratch orgs, not sandboxes or production orgs |
42
- | Source org accepts ID or username/alias | Command auto-resolves aliases to org IDs; org IDs start with 00D |
43
- | Include description for tracking | Best practice: reference version control tag or commit ID in description |
44
-
45
- ---
46
-
47
- ## Troubleshooting
48
-
49
- | Issue | Resolution |
50
- |-------|------------|
51
- | Error creating snapshot | Surface the CLI's own error unchanged; the message states what to do next |
52
- | `@salesforce/plugin-signups does not exist in the registry` | Snapshot commands live in the `signups` plugin, which ships bundled with a normal `sf` install. This error means the CLI environment is incomplete (slim image) or the plugin registry is unreachable (offline). Because the registry is unavailable, `sf plugins install` cannot succeed — do NOT attempt it (it will fail and loop). Surface the error and advise the user to repair their environment from a connected machine: reinstall or update the Salesforce CLI (for example with `sf update`, or a fresh global CLI install through their normal package manager) so the bundled `signups` plugin is present, or run in an image that already includes it. Never run any install/repair from inside the skill. |
53
- | "No org found for <alias>" error | Source org alias doesn't exist or isn't authenticated — verify with `sf org list` |
54
- | Snapshot name already exists | Use a different unique name — snapshot names must be unique per Dev Hub |
55
- | "An error while created the org snapshot" | Generic error — check that source org is a scratch org and still active |
56
- | Long-running snapshot creation | Use `sf org get snapshot --snapshot <name>` to check status — snapshot creation is asynchronous |
57
-
58
- ---
59
-
60
- ## Output Expectations
61
-
62
- The command returns JSON output with the created snapshot details.
63
-
64
- See `examples/snapshots/success_output.json` and `examples/snapshots/error_output.json` for complete response structures.
65
-
66
- Example success response:
67
- ```json
68
- {
69
- "result": {
70
- "SnapshotId": "0Ym...",
71
- "SnapshotName": "MySnapshot",
72
- "Status": "Active",
73
- "SourceOrg": "00D..."
74
- }
75
- }
76
- ```
77
-
78
- ---
79
-
80
- ## Using Snapshots
81
-
82
- After creating a snapshot, use it to create scratch orgs by:
83
-
84
- 1. **In scratch org definition file:**
85
- ```json
86
- {
87
- "snapshot": "MySnapshot"
88
- }
89
- ```
90
-
91
- 2. **Or via command flag:**
92
- ```bash
93
- sf org create scratch --snapshot MySnapshot --target-dev-hub <alias> --alias <name> --json
94
- ```
95
-
96
- See `snapshot_usage.md` for detailed examples.
97
-
98
- ---
99
-
100
- ## Additional Resources
101
-
102
- - See `cli_flags.md` for detailed explanation of all available flags
103
- - See `snapshot_usage.md` for how to use snapshots in scratch org creation
@@ -1,74 +0,0 @@
1
- # Using Snapshots in Scratch Org Definition Files
2
-
3
- After creating a snapshot, reference it in scratch org definition files to create new scratch orgs from the saved state.
4
-
5
- ## Scratch Org Definition File Format
6
-
7
- Use the `snapshot` field instead of `edition` in your `project-scratch-def.json`:
8
-
9
- ```json
10
- {
11
- "orgName": "My Company",
12
- "snapshot": "MySnapshot",
13
- "features": ["EnableSetPasswordInApi"],
14
- "settings": {
15
- "lightningExperienceSettings": {
16
- "enableS1DesktopEnabled": true
17
- }
18
- }
19
- }
20
- ```
21
-
22
- ## Key Differences from Edition-Based Definitions
23
-
24
- | Field | Edition-based | Snapshot-based |
25
- |-------|--------------|----------------|
26
- | Primary field | `"edition": "Developer"` | `"snapshot": "MySnapshot"` |
27
- | Contents | Empty org with edition defaults | Pre-configured org state from snapshot |
28
-
29
- ## Creating a Scratch Org from Snapshot
30
-
31
- ```bash
32
- sf org create scratch --definition-file config/project-scratch-def.json --alias from-snapshot
33
- ```
34
-
35
- The scratch org will be created with all the metadata, data, and configuration from the snapshot.
36
-
37
- ## Common Use Cases
38
-
39
- ### 1. Package Development
40
-
41
- ```json
42
- {
43
- "orgName": "Package Dev Org",
44
- "snapshot": "Dependencies_v1.2.0",
45
- "description": "Org with all dependencies installed"
46
- }
47
- ```
48
-
49
- ### 2. Testing Baseline
50
-
51
- ```json
52
- {
53
- "orgName": "Test Baseline",
54
- "snapshot": "TestData_Populated",
55
- "description": "Org with sample data for testing"
56
- }
57
- ```
58
-
59
- ### 3. CI/CD Pipeline
60
-
61
- ```json
62
- {
63
- "orgName": "CI Scratch Org",
64
- "snapshot": "Nightly_Build_Baseline",
65
- "description": "Latest nightly build dependencies"
66
- }
67
- ```
68
-
69
- ## Workflow Summary
70
-
71
- 1. **Create snapshot**: `sf org create snapshot --source-org <scratch> --name MySnapshot`
72
- 2. **Check status**: `sf org get snapshot --snapshot MySnapshot`
73
- 3. **Reference in definition file**: `"snapshot": "MySnapshot"`
74
- 4. **Create new scratch org**: `sf org create scratch --definition-file config/project-scratch-def.json`
@@ -1,153 +0,0 @@
1
- #!/usr/bin/env python3
2
- """WCAG 2.2 SC 1.4.3 / 1.4.11 contrast-ratio calculator.
3
-
4
- Computes the exact WCAG contrast ratio between a foreground and a background
5
- color so the accessibility reviewer never has to approximate relative luminance
6
- by hand (which is unreliable and has produced inconsistent findings). The
7
- reviewer resolves the two colors from the component's HTML/CSS, then invokes
8
- this script; the printed verdict is authoritative.
9
-
10
- Usage:
11
- contrast-ratio.py FOREGROUND BACKGROUND [--large] [--json]
12
-
13
- Arguments:
14
- FOREGROUND Text color. Accepts #RGB, #RRGGBB, rgb(r,g,b) or rgba(r,g,b,a).
15
- BACKGROUND Background color. Must be opaque (#RGB/#RRGGBB/rgb()); used as
16
- the compositing base when FOREGROUND carries an alpha channel.
17
-
18
- Options:
19
- --large Classify the text as large-scale (>=24px, or >=18.66px bold),
20
- which uses the 3:1 threshold instead of 4.5:1 for the primary
21
- PASS/FAIL. Both thresholds are always reported regardless.
22
- --json Emit a machine-readable JSON object instead of the text report.
23
-
24
- Exit codes:
25
- 0 Ratio meets the applicable threshold (PASS)
26
- 1 Ratio is below the applicable threshold (FAIL)
27
- 2 Argument / parse error
28
- """
29
-
30
- import argparse
31
- import json
32
- import re
33
- import sys
34
-
35
- _STANDARD_THRESHOLD = 4.5
36
- _LARGE_THRESHOLD = 3.0
37
-
38
-
39
- def _parse_color(value):
40
- """Return (r, g, b, a) with channels in 0-255 and alpha in 0.0-1.0."""
41
- s = value.strip()
42
-
43
- m = re.fullmatch(r"#([0-9a-fA-F]{3})", s)
44
- if m:
45
- r, g, b = (int(c * 2, 16) for c in m.group(1))
46
- return r, g, b, 1.0
47
-
48
- m = re.fullmatch(r"#([0-9a-fA-F]{6})", s)
49
- if m:
50
- h = m.group(1)
51
- return int(h[0:2], 16), int(h[2:4], 16), int(h[4:6], 16), 1.0
52
-
53
- m = re.fullmatch(
54
- r"rgba?\(\s*([\d.]+)\s*,\s*([\d.]+)\s*,\s*([\d.]+)\s*(?:,\s*([\d.]+)\s*)?\)",
55
- s,
56
- )
57
- if m:
58
- r, g, b = (int(round(float(m.group(i)))) for i in (1, 2, 3))
59
- a = float(m.group(4)) if m.group(4) is not None else 1.0
60
- for ch in (r, g, b):
61
- if not 0 <= ch <= 255:
62
- raise ValueError(f"channel out of range in '{value}'")
63
- if not 0.0 <= a <= 1.0:
64
- raise ValueError(f"alpha out of range in '{value}'")
65
- return r, g, b, a
66
-
67
- raise ValueError(
68
- f"unrecognized color '{value}' — use #RGB, #RRGGBB, rgb(), or rgba()"
69
- )
70
-
71
-
72
- def _composite(fg, bg):
73
- """Alpha-composite fg over an opaque bg; return an opaque (r, g, b)."""
74
- fr, fgc, fb, fa = fg
75
- br, bgc, bb, _ = bg
76
- if fa >= 1.0:
77
- return fr, fgc, fb
78
- return (
79
- round(fr * fa + br * (1 - fa)),
80
- round(fgc * fa + bgc * (1 - fa)),
81
- round(fb * fa + bb * (1 - fa)),
82
- )
83
-
84
-
85
- def _relative_luminance(rgb):
86
- """WCAG relative luminance for an opaque sRGB (r, g, b) triple."""
87
- def _lin(c):
88
- c /= 255.0
89
- return c / 12.92 if c <= 0.03928 else ((c + 0.055) / 1.055) ** 2.4
90
-
91
- r, g, b = (_lin(c) for c in rgb)
92
- return 0.2126 * r + 0.7152 * g + 0.0722 * b
93
-
94
-
95
- def contrast_ratio(foreground, background):
96
- """Exact WCAG contrast ratio between two color strings (>= 1.0)."""
97
- fg = _parse_color(foreground)
98
- bg = _parse_color(background)
99
- if bg[3] < 1.0:
100
- raise ValueError(
101
- f"background '{background}' is translucent — its rendered color "
102
- "depends on the layer beneath it and cannot be determined. Resolve "
103
- "the effective opaque background and pass that instead."
104
- )
105
- fg_rgb = _composite(fg, bg)
106
- l1 = _relative_luminance(fg_rgb)
107
- l2 = _relative_luminance(bg[:3])
108
- lighter, darker = (l1, l2) if l1 >= l2 else (l2, l1)
109
- return (lighter + 0.05) / (darker + 0.05)
110
-
111
-
112
- def main(argv=None):
113
- parser = argparse.ArgumentParser(add_help=True)
114
- parser.add_argument("foreground")
115
- parser.add_argument("background")
116
- parser.add_argument("--large", action="store_true")
117
- parser.add_argument("--json", action="store_true", dest="as_json")
118
- args = parser.parse_args(argv)
119
-
120
- try:
121
- ratio = contrast_ratio(args.foreground, args.background)
122
- except ValueError as exc:
123
- print(f"ERROR: {exc}", file=sys.stderr)
124
- return 2
125
-
126
- threshold = _LARGE_THRESHOLD if args.large else _STANDARD_THRESHOLD
127
- passes = ratio >= threshold
128
- result = {
129
- "foreground": args.foreground,
130
- "background": args.background,
131
- "ratio": round(ratio, 2),
132
- "textClass": "large" if args.large else "standard",
133
- "threshold": threshold,
134
- "passesStandard": ratio >= _STANDARD_THRESHOLD,
135
- "passesLarge": ratio >= _LARGE_THRESHOLD,
136
- "verdict": "PASS" if passes else "FAIL",
137
- }
138
-
139
- if args.as_json:
140
- print(json.dumps(result))
141
- else:
142
- print(
143
- f"{result['ratio']}:1 {result['verdict']} "
144
- f"({result['textClass']} text, threshold {threshold}:1) | "
145
- f"standard 4.5:1 {'pass' if result['passesStandard'] else 'fail'}, "
146
- f"large 3:1 {'pass' if result['passesLarge'] else 'fail'}"
147
- )
148
-
149
- return 0 if passes else 1
150
-
151
-
152
- if __name__ == "__main__":
153
- sys.exit(main())
@@ -1,205 +0,0 @@
1
- # Sa11y Accessibility Test Instructions
2
-
3
- ## Environment Detection
4
-
5
- Choose the approach based on your environment:
6
-
7
- - **Core Build Environment** — contains a `WORKSPACE` file, uses Bazel build system.
8
- - **Standalone Environment** — no `WORKSPACE` file, uses npm/yarn scripts.
9
-
10
- If this is not a Salesforce core build environment, do not mention anything about the core build environment.
11
-
12
- ---
13
-
14
- ## Core Build Environment (Bazel)
15
-
16
- When working within a Salesforce core build environment, use Bazel commands.
17
-
18
- ### Base Command Structure
19
-
20
- ```bash
21
- {coreRootPath}/tools/bazel test [TARGET] --test_output=streamed --test_env=SA11Y_AUTO=1 --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1
22
- ```
23
-
24
- **Replacements:**
25
-
26
- - `{coreRootPath}` — your actual core root directory path
27
- - `{moduleName}` — module name (e.g. `ui-content-authoring-components`)
28
- - `{relativePath}` — test file path **without** `.test.js` extension
29
-
30
- ### Testing Approaches
31
-
32
- #### 1. Single File Testing
33
-
34
- ```bash
35
- {coreRootPath}/tools/bazel test //{moduleName}:{relativePath} --test_output=streamed --test_env=SA11Y_AUTO=1 --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1
36
- ```
37
-
38
- Example:
39
-
40
- ```bash
41
- ./core/tools/bazel test //ui-content-authoring-components:modules/es_block_builder/blockBuilder/__tests__/blockBuilder --test_output=streamed --test_env=SA11Y_AUTO=1 --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1
42
- ```
43
-
44
- **Use when:** testing a specific component with a known test file path.
45
-
46
- #### 2. Module Testing
47
-
48
- ```bash
49
- {coreRootPath}/tools/bazel test //{moduleName}:sa11y_jest_test --test_output=streamed --test_env=SA11Y_AUTO=1 --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1
50
- ```
51
-
52
- Example:
53
-
54
- ```bash
55
- ./core/tools/bazel test //ui-content-authoring-components:sa11y_jest_test --test_output=streamed --test_env=SA11Y_AUTO=1 --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1
56
- ```
57
-
58
- **Use when:** testing an entire module or when unsure which specific component to target.
59
-
60
- #### 3. Multiple Modules
61
-
62
- ```bash
63
- {coreRootPath}/tools/bazel test //{module1}:sa11y_jest_test //{module2}:sa11y_jest_test --test_output=streamed --test_env=SA11Y_AUTO=1 --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1
64
- ```
65
-
66
- **Use when:** integration testing across module boundaries.
67
-
68
- #### 4. Wildcard Testing
69
-
70
- ```bash
71
- {coreRootPath}/tools/bazel test //{moduleName}:sa11y_jest_test --test_arg=--testMatch="**/{modulePath}/**" --test_output=streamed --test_env=SA11Y_AUTO=1 --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1
72
- ```
73
-
74
- **Use when:** filtering multiple components within a module by pattern.
75
-
76
- ---
77
-
78
- ## Standalone Environment (Direct Jest)
79
-
80
- No `SA11Y_*` environment variables are needed here — `@sa11y/jest` is wired into
81
- the project's Jest setup, so the accessibility assertions run automatically.
82
-
83
- ```bash
84
- # Run all accessibility tests (match by the *.accessibility.test.js convention)
85
- npm test -- --testMatch="**/*.accessibility.test.js"
86
-
87
- # Re-run a single test file — use the filename/path as given in the prompt
88
- # (a bare filename when the file is "in this directory")
89
- npm test -- myComponent.accessibility.test.js
90
- ```
91
-
92
- ### Jest Configuration
93
-
94
- Ensure Jest includes Sa11y setup:
95
-
96
- ```javascript
97
- // jest.config.js
98
- module.exports = {
99
- setupFilesAfterEnv: ['<rootDir>/test/setup/sa11y-setup.js'],
100
- testEnvironment: 'jsdom',
101
- };
102
- ```
103
-
104
- ### Sa11y Setup File
105
-
106
- ```javascript
107
- // test/setup/sa11y-setup.js
108
- import { configure } from '@sa11y/jest';
109
-
110
- configure({
111
- rules: ['wcag2a', 'wcag2aa', 'wcag2aaa'],
112
- });
113
- ```
114
-
115
- ---
116
-
117
- ## Path Discovery (Core Build Environment)
118
-
119
- ```bash
120
- # Find all test files in a module
121
- find {coreRootPath}/ui-content-authoring-components -name "*.test.js" -type f
122
-
123
- # Explore module structure
124
- ls {coreRootPath}/ui-content-authoring-components/modules/
125
-
126
- # Use Bazel to list test targets
127
- {coreRootPath}/tools/bazel query "tests(//ui-content-authoring-components:*)"
128
- ```
129
-
130
- ### Path Construction
131
-
132
- - **Module Name** — use directly (e.g. `ui-content-authoring-components`)
133
- - **Component Path** — `modules/{componentDir}/{componentName}/__tests__/`
134
- - **Test File** — remove `.test.js` extension
135
-
136
- ---
137
-
138
- ## Optional Arguments
139
-
140
- ### Bazel Options
141
-
142
- | Option | Command | Purpose |
143
- | ---------------- | --------------------------------------------------------------------------------------------------------------------------------- | -------------------------- |
144
- | Update Snapshots | `--test_arg="--updateSnapshot"` | Update test snapshots |
145
- | Disable Cache | `--cache_test_results=no` | Disable Bazel test caching |
146
- | Save HTML Files | `--test_env=SA11Y_ENABLE_RENDERED_DOM_SAVE=1 --test_env=SA11Y_RENDERED_DOM_SAVE_PATH=sfdc-test/unit/javascript/htdocs/sa11y/jest` | Save HTML for analysis |
147
-
148
- **Note:** Use `sfdc-test/unit/javascript/htdocs/sa11y/jest` as the save path to avoid EPERM permission issues.
149
-
150
- **Complete example with HTML saving:**
151
-
152
- ```bash
153
- ./core/tools/bazel test //ui-content-authoring-components:modules/es_block_builder/blockBuilder/__tests__/blockBuilder \
154
- --test_output=streamed \
155
- --test_env=SA11Y_AUTO=1 \
156
- --test_env=SA11Y_ENABLE_DOM_MUTATION_OBSERVER=1 \
157
- --test_env=SA11Y_ENABLE_RENDERED_DOM_SAVE=1 \
158
- --test_env=SA11Y_RENDERED_DOM_SAVE_PATH=sfdc-test/unit/javascript/htdocs/sa11y/jest
159
- ```
160
-
161
- ### Jest Options
162
-
163
- ```bash
164
- # Update snapshots
165
- npm test -- --testMatch="**/*.accessibility.test.js" --updateSnapshot
166
-
167
- # Run in watch mode
168
- npm test -- --testMatch="**/*.accessibility.test.js" --watch
169
-
170
- # Run with verbose output
171
- npm test -- --testMatch="**/*.accessibility.test.js" --verbose
172
- ```
173
-
174
- ---
175
-
176
- ## Expected Exit Codes
177
-
178
- ### Bazel
179
-
180
- - **0** — all tests passed
181
- - **3** — build succeeded, some tests failed
182
- - **1** — build or command failed
183
-
184
- ### Jest
185
-
186
- - **0** — all tests passed
187
- - **1** — some tests failed or error occurred
188
-
189
- ---
190
-
191
- ## Troubleshooting
192
-
193
- ### Bazel
194
-
195
- - Verify `WORKSPACE` file exists
196
- - Check Bazel version compatibility
197
- - Ensure test targets are properly defined
198
- - Verify repository-specific Bazel binary path
199
-
200
- ### Jest
201
-
202
- - Verify Jest configuration
203
- - Check test file naming conventions
204
- - Ensure Sa11y dependencies are installed
205
- - Verify jsdom environment setup
@@ -1,14 +0,0 @@
1
- #!/usr/bin/env bash
2
- # Verify that the project contains a React-based UI bundle
3
- # Exit 0 if React is found, exit 1 otherwise
4
-
5
- set -euo pipefail
6
-
7
- if ! grep -q '"react"' uiBundles/*/package.json 2>/dev/null; then
8
- echo "ERROR: Not a React bundle - @salesforce/ui-bundle-features requires React"
9
- echo "Found bundle type: $(grep '"type"' uiBundles/*/package.json 2>/dev/null || echo 'unknown')"
10
- exit 1
11
- fi
12
-
13
- echo "React bundle detected"
14
- exit 0