Set Up Your Development Environment
Learning Objectives
After completing this unit, you’ll be able to:
- Configure the developer tools for agent development.
- Set up a Salesforce org for agent development.
- Clone a repo that contains a sample agent in a Salesforce DX project.
Before You Start
Before you start this badge, we recommend that you complete this content. The work you do here builds on the concepts and skills you develop in that content.
Coral Cloud Resorts + Agentforce Vibes
You, a software developer, were recently hired by the development team at Coral Cloud Resorts and you’re learning all about creating agents. After completing the Build an Agent Using Agentforce DX badge, you’re now familiar with the Local Info Agent that provides customers with local weather updates and resort hours. You used the Agentforce DX tools (Salesforce CLI and VS Code commands) to preview and publish the agent, and even manually updated its Agent Script file to change its behavior.
But now you’re ready to add a new feature to the agent that provides details about local events close to the resort. You want to use natural language rather than manually updating code. Sounds like a job for Agentforce Vibes!

Agentforce Vibes IDE, Agentforce Vibes, and Agentforce DX
Agentforce Vibes IDE, formerly known as Code Builder, is a web-based integrated development environment that delivers the full power and flexibility of Visual Studio Code (VS Code) in your browser. It includes Salesforce Extensions, the Salesforce CLI, and GitHub integration, so you don’t need to install extra software to start building.
Agentforce Vibes is an AI-powered coding companion that helps you build and modify Salesforce apps and agents using natural language. Agentforce Vibes IDE includes Agentforce Vibes. Instead of manually writing Agent Script code or running CLI commands, you describe what you want, and Agentforce Vibes does the work.
Under the hood, Agentforce Vibes uses Agentforce DX — the pro code toolset for building agents. In this module, you use natural language prompts instead of manually running CLI commands or editing code.
Agentforce Vibes comes with specialized AI skills for developing agents. These activate automatically based on your requests. You’ll occasionally see prompts that explicitly mention these skills to help conserve AI tokens.
Sign Up for a Custom Playground with Agentforce Vibes IDE
To complete this badge, you need a special, limited-time custom playground with Agentforce and Agentforce Vibes IDE.
- Select Create Playground, and then select Yes, Create Playground.
- Your new org is automatically attached to your Trailhead account.
- Make note of your org's expiration date and complete this badge before then.
- Select Launch to open the playground.
Activate Agentforce in Your Playground
To develop agents using Agentforce DX, confirm that Agentforce is enabled in your playground. Einstein is the org-level toggle required for every AI feature, including Agentforce DX.
- To open the Setup menu, select Setup
.
- In the Quick Find box, search for and select
Einstein Setup.
- Make sure the Turn on Einstein toggle is set to On.
- If you changed the toggle status, refresh your browser.

Next, enable the Agentforce (Default) feature in Salesforce Go so that you can create agents for your users.
- In the Quick Find box, search for and select
Salesforce Go.
- In the Search features in your org… text box, enter
Agentforce (Default).
- In the Agentforce (Default) feature box, select Set Up.
- Select Get Started.
- Select Turn On.
- Select Turn On again.

Launch Agentforce Vibes IDE
With the required platform features turned on, you’re ready to configure your agent project in Agentforce Vibes IDE.
- To open Agentforce Vibes IDE, select Setup
and select Agentforce Vibes from the dropdown menu.
- Review and accept the Terms and Conditions.
The first time you launch Agentforce Vibes IDE, it runs through a setup process that may take a few minutes. You see the message: “Agentforce Vibes is loading…” After Agentforce Vibes IDE loads successfully, the Agentforce Vibes IDE editor window opens by default.

- Configure Workspace Trust settings. This feature allows Agentforce Vibes IDE to execute agents, terminal commands, extensions, and other tasks in selected folders.
- If the “Do you trust the authors of the files in this folder?” window opens automatically, select the checkbox Trust the authors of all files in the parent folder ‘codebuilder’, and then select Yes, I trust the authors.
- If the “Do you trust the authors of the files in this folder?” window doesn’t open automatically:
- Select Restricted Mode in the bottom status bar. The Workspace Trust window opens.
- Select Restricted Mode in the bottom status bar. The Workspace Trust window opens.
- If the “Do you trust the authors of the files in this folder?” window opens automatically, select the checkbox Trust the authors of all files in the parent folder ‘codebuilder’, and then select Yes, I trust the authors.

- In the Trusted Folders & Workspaces section, select Add Folder. Enter
/home/codebuilder/, and then select Trust Folder.
- Close the Workspace Trust window.
- Confirm that the Restricted Mode button no longer appears in the bottom status bar.
If the Agentforce Vibes side panel opens automatically, select I agree to the terms, and then select Enable Agentforce. Dismiss any additional pop-up windows that appear.
Clone the Sample Repo
As already mentioned, your dev team has started working on the Local Info Agent and has checked the source code into a GitHub repository. The source code is organized using a standard Salesforce DX project, which provides a project structure for your org’s metadata (code and configuration), sample data, and all your team’s tests. Agents are Salesforce metadata components, so you use DX projects to store and work with them just like any other component.
Follow these steps to clone the sample repo so you can start coding the agent.
- Copy this Github repository URL to your clipboard:
https://github.com/forcedotcom/afdx-pro-code-testdrive.git
- In Agentforce Vibes IDE, press Ctrl+Shift+P (Windows) or ⌘+Shift+P (macOS) to open the Command Palette.
- Enter
Gitand select Git: Clone.
- In the search bar, paste
https://github.com/forcedotcom/afdx-pro-code-testdrive.gitand select Clone from URL.
- Click Select as repository destination.
- If a “Would you like to open the repository, or add it to the current workspace?” popup window appears, select Open.
The Agentforce Vibes IDE window reloads and sets afdx-pro-code-testdrive as the current SFDX project. Dismiss any additional pop-up windows that appear.Feel free to review the existing code in this Salesforce DX project; this badge discusses some of the agent-related artifacts later.

Run a Script to Create and Deploy Required Org Artifacts
The sample repo that you cloned contains the source files for the artifacts that implement the new Local Info Agent, such as Apex classes, a prompt template, and a flow. Describing these artifacts is beyond the scope of this module. But you need them in your playground to continue with this Trailhead badge, so we provide a script in the repo you just cloned.
When you run this script, it deploys the source files, assigns permissions, and creates an agent user. Agents run as a dedicated user with the Einstein Agent User profile—this user is the runtime identity for your agent.
- Open the terminal in Agentforce Vibes IDE by pressing Ctrl+J (Windows) or ⌘+J (macOS).
- In the terminal, enter this command:
./setup.
- The script displays the steps it’s running, with a green checkmark when the step completes successfully.
Important: Save the unique username the script creates—you need it in the next unit.

Good job, you’re all set up to start vibe coding an agent!