
Observing Agentforce
Queries production Agentforce session traces from Salesforce Data Cloud's STDM (Session Trace Data Model) to diagnose agent failures and performance regressions. The workflow is observe production issues, reproduce them locally with `sf agent preview`, then edit the `.agent` file and redeploy. Notably includes a Data Space discovery step and a full fallback path when STDM isn't enabled, switching to test suites and local traces instead. The routing logic auto-resolves agent names against the org metadata and works around a known `sf project retrieve` bug that double-nests directories. Most useful when your agent works in dev but breaks in production and you need to see what real users actually said.
- skills.sh installs
- 1.5K
- GitHub stars
- 705
- last updated
- Jul 14, 2026
Install
$ npx -y skills add forcedotcom/afv-library --skill observing-agentforce --agent claude-codeInstalls into .claude/skills of the current project.
Files
Queries production Agentforce session traces from Salesforce Data Cloud's STDM (Session Trace Data Model) to diagnose agent failures and performance regressions. The workflow is observe production issues, reproduce them locally with `sf agent preview`, then edit the `.agent` file and redeploy. Notably includes a Data Space discovery step and a full fallback path when STDM isn't enabled, switching to test suites and local traces instead. The routing logic auto-resolves agent names against the org metadata and works around a known `sf project retrieve` bug that double-nests directories. Most useful when your agent works in dev but breaks in production and you need to see what real users actually said.
Browse the repository on GitHubSponsors
Details
- Repository
- github.com/forcedotcom/afv-library
- First seen
- May 16, 2026
More from forcedotcom/afv-library
All 58- Searching Media1.5K
- Switching Org1.5K
- Testing Agentforce1.5K
- Uplifting Components To Slds21.5K
- Using Ui Bundle Salesforce Data1.5K
- Creating B2b Commerce Store1.4K
- Generating Lwc Components541
- Querying Soql540
- Developing Datacloud Code Extension539
- Fetching Salesforce Docs537
- Getting Datacloud Schema536
- Deploying Metadata534
- Debugging Apex Logs532
- Handling Sf Data532
- Generating Mermaid Diagrams531
- Generating Visual Diagrams531
- Running Apex Tests531
- Configuring Connected Apps526
- Building Sf Integrations523
- Retrieving Datacloud523
- Activating Datacloud522
- Harmonizing Datacloud520
- Connecting Datacloud519
- Orchestrating Datacloud519