@salesforce/afv-skills 1.59.0 → 1.61.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 (174) hide show
  1. package/package.json +1 -1
  2. package/skills/agentforce-architecture-analyze/SKILL.md +66 -17
  3. package/skills/agentforce-architecture-analyze/assets/cli/show_access_token.yaml +4 -7
  4. package/skills/agentforce-architecture-analyze/references/contract.json +1 -1
  5. package/skills/agentforce-architecture-analyze/scripts/emit_env.py +2 -2
  6. package/skills/agentforce-architecture-analyze/scripts/main.py +40 -44
  7. package/skills/agentforce-architecture-analyze/scripts/rest_client.py +11 -3
  8. package/skills/agentforce-architecture-analyze/scripts/sf_cli.py +77 -10
  9. package/skills/agentforce-architecture-analyze/scripts/tests/test_end_to_end_fixture.py +1 -0
  10. package/skills/agentforce-architecture-analyze/scripts/tests/test_flow_children_inflation.py +1 -0
  11. package/skills/agentforce-architecture-analyze/scripts/tests/test_main_pipeline.py +53 -2
  12. package/skills/agentforce-architecture-analyze/scripts/tests/test_resolve_creds.py +184 -36
  13. package/skills/agentforce-architecture-analyze/scripts/tests/test_rest_client.py +17 -0
  14. package/skills/agentforce-architecture-analyze/scripts/tests/test_sf_cli.py +165 -11
  15. package/skills/agentforce-architecture-analyze/scripts/tests/test_skill_md_pipeline_block.py +319 -0
  16. package/skills/agentforce-d360-analyze/SKILL.md +28 -10
  17. package/skills/agentforce-d360-analyze/scripts/dc.py +200 -50
  18. package/skills/agentforce-d360-analyze/scripts/discover_sessions.py +10 -6
  19. package/skills/agentforce-d360-analyze/scripts/fetch_dc.py +22 -6
  20. package/skills/agentforce-d360-analyze/scripts/resolve_session.py +21 -13
  21. package/skills/agentforce-d360-analyze/scripts/tests/test_dc_and_resolve_session.py +298 -76
  22. package/skills/agentforce-d360-analyze/scripts/tests/test_default_target_org.py +432 -0
  23. package/skills/agentforce-d360-analyze/scripts/tests/test_discover_sessions.py +1 -1
  24. package/skills/agentforce-d360-analyze/scripts/tests/test_resolve_session_main.py +9 -3
  25. package/skills/agentforce-d360-analyze/scripts/tests/test_skill_md_prefix_block.py +176 -0
  26. package/skills/consumer-goods-accruals-datakit-deploy/SKILL.md +17 -27
  27. package/skills/consumer-goods-accruals-datakit-deploy/scripts/setup.js +7 -17
  28. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/00-check-prerequisites.js +47 -63
  29. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/01-download-static-resource.js +10 -13
  30. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/02-replace-org-id.js +46 -46
  31. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/03-deploy-metadata.js +4 -21
  32. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/06-create-dataspace.js +58 -82
  33. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/07-deploy-accruals-reports.js +16 -315
  34. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/08-deploy-ui.js +9 -24
  35. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/09-completion.js +44 -44
  36. package/skills/consumer-goods-accruals-datakit-deploy/scripts/steps/utils.js +11 -63
  37. package/skills/consumer-goods-rtr-datacloud-export-configure/SKILL.md +2 -1
  38. package/skills/consumer-goods-tpe-dashboard-configure/SKILL.md +2 -1
  39. package/skills/consumer-goods-tpe-dashboard-custom-kpi-configure/SKILL.md +2 -1
  40. package/skills/consumer-goods-tpe-datakit-deploy/SKILL.md +2 -1
  41. package/skills/data360-schema-get/SKILL.md +3 -3
  42. package/skills/design-systems-slds-validate/references/report-format.md +1 -1
  43. package/skills/dx-org-manage/SKILL.md +1 -0
  44. package/skills/dx-org-shape-manage/SKILL.md +1 -0
  45. package/skills/dx-org-snapshot-manage/SKILL.md +172 -0
  46. package/skills/dx-org-snapshot-manage/examples/create_error_output.json +16 -0
  47. package/skills/dx-org-snapshot-manage/examples/create_success_output.json +19 -0
  48. package/skills/dx-org-snapshot-manage/examples/delete_output.json +9 -0
  49. package/skills/dx-org-snapshot-manage/examples/get_output.json +19 -0
  50. package/skills/dx-org-snapshot-manage/examples/list_output.json +36 -0
  51. package/skills/dx-org-snapshot-manage/references/cli_flags.md +179 -0
  52. package/skills/dx-org-snapshot-manage/references/snapshot_usage.md +55 -0
  53. package/skills/dx-org-trial-expiration-check/SKILL.md +1 -1
  54. package/skills/dx-org-trial-expiration-check/scripts/check_expiration.sh +2 -2
  55. package/skills/education-cloud-student-recruitment-agent-configure/SKILL.md +7 -5
  56. package/skills/education-cloud-student-recruitment-agent-configure/references/prerequisites.md +11 -11
  57. package/skills/experience-content-media-image-generate/SKILL.md +83 -0
  58. package/skills/experience-content-media-image-generate/scripts/download-image.sh +84 -0
  59. package/skills/external-diagram-mermaid-generate/SKILL.md +12 -12
  60. package/skills/field-service-data-capture-migrate/references/component-mapping.md +1 -1
  61. package/skills/field-service-data-capture-migrate/references/fsm-dc-capability-catalog.md +1 -2
  62. package/skills/field-service-data-capture-migrate/references/known-deploy-errors.md +1 -0
  63. package/skills/field-service-data-capture-migrate/references/transformer-rules.md +1 -1
  64. package/skills/field-service-data-capture-migrate/scripts/transform_flow.py +12 -1
  65. package/skills/field-service-data-capture-migrate/scripts/vendor/build_flow.py +4 -1
  66. package/skills/field-service-setup-orchestrator-get/SKILL.md +0 -1
  67. package/skills/insurance-brokerage-agency-billing-configure/SKILL.md +233 -0
  68. package/skills/insurance-brokerage-agency-billing-configure/references/accounting-setup.md +117 -0
  69. package/skills/insurance-brokerage-agency-billing-configure/references/billing-rules-config.md +237 -0
  70. package/skills/insurance-brokerage-agency-billing-configure/references/billing-settings.md +271 -0
  71. package/skills/insurance-brokerage-agency-billing-configure/references/demo-policy-config.md +138 -0
  72. package/skills/insurance-brokerage-agency-billing-configure/references/org-defaults.md +64 -0
  73. package/skills/insurance-brokerage-agency-billing-configure/references/permissions-config.md +226 -0
  74. package/skills/insurance-brokerage-agency-billing-configure/references/prerequisites.md +142 -0
  75. package/skills/life-sciences-fieldsalesrep-coordinate/SKILL.md +3 -2
  76. package/skills/life-sciences-fieldsalesrep-coordinate/references/stage-5-visit-creation-execution-state-and-recovery.md +3 -3
  77. package/skills/life-sciences-fieldsalesrep-coordinate/references/stage-5-visit-creation-overview.md +68 -45
  78. package/skills/life-sciences-fieldsalesrep-coordinate/references/stage-5-visit-creation-visit-creation-data.md +17 -18
  79. package/skills/life-sciences-kam-coordinate/references/stage-5-data-and-plan-templates-overview.md +16 -3
  80. package/skills/life-sciences-kam-coordinate/references/stage-5-data-creation-data.md +16 -13
  81. package/skills/marketing-message-test/SKILL.md +194 -0
  82. package/skills/marketing-message-test/references/api-contract.md +333 -0
  83. package/skills/omnistudio-callable-apex-generate/SKILL.md +3 -3
  84. package/skills/omnistudio-datamapper-generate/SKILL.md +6 -6
  85. package/skills/omnistudio-datapacks-deploy/SKILL.md +11 -11
  86. package/skills/omnistudio-dependencies-analyze/SKILL.md +5 -5
  87. package/skills/omnistudio-epc-catalog-generate/SKILL.md +6 -6
  88. package/skills/omnistudio-flexcard-generate/SKILL.md +6 -6
  89. package/skills/omnistudio-integration-procedure-generate/SKILL.md +6 -6
  90. package/skills/omnistudio-omniscript-generate/SKILL.md +6 -5
  91. package/skills/platform-apex-logs-debug/SKILL.md +1 -0
  92. package/skills/platform-metadata-deploy/SKILL.md +1 -0
  93. package/skills/platform-models-api-configure/SKILL.md +5 -5
  94. package/skills/platform-soql-query/SKILL.md +1 -0
  95. package/skills/service-itsm-agentic-setup-cmdb-coordinate/SKILL.md +17 -6
  96. package/skills/service-itsm-agentic-setup-incident-sla-configure/SKILL.md +107 -192
  97. package/skills/service-itsm-agentic-setup-incident-sla-configure/assets/attach-milestone-action.json +6 -6
  98. package/skills/service-itsm-agentic-setup-incident-sla-configure/examples/milestone-patterns.md +49 -20
  99. package/skills/service-itsm-agentic-setup-incident-sla-configure/examples/output-templates.md +4 -4
  100. package/skills/service-itsm-agentic-setup-incident-sla-configure/references/mcp-invocation.md +224 -290
  101. package/skills/service-itsm-agentic-setup-incident-sla-configure/references/workflow.md +295 -0
  102. package/skills/service-itsm-incident-priority-configure/SKILL.md +1 -1
  103. package/skills/service-itsm-slack-itservice-configure/SKILL.md +2 -1
  104. package/skills/service-itsm-slack-itservice-configure/references/manage-slack-connection.md +2 -2
  105. package/skills/service-omni-channel-setup-coordinate/SKILL.md +20 -13
  106. package/skills/service-omni-channel-setup-coordinate/scripts/integration-driver.sh +5 -55
  107. package/skills/service-omni-channel-setup-coordinate/scripts/tests/test_omni_contracts.py +0 -38
  108. package/skills/service-omni-command-center-analyze/SKILL.md +2 -3
  109. package/skills/service-omni-command-center-analyze/scripts/analyze.sh +3 -3
  110. package/skills/tableau-next-asset-create/README.md +65 -0
  111. package/skills/tableau-next-asset-create/SKILL.md +409 -0
  112. package/skills/tableau-next-asset-create/references/admin-users.md +149 -0
  113. package/skills/tableau-next-asset-create/references/ai-readiness.md +355 -0
  114. package/skills/tableau-next-asset-create/references/alerts.md +111 -0
  115. package/skills/tableau-next-asset-create/references/build-workflow.md +819 -0
  116. package/skills/tableau-next-asset-create/references/dashboard-authoring.md +302 -0
  117. package/skills/tableau-next-asset-create/references/dashboard-design-principles.md +352 -0
  118. package/skills/tableau-next-asset-create/references/data-transform-gotchas.md +210 -0
  119. package/skills/tableau-next-asset-create/references/data-understanding.md +387 -0
  120. package/skills/tableau-next-asset-create/references/deep-reference-index.md +74 -0
  121. package/skills/tableau-next-asset-create/references/destructive-operations.md +62 -0
  122. package/skills/tableau-next-asset-create/references/edit-dashboard.md +273 -0
  123. package/skills/tableau-next-asset-create/references/edit-visualization.md +529 -0
  124. package/skills/tableau-next-asset-create/references/empty-source-handling.md +104 -0
  125. package/skills/tableau-next-asset-create/references/ingest-and-metric-gotchas.md +638 -0
  126. package/skills/tableau-next-asset-create/references/insight-bundle.md +69 -0
  127. package/skills/tableau-next-asset-create/references/large-flat-file-handling.md +331 -0
  128. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/_envelope.json +54 -0
  129. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/_shared-widget-fields.json +122 -0
  130. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/add_page.json +29 -0
  131. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/delete_page.json +27 -0
  132. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/discard_dashboard.json +11 -0
  133. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/move_widget.json +30 -0
  134. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/move_widget_to_page.json +30 -0
  135. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/place_widget_on_page.json +30 -0
  136. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/remove_widget_from_dashboard.json +16 -0
  137. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/remove_widget_from_page.json +26 -0
  138. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/rename_page.json +28 -0
  139. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/save_dashboard.json +18 -0
  140. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/undo.json +11 -0
  141. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/upsert_button_widget.json +69 -0
  142. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/upsert_container_widget.json +88 -0
  143. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/upsert_filter_widget.json +146 -0
  144. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/upsert_metric_widget.json +78 -0
  145. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/upsert_navigation_widget.json +80 -0
  146. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/upsert_parameter_widget.json +160 -0
  147. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/upsert_text_widget.json +103 -0
  148. package/skills/tableau-next-asset-create/references/schemas/edit-dashboard/upsert_visualization_widget.json +68 -0
  149. package/skills/tableau-next-asset-create/references/sdm-tool-reference.md +721 -0
  150. package/skills/tableau-next-asset-create/references/semantic-query-and-enrichment.md +355 -0
  151. package/skills/tableau-next-asset-create/references/shared-gates.md +322 -0
  152. package/skills/tableau-next-asset-create/references/sharing-and-promotion.md +306 -0
  153. package/skills/tableau-next-asset-create/references/tasks/ai-readiness-audit.md +51 -0
  154. package/skills/tableau-next-asset-create/references/tasks/analyze-data.md +48 -0
  155. package/skills/tableau-next-asset-create/references/tasks/build-dashboard.md +66 -0
  156. package/skills/tableau-next-asset-create/references/tasks/build-end-to-end.md +73 -0
  157. package/skills/tableau-next-asset-create/references/tasks/create-data-transform.md +51 -0
  158. package/skills/tableau-next-asset-create/references/tasks/create-viz.md +58 -0
  159. package/skills/tableau-next-asset-create/references/tasks/edit-dashboard.md +80 -0
  160. package/skills/tableau-next-asset-create/references/tasks/edit-sdm.md +106 -0
  161. package/skills/tableau-next-asset-create/references/tasks/edit-viz.md +40 -0
  162. package/skills/tableau-next-asset-create/references/tasks/enrich-model.md +68 -0
  163. package/skills/tableau-next-asset-create/references/tasks/ingest-flat-file.md +68 -0
  164. package/skills/tableau-next-asset-create/references/tasks/manage-alert.md +35 -0
  165. package/skills/tableau-next-asset-create/references/tasks/profile-dataset.md +47 -0
  166. package/skills/tableau-next-asset-create/references/tasks/promote-or-reuse.md +46 -0
  167. package/skills/tableau-next-asset-create/references/tasks/provision-user.md +39 -0
  168. package/skills/tableau-next-asset-create/references/tasks/query-model.md +92 -0
  169. package/skills/tableau-next-asset-create/references/tasks/review-verified-questions.md +42 -0
  170. package/skills/tableau-next-asset-create/references/tasks/share-asset.md +37 -0
  171. package/skills/tableau-next-asset-create/references/verified-questions.md +125 -0
  172. package/skills/tableau-next-asset-create/references/viz-authoring.md +992 -0
  173. package/skills/service-de-channel-consent-configure/SKILL.md +0 -230
  174. package/skills/service-itsm-agentic-setup-incident-sla-configure/assets/predefined-incident-policy.json +0 -102
@@ -0,0 +1,295 @@
1
+ # Incident SLA setup — full step-by-step workflow
2
+
3
+ Detailed companion to `SKILL.md`. The SKILL.md body carries the phase **overview**, the
4
+ **Rules / Constraints** table, and the **Verification Checklist**; this file carries the
5
+ per-phase step-by-step detail (every read, delegated write, and API quirk). All steps are
6
+ sequential. **Always read before you write.** Every call goes through `mcp__headless-360__*`
7
+ tools. Call shapes / templates / response envelope / gotchas live in `references/mcp-invocation.md`.
8
+
9
+ ## Phase 0 — Reuse what the session already knows
10
+
11
+ Each Phase 1 read carries a **skip-if-already-known** clause: skip only when the same fact was
12
+ produced **this session** by a successful `dispatch_readonly` on the current org and unwritten since —
13
+ a user statement is never cache-eligible. Cacheable: master Incident Mgmt pref (step 1, only if
14
+ `ENABLED`), SLA feature + Versioning (Phase 0.5), Incident describe (3, incl. the `Incident.Priority`
15
+ picklist), `BusinessHoursId` (4), SLA Connect ops (2). (Step 5 resolves no Account — Incident has
16
+ none.) **When in doubt, re-check.**
17
+
18
+ ## Phase 0.5 — SLA Management for IT Service prerequisite gate
19
+
20
+ **Resolve this gate first, on its own. Reads are safe up front; confirm the org before any write.**
21
+ "SLA Management for IT Service" is enabled only when **both** Simplified SLA Setup **and** SLA
22
+ Versioning are on; either off → not enabled. These are **two separate writes** — enabling SLA
23
+ Management (which flips its composite prefs atomically, and requires Entitlements already on) does
24
+ **not** turn on Versioning; Versioning is a distinct, **permanent, one-way** write. Both the reads and
25
+ the writes are **delegated to `itsm-shakti/SLASettings`** (owns the SLA-Management
26
+ settings surface) — discover → describe → dispatch rather than re-deriving the routes here.
27
+ Shapes / preconditions / `enableBlockedReasons` / ack wording: `references/mcp-invocation.md`.
28
+
29
+ - **Read both** (`dispatch_readonly`); proceed to Phase 0.6 **only when both are on**.
30
+ - **On an OFF org, read the master license first** (Phase 1 step 1, `service-cloud-itsm-incident`):
31
+ `NOT_AVAILABLE` → **HALT** — don't flip the permanent Versioning switch where Incident SLA can't run.
32
+ - **Two separate `AskUserQuestion` acks — never merge.** (a) master Incident Mgmt `NOT_ENABLED` → ask
33
+ to enable it first (reversible, no permanence warning). (b) a *distinct* permanence ack: completing
34
+ the gate also turns on **SLA Versioning** (a **separate** write), which **can't be turned off** (SLA
35
+ Management disables later but Versioning stays on). Offer **enable**/**stop** — no "versioning-off";
36
+ a bare "enable SLA" is **not** consent.
37
+ - **Decline (b), non-empty `enableBlockedReasons`, or a re-read mismatch → HALT** — enable no SLA
38
+ Mgmt/Versioning, don't proceed to Phase 0.6/1 (a reversible master enable from (a) stands). **After
39
+ any write, re-read both and report the REAL state** — never trust `201`/`204`.
40
+
41
+ ## Phase 0.6 — Predefined (OOB) vs Custom
42
+
43
+ Once the gate passes, offer the OOB policy **before** any custom-flow questions. **Incident only.**
44
+
45
+ 1. **Prerequisite + detect.** Confirm master Incident Mgmt pref `ENABLED` (Phase 1 step 1). Then
46
+ `dispatch_readonly` `GET /headless/invoke/platform/slasettings` (get-existing-checkbox-states) —
47
+ its lowercase-keyed map's `incident` value is the authoritative "is the OOB default seeded?"
48
+ answer (this is the seeder's own dedup read; it maps to display name **"Standard Support for
49
+ Incidents"**).
50
+ - **`incident: true`** → **no re-seed** (no idempotency), no custom upsell; report it is seeded.
51
+ **If warn/escalate actions were requested → resolve the named existing milestones → Phase 2.5 →
52
+ Phase 3 verify → STOP** (attach actions even though the policy was already seeded).
53
+ 2. **Fork.** **First — before presenting the fork prompt** — read the live `Incident.Priority`
54
+ picklist. This is the **Phase 1 step 3 `Incident/describe`** pulled forward (its
55
+ `fields[].picklistValues`), cached per Phase 0 — so the Custom branch's Phase 1 step 3 is then a
56
+ no-op, not a second describe (**Custom-Priority coverage note; informational — NOT an OOB option**). If it carries
57
+ **custom active values beyond the four standard tiers** (Critical / High / Moderate / Low) — e.g.
58
+ an org-added `Emergency` — the fork prompt must **say plainly that the predefined policy covers
59
+ only the standard tiers**, so those custom values get **no First Response milestone under OOB**.
60
+ Do **not** *proactively* offer to bolt a milestone for them onto the predefined policy, and **never
61
+ re-seed** (the seeder builds one fixed bundle server-side and isn't idempotent — re-running
62
+ duplicates). Point the user to the **Custom** path by default, which reconciles every value against
63
+ the live picklist **and adds a milestone for each custom active Priority value** (Phase 1.4 / Phase 2
64
+ step 10). **But if the user *explicitly* asks to add a milestone for a custom tier onto the seeded
65
+ policy, honor it** — resolve the seeded *Standard Support for Incidents* policy by name (SOQL) and
66
+ delegate a **direct `csp-sun/create-milestone`** against that policy id (the same milestone-attach op
67
+ the Custom flow uses at Phase 2 step 10 — a direct attach, **not** a re-seed of the bundle). The
68
+ default decision stays a clean Predefined-vs-Custom fork; the explicit attach is opt-in only. **Then** ask one `AskUserQuestion`, **Predefined first / recommended**:
69
+ Salesforce's predefined Incident policy (*Standard Support for Incidents* — priority-tiered) **or**
70
+ a custom one. One-way: predefined seeds an **active** policy + Entitlement, no un-seed path (manual
71
+ delete only).
72
+ - **Predefined →** **do not resolve or ask for an Account.** The seeder wires the policy's
73
+ Entitlement and BusinessHours **server-side itself**, so Phase 1 steps 4 (default BusinessHours)
74
+ and 5 (Account) are Custom-flow inputs and are **not** run here — asking for an Account on this
75
+ branch is an over-ask. The Phase 3 test Incident sets the seeded Entitlement's `EntitlementId`
76
+ **directly** (no Account needed). → **Phase 2-OOB** → **Phase 2.5** (if actions requested) →
77
+ Phase 3 verify → **STOP**.
78
+ - **Custom →** existing Phase 1 → 1.4 → 1.5 → 2 → 3, unchanged.
79
+
80
+ ## Phase 1 — Preflight & discovery
81
+
82
+ **On any `401` / `403` / `404` from a step below, halt and surface the raw error** — the org/client is misconfigured. `401` → MCP auth (ECA/token). `403` → user perm OR ITSM Incident Management license/pref missing. `404` → `headless-360` not activated OR Entitlement Management not enabled for Incident.
83
+
84
+ 1. **Master Incident Management pref — direct read** *(skip conditions in Phase 0)*.
85
+ `dispatch_readonly` `GET .../connect/setup/discovery/features`, filter `features[]` to the **exact**
86
+ `apiName == "service-cloud-itsm-incident"` — never a look-alike (`service-cloud-incident-management`
87
+ is generic Case-based Incident Management, not our target). Read `status`: `ENABLED` → proceed;
88
+ `NOT_AVAILABLE` (license missing) → **halt and surface it** — cannot be enabled here, no delegate/ack;
89
+ `NOT_ENABLED` → **explicit `AskUserQuestion` ack first (never auto-enable as an implied SLA
90
+ dependency)**, then delegate to `service-itsm-incident-mgmt-configure` inline (confirms-to-write) and
91
+ re-read; if declined, halt — every SLA artifact below depends on the master being on. Full shape + why
92
+ setup-org-preferences 404s here: `references/mcp-invocation.md` (Preflight A).
93
+ 2. **Discover the Connect operations** — *(skip if already verified this session — see Phase 0)*.
94
+ `mcp__headless-360__discover(query="sla-management milestone")` to confirm the SLA Management
95
+ Connect API is indexed, then `mcp__headless-360__describe(id=<operation_id>)`
96
+ for the `milestone-types`, `sla-policies`, and `sla-policies/{id}/milestones` POST operations to pull
97
+ their exact input schemas + HTTP routes. If `discover` returns nothing after rewording the query,
98
+ the corpus does not index this surface for the org — direct the user to **Setup → SLA/Entitlement
99
+ setup** and stop.
100
+ 3. **Verify Incident Management + SLA fields** — *(skip if `Incident.describe` result for the
101
+ current org is already in context — see Phase 0)*. Otherwise `dispatch_readonly` on
102
+ `GET /services/data/v{version}/sobjects/Incident/describe` and confirm `fields[]` includes
103
+ `EntitlementId`, `SlaStartDate`, `SlaExitDate`. If the describe 404s or fields are missing, direct
104
+ the user to enable Entitlement Management for Incident and stop. **This same describe also yields
105
+ the live `Incident.Priority` picklist** (`fields[].picklistValues`) consumed by the Phase 0.6 fork
106
+ note and the Phase 1.4 / Phase 2 step 10 reconciliation — so on the Custom branch it is already in
107
+ context from Phase 0.6 step 2 (Phase 0 skip).
108
+ 4. **Find default BusinessHours** — *(skip if `BusinessHoursId` for the current org's default is
109
+ already captured this session)*. Otherwise `dispatch_readonly` on `GET /services/data/v{version}/query` with
110
+ `query_params.q="SELECT Id, Name FROM BusinessHours WHERE IsActive = true AND IsDefault = true"`.
111
+ If `body.records` is empty, stop with a message to create default Business Hours in Setup. Capture
112
+ `BusinessHoursId`.
113
+ 5. **Account — NOT required for Incident; do not resolve or ask for one.** Unlike Case, `Incident`
114
+ has no customer-`Account` field, and the Custom flow's Entitlement auto-provisions on activation
115
+ (`createEntitlement=true`, step 11) **without** an `AccountId` — no write in this flow consumes an
116
+ Account (engagement is per-Incident via `EntitlementId`; see step 12). So **skip this step** — asking
117
+ for an Account here is an over-ask that also seeds the false "Account-scoped auto-apply" premise.
118
+ (Only revisit if a specific leaf's `describe` proves it hard-requires an `AccountId`; it does not
119
+ today.) If the user *volunteers* an Account name, acknowledge it but do not treat it as required.
120
+ 6. **Read existing SLA artifacts (idempotency probe)** — `dispatch_readonly` SOQL for `SlaProcess` by
121
+ name (`... WHERE Name = '<name>' AND SobjectType = 'Incident'` — the field is `SobjectType`;
122
+ `ProcessType` returns `INVALID_FIELD`), each `MilestoneType` the strategy would create,
123
+ `SlaMilestone` under the matched policy, and `Entitlement` by name (no Account filter — Incident has none). If
124
+ **every** artifact already exists with the requested config, set `noOp=true` and skip Phase 1.4 +
125
+ Phase 2 (skip condition (b)); any missing/divergent artifact → proceed to Phase 1.4.
126
+
127
+ **Coexistence with an existing active Incident policy (Custom flow).** When the Phase 0.6 / Phase 1
128
+ reads surface a *different* active Incident SLA policy already present (e.g. a predefined *Standard
129
+ Support for Incidents* detected at Phase 0.6 step 1) **and the user has explicitly asked for Custom**
130
+ (this is the deliberate-Custom case while that policy stays seeded — not the upsell path Phase 0.6
131
+ forbids): **do NOT offer to deactivate, replace, or un-scope the existing policy** — changing a policy
132
+ the user didn't ask to touch is out of this skill's scope and risks disrupting a live SLA (deactivation
133
+ is technically reachable via `activate-sla-policy` `isActive=false`, but that is not this flow's job),
134
+ and predefined has **no un-seed path (manual delete only)**. The
135
+ two are meant to coexist — creating the custom policy never removes or hides the existing one: both
136
+ remain in **Setup → SLA/Entitlement setup** and both stay usable. The custom policy coexists cleanly
137
+ **because it engages per-Incident via `EntitlementId`** (step 12), not by any Account-scoped auto-apply
138
+ (Incident has no Account field to scope on) — narrate that, don't fork on it: "your existing *<name>*
139
+ policy stays active; this custom policy is applied per-Incident by setting the Incident's Entitlement
140
+ to it." State the one genuinely singular point without inventing a fix: an Incident engages exactly
141
+ **one** Entitlement (its `EntitlementId`); to put the custom policy on a specific Incident, set that
142
+ Incident's `EntitlementId` to the custom Entitlement (the mechanism Phase 3 already uses) — **never**
143
+ reorder or disable the other policy's criteria. Keep this a Phase 1.5 plan-narration, **not** a
144
+ Replace-vs-Keep-both prompt. **The closing report follows the same rule:** the existing/predefined
145
+ policy stays the broad org-wide one and the custom is targeted per-Incident — do **not** end the report
146
+ by offering to broaden the custom policy to auto-apply to **all** Incidents or to "decide/resolve
147
+ precedence" against the existing policies (there is no leaf that arbitrates cross-policy precedence);
148
+ point to `EntitlementId` for targeting a specific Incident instead.
149
+
150
+ ## Phase 1.4 — Milestone Strategy
151
+
152
+ Every SLA policy needs at least one milestone. Load `examples/milestone-patterns.md` — it lists the
153
+ skip conditions (concrete shape in prompt / idempotent no-op / explicit up-front authorization) and
154
+ the five strategy options with their `AskUserQuestion` prompt, defaults, and MilestoneType-reuse
155
+ rules. Skip condition (c) still requires Phase 1.5 plan-narration before dispatch. Multi-milestone
156
+ selection expands to N creates in Phase 2 step 10 (one delegation per milestone, `order` 1..N, same SlaProcess).
157
+
158
+ ## Phase 1.5 — Confirm before mutating
159
+
160
+ 7. **Confirm the plan** — present the resolved config (target **org**, **SLA Policy** name, the
161
+ **engagement model** (per-Incident via `EntitlementId` — **no Account**, since Incident has no
162
+ Account field), and the **full per-milestone list** — never collapse Priority-tiered / Custom to
163
+ "N milestones"). **Skip the `AskUserQuestion`** (but still narrate the
164
+ plan before dispatch) when up-front authorization was granted (note `(authorized in prompt)`), the
165
+ branch is a no-op, or it was already confirmed in conversation (note `(confirmed in conversation)`);
166
+ otherwise require an explicit "yes" before Phase 2. Everything after this step mutates the org.
167
+
168
+ ## Phase 2 — Create SLA Artifacts (delegated writes — exact order, each depends on the previous)
169
+
170
+ **The skill decides every input below; the raw writes are delegated to the approved csp-sun SLA leaf
171
+ capabilities** (discover → describe → dispatch each) — they own the approved Connect contracts, so do
172
+ not re-derive request shapes here. Capture each returned `id` for chaining only (never surface it —
173
+ Output contract).
174
+
175
+ 8. **MilestoneType(s) → delegate to `csp-sun/MilestoneTypes`.** Decide the set + reuse rule **here**:
176
+ reuse a single MilestoneType across milestones that share a name (Priority-tiered "Incident First
177
+ Response" is reused across **all** its milestones, including any custom active Priority value);
178
+ create separate MilestoneTypes for distinct concerns (Response + Resolution = two; Escalation
179
+ ladder = three); skip a name the Phase 1 probe already found. Delegate the raw create per required
180
+ type; a detected/reused one is narrated by name only (Output contract: name, never `→ <Id>`).
181
+ 9. **SLA Policy → delegate to `csp-sun/create-sla-policy`.** Pass `processType='Incident'`, the
182
+ default `businessHourId` from Phase 1, and the entry/exit criteria confirmed in Phase 1.5. Created
183
+ **inactive** — activation is the explicit step 11 so the auto-entitlement is provisioned. **The
184
+ create response echoes nulls — verify via SOQL, not the body; narrate the policy by name, never
185
+ the Id** (Output contract).
186
+ 10. **Milestone(s) → delegate to `csp-sun/create-milestone`, one delegation per milestone** in
187
+ ascending time-trigger order (`order` 1..N, same policy). Build each `milestoneCriteria` **here**
188
+ from `assets/attach-milestone.json` + the per-pattern `filterItems` in
189
+ `examples/milestone-patterns.md`. **This is where the Priority reconciliation lands:** match every
190
+ criteria value against the **live** `Incident.Priority` picklist, drop/rename unmatched standard
191
+ rows, **and add a milestone for each custom active Priority value** the org added — no active value
192
+ left without an SLA. The leaf owns the UPPERCASE `milestoneState=ACTIVE`, `filterType=RuleFilter`,
193
+ no-`slaProcessId`-in-body, and confirm-from-body (this endpoint returns `201` even on a failed
194
+ save) contract. On any failure, halt (no half-attached policy) — narrate each by `MilestoneType`
195
+ name, never its Id/`triggerId` (Output contract).
196
+ 11. **Activate + auto-provision Entitlement → delegate to `csp-sun/activate-sla-policy`.** Activate
197
+ the policy and provision its Entitlement in one call — `isActive` and `createEntitlement` are
198
+ **QUERY params, not a body** (always send `createEntitlement` explicitly). This is the **custom
199
+ flow only** — it replaces the old `active:true`-on-create + manual `POST /sobjects/Entitlement`.
200
+ The **OOB seed path does not run this step at all**: its single `save-selected-options` call seeds
201
+ an already-active policy and auto-provisions the Entitlement itself (see Phase 2-OOB). The leaf carries the
202
+ no-500 activation contract: a `200` with a returned `entitlementId` is the success shape. Capture the
203
+ returned `entitlementId`. **Verify by reading the policy back (`active=true`)**, never the write response.
204
+ 12. **Engagement targeting (Incident has NO Account-scoped auto-apply).** Unlike Case, **`Incident`
205
+ has no customer-`Account` field** (its only Account-ish field is the polymorphic `ReportedById`),
206
+ so an Entitlement's auto-apply criteria **cannot be Account-scoped for Incident** — do not attempt
207
+ it, and **do not ask for or bind an Account for auto-apply scope** (that was an over-ask that also
208
+ caused a mid-flow contradiction). **Default: per-Incident targeting** — the custom policy engages by
209
+ setting an Incident's `EntitlementId` to this policy's Entitlement (the same mechanism Phase 3
210
+ uses); create **no auto-apply criterion**, and say so in the plan/report ("engages per-Incident via
211
+ `EntitlementId`; no auto-apply criterion — Incident has no Account field to scope on"). Only if the
212
+ user **explicitly** wants an org-wide always-match criterion do you delegate to
213
+ `csp-sun/create-entitlement-criteria` (`entitlementId` from step 11; leaf owns the uppercase
214
+ `AND|OR|CUSTOM` `criteriaType` contract — mixed-case / `RuleFilter` / `Formula` silently fail to
215
+ open on the Setup edit page; verify by "read every rule in the org, match by `entitlementId`") —
216
+ and first surface that an always-match criterion **collides** with any existing broad Incident
217
+ policy (Coexistence rule). Narrate by name, never the Id.
218
+
219
+ ## Phase 2-OOB — Seed the Predefined Incident Policy
220
+
221
+ Reached only from Phase 0.6 Predefined (replaces Phase 1.4/1.5/2). The predefined **"Standard
222
+ Support for Incidents"** bundle is seeded by **one** call to the platform's own default-policy
223
+ seeder — the same action the SLA Settings Setup page runs — served headless on the Aura dispatcher
224
+ route. Core's seeder builds the entire active bundle itself (policy + MilestoneTypes + milestones +
225
+ Entitlement + entitlement criteria), so the skill neither hand-lists the milestones nor provisions
226
+ the Entitlement. This replaces the former hand-rebuilt seed (a raw `active:true` `POST .../sla-policies`
227
+ + 6 `create-milestone` calls + a manual `POST /sobjects/Entitlement`) — that whole replica is retired.
228
+ The detect + seed are **delegated to `itsm-shakti/SLASettings`** (contract owner of the seeder route).
229
+
230
+ Follow the seed recipe in `references/mcp-invocation.md` (**Predefined Incident Policy**):
231
+
232
+ 1. **Detect (dedup).** `dispatch_readonly` `GET /headless/invoke/platform/slasettings`
233
+ (get-existing-checkbox-states) — its lowercase-keyed map's `incident` value is the authoritative
234
+ "is the OOB default already seeded?" answer. **`incident: true`** → **no re-seed** (the seeder is
235
+ NOT idempotent — re-running duplicates), no custom upsell; report it seeded and skip to Phase 2.5/3.
236
+ 2. **Seed.** `dispatch` `PATCH /headless/invoke/platform/slasettings/save-selected-options` with body
237
+ `{"selectedOptions": ["incident"]}` — **the value MUST be lowercase `incident`**; the capitalized
238
+ `Incident` returns a server-side `500`. A `200` with body `true` is success. This provisions the
239
+ full **active** bundle + auto-entitlement in one shot — no manual Entitlement, and no Connect
240
+ activate PATCH, so the 500 that path could throw never arises.
241
+ 3. **Verify.** Re-read `GET /headless/invoke/platform/slasettings` and confirm `incident: true`, then
242
+ SOQL `SlaProcess` for **"Standard Support for Incidents"** `IsActive = true` (do not trust the write
243
+ body). Narrate the policy by name, never its Id.
244
+
245
+ Then Phase 2.5 (if actions requested), Phase 3 (a non-lowest tier — Moderate/Low, not Critical),
246
+ and **STOP** — no *proactive* custom offer. Any custom-Priority coverage gap was surfaced at the
247
+ Phase 0.6 fork (as an informational note + redirect to the Custom path), **not** by proactively
248
+ augmenting the seeded OOB policy here. **The one exception is an *explicit* user request** to attach a
249
+ milestone (or a warn/escalate action) to the seeded policy — honor it via a **direct
250
+ `csp-sun/create-milestone`** (resolve the *Standard Support for Incidents* policy by name; a direct
251
+ attach, **never** a re-seed), then verify and STOP.
252
+
253
+ ## Phase 2.5 — Milestone Actions (optional: Warn / Escalate)
254
+
255
+ After milestones exist (Phase 2 or 2-OOB), **only if** the user asked to warn/escalate/notify: apply
256
+ the requested checkpoint(s) to **every milestone the user named** (not just one), each offset computed
257
+ from that milestone's own target. Map "warn at X%" → an offset *before* target, "on breach" →
258
+ *at/after* it; **confirm the full set before writing** (up-front auth waives the re-ask; narrate it
259
+ regardless — no headless delete), then, per milestone, delegate to headless
260
+ **`create-milestone-action`** (`discover` → `describe` → `dispatch`). **Confirm each from the response
261
+ body** (`success` + non-empty `actionMappings`; a *timed* checkpoint also returns a `triggerId`), never
262
+ the `201`. Narrate each by its **`MilestoneType` name**, never the milestone Id/`triggerId` (Output
263
+ contract). **Id-leak guard — the #1 retest failure lands here:** you hold the policy Id and each
264
+ milestone Id internally (you need them to target each action write), but the **pre-write plan table
265
+ AND the closing report MUST key every row by the milestone's tier / Priority / MilestoneType name**
266
+ (e.g. row header `Emergency`, `Critical`), **never** its Id. Do **not** write `Emergency
267
+ (553VW000000…)`, a `Policy … (552VW000009…)` header, or any `55…`/`553…` Id in a table cell, a
268
+ parenthetical, or the report — those Ids are chaining-only. Formula, roles, example body, defaults,
269
+ IST business-hours note: `references/mcp-invocation.md` (Milestone Actions).
270
+
271
+ ## Phase 3 — Verify
272
+
273
+ 13. **Verify the SLA Policy** — SOQL on `SlaProcess` (do not trust the create response); confirm it
274
+ read back `active=true` — from the activation delegation (Custom flow) or from the seeder (OOB).
275
+ 14. **Create a test Incident** to prove engagement — **both flows: set the policy's `EntitlementId`
276
+ directly on the test Incident** (`Incident` has no Account field, so there is no Account-scoped
277
+ auto-apply to rely on; `EntitlementId`-direct is the reliable engagement path — Custom uses the
278
+ Entitlement returned by activation, OOB the seeded Entitlement). For Priority-tiered / OOB
279
+ strategies, test a tier **other than the lowest `order`** — Critical is order-1, the collapse
280
+ fallback, so it can't detect a dropped criterion. If a direct `Priority` insert is rejected (it
281
+ may be matrix-derived), set `Urgency`/`Impact` to derive the tier. Narrate by `IncidentNumber`,
282
+ never the Id.
283
+ 15. **Verify engagement + tiering** — SOQL that an `EntityMilestone` landed on the **correct tier**
284
+ (a Moderate/Low Incident → the 240/960 tier, NOT 30/120) with a `TargetDate` — that row is the
285
+ reliable engagement proof. `Incident.SlaStartDate` is populated when you set `EntitlementId` at
286
+ insert, but can be **null** when the Entitlement is auto-applied via criteria (the milestone still
287
+ lands); treat a null `SlaStartDate` as a non-blocker, not a failure. The create `201` always
288
+ echoes `milestoneCriteria:[]`; only this runtime read proves the ACTIVE criteria persisted.
289
+ 16. **Report results** using the output format in `examples/output-templates.md`.
290
+
291
+ ---
292
+
293
+ The **Rules / Constraints** table and the **Verification Checklist** live in `SKILL.md`
294
+ (body) — read them there before executing; they are the non-negotiable gates this step-by-step
295
+ detail implements.
@@ -2,9 +2,9 @@
2
2
  name: service-itsm-incident-priority-configure
3
3
  description: "Configures the Incident Priority Matrix for Salesforce ITSM through the sf CLI — enabling or disabling the matrix, shaping the Impact x Urgency grid that derives Priority on Incident records, toggling the manual-override preference, and reading or setting the default fallback priority. Reads every value before writing, is idempotent, and requires explicit user confirmation before any mutation. Use when the user wants to view, enable, disable, set up, seed, add to, change, or remove priority matrix configuration for Incident records, change the default incident priority, or asks about incident priority setup, impact/urgency mapping, override, or the ITSM incident priority matrix. DO NOT TRIGGER for Problem or ChangeRequest priority matrices, Case priority fields, standard Priority picklists outside ITSM, SLA or milestone configuration, or enabling Incident Management itself (use the service-itsm-incident-mgmt-configure skill)."
4
4
  metadata:
5
- version: "1.4"
6
5
  relatedSkills:
7
6
  - "service-itsm-incident-mgmt-configure"
7
+ version: "1.4"
8
8
  domains: ["Service"]
9
9
  minApiVersion: "67.0"
10
10
  cliTools:
@@ -4,7 +4,8 @@ description: "Configure the \"Set Up Self Service for Employees on Slack\" / \"S
4
4
  metadata:
5
5
  version: "1.0"
6
6
  minApiVersion: "67.0"
7
- domains: ["Service"]
7
+ domains:
8
+ - "Service"
8
9
  relatedSkills:
9
10
  - "experience-portal-create"
10
11
  - "service-itsm-agentic-setup-employee-agent-configure"
@@ -19,8 +19,8 @@ Returns the live state (verified `200`):
19
19
  {
20
20
  "team": {
21
21
  "status": "CONNECTED",
22
- "teamName": "Slackfarm 1473",
23
- "teamDomain": "https://slackfarm-1473.enterprise.slack.com",
22
+ "teamName": "Acme Workspace",
23
+ "teamDomain": "https://acme.enterprise.slack.com",
24
24
  "teamId": "E0…"
25
25
  },
26
26
  "currentUserMapping": { "salesforceUserId": "005…", "slackUserId": "U0…" }
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: service-omni-channel-setup-coordinate
3
- description: "Use to stand up Omni-Channel headlessly: base settings, users, service channels, routing configs, queues and members, presence statuses, permissions, supervisor configuration, and Case or VoiceCall routing flows. Reuses existing records and creates missing ones. Optional stages cover Command Center V2 on supported releases, agent experience, and skills-based routing. TRIGGER when: set up Omni-Channel, configure Omni routing, provision Omni agents, provision Omni supervisors, or configure Case, Incident, MessagingSession, or VoiceCall routing. Do not use for Agentforce bots, one existing field change, or bare metadata deployment."
3
+ description: "Use to stand up Omni-Channel setup headlessly on Salesforce: base settings, agent users, service channels, routing configs, queues (create and align) and members, presence statuses, permission assignments, the classic Omni Supervisor config plus its action/tab surface, and — for Case and VoiceCall — the record-triggered routing flow. Supports Case, Incident, MessagingSession, and VoiceCall targets; reuses existing records and creates what is missing. Opt-in extras: presence user config, Omni sidebar, skills-based routing, and field-based WorkSkillRouting; also reports (read-only) whether the org is on the classic supervisor surface or Command Center V2. Triggers: set up Omni-Channel, configure Omni routing, provision Omni agents or supervisors, configure Case/Incident/Messaging/Voice routing. Do not use for Agentforce agents or bots, a single existing Omni field change, bare metadata deployment (use platform-metadata-deploy), or to enable Command Center V2 (not writable via the Metadata API)."
4
4
  allowed-tools: Bash Read Write Edit Glob Grep AskUserQuestion TodoWrite
5
5
  metadata:
6
6
  version: "1.0"
@@ -11,9 +11,7 @@ metadata:
11
11
  - "service-agentforce-human-escalation-configure"
12
12
  - "service-omni-agent-users-create"
13
13
  - "service-omni-base-settings-configure"
14
- - "service-omni-channel-inventory-analyze"
15
14
  - "service-omni-command-center-analyze"
16
- - "service-omni-command-center-configure"
17
15
  - "service-omni-permission-set-assign"
18
16
  - "service-omni-presence-status-deploy"
19
17
  - "service-omni-presence-user-config-deploy"
@@ -81,22 +79,20 @@ bash scripts/integration-driver.sh --run <org-alias> [agent_count] [routing_tar
81
79
  - `Incident` targets require the Incident Management feature enabled; `MessagingSession` requires Enhanced Messaging; `VoiceCall` requires Service Cloud Voice. The readiness check hard-fails with a click-path when a requested target sObject is absent.
82
80
  - **Production guardrail:** `safe_to_write` is `true` iff any of `IsSandbox = true`, `TrialExpirationDate != null`, or `OrganizationType IN ('Developer Edition', 'Base Edition')`. The run hard-refuses when it is false. CDOs return `IsSandbox=false` with a non-null `TrialExpirationDate` and must be permitted, so `IsSandbox` alone is never the guard.
83
81
 
84
- Readiness check (mandatory, before any write leaf runs):
82
+ Readiness check (silent, mandatory, before any leaf runs):
85
83
 
86
84
  1. `sf org display` → confirm the org alias is authenticated; refuse (exit 1) if not.
87
85
  2. `Organization` (`IsSandbox`, `TrialExpirationDate`, `OrganizationType`) → compute `safe_to_write`; refuse (exit 1) if false.
88
- 3. `service-omni-channel-inventory-analyze` → capture the complete channel/routing baseline through the approved read-only aggregate operation; a blocked inventory prevents writes because the coordinator cannot safely establish the starting state.
89
- 4. Preflight entity availability → for each **non-`Case`** routing target, confirm the sObject exists via `EntityDefinition`; a missing target hard-fails with a feature-enablement click-path (exit 2). `Case` is assumed present and skipped.
86
+ 3. Preflight entity availability → for each **non-`Case`** routing target, confirm the sObject exists via `EntityDefinition`; a missing target hard-fails with a feature-enablement click-path (exit 2). `Case` is assumed present and skipped.
90
87
 
91
88
  Omni-Channel base-settings enablement is not a separate upfront probe — it is detected by the base-settings leaf (step 1), and downstream Omni-dependent leaves are deferred as pending in `--plan` until it is on. The driver does not pre-check `UserLicense` headroom or `ServicePresenceStatus`/`QueueRoutingConfig` availability in this readiness pass.
92
89
 
93
90
  ## Skills this coordinates
94
91
 
95
- The coordinator delegates every write to a leaf skill. sObject-specific leaves (3, 5, 6, 6c, 7) loop once per routing target; the rest run once. For SkillsBased routing, steps 6a and 6b complete before any trigger flow is activated. Step 10a (`command-center-configure`) is opt-in through `OMNI_COMMAND_CENTER_V2=1`; step 10b (`command-center-analyze`) is a read-only advisory and always runs. Step 11a (`supervisor-surface-deploy`) always runs after the supervisor config succeeds. Leaves 12–13 are the opt-in rep-experience stages (`OMNI_REP_EXPERIENCE=1`).
92
+ The coordinator delegates every write to a leaf skill. sObject-specific leaves (3, 5, 6, 6c, 7) loop once per routing target; the rest run once. For SkillsBased routing, steps 6a and 6b complete before any trigger flow is activated. Step 10a (`command-center-analyze`) is a read-only advisory and always runs. Step 11a (`supervisor-surface-deploy`) always runs after the supervisor config succeeds. Leaves 12–13 are the opt-in rep-experience stages (`OMNI_REP_EXPERIENCE=1`).
96
93
 
97
94
  | # | Child skill | Role |
98
95
  |---|---|---|
99
- | 0 | `service-omni-channel-inventory-analyze` | Capture the read-only cross-channel and routing baseline before any writes |
100
96
  | 1 | `service-omni-base-settings-configure` | Deploy `Settings:OmniChannel` (5 toggles) |
101
97
  | 2 | `service-omni-agent-users-create` | Provision the requested agent users |
102
98
  | 3 | `service-omni-service-channel-configure` | Reuse the standard `ServiceChannel` for the target sObject, or deploy the canonical XML |
@@ -110,8 +106,7 @@ The coordinator delegates every write to a leaf skill. sObject-specific leaves (
110
106
  | 8 | `service-omni-permission-set-assign` | Assign the `Omni_Agent` PermissionSet to agent users; self-heals the bundled metadata when absent (run mode only) |
111
107
  | 9 | `service-omni-supervisor-users-create` | Provision supervisor users |
112
108
  | 10 | `service-omni-supervisor-permset-assign` | Assign the standard `ContactCenterSupervisor` PermissionSet to supervisor users |
113
- | 10a | `service-omni-command-center-configure` | *(opt-in)* Enable Command Center V2 through preserved `OmniChannel.settings` and verify its seeded page and tab |
114
- | 10b | `service-omni-command-center-analyze` | **Read-only advisory** — report whether the org is on the classic supervisor surface or Command Center V2; never writes, never hard-blocks |
109
+ | 10a | `service-omni-command-center-analyze` | **Read-only advisory** — report whether the org is on the classic supervisor surface or Command Center V2; never writes, never hard-blocks |
115
110
  | 11 | `service-omni-supervisor-config-deploy` | Deploy `OmniSupervisorConfig` binding supervisor users to the queues discovered in step 5 |
116
111
  | 11a | `service-omni-supervisor-surface-deploy` | Populate the supervisor **action + tab surface** (`OmniSupervisorConfigAction` / `OmniSupervisorConfigTab`) on the config from step 11 |
117
112
  | 12 | `service-omni-presence-user-config-deploy` | *(opt-in)* Deploy `PresenceUserConfig` + `PresenceDeclineReason` (decline + ACW) and assign the provisioned agents |
@@ -124,7 +119,7 @@ The coordinator delegates every write to a leaf skill. sObject-specific leaves (
124
119
 
125
120
  **Ordering and gating.** Leaves run in dependency order. Base settings are a hard prerequisite for every write below. For SkillsBased routing, agent `SkillUser` bindings (6a) and the `WorkSkillRouting` rule (6b) must succeed before the routing-flow leaf (6c) can activate the trigger. The flow also requires the queue (5) and its members (6), and it round-trips `FlowDefinitionView.ActiveVersionId` to prove the flow is Active. A required runtime proof does not pass merely because a PSR exists: SkillsBased requires at least one `SkillRequirement` on that PSR.
126
121
 
127
- **Supervisor path.** Supervisor users (9) use the same Anonymous Apex `System.setPassword` model as agent users. Because a password literal can be captured in an `ApexLog` when a debug TraceFlag is active, both user-create leaves fail closed *before* the first `System.setPassword`: they prove via a SOQL-filtered Tooling API query (`ExpirationDate > now`) that no active TraceFlag exists for the running user, and if that cannot be positively proven they set no password at all (users left ACTIVE and `reset_required`, with a `security_warning`). They never delete logs, so unrelated audit logs are untouched. The supervisor permset leaf (10) assigns the standard `ContactCenterSupervisor` — never the custom `Omni_Supervisor`, whose license-gated permissions fail assignment — and a contract test asserts this wiring. With `OMNI_COMMAND_CENTER_V2=1`, the coordinator enables and verifies the V2 org preference through `service-omni-command-center-configure`; optional `OMNI_COMMAND_CENTER_*` booleans select its subordinate controls. A read-only Command Center analysis then reports the resulting supervisor surface and never hard-blocks (ambiguous detection is yellow, a clean read green). Once the classic config lands (11), the surface leaf (11a) inserts the standard action + tab companions (`OmniSupervisorConfigAction` / `OmniSupervisorConfigTab`) against the config's Id — plain Data API rows, so no metadata-file redeploy — and is idempotent (only missing types are inserted). It runs only after the config succeeds; a skipped or failed config skips the surface with a dependency note.
122
+ **Supervisor path.** Supervisor users (9) use the same Anonymous Apex `System.setPassword` model as agent users. Because a password literal can be captured in an `ApexLog` when a debug TraceFlag is active, both user-create leaves fail closed *before* the first `System.setPassword`: they prove via a SOQL-filtered Tooling API query (`ExpirationDate > now`) that no active TraceFlag exists for the running user, and if that cannot be positively proven they set no password at all (users left ACTIVE and `reset_required`, with a `security_warning`). They never delete logs, so unrelated audit logs are untouched. The supervisor permset leaf (10) assigns the standard `ContactCenterSupervisor` — never the custom `Omni_Supervisor`, whose license-gated permissions fail assignment — and a contract test asserts this wiring. After the supervisor permset, a read-only Command Center analysis (10a) reports the org's supervisor surface (classic vs Command Center V2); it never writes and never hard-blocks (ambiguous detection is yellow, a clean read green). Once the config lands (11), the surface leaf (11a) inserts the standard action + tab companions (`OmniSupervisorConfigAction` / `OmniSupervisorConfigTab`) against the config's Id — plain Data API rows, so no metadata-file redeploy — and is idempotent (only missing types are inserted). It runs only after the config succeeds; a skipped or failed config skips the surface with a dependency note.
128
123
 
129
124
  **Optional rep-experience stages.** With `OMNI_REP_EXPERIENCE=1`, presence user config (12) deploys a validator-safe `PresenceUserConfig` with its decline reason and assigns every resolved agent username, including reused users. Sidebar (13) pins the Omni utility region on `OMNI_CONSOLE_APP`, or auto-detects a single console app. SkillsBased routing is not a cosmetic rep-experience stage: when requested, its SkillUser and WorkSkillRouting prerequisites run before flow activation.
130
125
 
@@ -147,11 +142,23 @@ Report content rules:
147
142
  ## Limitations
148
143
 
149
144
  - Routing-flow deploy covers `Case` and `VoiceCall` only.
150
- - Classic `OmniSupervisorConfig`, including its standard action and tab surface, is supported. Command Center V2 is an explicit opt-in (`OMNI_COMMAND_CENTER_V2=1`) and runs only when the org's Metadata API exposes the V2 settings; otherwise the configure leaf fails closed. Custom actions, FlexiPages, AWS dashboards, and AI-agent surfaces still need external references and separate setup.
145
+ - Classic `OmniSupervisorConfig` (including its action + tab surface) only. Command Center V2 (Enhanced Omni-Channel) is reported by the read-only analysis step but not enabled — the org preference is not writable via the Metadata API. The surface leaf populates only the reference-free standard action/tab types; custom-action, FlexiPage, AWS-dashboard, and AI-agent surfaces need an external reference and must be set up in Setup.
151
146
  - The rep-experience stages (presence user config, decline reasons, sidebar) run only with `OMNI_REP_EXPERIENCE=1`. SkillsBased routing is selected explicitly or inferred from a complete `OMNI_WSR_*` mapping and runs independently of that flag.
152
147
  - Teardown is **plan-only**: `--run` emits `deploy_ids.json` (a provenance manifest) and a dry-run `teardown.sh` that prints the reverse-order removal/restore plan, but does not execute destructive changes. Automated reversal is deliberately deferred until every leaf emits a normalized provenance block and the reversal is validated live — metadata-deployed components need destructiveChanges deploys and adopted records must never be deleted. Reversal today is a manual operator task guided by the plan and the per-skill artifacts.
153
148
 
154
- Detailed coverage and known headless gaps are maintained in `references/gap-catalog.md`. In short, Case routing is fully coordinated; VoiceCall needs a provisioned voice runtime; Incident and generic MessagingSession routing are adopted rather than created; and Omni Inbox or external supervisor surfaces remain outside this workflow.
149
+ ### Use-case coverage (current)
150
+
151
+ | Use case | Status | What is / isn't headless |
152
+ | --- | --- | --- |
153
+ | Case routing | Ready | Full create-and-bind thread (queue + QRC + members + routing flow), idempotent; runtime `PendingServiceRouting` proof optional. |
154
+ | VoiceCall / AFCC routing | Conditional | QRC + queue + members + routing flow are deployable, but require a **provisioned Amazon/AFCC contact center** and a live Voice runtime to prove end-to-end. Contact-center provisioning is the caller's responsibility. |
155
+ | Open CTI → AFCC migration | Partial | The coordinator creates the Omni routing resources; it does not provision or migrate the contact center itself. |
156
+ | Incident routing | Partial | Service channel + presence are supported; the coordinator **verifies/adopts** Incident routing but does not create a missing queue/QRC/flow for it. |
157
+ | Generic MessagingSession routing | Partial | Service channel + presence supported; full create-and-bind is delegated to `service-agentforce-human-escalation-configure`, not run generically here. |
158
+ | Classic Omni Supervisor | Ready | Users, permissions, config, queues/users, and the action/tab surface companions are all implemented. |
159
+ | Command Center V2 | Detection only | The read-only analysis step reports classic vs V2; the org preference `CommandCenterForServiceV2` is **not writable via the Metadata API** (tracked: W-23827287) and must be enabled in Setup. |
160
+ | Supervisor monitoring OrgValues | Not implemented | `OmniSuperConvMonitor`, `OmniSuperAgentSneakpeek`, `OmniSuperClientSneakpeek`, `OmniSuperWhisper`, `OmniSuperAdminSkillQueue` are OrgValues with no proven supported external write API. |
161
+ | Omni Inbox | Not implemented | The sidebar leaf pins the Omni sidebar (`isOmniPinnedViewEnabled`); it does not create or configure Omni Inbox, a console app, or utility items. |
155
162
 
156
163
  ## References
157
164
 
@@ -68,25 +68,6 @@ SUPERVISOR_COUNT="${4:-1}"
68
68
  AGENT_PROFILE="${OMNI_AGENT_PROFILE:-}"
69
69
  SUPERVISOR_PROFILE="${OMNI_SUPERVISOR_PROFILE:-}"
70
70
  SUPERVISOR_CONFIG_DN="${OMNI_SUPERVISOR_CONFIG_DEVELOPER_NAME:-Omni_Supervisor}"
71
- COMMAND_CENTER_V2="${OMNI_COMMAND_CENTER_V2:-0}"
72
-
73
- case "$COMMAND_CENTER_V2" in
74
- 0|1) ;;
75
- *) echo "{\"error\":\"Invalid OMNI_COMMAND_CENTER_V2 '$COMMAND_CENTER_V2'. Supported: 0 or 1.\"}" >&2; exit 2 ;;
76
- esac
77
-
78
- for command_center_setting in \
79
- OMNI_COMMAND_CENTER_CONVERSATION_MONITORING \
80
- OMNI_COMMAND_CENTER_AGENT_SNEAK_PEEK \
81
- OMNI_COMMAND_CENTER_CUSTOMER_SNEAK_PEEK \
82
- OMNI_COMMAND_CENTER_WHISPER_MESSAGING \
83
- OMNI_COMMAND_CENTER_QUEUES_AND_SKILLS; do
84
- command_center_value="${!command_center_setting:-}"
85
- if [ -n "$command_center_value" ] && [ "$command_center_value" != "true" ] && [ "$command_center_value" != "false" ]; then
86
- echo "{\"error\":\"Invalid $command_center_setting '$command_center_value'. Supported: true or false.\"}" >&2
87
- exit 2
88
- fi
89
- done
90
71
 
91
72
  # A complete WorkSkillRouting mapping is an unambiguous SBR request. Infer SkillsBased so callers do
92
73
  # not need a hidden second switch; an explicit OMNI_ROUTING_TYPE still wins.
@@ -563,7 +544,7 @@ run_skill() {
563
544
  # configured/bound/assigned/ok/success/skipped.
564
545
  local color
565
546
  case "$status" in
566
- analyzed|reused|updated|created|deployed|configured|bound|assigned|ok|success|skipped)
547
+ reused|updated|created|deployed|configured|bound|assigned|ok|success|skipped)
567
548
  color="green"
568
549
  ;;
569
550
  action_needed|partial|unsupported_v1|not_evaluated)
@@ -630,16 +611,6 @@ run_skill() {
630
611
  return 0
631
612
  }
632
613
 
633
- # ---- Read-only cross-channel baseline ----
634
- # A blocked inventory means the coordinator cannot establish an authoritative starting state, so no
635
- # write leaf is allowed to run.
636
- run_skill "service-omni-channel-inventory-analyze" \
637
- "service-omni-channel-inventory-analyze" \
638
- "Omni channel and routing inventory (read-only preflight)" \
639
- '.status' \
640
- analyze.sh "$ORG" \
641
- || exit 1
642
-
643
614
  # ---- Base settings ----
644
615
  # Plan detects; run deploys the 5 OmniChannelSettings toggles + re-verifies. Hard prerequisite for
645
616
  # every write skill below (INVALID_TYPE when Omni is off), so a red here fails fast.
@@ -1276,32 +1247,11 @@ else
1276
1247
  || true
1277
1248
  fi
1278
1249
 
1279
- # ---- Command Center V2 configuration (explicit opt-in) ----
1280
- if [ "$COMMAND_CENTER_V2" = "1" ]; then
1281
- if [ "$MODE" = "run" ]; then
1282
- COMMAND_CENTER_ARGS=(run "$ORG" --apply)
1283
- else
1284
- COMMAND_CENTER_ARGS=(plan "$ORG")
1285
- fi
1286
-
1287
- [ -z "${OMNI_COMMAND_CENTER_CONVERSATION_MONITORING:-}" ] || COMMAND_CENTER_ARGS+=(--conversation-monitoring "$OMNI_COMMAND_CENTER_CONVERSATION_MONITORING")
1288
- [ -z "${OMNI_COMMAND_CENTER_AGENT_SNEAK_PEEK:-}" ] || COMMAND_CENTER_ARGS+=(--agent-sneak-peek "$OMNI_COMMAND_CENTER_AGENT_SNEAK_PEEK")
1289
- [ -z "${OMNI_COMMAND_CENTER_CUSTOMER_SNEAK_PEEK:-}" ] || COMMAND_CENTER_ARGS+=(--customer-sneak-peek "$OMNI_COMMAND_CENTER_CUSTOMER_SNEAK_PEEK")
1290
- [ -z "${OMNI_COMMAND_CENTER_WHISPER_MESSAGING:-}" ] || COMMAND_CENTER_ARGS+=(--whisper-messaging "$OMNI_COMMAND_CENTER_WHISPER_MESSAGING")
1291
- [ -z "${OMNI_COMMAND_CENTER_QUEUES_AND_SKILLS:-}" ] || COMMAND_CENTER_ARGS+=(--queues-and-skills "$OMNI_COMMAND_CENTER_QUEUES_AND_SKILLS")
1292
-
1293
- run_skill "service-omni-command-center-configure" \
1294
- "service-omni-command-center-configure" \
1295
- "Command Center for Service V2 (opt-in Metadata API configuration)" \
1296
- '.status' \
1297
- configure-and-report.sh "${COMMAND_CENTER_ARGS[@]}" \
1298
- || true
1299
- fi
1300
-
1301
1250
  # ---- Command Center surface analysis (read-only advisory) ----
1302
- # Reports whether the org is on the classic Omni Supervisor surface or Command Center V2 after any
1303
- # requested V2 configuration. It never writes and never hard-blocks: ambiguous detection surfaces
1304
- # as yellow, while a clean read is green.
1251
+ # Reports whether the org is on the classic Omni Supervisor surface or Command Center V2 (Enhanced
1252
+ # Omni-Channel). Advisory only: this coordinator configures the classic surface; V2 enablement is an
1253
+ # org-preference flip outside the Metadata API. It never writes, so it runs identically in plan and
1254
+ # run and never hard-blocks - ambiguous detection surfaces as yellow, a clean read as green.
1305
1255
  run_skill "service-omni-command-center-analyze" \
1306
1256
  "service-omni-command-center-analyze" \
1307
1257
  "Command Center surface analysis (classic vs V2, read-only)" \
@@ -586,26 +586,6 @@ class SkillsBasedRoutingFlowTests(unittest.TestCase):
586
586
  return _run(_FLOW_SCRIPT, args, path_prefix=fake_dir, extra_env=merged)
587
587
 
588
588
 
589
- class CoordinatorInventoryPreflightTests(unittest.TestCase):
590
- """The authoritative cross-channel inventory must run before the first write leaf."""
591
-
592
- DRIVER = SKILLS_ROOT / "service-omni-channel-setup-coordinate" / "scripts" / "integration-driver.sh"
593
-
594
- def test_inventory_runs_before_base_settings(self):
595
- source = self.DRIVER.read_text()
596
- inventory_index = source.index('run_skill "service-omni-channel-inventory-analyze"')
597
- base_index = source.index('run_skill "service-omni-base-settings-configure"')
598
- self.assertLess(inventory_index, base_index)
599
-
600
- def test_inventory_failure_stops_the_driver(self):
601
- source = self.DRIVER.read_text()
602
- invocation = re.search(
603
- r'run_skill "service-omni-channel-inventory-analyze"[\s\S]+?\|\| exit 1',
604
- source,
605
- )
606
- self.assertIsNotNone(invocation, "blocked inventory must stop the coordinator before writes")
607
-
608
-
609
589
  class VoiceMembershipContractTests(unittest.TestCase):
610
590
  """(7) Explicit real-agent membership contract for service-omni-queue-members-assign."""
611
591
 
@@ -785,24 +765,6 @@ class CoordinatorSupervisorSurfaceTests(unittest.TestCase):
785
765
  self.src, r'(?m)^run_skill "service-omni-command-center-analyze"',
786
766
  "command-center-analyze must be invoked top-level, outside the OMNI_REP_EXPERIENCE gate")
787
767
 
788
- def test_command_center_v2_configuration_is_explicit_and_precedes_analysis(self):
789
- self.assertIn('COMMAND_CENTER_V2="${OMNI_COMMAND_CENTER_V2:-0}"', self.src)
790
- self.assertIn('run_skill "service-omni-command-center-configure"', self.src)
791
- configure_at = self.src.index('run_skill "service-omni-command-center-configure"')
792
- analyze_at = self.src.index('run_skill "service-omni-command-center-analyze"')
793
- self.assertLess(configure_at, analyze_at)
794
- self.assertIn('COMMAND_CENTER_ARGS=(run "$ORG" --apply)', self.src)
795
-
796
- def test_command_center_control_inputs_are_forwarded(self):
797
- for option in (
798
- "--conversation-monitoring",
799
- "--agent-sneak-peek",
800
- "--customer-sneak-peek",
801
- "--whisper-messaging",
802
- "--queues-and-skills",
803
- ):
804
- self.assertIn(option, self.src)
805
-
806
768
  def test_supervisor_surface_invoked_after_config(self):
807
769
  self.assertIn("service-omni-supervisor-surface-deploy", self.src,
808
770
  "coordinator never invokes supervisor-surface-deploy")
@@ -8,7 +8,6 @@ metadata:
8
8
  minApiVersion: "66.0"
9
9
  relatedSkills:
10
10
  - "service-omni-channel-setup-coordinate"
11
- - "service-omni-command-center-configure"
12
11
  - "service-omni-supervisor-config-deploy"
13
12
  accessCheck:
14
13
  - type: license
@@ -61,7 +60,7 @@ bash scripts/analyze.sh <org-alias> [supervisor_username_or_id]
61
60
  | `v2_ready` | Capability + seed present (and supervisor has permission, if checked) | verify only (coordinator proceeds to V2 verification) |
62
61
  | `v2_permission_missing` | V2 enabled but the named supervisor lacks `CommandCenterForServiceUser` | Manual — assign `CommandCenterForServiceUser` (headless-capable via PermissionSet; packaging pending) |
63
62
  | `v2_seed_incomplete` | Capability present but the FlexiPage/tab provisioning is inconsistent | Manual — re-check in Setup → Omni-Channel → Supervisor Settings (no supported public write API) |
64
- | `v2_available_not_enabled` | Org supports V2 but the preference is off | `service-omni-command-center-configure` when the W-24039822 Metadata API contract is available; otherwise enable manually |
63
+ | `v2_available_not_enabled` | Org supports V2 but the preference is off | Manual — enable in Setup → Omni-Channel → Supervisor Settings (no supported Metadata/Tooling write API) |
65
64
  | `legacy_selected` | V2 capability absent | `service-omni-supervisor-config-deploy` |
66
65
  | `ambiguous` | A required signal could not be read through a supported API | none — **blocks**, do not guess |
67
66
 
@@ -73,7 +72,7 @@ A single JSON object: `status` (`detected` | `blocked`), `state` (one of the six
73
72
 
74
73
  ## Limitations
75
74
 
76
- - The analyzer keeps using the seeded FlexiPage as its cross-release read signal. On releases containing W-24039822, `service-omni-command-center-configure` can write and re-read the preference through `Settings:OmniChannel`.
75
+ - The `CommandCenterForServiceV2` org preference has no supported public read; its state is **inferred** from the seeded FlexiPage (the platform seeds on the ON-flip). This is called out in `signals` and is why a bare capability-without-seed reads as `v2_available_not_enabled`.
77
76
  - The release gater cannot be read directly; capability is inferred from the presence of the user-permission column on the org schema.
78
77
  - Tab detection is best-effort; when the tab query cannot run, `v2_tab_present` is `"unknown"` and state is derived from the remaining signals.
79
78
  - Read-only: it never enables V2, seeds pages, assigns permissions, or deploys config.