@salesforce/afv-skills 1.67.0 → 1.69.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 (258) hide show
  1. package/README.md +55 -5
  2. package/package.json +1 -1
  3. package/skills/afcc-setup-coordinate/SKILL.md +348 -0
  4. package/skills/afcc-setup-coordinate/assets/console-app/AFCC_Service_Console.app-meta.xml +19 -0
  5. package/skills/afcc-setup-coordinate/assets/console-app/Admin.profile-meta.xml +8 -0
  6. package/skills/afcc-setup-coordinate/assets/console-app/Standard.profile-meta.xml +8 -0
  7. package/skills/afcc-setup-coordinate/assets/gap_report_template.md +35 -0
  8. package/skills/afcc-setup-coordinate/assets/org_profile_template.json +16 -0
  9. package/skills/afcc-setup-coordinate/references/gotchas.md +22 -0
  10. package/skills/afcc-setup-coordinate/scripts/audit_org.sh +159 -0
  11. package/skills/agentforce-bot-upgrade/SKILL.md +117 -66
  12. package/skills/agentforce-bot-upgrade/assets/_vendored/agent-spec-template.md +139 -0
  13. package/skills/agentforce-bot-upgrade/references/_vendored/agent-design-and-spec-creation.md +1211 -0
  14. package/skills/agentforce-bot-upgrade/references/_vendored/agent-script-core-language.md +1390 -0
  15. package/skills/agentforce-bot-upgrade/references/_vendored/agent-subagent-map-diagrams.md +341 -0
  16. package/skills/agentforce-bot-upgrade/references/_vendored/agent-user-setup.md +672 -0
  17. package/skills/agentforce-bot-upgrade/references/_vendored/agent-validation-and-debugging.md +904 -0
  18. package/skills/agentforce-bot-upgrade/references/_vendored/agentscript-toolchain.md +112 -0
  19. package/skills/agentforce-bot-upgrade/references/_vendored/architecture-patterns.md +277 -0
  20. package/skills/agentforce-bot-upgrade/references/_vendored/common-control-flow-pitfalls.md +255 -0
  21. package/skills/agentforce-bot-upgrade/references/_vendored/control-flow-actions-sequencing.md +198 -0
  22. package/skills/agentforce-bot-upgrade/references/_vendored/control-flow-lifecycle-side-effects.md +87 -0
  23. package/skills/agentforce-bot-upgrade/references/_vendored/data-library-reference.md +891 -0
  24. package/skills/agentforce-bot-upgrade/references/_vendored/instruction-resolution.md +658 -0
  25. package/skills/agentforce-bot-upgrade/references/_vendored/org-setup-for-adl.md +551 -0
  26. package/skills/agentforce-bot-upgrade/references/_vendored/patterns-by-requirement.md +88 -0
  27. package/skills/agentforce-bot-upgrade/references/_vendored/posture-and-determinism.md +215 -0
  28. package/skills/agentforce-bot-upgrade/references/extraction-blueprint.md +11 -4
  29. package/skills/agentforce-bot-upgrade/references/generate-agent-spec.md +19 -3
  30. package/skills/agentforce-bot-upgrade/references/handoff-output-format.md +82 -52
  31. package/skills/agentforce-bot-upgrade/references/input-contract.md +8 -8
  32. package/skills/agentforce-bot-upgrade/references/mapping-rules.md +19 -6
  33. package/skills/agentforce-bot-upgrade/references/post-conversion-enhancements-reference.md +65 -6
  34. package/skills/agentforce-bot-upgrade/references/quality-checklist.md +4 -4
  35. package/skills/agentforce-bot-upgrade/references/sf-cli-bot-reference.md +17 -3
  36. package/skills/agentforce-hyperclassifier-configure/README.md +24 -0
  37. package/skills/agentforce-hyperclassifier-configure/SKILL.md +111 -0
  38. package/skills/agentforce-hyperclassifier-configure/assets/customer-org.env.example +4 -0
  39. package/skills/agentforce-hyperclassifier-configure/assets/sample_descriptions.json +8 -0
  40. package/skills/agentforce-hyperclassifier-configure/assets/sample_evals.csv +17 -0
  41. package/skills/agentforce-hyperclassifier-configure/references/api-contract.md +41 -0
  42. package/skills/agentforce-hyperclassifier-configure/references/authentication.md +35 -0
  43. package/skills/agentforce-hyperclassifier-configure/references/evaluation.md +46 -0
  44. package/skills/agentforce-hyperclassifier-configure/references/installation.md +35 -0
  45. package/skills/agentforce-hyperclassifier-configure/references/onboarding.md +93 -0
  46. package/skills/agentforce-hyperclassifier-configure/scripts/hcopt/__init__.py +1 -0
  47. package/skills/agentforce-hyperclassifier-configure/scripts/hcopt/client.py +219 -0
  48. package/skills/agentforce-hyperclassifier-configure/scripts/hcopt/eca.py +178 -0
  49. package/skills/agentforce-hyperclassifier-configure/scripts/hcopt/evaluation.py +207 -0
  50. package/skills/agentforce-hyperclassifier-configure/scripts/hcopt/onboarding.py +191 -0
  51. package/skills/agentforce-hyperclassifier-configure/scripts/hcopt/optimizer.py +187 -0
  52. package/skills/agentforce-hyperclassifier-configure/scripts/hyperclassifier.py +111 -0
  53. package/skills/agentforce-hyperclassifier-configure/scripts/report_hyperclassifier.py +149 -0
  54. package/skills/agentforce-hyperclassifier-configure/scripts/setup_hyperclassifier.py +74 -0
  55. package/skills/agentforce-hyperclassifier-configure/scripts/tests/test_hyperclassifier_skill.py +887 -0
  56. package/skills/agentforce-offline-experimentation-run/SKILL.md +14 -22
  57. package/skills/agentforce-offline-experimentation-run/scripts/bt_compare.py +81 -0
  58. package/skills/agentforce-offline-experimentation-run/scripts/bt_fetch.py +358 -0
  59. package/skills/agentforce-offline-experimentation-run/scripts/bt_patch_agent.py +110 -0
  60. package/skills/agentforce-offline-experimentation-run/scripts/btlib/__init__.py +34 -0
  61. package/skills/agentforce-offline-experimentation-run/scripts/btlib/agentpatch.py +483 -0
  62. package/skills/agentforce-offline-experimentation-run/scripts/btlib/agentsrc.py +565 -0
  63. package/skills/agentforce-offline-experimentation-run/scripts/btlib/cache.py +95 -0
  64. package/skills/agentforce-offline-experimentation-run/scripts/btlib/compare.py +617 -0
  65. package/skills/agentforce-offline-experimentation-run/scripts/btlib/fetch.py +1012 -0
  66. package/skills/agentforce-offline-experimentation-run/scripts/btlib/judge.py +140 -0
  67. package/skills/agentforce-offline-experimentation-run/scripts/btlib/messages.py +93 -0
  68. package/skills/agentforce-offline-experimentation-run/scripts/btlib/patch.py +327 -0
  69. package/skills/agentforce-offline-experimentation-run/scripts/btlib/redact.py +40 -0
  70. package/skills/agentforce-offline-experimentation-run/scripts/btlib/results.py +288 -0
  71. package/skills/agentforce-offline-experimentation-run/scripts/btlib/scoring.py +340 -0
  72. package/skills/agentforce-offline-experimentation-run/scripts/btlib/sfap.py +354 -0
  73. package/skills/agentforce-offline-experimentation-run/scripts/btlib/splits.py +136 -0
  74. package/skills/agentforce-offline-experimentation-run/scripts/btlib/stdm.py +98 -0
  75. package/skills/agentforce-offline-experimentation-run/scripts/btlib/tokens.py +173 -0
  76. package/skills/agentforce-offline-experimentation-run/scripts/btlib/units.py +199 -0
  77. package/skills/agentforce-offline-experimentation-run/scripts/btlib/versions.py +194 -0
  78. package/skills/agentforce-offline-experimentation-run/scripts/build_report.py +367 -379
  79. package/skills/agentforce-offline-experimentation-run/scripts/resolve-token.sh +23 -6
  80. package/skills/agentforce-offline-experimentation-run/scripts/sfap_replay.py +483 -796
  81. package/skills/commerce-react-storefront-create/SKILL.md +54 -21
  82. package/skills/dx-lifecycle-center/SKILL.md +22 -13
  83. package/skills/dx-lifecycle-center/examples/workflows.md +54 -17
  84. package/skills/dx-lifecycle-center/references/connect-api.md +33 -4
  85. package/skills/dx-lifecycle-center/references/connect-org.md +62 -12
  86. package/skills/dx-lifecycle-center/references/deploy.md +3 -3
  87. package/skills/dx-lifecycle-center/references/hub-org.md +19 -3
  88. package/skills/dx-lifecycle-center/references/list-orgs.md +50 -24
  89. package/skills/dx-lifecycle-center/references/troubleshooting.md +22 -1
  90. package/skills/dx-lifecycle-center/scripts/hub-get.sh +41 -0
  91. package/skills/dx-lifecycle-center/scripts/resolve-environment.sh +151 -4
  92. package/skills/dx-org-devhub-configure/SKILL.md +85 -84
  93. package/skills/dx-org-devhub-configure/examples/status-output.md +25 -2
  94. package/skills/dx-org-devhub-configure/scripts/devhub.sh +265 -140
  95. package/skills/dx-org-devhub-configure/scripts/test-devhub.sh +100 -15
  96. package/skills/dx-packaging-convert-1gp-to-2gp-create/SKILL.md +63 -0
  97. package/skills/dx-packaging-convert-1gp-to-2gp-create/references/conversion-operations.md +252 -0
  98. package/skills/dx-packaging-move-to-2gp-migrate/SKILL.md +88 -0
  99. package/skills/dx-packaging-move-to-2gp-migrate/references/api-operations.md +167 -0
  100. package/skills/dx-packaging-push-upgrade-configure/README.md +47 -0
  101. package/skills/dx-packaging-push-upgrade-configure/SKILL.md +355 -0
  102. package/skills/dx-packaging-push-upgrade-configure/references/best-practices.md +61 -0
  103. package/skills/dx-packaging-push-upgrade-configure/references/cli-reference.md +148 -0
  104. package/skills/dx-packaging-push-upgrade-configure/references/objects.md +106 -0
  105. package/skills/dx-packaging-push-upgrade-configure/references/soql-recipes.md +144 -0
  106. package/skills/dx-scratch-def-configure/SKILL.md +163 -0
  107. package/skills/dx-scratch-def-configure/examples/confirm-card.md +53 -0
  108. package/skills/dx-scratch-def-configure/examples/report-recipes.md +100 -0
  109. package/skills/dx-scratch-def-configure/references/features.json +3270 -0
  110. package/skills/dx-scratch-def-configure/references/project-scratch-def.schema.json +1841 -0
  111. package/skills/dx-scratch-def-configure/references/settings-map.json +682 -0
  112. package/skills/dx-scratch-def-configure/scripts/lib_scratch_def.py +1306 -0
  113. package/skills/dx-scratch-def-configure/scripts/requirements.txt +3 -0
  114. package/skills/dx-scratch-def-configure/scripts/scrape_config_values.py +848 -0
  115. package/skills/education-cloud-domain-configure/SKILL.md +1 -1
  116. package/skills/education-cloud-multi-campus-configure/SKILL.md +1 -1
  117. package/skills/education-cloud-student-recruitment-agent-configure/SKILL.md +1 -1
  118. package/skills/experience-afv-analytics-query/SKILL.md +239 -0
  119. package/skills/experience-afv-analytics-query/references/references.md +176 -0
  120. package/skills/experience-app-mcp-delivery-generate/SKILL.md +142 -0
  121. package/skills/experience-app-mcp-delivery-generate/references/eca-consumer-key.md +26 -0
  122. package/skills/experience-app-mcp-delivery-generate/references/mcp-config-delivery.md +38 -0
  123. package/skills/experience-app-mcp-delivery-generate/references/plugin-format-and-publishing.md +80 -0
  124. package/skills/experience-app-mcp-delivery-generate/scripts/developer_name.mjs +9 -0
  125. package/skills/experience-app-mcp-delivery-generate/scripts/discover_mcp_context.mjs +114 -0
  126. package/skills/experience-app-mcp-delivery-generate/scripts/generate_mcp_config.mjs +27 -0
  127. package/skills/experience-app-mcp-delivery-generate/scripts/generate_plugin.mjs +184 -0
  128. package/skills/experience-app-mcp-delivery-generate/scripts/mcp_config.mjs +57 -0
  129. package/skills/experience-app-mcp-delivery-generate/scripts/preflight.mjs +109 -0
  130. package/skills/experience-app-mcp-delivery-generate/scripts/retrieve_eca_consumer_key.mjs +143 -0
  131. package/skills/experience-app-mcp-generate/SKILL.md +174 -0
  132. package/skills/experience-app-mcp-generate/assets/__ECA_NAME__.eca-meta.xml +7 -0
  133. package/skills/experience-app-mcp-generate/assets/__ECA_NAME__.ecaGlblOauth-meta.xml +15 -0
  134. package/skills/experience-app-mcp-generate/assets/__ECA_NAME__.ecaOauth-meta.xml +6 -0
  135. package/skills/experience-app-mcp-generate/assets/__ECA_NAME__.ecaOauthPlcy-meta.xml +12 -0
  136. package/skills/experience-app-mcp-generate/assets/__ECA_NAME___defaultPolicy.ecaPlcy-meta.xml +7 -0
  137. package/skills/experience-app-mcp-generate/assets/__MCP_SERVER_NAME__.mcpServerDefinition-meta.xml +5 -0
  138. package/skills/experience-app-mcp-generate/references/eca-fields.md +76 -0
  139. package/skills/experience-app-mcp-generate/references/mcp-objects.md +66 -0
  140. package/skills/experience-app-mcp-generate/references/tool-bindings.md +85 -0
  141. package/skills/experience-app-mcp-generate/references/troubleshooting.md +41 -0
  142. package/skills/experience-app-mcp-generate/references/ui-frameworks.md +19 -0
  143. package/skills/experience-app-mcp-generate/references/widget-resources.md +96 -0
  144. package/skills/experience-app-mcp-generate/scripts/activate_server.mjs +166 -0
  145. package/skills/experience-app-mcp-generate/scripts/check_setup_progress.mjs +212 -0
  146. package/skills/experience-app-mcp-generate/scripts/list_sites.mjs +211 -0
  147. package/skills/experience-app-mcp-generate/scripts/merge_tools.mjs +407 -0
  148. package/skills/experience-app-mcp-generate/scripts/preflight.mjs +127 -0
  149. package/skills/experience-app-mcp-generate/scripts/render_eca.mjs +144 -0
  150. package/skills/experience-app-mcp-generate/scripts/render_mcp_server.mjs +64 -0
  151. package/skills/experience-app-mcp-generate/scripts/retrieve_existing_prompts.mjs +145 -0
  152. package/skills/experience-app-mcp-generate/scripts/retrieve_existing_tools.mjs +72 -0
  153. package/skills/experience-app-mcp-generate/scripts/scan_tool_candidates.mjs +195 -0
  154. package/skills/experience-app-mcp-generate/scripts/utils/callback_url.mjs +36 -0
  155. package/skills/experience-app-mcp-generate/scripts/utils/developer_name.mjs +9 -0
  156. package/skills/experience-app-mcp-generate/scripts/utils/eca_check.mjs +156 -0
  157. package/skills/experience-app-mcp-generate/scripts/utils/metadata_path.mjs +13 -0
  158. package/skills/experience-app-mcp-generate/scripts/verify_server.mjs +118 -0
  159. package/skills/experience-cms-content-type-generate/SKILL.md +1 -1
  160. package/skills/experience-design-validate/SKILL.md +1 -1
  161. package/skills/experience-search-coordinate/SKILL.md +18 -12
  162. package/skills/experience-search-coordinate/references/content-route.md +79 -1
  163. package/skills/field-service-data-capture-migrate/SKILL.md +1 -1
  164. package/skills/nonprofit-fundraising-configure/SKILL.md +1 -1
  165. package/skills/nonprofit-fundraising-configure/references/mcp-invocation.md +52 -4
  166. package/skills/nonprofit-fundraising-configure/references/permission-targeting.md +19 -2
  167. package/skills/platform-apex-generate/SKILL.md +14 -11
  168. package/skills/platform-apex-test-generate/SKILL.md +2 -1
  169. package/skills/platform-custom-field-generate/SKILL.md +24 -16
  170. package/skills/platform-custom-metadata-type-generate/SKILL.md +1 -0
  171. package/skills/platform-custom-setting-generate/SKILL.md +1 -0
  172. package/skills/platform-datamask-run/SKILL.md +52 -71
  173. package/skills/platform-datamask-run/references/api-surface.md +10 -4
  174. package/skills/platform-datamask-run/references/policy-authoring.md +56 -7
  175. package/skills/platform-datamask-run/references/run-and-abort.md +17 -10
  176. package/skills/platform-datamask-run/scripts/poll-job.sh +15 -25
  177. package/skills/platform-dataspace-access-configure/SKILL.md +43 -10
  178. package/skills/platform-flexipage-generate/SKILL.md +7 -10
  179. package/skills/platform-flexipage-generate/references/mcp_action_examples.md +42 -38
  180. package/skills/platform-metadata-discovery-get/SKILL.md +185 -0
  181. package/skills/platform-metadata-discovery-get/references/api-map.md +25 -0
  182. package/skills/platform-metadata-discovery-get/references/h360-routes.md +30 -0
  183. package/skills/platform-metadata-discovery-get/references/scoped-soql.md +52 -0
  184. package/skills/platform-metadata-grounding-get/SKILL.md +170 -0
  185. package/skills/platform-policy-rule-generate/SKILL.md +85 -231
  186. package/skills/platform-policy-rule-generate/references/condition-model.md +47 -0
  187. package/skills/platform-policy-rule-generate/references/condition-templates.md +89 -0
  188. package/skills/platform-policy-rule-generate/references/conjunction-compiler.md +25 -0
  189. package/skills/platform-policy-rule-generate/references/conjunction-expression.md +30 -0
  190. package/skills/platform-policy-rule-generate/references/consumer-all.md +9 -0
  191. package/skills/platform-policy-rule-generate/references/consumer-datacloud-ui.md +99 -0
  192. package/skills/platform-policy-rule-generate/references/deploy-errors.md +24 -36
  193. package/skills/platform-policy-rule-generate/references/examples/ExistsJoinRLS/package.xml +12 -0
  194. package/skills/platform-policy-rule-generate/references/examples/ExistsJoinRLS/policyRuleDefinitionSets/ExistsJoinRLS.policyRuleDefinitionSet +5 -0
  195. package/skills/platform-policy-rule-generate/references/examples/ExistsJoinRLS/policyRuleDefinitions/ExistsJoinRLS_Rule_1.policyRuleDefinition +91 -0
  196. package/skills/platform-policy-rule-generate/references/examples/FieldReadDeny/package.xml +12 -0
  197. package/skills/platform-policy-rule-generate/references/examples/FieldReadDeny/policyRuleDefinitionSets/FieldReadDeny.policyRuleDefinitionSet +5 -0
  198. package/skills/platform-policy-rule-generate/references/examples/FieldReadDeny/policyRuleDefinitions/FieldReadDeny_Rule_1.policyRuleDefinition +72 -0
  199. package/skills/platform-policy-rule-generate/references/examples/LastCharactersFieldMasking/package.xml +12 -0
  200. package/skills/platform-policy-rule-generate/references/examples/LastCharactersFieldMasking/policyRuleDefinitionSets/LastCharactersFieldMasking.policyRuleDefinitionSet +5 -0
  201. package/skills/platform-policy-rule-generate/references/examples/LastCharactersFieldMasking/policyRuleDefinitions/LastCharactersFieldMasking_Rule_1.policyRuleDefinition +77 -0
  202. package/skills/platform-policy-rule-generate/references/examples/PrincipalFieldMatchRLS/package.xml +12 -0
  203. package/skills/platform-policy-rule-generate/references/examples/PrincipalFieldMatchRLS/policyRuleDefinitionSets/PrincipalFieldMatchRLS.policyRuleDefinitionSet +5 -0
  204. package/skills/platform-policy-rule-generate/references/examples/PrincipalFieldMatchRLS/policyRuleDefinitions/PrincipalFieldMatchRLS_Rule_1.policyRuleDefinition +77 -0
  205. package/skills/platform-policy-rule-generate/references/examples/TaggedObjectAccess/package.xml +12 -0
  206. package/skills/platform-policy-rule-generate/references/examples/TaggedObjectAccess/policyRuleDefinitionSets/TaggedObjectAccess.policyRuleDefinitionSet +5 -0
  207. package/skills/platform-policy-rule-generate/references/examples/TaggedObjectAccess/policyRuleDefinitions/TaggedObjectAccess_Rule_1.policyRuleDefinition +65 -0
  208. package/skills/platform-policy-rule-generate/references/headless-transport.md +87 -0
  209. package/skills/platform-policy-rule-generate/references/policy-schema-full.md +18 -11
  210. package/skills/platform-policy-rule-generate/references/policy-shapes.md +107 -0
  211. package/skills/platform-policy-rule-generate/references/principal-expression.md +31 -0
  212. package/skills/platform-policy-rule-generate/references/reference-resolution.md +51 -0
  213. package/skills/platform-policy-rule-generate/references/resource-expression.md +48 -0
  214. package/skills/platform-policy-rule-generate/references/runtime-context.md +9 -0
  215. package/skills/platform-policy-rule-generate/references/templates-access.md +11 -9
  216. package/skills/platform-policy-rule-generate/references/templates-advanced.md +5 -3
  217. package/skills/platform-policy-rule-generate/references/templates-record.md +37 -22
  218. package/skills/platform-policy-rule-generate/references/templates-transform.md +10 -8
  219. package/skills/platform-policy-rule-generate/references/templates.md +2 -2
  220. package/skills/platform-policy-rule-generate/references/ui-compatibility.md +36 -18
  221. package/skills/platform-report-generate/SKILL.md +29 -5
  222. package/skills/platform-report-generate/references/chart-types.md +26 -2
  223. package/skills/platform-report-generate/references/column-names.md +43 -0
  224. package/skills/platform-report-generate/references/errors-and-troubleshooting.md +1 -1
  225. package/skills/platform-report-generate/references/summary-formulas-sorting-limits.md +118 -0
  226. package/skills/platform-report-generate/references/verification-checklist.md +22 -2
  227. package/skills/service-digital-engagement-channel-configure/SKILL.md +49 -110
  228. package/skills/service-digital-engagement-channel-configure/assets/messaging_channel_template.xml +35 -0
  229. package/skills/service-digital-engagement-channel-configure/examples/asa_agent_channel.xml +2 -2
  230. package/skills/service-digital-engagement-channel-configure/examples/auth_queue_channel.xml +58 -0
  231. package/skills/service-digital-engagement-channel-configure/examples/omni_flow_channel.xml +2 -2
  232. package/skills/service-digital-engagement-channel-configure/examples/omni_queue_channel.xml +3 -3
  233. package/skills/service-digital-engagement-channel-configure/references/channel_settings.md +128 -28
  234. package/skills/service-digital-engagement-channel-configure/references/onboarding_contract.md +16 -20
  235. package/skills/service-digital-engagement-channel-configure/references/prechat_params.md +10 -0
  236. package/skills/service-digital-engagement-channel-configure/references/recaptcha_handoff.md +38 -0
  237. package/skills/service-digital-engagement-channel-configure/references/user_verification.md +9 -0
  238. package/skills/service-digital-engagement-channel-configure/scripts/check-api-version.sh +4 -4
  239. package/skills/service-digital-engagement-channel-configure/scripts/normalize-channel-name.sh +12 -7
  240. package/skills/service-e911-configure/SKILL.md +242 -0
  241. package/skills/service-itsm-agentic-setup-agent-runtime-access-assign/SKILL.md +1 -1
  242. package/skills/service-itsm-agentic-setup-agentforce-coordinate/SKILL.md +1 -1
  243. package/skills/service-itsm-agentic-setup-agentforce-studio-configure/SKILL.md +1 -1
  244. package/skills/service-itsm-agentic-setup-agentforce-studio-validate/SKILL.md +1 -1
  245. package/skills/service-itsm-agentic-setup-employee-agent-configure/SKILL.md +1 -1
  246. package/skills/service-itsm-agentic-setup-fulfiller-agent-configure/SKILL.md +1 -1
  247. package/skills/service-itsm-agentic-setup-incident-management/SKILL.md +47 -44
  248. package/skills/service-itsm-agentic-setup-incident-management/examples/output-templates.md +110 -83
  249. package/skills/service-itsm-agentic-setup-incident-management/references/manage-incidents-with-ai.md +7 -3
  250. package/skills/service-itsm-agentic-setup-incident-management/references/priority-matrix.md +7 -5
  251. package/skills/service-itsm-agentic-setup-incident-management/references/sla-milestones.md +2 -2
  252. package/skills/service-itsm-agentic-setup-incident-management/references/status-checks.md +437 -0
  253. package/skills/service-itsm-agentic-setup-itsm-agentforce-permset-assign/SKILL.md +1 -1
  254. package/skills/agentforce-bot-upgrade/references/planner-workflow-reference.md +0 -78
  255. package/skills/experience-content-media-image-generate/SKILL.md +0 -83
  256. package/skills/experience-content-media-image-generate/scripts/download-image.sh +0 -84
  257. package/skills/experience-content-media-stock-image-search/SKILL.md +0 -193
  258. package/skills/experience-content-media-stock-image-search/scripts/download-stock-image.py +0 -102
@@ -1,6 +1,6 @@
1
1
  # MCP Action Integration — Examples & Reference
2
2
 
3
- Two MCP actions provide component discovery and schema retrieval. Call them via `execute_metadata_action`.
3
+ Two invocable actions provide component discovery and schema retrieval, called via the `dispatch` MCP tool. The API-version requirement and shared conventions are in SKILL.md → MCP Action Integration.
4
4
 
5
5
  ## discoverUiComponents
6
6
 
@@ -9,19 +9,19 @@ Discovers components available for a page type in the user's org.
9
9
  **When to call:** Tier 2 discovery — after local scan finds no match.
10
10
 
11
11
  **Input:**
12
- ```json
13
- execute_metadata_action({
14
- "actionName": "DISCOVER_UI_COMPONENTS",
15
- "metadataType": "FLEXI_PAGE",
16
- "parameters": {
17
- "pageType": "RECORD_PAGE",
18
- "pageContext": { "entityName": "Account" },
19
- "searchQuery": "related list"
12
+ ```text
13
+ dispatch POST /services/data/<ver>/headless/invocableaction
14
+ body: {
15
+ "action": "discoverUiComponents-discoverUiComponents",
16
+ "inputs": {
17
+ "pageType": "RECORD_PAGE",
18
+ "pageContext": { "entityName": "Account" },
19
+ "searchQuery": "related list"
20
+ }
20
21
  }
21
- })
22
22
  ```
23
23
 
24
- **Parameters:**
24
+ **Parameters** (all go in `inputs`):
25
25
 
26
26
  | Param | Type | Required | Description |
27
27
  |-------|------|----------|-------------|
@@ -32,14 +32,16 @@ execute_metadata_action({
32
32
  **Output:**
33
33
  ```json
34
34
  {
35
- "componentDefinitions": [
36
- {
37
- "definition": "lst/dynamicRelatedList",
38
- "label": "Dynamic Related List",
39
- "description": "Shows related records...",
40
- "attributes": [{"name": "parentFieldApiName", "description": "..."}]
41
- }
42
- ]
35
+ "outputs": {
36
+ "componentDefinitions": [
37
+ {
38
+ "definition": "lst/dynamicRelatedList",
39
+ "label": "Dynamic Related List",
40
+ "description": "Shows related records...",
41
+ "attributes": [{"name": "parentFieldApiName", "description": "..."}]
42
+ }
43
+ ]
44
+ }
43
45
  }
44
46
  ```
45
47
 
@@ -60,20 +62,20 @@ Retrieves the full property schema for one or more components.
60
62
  **When to call:** Tier 2 (org-discovered) components only — skip for Tier 1 (local) and Tier 3 (generated) components; read @api properties from source instead.
61
63
 
62
64
  **Input:**
63
- ```json
64
- execute_metadata_action({
65
- "actionName": "GET_UI_COMPONENT_SCHEMAS",
66
- "metadataType": "FLEXI_PAGE",
67
- "parameters": {
68
- "pageType": "RECORD_PAGE",
69
- "pageContext": { "entityName": "Account" },
70
- "componentDefinitions": ["lst/dynamicRelatedList", "flexipage/richText"],
71
- "includeKnowledge": true
65
+ ```text
66
+ dispatch POST /services/data/<ver>/headless/invocableaction
67
+ body: {
68
+ "action": "getUiComponentSchemas-getUiComponentSchemas",
69
+ "inputs": {
70
+ "pageType": "RECORD_PAGE",
71
+ "pageContext": { "entityName": "Account" },
72
+ "componentDefinitions": ["lst/dynamicRelatedList", "flexipage/richText"],
73
+ "includeKnowledge": true
74
+ }
72
75
  }
73
- })
74
76
  ```
75
77
 
76
- **Parameters:**
78
+ **Parameters** (all go in `inputs`):
77
79
 
78
80
  | Param | Type | Required | Description |
79
81
  |-------|------|----------|-------------|
@@ -85,14 +87,16 @@ execute_metadata_action({
85
87
  **Output:**
86
88
  ```json
87
89
  {
88
- "componentSchemas": [
89
- {
90
- "definition": "lst/dynamicRelatedList",
91
- "success": true,
92
- "schema": "{...JSON Schema string...}",
93
- "knowledge": "Optional guidance text for this component"
94
- }
95
- ]
90
+ "outputs": {
91
+ "componentSchemas": [
92
+ {
93
+ "definition": "lst/dynamicRelatedList",
94
+ "success": true,
95
+ "schema": "{...JSON Schema string...}",
96
+ "knowledge": "Optional guidance text for this component"
97
+ }
98
+ ]
99
+ }
96
100
  }
97
101
  ```
98
102
 
@@ -0,0 +1,185 @@
1
+ ---
2
+ name: platform-metadata-discovery-get
3
+ description: "Use before creating, changing, or writing code against Salesforce metadata, to find out what already exists in the org with the right tool. Routes each question to metadata grounding, scoped SOQL with sf data query, sf sobject list or describe, sf org list metadata, source retrieval, or local files, and covers orgs and setups where grounding is not available. Use to check whether an object, field, picklist, permission set, page, app, or flow already exists before creating one, confirm field names, types, and picklist values before writing Apex, LWC, SOQL, or Flow logic, list every field on an object or every member of a metadata type, find automation that runs on an object, or explain how something in the org is configured and who can access it. DO NOT TRIGGER for whole-org overviews, org comparison, or drift (use dx-org-analyze), metadata file structure or XML shape (platform-metadata-api-context-get), or Data Cloud DLO and DMO schema (data360-code-extension-generate)."
4
+ metadata:
5
+ relatedSkills:
6
+ - data360-code-extension-generate
7
+ - dx-org-analyze
8
+ - platform-metadata-api-context-get
9
+ - platform-metadata-grounding-get
10
+ - platform-metadata-retrieve
11
+ version: "1.3"
12
+ domains:
13
+ - "Platform"
14
+ cliTools:
15
+ - tool:
16
+ - "sf"
17
+ semver: ">=2.0.0"
18
+ mcpTools:
19
+ metadata-grounding:
20
+ tools:
21
+ - "search_metadata"
22
+ - "query_metadata"
23
+ - "describe_metadata"
24
+ semver: ">=1.0.0"
25
+ headless-360:
26
+ tools:
27
+ - "describe"
28
+ - "dispatch"
29
+ - "dispatch_readonly"
30
+ semver: ">=1.0.0"
31
+ id: "platform-metadata-discovery-get"
32
+ ---
33
+
34
+ # Salesforce Metadata Discovery
35
+
36
+ Before you create metadata, change it, or write code that references it, know what already exists in the org. This skill picks the tool for each question. Metadata grounding finds metadata by meaning when you do not know its name. It needs Salesforce Catalog and a connected grounding server, and many orgs and setups have neither. Every other route works with the `sf` CLI alone.
37
+
38
+ Skip discovery when the request only changes local files and adds no new references to org metadata.
39
+
40
+ ## Check What You Have
41
+
42
+ Do this once per session, before the first lookup.
43
+
44
+ 1. **The CLI and its org.** Run `sf org display --json` to see the default org and its id. If no org is authenticated, ask the user to run `sf org login web` and wait. If you cannot run commands at all, read `references/h360-routes.md`.
45
+ 2. **Grounding servers.** Note whether the Metadata Grounding MCP (tools `search_metadata`, `query_metadata`, `describe_metadata`) or the Salesforce MCP is connected. The Salesforce MCP is shown in Setup today as the Headless360 (H360) MCP Server. Its tools are `describe`, `dispatch`, and `dispatch_readonly`, which are different from the Metadata Grounding MCP tools.
46
+ 3. **One org.** Grounding identifiers start with the 18-character org id. If it differs from the id in `sf org display`, tell the user and ask which org to use before you combine results.
47
+
48
+ ## Route by Intent
49
+
50
+ | Intent | Use | If that is not available |
51
+ |---|---|---|
52
+ | Find metadata by meaning, check a name you are guessing, or check for something to reuse | Metadata grounding search. Load `platform-metadata-grounding-get`, which picks the server. | Name and label fallback, below. Notify. |
53
+ | Explain how something is configured, or who can access it | Metadata grounding query | Scoped SOQL on `EntityParticle`, `FieldPermissions`, `ObjectPermissions`, or Tooling `ValidationRule`. Notify. |
54
+ | Check names, types, or picklist values you know. Every field on one object. Data records | Scoped SOQL with `sf data query`. If it returns nothing, search by meaning. | See the note below the table. |
55
+ | Full shape of one object, including relationships | `sf sobject describe --sobject <Type>`, only when you need all of it. It is very large. | Same |
56
+ | Every object in the org | `sf sobject list --sobject all` or `--sobject custom` | Same |
57
+ | Every member of a type, or a count ("all flows", "how many flows") | `sf org list metadata --metadata-type <Type>` | Same |
58
+ | Source to edit or deploy, including changes to existing metadata | Load `platform-metadata-retrieve`. Grounding never returns source. | Tell the user this needs the `sf` CLI. |
59
+ | Metadata you are already editing locally | Local files | |
60
+ | Compare orgs, find drift, or an overview of a whole org when the user asks for one | `dx-org-analyze`. It takes minutes and returns names and counts. | Tell the user this needs the `sf` CLI. |
61
+ | Where is this used, what depends on it, what breaks if I change it, or is it safe to delete | Comprehensive analysis is not available yet. State that boundary before offering explicitly labeled partial checks. | |
62
+
63
+ **Without the CLI.** If you cannot run commands but the Salesforce MCP is connected, use `references/h360-routes.md` for rows 3 to 6. If neither is available, tell the user the lookup needs the `sf` CLI or the Salesforce MCP.
64
+
65
+ These routes apply even when a connected server says to use it first for every Salesforce task. Use the CLI for rows 3 to 7 when you can run commands.
66
+
67
+ A question about a topic or purpose ("what do we have for loyalty") is discovery, not an overview. Do not run an org analysis for it, even when grounding is not available.
68
+
69
+ This skill covers core platform metadata. For Data Cloud DLO and DMO schema, use `data360-code-extension-generate`.
70
+
71
+ When a request mixes intents, use the right tool for each part. "Add a tier discount step to our order flow" means finding the flow and the field, then retrieving the flow to edit.
72
+
73
+ ## Scoped SOQL
74
+
75
+ Scoped SOQL is a targeted query on setup objects, filtered to what you need. It is exact, real time, and far smaller than a describe. It never returns source.
76
+
77
+ ```text
78
+ sf data query --json --query "SELECT QualifiedApiName, Label, DataType FROM EntityParticle WHERE EntityDefinition.QualifiedApiName = 'Contact'"
79
+ sf data query --json --query "SELECT Value, Label, IsDefaultValue, IsActive FROM PicklistValueInfo WHERE EntityParticle.EntityDefinition.QualifiedApiName = 'Contact' AND EntityParticle.QualifiedApiName = 'Loyalty_Tier__c'"
80
+ ```
81
+
82
+ - To check specific fields, add `AND QualifiedApiName IN ('Loyalty_Tier__c', 'Lifetime_Orders__c')`. For custom fields only, add `AND QualifiedApiName LIKE '%__c'`.
83
+ - `EntityParticle` includes parts of compound fields, such as `MailingCity`.
84
+ - Add `--use-tooling-api` for `CustomField` and `ValidationRule`.
85
+ - `EntityDefinition`, `EntityParticle`, and `FieldDefinition` do not accept `OR`. Run one scoped query per condition instead of broadening the query or removing its object/type filters.
86
+
87
+ More patterns, including access and automation, are in `references/scoped-soql.md`.
88
+
89
+ ## When Grounding Is Not Available
90
+
91
+ Say the line below once per session, in your answer, next to the results of the name and label search. Do not announce the fallback before you search, and do not repeat it later in the session. Use the line that matches the cause, word for word, including the last sentence. Do not shorten or rephrase it. If you stop before you can report results, say it in that message instead.
92
+
93
+ | Cause | Say |
94
+ |---|---|
95
+ | No grounding server connected | "Metadata Grounding isn't connected, so I matched by name and label, which can miss metadata named differently. Connect the Metadata Grounding MCP to search by meaning." |
96
+ | Catalog not enabled | "Salesforce Catalog isn't turned on in this org, so I matched by name and label, which can miss metadata named differently. An admin can turn on Salesforce Catalog through Feature Manager in Data Cloud Setup." |
97
+ | Permission missing | "Catalog search needs the Customize Application permission, so I matched by name and label, which can miss metadata named differently." |
98
+
99
+ Then search names and labels. Try two or three likely words, one `LIKE` per query.
100
+
101
+ ```text
102
+ sf data query --json --query "SELECT QualifiedApiName, Label FROM EntityDefinition WHERE Label LIKE '%loyalty%'"
103
+ sf data query --json --query "SELECT QualifiedApiName, Label, DataType FROM EntityParticle WHERE EntityDefinition.QualifiedApiName = 'Contact' AND Label LIKE '%tier%'"
104
+ sf data query --json --use-tooling-api --query "SELECT DeveloperName, EntityDefinition.QualifiedApiName FROM CustomField WHERE DeveloperName LIKE '%tier%' AND NamespacePrefix = null"
105
+ sf data query --json --query "SELECT ApiName, Label, ProcessType, IsActive FROM FlowDefinitionView WHERE Label LIKE '%order%'"
106
+ ```
107
+
108
+ - The `CustomField` query searches custom fields on every object. `DeveloperName` has no `__c`. Drop rows with no object name. They are Data Cloud fields.
109
+ - For other types, and for types the catalog does not cover, list names with `sf org list metadata` and scan them.
110
+ - Name matching misses metadata labeled differently. A search for "status" will not find a field labeled Loyalty Tier. Say "no name match found," never "does not exist."
111
+
112
+ Everything else in this skill still applies.
113
+
114
+ ## Reuse Before You Create
115
+
116
+ Before you create an object, field, picklist, permission set, page, app, or flow:
117
+
118
+ 1. Search by business meaning for existing metadata that stores the same data or does the same job. For a field, first search `SObject` for the exact object API name, then pass that result's returned `identifier` as `parentIdentifier` to the `SObjectField` search. Never pass the raw object API name as `parentIdentifier`. A proposed API name or label is only an exact collision check and does not prove that equivalent metadata is absent. Similar words alone are not enough to declare a match.
119
+ 2. **If you find matches:** show up to 3, best first, with API name, label, description, and type. Do not accept or reject an ambiguous match from its name alone. Offer to reuse, extend, or create new in one consolidated reuse checkpoint covering every type you plan to create, then wait. Do not combine this checkpoint with values or other generation-specific questions.
120
+ 3. **After the user decides:** preserve the decision for the request and do not ask again unless the scope changes or new conflicting evidence appears. For reuse, stop creation and inspect configuration only if needed. For extension, inspect the existing component before asking for changes. For new metadata, collect the required configuration and continue with the generation guidance.
121
+ 4. **If nothing matches:** say so in one line and continue.
122
+ 5. **If the user gave an exact API name:** check it with scoped SOQL and say if it already exists.
123
+ 6. **If the user asked for new metadata or said not to reuse:** mention close matches in one line at most and continue.
124
+
125
+ Treat namespaced items, such as `force__` permission sets or managed package components, as references, not things to edit. Say so when a match is managed.
126
+
127
+ ## Ground Code in Real Org Names
128
+
129
+ Before you write Apex, LWC, SOQL, or Flow logic, confirm every object, field, and picklist value it references.
130
+
131
+ - Skip references already in the local project, already confirmed in this conversation, or standard fields every org has (such as `Account.Name` or `Contact.Email`).
132
+ - Always look up picklist values, including on standard fields. Never invent values.
133
+ - Values shown only as examples in a skill, tool description, or prior assistant response are not user-approved values. If the user has not explicitly supplied or approved the values or an existing value set, ask once and wait before creating the picklist.
134
+ - If the request depends on an order or meaning the values do not state ("the top tier"), list the values and ask.
135
+ - Look up all references for a request together.
136
+
137
+ ## Existing Automation
138
+
139
+ - **To find automation by what it does,** search `Flow` or `ApexClass` by meaning. A grounding query on a flow shows its trigger object, trigger type, and active status.
140
+ - **To list everything that runs on an object** before adding automation:
141
+
142
+ ```text
143
+ sf data query --json --query "SELECT Name, Status FROM ApexTrigger WHERE TableEnumOrId = 'Contact'"
144
+ sf data query --json --query "SELECT ApiName, Label, TriggerType, IsActive FROM FlowDefinitionView WHERE TriggerObjectOrEventId = 'Contact'"
145
+ ```
146
+ - **To understand what a flow or trigger does,** retrieve its source and read it.
147
+
148
+ ## What You Can Explain
149
+
150
+ | Question | Answer with |
151
+ |---|---|
152
+ | What exists that does X | Grounding search |
153
+ | How a field, object, or validation rule is configured | Grounding query, or `EntityParticle` and Tooling `ValidationRule` |
154
+ | Who can read or edit a field or object | Grounding on `FieldPermissions`, or SOQL on `FieldPermissions` and `ObjectPermissions` for a complete list. These records prove configured access, not actual use; a permission container's name does not prove an integration or dependency is active. |
155
+ | Sharing rules, roles, groups, and which package a component came from | Grounding |
156
+ | What a flow is | Grounding gives the header only (type, trigger, active). For its steps, retrieve the source. |
157
+ | What an Apex class does | Grounding gives signatures only. Retrieve the source. |
158
+ | Why a save failed | A partial answer. Check validation rules on the object, then retrieve the automation that runs on it. |
159
+ | Page layouts, reports, custom metadata types, custom settings | Not in the catalog. Use `sf org list metadata` and retrieve. |
160
+ | Where something is used, what depends on it, what breaks if it changes, or whether it is safe to delete | Comprehensive analysis is not available yet. Say so before any checks. You may offer narrow checks, but label each one as partial and never present their union as complete or conclude that the change is safe. |
161
+
162
+ ## Working With Skills
163
+
164
+ - This skill decides what already exists. Build skills decide how to create it. Run discovery before any skill writes files.
165
+ - If a loaded skill has its own equivalent semantic reuse check, use it instead of the matching step here. Do not run both. An exact-name or exact-label collision check is not equivalent and does not replace semantic reuse discovery.
166
+ - Two exceptions, even when a skill says otherwise: always look up picklist values, and check names, types, or picklist values you know with scoped SOQL instead of a full object describe.
167
+ - If a skill's discovery step fails or its tool is not available, use the routes in this skill and tell the user once.
168
+
169
+ ## Freshness and Local Files
170
+
171
+ - Reuse discovery results for the rest of the conversation unless that item has changed.
172
+ - The catalog can take several minutes to reflect deploys and other org changes. For anything changed in this session, trust the local source and deploy results, and confirm with SOQL, which is real time. If the user reports a change SOQL does not show, ask them to confirm the name and org before you write code that uses it.
173
+ - When the metadata you need is not in the local project, retrieve it before editing, and tell the user you did.
174
+ - If you learn the org version differs from local in ways you did not make, for example from a retrieve or a deploy conflict, show the difference and ask before you overwrite either one.
175
+ - When scanning local source for references, read the package directories from `sfdx-project.json` and search those directories. Exclude response exports, logs, generated output, caches, and agent configuration unless the user explicitly asks to inspect them.
176
+ - Searching local files finds exact text only. Do not use it to find org metadata by meaning.
177
+
178
+ ## Never
179
+
180
+ - Write or deploy files built from grounding query output. It returns properties, not source.
181
+ - Treat grounding results as a complete list. They are ranked and capped.
182
+ - Say metadata does not exist because a search or a name match found nothing.
183
+ - Combine results from two different orgs.
184
+ - Present partial dependency or reference checks as a complete impact analysis, or conclude from them that metadata is safe to change or delete.
185
+ - Treat illustrative values from examples, skills, or tool descriptions as user-approved metadata.
@@ -0,0 +1,25 @@
1
+ # What Each Route Calls
2
+
3
+ For engineers and reviewers. The skill names tools, not APIs, because the agent picks tools. Read from sf CLI 2.150.6 and jsforce source, and checked live on 2026-10-07.
4
+
5
+ | Route | API call |
6
+ |---|---|
7
+ | `sf sobject list` | REST `describeGlobal` (`GET /services/data/vXX.0/sobjects`), filtered to custom or all on the client |
8
+ | `sf sobject describe` | REST describe SObject (`GET /services/data/vXX.0/sobjects/<Type>/describe`). Tooling describe with `--use-tooling-api` |
9
+ | `sf org list metadata` | Metadata API `listMetadata` (SOAP) |
10
+ | `sf data query` | REST query resource (`GET /services/data/vXX.0/query`). Tooling query resource with `--use-tooling-api` |
11
+ | `sf project retrieve start` | Metadata API `retrieve` (SOAP) |
12
+ | Metadata grounding search | `GET /services/data/vXX.0/metadata-grounding/search` |
13
+ | Metadata grounding describe | `POST /services/data/vXX.0/metadata-grounding/schema` |
14
+ | Metadata grounding query | `POST /services/data/vXX.0/metadata-grounding/query` |
15
+
16
+ ## Which Surface Reaches Which Call
17
+
18
+ | Call | `sf` CLI | Metadata Grounding MCP | Salesforce MCP |
19
+ |---|---|---|---|
20
+ | REST and Tooling query | Yes | No | Yes, `dispatch_readonly` |
21
+ | REST describe and object list | Yes | No | Yes, `dispatch_readonly` |
22
+ | Metadata API `listMetadata` and `retrieve` | Yes | No | No |
23
+ | Metadata grounding | No. The grounding paths are reachable only through an MCP server, so a direct REST call returns not found | Yes | Yes, after `describe` on the operation id |
24
+
25
+ The skills do not use the Enterprise API, the SOAP API with the org-specific WSDL. None of these tools call it.
@@ -0,0 +1,30 @@
1
+ # Routes Through the Salesforce MCP
2
+
3
+ Use this file when you reach the org through the Salesforce MCP. If you are in a terminal or IDE and can run the `sf` CLI, the CLI routes work as well.
4
+
5
+ Grounding itself is covered in `platform-metadata-grounding-get`. This file covers the routes the skill body sends to the CLI.
6
+
7
+ ## How to Call
8
+
9
+ Use `dispatch_readonly` with `method: GET`. Pass the path as `url` and the SOQL as the `q` query parameter, not appended to the URL.
10
+
11
+ | Route | `url` | Query parameters |
12
+ |---|---|---|
13
+ | Standard SOQL | `/services/data/v66.0/query` | `q`: the SOQL |
14
+ | Tooling SOQL | `/services/data/v66.0/tooling/query` | `q`: the SOQL |
15
+ | Describe one object | `/services/data/v66.0/sobjects/<Type>/describe` | None |
16
+
17
+ The rows are in `body.records`. For a `COUNT()` query the number is in `body.totalSize` and `records` is empty. Every pattern in `scoped-soql.md` works through these paths.
18
+
19
+ ## Route by Intent
20
+
21
+ | Intent | Through this server |
22
+ |---|---|
23
+ | Check names, types, or picklist values you know. Every field on one object. Data records | Standard SOQL. Use Tooling SOQL for `CustomField` and `ValidationRule`. |
24
+ | Full shape of one object, only when you need all of it | Describe one object. It is very large. |
25
+ | Every object in the org | Standard SOQL on `EntityDefinition`, for example `SELECT QualifiedApiName, Label FROM EntityDefinition WHERE QualifiedApiName LIKE '%__c'` for custom objects. Never call `/sobjects` for the full object list. It returned about 1.8 million characters in one test org. |
26
+ | Every member of a type, or a count | Tooling SOQL for Tooling types, for example `SELECT COUNT() FROM FlowDefinition`, or `ApexClass` and `ValidationRule`. To list flows with labels, use Standard SOQL on `FlowDefinitionView`. Other types cannot be listed through this server. Tell the user it needs the `sf` CLI in a terminal or IDE. |
27
+ | Source to edit or deploy | Not available through this server. Load `platform-metadata-retrieve` if it is available. Otherwise tell the user it needs the `sf` CLI in a terminal or IDE. |
28
+ | Compare orgs, find drift, or a whole-org overview | Not available through this server. Tell the user it needs the `sf` CLI. |
29
+
30
+ If a call fails with an authentication or session error, tell the user to reconnect the Salesforce MCP. If it fails as not found or not allowed, say so, and tell the user the lookup may need the `sf` CLI in a terminal or IDE.
@@ -0,0 +1,52 @@
1
+ # Scoped SOQL Patterns
2
+
3
+ Run each query through the Salesforce MCP with `dispatch_readonly`, as Standard or Tooling SOQL per the table. The paths are in `ref:platform-metadata-discovery-get/references/h360-routes`. In a terminal or IDE, `sf data query --json --query "<SOQL>"` works too. Add `--use-tooling-api` where the table says Tooling, and `--target-org <alias>` when the user named an org other than the default.
4
+
5
+ ## Objects and Fields
6
+
7
+ | Need | Query | API |
8
+ |---|---|---|
9
+ | Does this object exist | `SELECT QualifiedApiName, Label FROM EntityDefinition WHERE QualifiedApiName = 'Loyalty_Transaction__c'` | Standard |
10
+ | Several objects at once | `SELECT QualifiedApiName, Label FROM EntityDefinition WHERE QualifiedApiName IN ('Menu__c', 'Promotion__c')` | Standard |
11
+ | Every field on one object | `SELECT QualifiedApiName, Label, DataType FROM EntityParticle WHERE EntityDefinition.QualifiedApiName = 'Contact'` | Standard |
12
+ | Custom fields only | Add `AND QualifiedApiName LIKE '%__c'` to the query above | Standard |
13
+ | Check specific fields | Add `AND QualifiedApiName IN ('Loyalty_Tier__c', 'Email')` | Standard |
14
+ | Picklist values | `SELECT Value, Label, IsDefaultValue, IsActive FROM PicklistValueInfo WHERE EntityParticle.EntityDefinition.QualifiedApiName = 'Contact' AND EntityParticle.QualifiedApiName = 'Loyalty_Tier__c'` | Standard |
15
+ | Record types on an object | `SELECT Name, DeveloperName, IsActive FROM RecordType WHERE SobjectType = 'Contact'` | Standard |
16
+
17
+ `EntityParticle` includes parts of compound fields, such as `MailingCity`. A full field list for Contact is about a tenth the size of a describe.
18
+
19
+ ## Name and Label Fallback
20
+
21
+ Use these only when grounding is not available. Try two or three likely words.
22
+
23
+ | Need | Query | API |
24
+ |---|---|---|
25
+ | Objects by label | `SELECT QualifiedApiName, Label FROM EntityDefinition WHERE Label LIKE '%loyalty%'` | Standard |
26
+ | Fields on one object by label | `SELECT QualifiedApiName, Label, DataType FROM EntityParticle WHERE EntityDefinition.QualifiedApiName = 'Contact' AND Label LIKE '%tier%'` | Standard |
27
+ | Custom fields on every object by name | `SELECT DeveloperName, EntityDefinition.QualifiedApiName FROM CustomField WHERE DeveloperName LIKE '%tier%' AND NamespacePrefix = null` | Tooling |
28
+ | Flows by label | `SELECT ApiName, Label, ProcessType, IsActive FROM FlowDefinitionView WHERE Label LIKE '%order%'` | Standard |
29
+ | Permission sets by label | `SELECT Name, Label FROM PermissionSet WHERE IsOwnedByProfile = false AND Label LIKE '%loyalty%'` | Standard |
30
+
31
+ - `EntityDefinition`, `EntityParticle`, and `FieldDefinition` do not accept `OR`. The query fails with "Disjunctions not supported." Run one query per word.
32
+ - `CustomField` accepts `OR`. `DeveloperName` has no `__c`. Drop rows with no object name. They are Data Cloud fields.
33
+
34
+ ## Access
35
+
36
+ | Need | Query | API |
37
+ |---|---|---|
38
+ | Who can read or edit a field | `SELECT Parent.Label, Parent.IsOwnedByProfile, Parent.Profile.Name, PermissionsRead, PermissionsEdit FROM FieldPermissions WHERE SobjectType = 'Contact' AND Field = 'Contact.Loyalty_Tier__c'` | Standard |
39
+ | Who can use an object | `SELECT Parent.Label, Parent.IsOwnedByProfile, Parent.Profile.Name, PermissionsRead, PermissionsCreate, PermissionsEdit, PermissionsDelete FROM ObjectPermissions WHERE SobjectType = 'Loyalty_Transaction__c'` | Standard |
40
+
41
+ When `Parent.IsOwnedByProfile` is true, the row belongs to a profile. Read the name from `Parent.Profile.Name`, because `Parent.Label` is an id for those rows. A field or object with no row for a profile or permission set has no access through it.
42
+
43
+ ## Automation and Rules
44
+
45
+ | Need | Query | API |
46
+ |---|---|---|
47
+ | Triggers on an object | `SELECT Name, Status FROM ApexTrigger WHERE TableEnumOrId = 'Contact'` | Standard |
48
+ | Flows that run on an object | `SELECT ApiName, Label, TriggerType, IsActive FROM FlowDefinitionView WHERE TriggerObjectOrEventId = 'Contact'` | Standard |
49
+ | Validation rules on an object | `SELECT ValidationName, Active, ErrorMessage FROM ValidationRule WHERE EntityDefinition.QualifiedApiName = 'Contact'` | Tooling |
50
+ | Count of flows | `SELECT COUNT() FROM FlowDefinition` | Tooling |
51
+
52
+ These return names and status, not logic. To read what a flow, trigger, or rule does, retrieve its source.
@@ -0,0 +1,170 @@
1
+ ---
2
+ name: platform-metadata-grounding-get
3
+ description: "Find metadata that already exists in a Salesforce org by meaning, when you do not know its exact API name. Use to find objects, fields, flows, Apex classes, picklist values, permission sets, validation rules, record types, and sharing rules by what they store or do. Use before creating metadata to check whether something similar already exists, and before writing Apex, LWC, SOQL, or Flow logic to confirm the real names. Use to read how a field, object, or validation rule is configured, and which profiles and permission sets can read or edit a field. Works through the Metadata Grounding MCP (search_metadata, query_metadata, describe_metadata) or the Salesforce MCP operations searchMetadata, queryMetadata, and describeMetadata. Needs Salesforce Catalog in the org. DO NOT TRIGGER for choosing between grounding, SOQL, and the CLI (use platform-metadata-discovery-get), retrieving source (platform-metadata-retrieve), or Data Cloud DLO and DMO schema (data360-code-extension-generate)."
4
+ metadata:
5
+ relatedSkills:
6
+ - data360-code-extension-generate
7
+ - platform-metadata-discovery-get
8
+ - platform-metadata-retrieve
9
+ version: "2.2"
10
+ accessCheck: "CDP.orgHasUnifiedCatalogProvisioned"
11
+ domains:
12
+ - "Platform"
13
+ mcpTools:
14
+ metadata-grounding:
15
+ tools:
16
+ - "search_metadata"
17
+ - "query_metadata"
18
+ - "describe_metadata"
19
+ semver: ">=1.0.0"
20
+ headless-360:
21
+ tools:
22
+ - "describe"
23
+ - "dispatch"
24
+ - "dispatch_readonly"
25
+ semver: ">=1.0.0"
26
+ cliTools:
27
+ - tool:
28
+ - "sf"
29
+ semver: ">=2.0.0"
30
+ id: "platform-metadata-grounding-get"
31
+ ---
32
+
33
+ # Salesforce Metadata Grounding
34
+
35
+ Metadata grounding searches the org's Salesforce Catalog, an index of the org's metadata with names, labels, descriptions, and configuration properties. It finds metadata by meaning, so "customer rewards status" can find a field labeled Loyalty Tier. It has three read-only operations: search, query, and describe.
36
+
37
+ Results are ranked and capped. They are never a complete list, and grounding never returns source.
38
+
39
+ ## When Not to Use Grounding
40
+
41
+ - Questions about standard Salesforce features or product behavior that do not depend on this org.
42
+ - A name you already know. Check it with scoped SOQL, which is exact and real time.
43
+ - A complete list, a count, or proof that something does not exist. Use scoped SOQL or `sf org list metadata`.
44
+ - Source to edit or deploy. Retrieve it with `platform-metadata-retrieve`.
45
+ - Where something is used, or what breaks if it changes. Grounding has no reference data.
46
+ - Metadata already returned in this conversation that has not changed since.
47
+
48
+ `platform-metadata-discovery-get` picks the right tool for each of these.
49
+
50
+ ## Pick the Server
51
+
52
+ Two servers reach the same catalog and return the same results. Use one server per request, never both for the same lookup.
53
+
54
+ The Salesforce MCP is shown in Setup today as the Headless360 (H360) MCP Server. On that server, `searchMetadata`, `queryMetadata`, and `describeMetadata` are operation ids that you pass to `describe` and `dispatch`. They are not tool names. The tools `search_metadata`, `query_metadata`, and `describe_metadata` exist only on the Metadata Grounding MCP.
55
+
56
+ | Order | Server | How to call |
57
+ |---|---|---|
58
+ | 1 | Metadata Grounding MCP | Call `search_metadata`, `query_metadata`, or `describe_metadata` with the inputs below. |
59
+ | 2 | Salesforce MCP, when the Metadata Grounding MCP is not connected or keeps failing | Call `describe` on the operation id `searchMetadata`, `queryMetadata`, or `describeMetadata`. Do not use `discover`, and do not describe the grounding recipe, which is too large to read. Then call the path `describe` returns with the same inputs. Use `dispatch_readonly` for `searchMetadata` and pass the inputs as query parameters. Use `dispatch` for `queryMetadata` and `describeMetadata`, which are POST calls but only read, and pass the inputs as the JSON body. Do not use other metadata search operations. |
60
+ | Neither connected | | Grounding is not available. Use the name and label fallback in `platform-metadata-discovery-get`. |
61
+
62
+ ## When a Call Fails
63
+
64
+ | What happens | What to do |
65
+ |---|---|
66
+ | The error says Salesforce Catalog is not enabled, or the user lacks the Customize Application permission | Stop using grounding on both servers for the rest of the session. Use the fallback and tell the user why, once. |
67
+ | Any other error or a timeout | Retry once. If it fails again, use the next server for this request. After failures on two requests, use the next server for the rest of the session. |
68
+ | The tool or server is not present | Start with the next server. |
69
+
70
+ A missing tool, an access error, or a 404 is not proof that the metadata does not exist.
71
+
72
+ ## Response Shapes
73
+
74
+ | Call | Metadata Grounding MCP | Salesforce MCP |
75
+ |---|---|---|
76
+ | Search | `{results, totalCount}` | Same payload in the response body |
77
+ | Describe and query | Wrapped as `{defaultExc: "<json string>", responseCode}`. Parse the `defaultExc` string to read `types`, `typeDetails`, or `records`. | Payload in the response body, not wrapped |
78
+ | Error | An array of `{errorCode, message}` | Same array in the response body |
79
+
80
+ Handle both shapes. If the response has a `defaultExc` string, parse it. Otherwise read the payload directly.
81
+
82
+ ## Catalog Type Names
83
+
84
+ Type names are case-sensitive, and some differ from Metadata API names.
85
+
86
+ | Metadata API name | Catalog type |
87
+ |---|---|
88
+ | CustomObject | `SObject` (subtypes `CustomObject`, `StandardData`) |
89
+ | CustomField | `SObjectField` (subtypes `CustomField`, `StandardField`, `CustomPersonAccountField`) |
90
+ | GlobalValueSet, StandardValueSet | `PicklistValueSet` (subtypes `Global`, `Standard`, `Local`) |
91
+ | FlexiPage | `Flexipage` |
92
+ | CustomTab | `Tab` |
93
+ | CustomApplication | `TabSet` |
94
+ | QuickAction | `QuickActionDefinition` |
95
+ | Queue | `Group` with subtype `Queue` |
96
+ | Role | `UserRole` |
97
+
98
+ Most other types use the Metadata API name, for example `ApexClass`, `ApexTrigger`, `Flow`, `PermissionSet`, `PermissionSetGroup`, `Profile`, `ValidationRule`, `RecordType`, `SharingRule`, `FieldPermissions`, `PicklistValue`, and `CustomPermission`.
99
+
100
+ Call describe with no `requests` only when a type you need is in neither list, and read only the type names. The full response is about 29K characters. Call describe with a `metadataType` only when you need that type's properties.
101
+
102
+ ## Search
103
+
104
+ Inputs:
105
+ - `query`: required plain-language phrase. An empty query returns `ILLEGAL_QUERY_PARAMETER_VALUE`.
106
+ - `metadataType`: optional catalog type name.
107
+ - `metadataSubType`: optional single value. It requires `metadataType`.
108
+ - `parentIdentifier`: optional, to search inside one object or permission container.
109
+ - `limit`: 1 to 100, default 50. Use 10 to 20.
110
+
111
+ How to search well:
112
+ 1. **Filter by type when you can.** For broad questions, run a few searches on likely types, such as `SObject`, `SObjectField`, and `Flow`, instead of one unfiltered search.
113
+ 2. **Search inside an object** by passing its returned identifier as `parentIdentifier`. First search `SObject` for the exact object API name, or reuse a field result's `parentIdentifier`, then copy the identifier unchanged. Never pass the raw object API name. This finds fields related to a topic. It is not a full field list.
114
+ 3. **Try one more phrasing** with synonyms or likely labels before you report "no match found in the org catalog."
115
+ 4. **Trust the service's exposure policy.** Do not infer visibility or support from API-name suffixes. Keep results relevant to the user's requested domain; intentionally exposed Data Cloud metadata must remain available when it is relevant.
116
+ 5. **Stop at search** when names, labels, and descriptions answer the question. Do not query after a search that returned nothing.
117
+
118
+ ## Query
119
+
120
+ Query returns full records with type-specific `properties`, such as a field's data type, required flag, length, formula, default, help text, and picklist value set.
121
+
122
+ Send exactly one of:
123
+ - `metadataIdentifiers`: 1 to 50 identifiers, to read the records themselves.
124
+ - `parentIdentifiers`: 1 to 10 identifiers, to read their child records.
125
+
126
+ Use `parentIdentifiers` for picklist values: search `PicklistValueSet` for the field, then pass the value set's identifier. Do not pass an object. That returns every field on it, which is very large (about 77KB for Contact). For a full field list, use scoped SOQL on `EntityParticle`.
127
+
128
+ Identifiers have three parts separated by `::`: the 18-character org id, the name, and the type. Use only identifiers the tools returned. Never build, shorten, or edit one.
129
+
130
+ ## Common Patterns
131
+
132
+ **Is there a field for this already?** Search `SObjectField` with the user's words and the object's `parentIdentifier`. Show the best matches with API name, label, and description.
133
+
134
+ **How is this field configured?** Search for the field, then query its identifier and read `properties`.
135
+
136
+ **What values does this picklist have?** Search `PicklistValueSet` for the field, then query the value set with `parentIdentifiers`.
137
+
138
+ **Who can read or edit this field?** Search `FieldPermissions` with the field's API name, such as `Contact.Loyalty_Tier__c`. Each result's parent is a profile or permission set. Query the results to read the read and edit flags. Results stop at 100, so for a complete list use scoped SOQL on `FieldPermissions`.
139
+
140
+ **What does this validation rule enforce?** Search `ValidationRule`, then query it for the formula, error message, and active flag.
141
+
142
+ ## Limits
143
+
144
+ - **Flows:** the header only, meaning process type, trigger type, trigger object, and active status. No elements or logic. Trigger object is not a filter, so searching cannot list every flow on an object.
145
+ - **Apex:** signatures only, no method bodies. Managed classes return an empty stub.
146
+ - **Pages and actions:** `Flexipage` and `QuickActionDefinition` records are not children of their object. Searching with the object as `parentIdentifier` does not find them. Search by meaning instead.
147
+ - **Not in the catalog:** page layouts, reports, custom metadata types, and custom settings.
148
+ - **Freshness:** the catalog can take several minutes to reflect deploys and other changes. For anything changed in this session, trust the deploy results and confirm with SOQL, which is real time.
149
+
150
+ ## Grounding Discipline
151
+
152
+ - Cite the API names, labels, and properties the tools returned. Say which statements are observed and which are inferred.
153
+ - Say "no match found in the org catalog." Never say the metadata does not exist.
154
+ - Never treat results as a complete list.
155
+ - Never write or deploy files built from query output. It returns properties, not source.
156
+ - Every identifier starts with the org id. If you also use the CLI or another tool, confirm both point to the same org before you combine results.
157
+
158
+ <!-- skill-validate: ignore-start -->
159
+ <!-- codey:operations start -->
160
+ ## Operations Reference
161
+
162
+ Operations this skill uses — routing and dependency reference.
163
+
164
+ | Operation | Purpose | Status | Call | Depends on |
165
+ |-----------|---------|--------|------|------------|
166
+ | `describe-metadata` | read | — | `POST /metadata-grounding/schema` | — |
167
+ | `search-metadata` | read | — | `GET /metadata-grounding/search` | — |
168
+ | `query-metadata` | read | — | `POST /metadata-grounding/query` | — |
169
+ <!-- codey:operations end -->
170
+ <!-- skill-validate: ignore-end -->