Back to Home
How to Connect a Trailhead Org to Salesforce CLI

How to Connect a Trailhead Org to Salesforce CLI

B
Blizine Admin
·2 min read·0 views

Exploring Agentforce Posted on May 31 How to Connect a Trailhead Org to Salesforce CLI # tutorial # agentforce # trailhead # sfdx Take Trailhead Learning beyond the browser Salesforce Trailhead is a great way to learn Agentforce . You can level up this experience by connecting your Trailhead org to Salesforce CLI and working with AgentScript metadata locally in VS Code. Here’s a quick setup flow for connecting a Trailhead Agentforce org to Salesforce CLI 👇 Prerequisites : • VS Code • Salesforce CLI installed • Trailhead org with Agentforce enabled Step 1. Open your Trailhead org Launch the Trailhead playground or developer org that you want to connect. Step 2. Find your username Profile → Settings Step 3. Set password (if not set already) Settings → Change My Password Step 4. Connect org via CLI Authenticate via browser, setting up alias for the org and providing your Trailhead org url: # Authenticate with your Trailhead org sf org login web --alias your-org-alias --instance-url https://your-org-name.develop.my.salesforce.com Enter fullscreen mode Exit fullscreen mode Step 5. Verify connection Confirm that the org was added successfully: sf org list Enter fullscreen mode Exit fullscreen mode Step 6. Set the default org To avoid specifying the org in every command, set it as the default target: sf config set target-org your-org-alias Enter fullscreen mode Exit fullscreen mode Important : Use the Correct Login URL Trailhead org URLs used for login usually look like: https://your-org-name.develop.my.salesforce.com NOT : • login.salesforce.com • develop.lightning.force.com Once connected, you can retrieve AgentScript metadata locally in VS Code, experiment faster, and work with Agentforce in a more development-oriented workflow . Top comments (0) Subscribe Personal Trusted User Create template Templates let you quickly answer FAQs or store snippets for re-use. Submit Preview Dismiss Code of Conduct • Report abuse Are you sure you want to hide this comment? It will

📰Dev.to — dev.to

Comments