forcedotcom/sf-skills

platform-agentsetup-categories-fetch

Fetch agentic setup prompt categories from a connected Salesforce org using the Connect API.

View source
Original skill document

Rendered from the source repository. Headings, examples, code, tables, links, and referenced images are preserved.

platform-agentsetup-categories-fetch

Fetch prompt categories from the Agentic Setup Categories Connect API on a connected Salesforce org.

Scope

In scope:

  • Calling GET /services/data/{apiVersion}/agenticsetup/categories via SF CLI
  • Passing the fetchPrompts query parameter to include nested prompts
  • Parsing and presenting the JSON response (categories, labels, prompts)
  • Handling errors (403 when feature is disabled, auth failures)

Out of scope — delegate elsewhere:

  • Creating or modifying prompt categories → not supported via this API (read-only)
  • Org authentication setup → use sf org login separately
  • Permission set assignment → assigning-permission-set

Required Inputs

The agent needs:

  • A connected org (already authenticated via sf org login)
  • Optionally: whether to include nested prompts (fetchPrompts=true)
  • Optionally: target API version (default: v67.0). Replace v67.0 in the URL with the user-specified version if provided.

Workflow

1. Verify org connectivity

bash
sf org display --json

Confirm the org is authenticated and extract the instance URL. If no default org is set, ask the user which org to target with --target-org.

2. Call the Categories API

Basic call (categories only):

bash
sf api request rest /services/data/v67.0/agenticsetup/categories --method GET

With nested prompts:

bash
sf api request rest "/services/data/v67.0/agenticsetup/categories?fetchPrompts=true" --method GET

3. Parse and present the response

The API returns a JSON object with a categories array. Each category has name, label, and prompts fields. See references/api-response-schema.md for the full response structure and examples for both fetchPrompts=true and fetchPrompts=false.

Present the results clearly:

  • List categories with their name and label
  • If fetchPrompts=true was used, show nested prompts under each category
  • Note any categories with empty prompts arrays (means no prompts exist for that category)

4. Handle errors

ErrorMeaningAction
Success (exit 0)200 OKParse and display results
FUNCTIONALITY_NOT_ENABLEDFeature not enabled for this org/userTell user the Agentic Setup Categories feature needs to be enabled — check Setup > Einstein/Agentforce
INVALID_SESSION_IDSession expiredRe-authenticate with sf org login
NOT_FOUNDEndpoint not foundAPI version too old or feature not deployed to this org

Rules / Constraints

RuleRationale
Always use sf api request rest — never curl or raw HTTPcurl bypasses ~/.sfdx session tokens and requires manual Authorization headers, making it brittle
NEVER use SOQL queriesCategories are NOT in standard objects — only available via this Connect REST API
NEVER generate files (LWC, Apex, XML)This is a data-fetching task, not a code generation task
Default to v67.0 unless user specifiesThis is the min-version where the endpoint was introduced
Don't pass fetchPrompts unless askedReduces payload size; prompts can be large
Categories are sorted by labelThe API returns them alphabetically — don't re-sort
Prompts are sorted by textWithin each category, prompts come alphabetically

Output Expectations

When finishing, present:

  1. Number of categories returned
  2. Category list — name and label for each
  3. Prompts (if requested) — nested under their category
  4. Any errors encountered with suggested fixes

Reference File Index

FileWhen to read
references/api-response-schema.mdWhen you need to understand the full response structure and field descriptions
from this repository

More skills

All skills
forcedotcom
Community

design-systems-slds-apply

Apply SLDS-compliant UI using the correct blueprints, styling hooks, utility classes, and icons. Use when building any UI that needs SLDS, choosing between Lightning Base Components and SLDS Blueprints, applying styling hooks for theming, using utility classes for layout and spacing, or selecting icons. Triggers include \"build a modal\", \"create a form\", \"data table\", \"SLDS styling\", \"style with hooks\", \"add an icon\".

installs
5
GitHub stars
948
Updated
8月28日
forcedotcom
Community

design-systems-slds-validate

Audit Lightning Web Components for SLDS design-system compliance and produce a scored quality report. Runs the SLDS linter and analyzes CSS for theming hook usage and pairing, scoring SLDS findings across categories into an overall grade. Use when asked to \"score my component's SLDS\", \"SLDS scorecard\", \"SLDS quality report\", \"audit SLDS compliance\", \"how good is my SLDS\", \"check SLDS quality\", \"rate my SLDS styling\", \"evaluate my component's SLDS\", \"is this component's SLDS ready to ship?\", \"look at my LWC for SLDS issues\", \"audit SLDS before I submit\", \"review my component's SLDS before code review\", or any time a user wants an SLDS quality assessment or SLDS production-readiness check on an LWC. Not for fixing violations (use design-systems-slds2-migrate), building new components (use design-systems-slds-apply), or accessibility/WCAG/ARIA audits (use experience-accessibility-validate).

installs
5
GitHub stars
948
Updated
8月28日
forcedotcom
Community

design-systems-slds2-migrate

Migrate Lightning Web Components from SLDS 1 to SLDS 2 by running the SLDS linter and fixing violations. Use this skill whenever users mention SLDS 2, SLDS uplift, linter violations, LWC token migration, class overrides, hardcoded CSS values that need SLDS hook replacement, or styling hook selection. Covers all styling hook categories — color, spacing, sizing, typography, borders, radius, and shadows. Also use when users mention no-hardcoded-values, no-slds-class-overrides, lwc-to-slds-hooks, no-deprecated-tokens-slds1, or ask about SLDS component migration — even if they don't explicitly say \"uplift\" or \"migration\".

installs
5
GitHub stars
948
Updated
8月28日
forcedotcom
Community

agentforce-architecture-analyze

Declared architecture snapshot for one Agentforce agent: planner, topics, actions, flows, Apex, prompt templates, and NGA plugins. Renders a human-readable architecture document and Mermaid invocation graph from design-time metadata (not runtime audit rows). TRIGGER when user asks to describe, diagram, inventory, audit, document, or diff (e.g. v3 vs v5) the architecture / action tree / topic structure / tool inventory of a specific agent by agent API name in a specific org. DO NOT TRIGGER for runtime session traces, conversation transcripts, generation timings, or gateway audit chains — this skill reads design-time metadata only (use agentforce-d360-analyze for session traces).

installs
4
GitHub stars
948
Updated
8月28日