The Salesforce Developer's AI Toolkit: What to Use at Each Step, from Prompt to Production
What is AI-assisted Salesforce development?
AI-assisted Salesforce development means using generative AI inside your everyday workflow to write, explain, review, test and deploy Apex, Lightning Web Components (LWC), Flow and agent metadata. Salesforce's own tool for this is Agentforce Vibes, which runs as a Visual Studio Code (VS Code) extension or as a browser-based IDE and can read your org's metadata. Code Analyzer, ApexGuru and Agentforce DX sit around it. This post maps each tool to a step of your workflow and shows where human review still matters.
A general-purpose chatbot will happily write you an Apex trigger. It just won't know your custom fields, your naming conventions or your org's governor-limit hotspots, so you spend the time you saved fixing what it guessed.
Salesforce's developer AI tools close that gap by giving the model your project, your org metadata and your team's rules. Below is a practical map of what exists today, what each tool is actually good at, and the guardrails we'd put in place before rolling it out to a team.
1. The toolkit at a glance
Several of these tools were renamed in the last year, which is why forum answers often seem to contradict each other. Agentforce Vibes is the current name for both the old Agentforce for Developers extension and the old Code Builder IDE, according to Salesforce Help.
| Tool | What it does for you | Where it runs |
|---|---|---|
| Agentforce Vibes extension | Agentic chat that plans and generates Apex classes, triggers, tests and LWC, runs tools and deploys (formerly Agentforce for Developers) | VS Code on your machine |
| Agentforce Vibes IDE | Browser-based VS Code with Salesforce Extensions, Salesforce CLI and GitHub ready to use (formerly Code Builder) | Opened from Setup in your org |
| Agentforce Vibes Autocomplete | Inline "ghost text" suggestions as you type Apex, JavaScript, HTML and CSS, including LWC files | Separate VS Code extension |
| Salesforce Code Analyzer v5 | Static analysis across several engines (PMD, ESLint, RetireJS, Flow Scanner, Regex and more) for security, quality and performance | CLI, VS Code, CI/CD |
| ApexGuru | AI performance analysis of Apex based on runtime profiles, with suggested fixes | Scale Center, and as a Code Analyzer engine |
| Agentforce DX | Pro-code tools to author, preview and test Agentforce agents and move their metadata between orgs | Salesforce CLI and VS Code |
| Salesforce skills library | Salesforce-curated agent skills and plugins (Apex, LWC, Flow, SOQL and more) for any AI tool that supports skills | GitHub: forcedotcom/sf-skills |
2. Agentforce Vibes: what's actually inside
Agentforce Vibes is Salesforce's agentic coding tool. Salesforce Help describes it as a set of tools to plan, build, debug, test and deploy agents, web apps, mobile apps and Salesforce metadata. It comes in two forms: a VS Code extension you install from the Marketplace, and a browser-based IDE you open from Setup with nothing to install. Since April 2026, Developer Edition orgs include the IDE at no cost, so you can try it without a paid org.
The Agentforce Vibes Basics module on Trailhead breaks it into three building blocks:
- Skills: reusable instruction sets for specific tasks, such as Apex testing standards or LWC naming. Vibes loads only the skills that match your request.
- Rules: persistent instructions that apply to every session, such as naming conventions or a minimum test-coverage target. Unlike skills, rules are always on.
- MCP tools: Model Context Protocol (MCP) tools that let the agent act, not just talk. Trailhead counts 50+ tools for running tests, deploying, checking quality and validating dependencies in one conversation.
Two habits make the biggest difference in practice. First, use Plan mode for anything bigger than a single class: in Plan mode, no code is generated until you review and approve the plan. Second, keep the default human-in-the-loop flow, where the agent proposes changes and you accept, edit or reject them before anything reaches your org.
On models and data: Vibes sends every model request, whichever provider it goes to, through the Agentforce Trust Layer, and Salesforce states that your data and code aren't used for model training. Which models you can pick depends on your org. Salesforce Help describes a default model plus OpenAI models that an admin can switch off, and the April 2026 Developer Edition announcement named Claude Sonnet 4.5 as the default coding model there.
3. Teach it your team's standards with Rules
The fastest way to stop fixing AI output by hand is to write your standards down once. In Vibes, rules are markdown files. Project rules live in .vibes/rules/ in your repo, and Salesforce recommends committing them to version control so the whole team gets the same behaviour.
# .vibes/rules/apex-standards.md (scope: Project, mode: File pattern **/*.cls)
- Bulkify all trigger logic: no SOQL or DML inside loops.
- One trigger per object. Business logic goes in a handler class.
- Every new class gets a test class with real assertions, not just coverage.
- Query in user mode (WITH USER_MODE) unless the class comment explains why not.
- Never hardcode record IDs; use Custom Metadata or a query.- Application mode: "Always" applies the rule in every interaction. "File pattern" applies it only when the agent touches files matching a glob such as
**/*.cls, which keeps Apex rules out of your LWC work. - Scope: project rules override global rules when both cover the same thing.
- Built-in rules: Salesforce ships its own rules, such as
production-guardrailsandmetadata-best-practices. You can switch them on or off but can't edit or delete them.
Manage rules from the Agentforce Vibes panel: open the Toolkit tab and click Rules.
4. Review what the AI wrote: Code Analyzer and ApexGuru
Generated code needs the same checks as human-written code, and the checks should run automatically. Code Analyzer v5 is the current version: v4 was retired in August 2025. The v5 commands moved from the scanner topic to code-analyzer, so update any old pipeline scripts.
# Install or update the Code Analyzer v5 plugin
sf plugins install @salesforce/plugin-code-analyzer
# Run only the security rules (v4 was: sf scanner run --category Security)
sf code-analyzer run --rule-selector Security
# AppExchange security review rules
sf code-analyzer run --rule-selector AppExchange
# ApexGuru performance rules (uses your existing sf login; see the engine docs for org settings)
sf code-analyzer run --rule-selector apexguruApexGuru is the AI part of this step. It began in Scale Center, where it uses runtime profiles from your org to point out anti-patterns and performance hotspots in Apex, such as SOQL or DML in loops, and to suggest fixes. It's now also built into Code Analyzer as an engine, so the same checks can run in the IDE, the CLI and CI/CD. When your org has ApexGuru turned on in Setup, Code Analyzer scans in Advanced Mode using runtime data; otherwise it falls back to Basic Mode.
To turn it on in Scale Center, go to Setup, find ApexGuru Insights and accept the ApexGuru Agreement. Salesforce says the first insights can take up to 24 hours and then refresh weekly. ApexGuru isn't supported in Government Cloud Plus.
5. Building agents as code: Agentforce DX
If you're building Agentforce agents rather than using AI to write code, Agentforce DX is the pro-code path. It adds CLI commands and a VS Code extension to create, preview and test agents outside the builder UI, and to move agent metadata between your DX project, scratch orgs, sandboxes and production. That means agents can live in Git and go through the same review and deployment process as your Apex.
# Describe the agent in a YAML spec, then generate its Agent Script authoring bundle
sf agent generate agent-spec
sf agent generate authoring-bundle --spec agent-specs/resort-manager.yaml
# Turn test cases into a YAML test spec, then create the test in your dev org
sf agent generate test-spec
sf agent test create --spec specs/Resort_Manager-testSpec.yaml --api-name Resort_Manager_TestFrom there, run the tests with the agent test run command or the VS Code testing panel. When a test fails, use the Agent Preview pane or the agent preview command to talk to the agent in simulated or live mode and see where it went wrong. The test commands cover both the newer Agentforce Studio tests and the legacy Agentforce Testing Center, so check which runner your org uses before you build a test suite. You can also ask Agentforce Vibes to explain and edit an Agent Script file in plain language. Trailhead has a full badge on that workflow.
For a hands-on look at the script itself, see our Agent Script walkthrough.
6. MCP servers, and the one that was retired
MCP is what connects an AI tool to your org. In Agentforce Vibes, servers are managed from the Toolkit tab under MCP Servers. A Salesforce DX server ships with Vibes: it's enabled by default in the browser IDE, and you switch it on yourself in desktop VS Code. Salesforce-hosted servers, such as API Context and Metadata Experts (both beta), connect to remote Salesforce capabilities, but an admin must enable them in the org first.
Watch out for old setup guides. The standalone open-source DX MCP package, @salesforce/mcp, reached end of life on November 2, 2026, and its GitHub repository is now archived. Blog posts from 2025 that tell you to add it to Cursor or Claude Desktop with npx are out of date. Use what Vibes provides, Salesforce-hosted servers, or the skills library instead.
One practical limit: the Vibes guide says only about 20 tools can be active at once, so turn off servers you aren't using. For the bigger picture of hosted servers and MCP for Agentforce, read MCP in Salesforce.
7. Where AI still needs you
Salesforce's own training material says it plainly: vibe coding is nondeterministic, results vary, and the agent sometimes makes mistakes and then corrects itself. These are the guardrails we recommend (our guidance, not a Salesforce requirement):
- Sandbox first, always. Point AI tools at scratch orgs, Developer Edition or sandboxes. Deploy to production through your normal pipeline, never from a chat window.
- Read every diff. Check bulkification, sharing (
with sharing), field- and object-level security and error handling. These are the easiest things for generated code to get subtly wrong, so check them first. - Make tests prove behaviour. An AI can reach 75% coverage with tests that assert nothing. Ask for assertions on outcomes and negative cases, and write that into a rule.
- Gate with tools, not trust. Run Code Analyzer (with ApexGuru) on every pull request, so standards don't depend on who wrote the prompt.
- Watch the budget. Usage draws on your org's Flex Credits. Agree on who gets access and keep an eye on consumption.
Cheat sheet: which tool for which job?
| You want to… | Reach for | Remember |
|---|---|---|
| Generate Apex, tests or an LWC from a description | Agentforce Vibes (Plan mode) | Approve the plan before code is written |
| Code in a browser with no local setup | Agentforce Vibes IDE | Opens from Setup; formerly Code Builder |
| Get suggestions while typing | Vibes Autocomplete | Tab accepts, Esc dismisses |
| Make the AI follow team standards | Rules in .vibes/rules/ | Commit them to Git |
| Scan for security and quality issues | Code Analyzer v5 | sf code-analyzer, not sf scanner |
| Find Apex performance hotspots | ApexGuru | Runtime data needs it turned on in Setup |
| Build and test agents in source control | Agentforce DX | sf agent generate / test commands |
| Use Claude Code or Cursor on Salesforce | forcedotcom/sf-skills | The npm @salesforce/mcp package is retired |
Based on the Agentforce Vibes Developer Guide, the Code Analyzer and Agentforce DX guides, Salesforce Help and Trailhead, checked on December 1, 2026. Names, models and pricing in this space change often, so check the linked pages before you plan a rollout.
Official Resources
Straight from Salesforce: the docs this article is based on.
Trailhead
Developer Docs
Rolling out AI coding tools to your team?
We'll help you set up rules, review gates and a sandbox-first workflow that holds up.
All information in this article was collected from publicly available resources, including official Salesforce documentation. Other product names are trademarks of their respective owners.