Salesforce Skills for Claude Code let developers describe features in natural language and get production-ready Apex controllers, Lightning Web Components, and test classes that automatically pass Salesforce Code Analyzer checks and reach 75%+ test coverage. The workflow maps prompts to specialized skills (generating-apex, generating-apex-test, generating-lwc-components, debugging-apex-logs, generating-flow) that enforce governor-limit-safe patterns, bulkification, sharing rules, and required metadata files. A step-by-step tutorial builds a full account creation form (LWC, Apex controller, test class) from installation through deployment to a Salesforce org's home page. Additional patterns covered include batch Apex jobs, service-selector-domain layer architecture, screen flows, and Apex log debugging. The sf-skills library is open source on GitHub with 60+ skills, installable via npx skills, and integrates with the Claude Code VS Code extension and CI/CD pipelines.

2m read timeFrom developer.salesforce.com
Post cover image

Questions this post answers

How do I install Salesforce Skills for Claude Code?

Run npx skills in the Salesforce project directory to fetch the official forcedotcom/sf-skills library from GitHub, then use the space bar to select which skills to install (such as generating-apex, generating-apex-test, generating-lwc-components, and debugging-apex-logs) and press Enter. Installation can target the current project or a global home directory scope, and installed skills are recorded in skills-lock.json. Developers wiring AI agent skills into their workflow can track Claude Code updates on daily.dev.

What code coverage does Claude Code generate for Apex test classes using Salesforce Skills?

Generated Apex test classes reach at least 75% code coverage by default, with the generating-apex-test skill using the TestDataFactory pattern and bulk testing against 251+ records to validate governor-limit-safe behavior. In one example a service layer class was built with a required test coverage target of 90%, and a tutorial's account controller test class actually reached 100% coverage. Teams evaluating AI-generated Apex quality can follow coding-agent capabilities and gotchas on daily.dev.

How many skills are available in the Salesforce sf-skills library for Claude Code?

The forcedotcom/sf-skills GitHub repository currently offers more than 60 skills, with new ones being added continuously, covering areas like batch Apex, service-selector-domain architecture, screen flows, OmniStudio, Data 360 connections, B2B commerce stores, Trigger Actions Framework, Queueable with Finalizers, and custom REST resources. The library is open source, so teams can fork it to add organization-specific naming conventions and patterns. Developers deciding which AI agent skill libraries to adopt can follow ecosystem growth on daily.dev.

655 Impressions