Skip to main content
Glama
advancedcommunities

Salesforce MCP Server

list_connected_salesforce_orgs

Read-onlyIdempotent

Retrieve all Salesforce orgs connected to the Salesforce CLI as JSON, including aliases and metadata, to choose which org to target in other tools.

Instructions

List connected Salesforce Orgs. This command retrieves a list of all Salesforce Orgs that are currently connected to the Salesforce CLI. The results are returned in JSON format, providing details about each Org, including its alias, username, and other metadata. Use this command to see which Salesforce Orgs you have access to and can interact with using the Salesforce CLI. Usernames, org IDs and instance URLs in the result are masked for privacy; refer to orgs by alias when passing targetOrg to other tools.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
noteYes
sandboxesYes
totalOrgsYes
devHubOrgsYes
productionYes
scratchOrgsYes
permissionMessageNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.7.0

TDQS

A3.9/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already establish read-only, idempotent, non-destructive, open-world behavior, so the bar is lower. The description still adds non-obvious value by disclosing that usernames, org IDs, and instance URLs are masked for privacy, and that orgs should be referenced by alias when passed to targetOrg elsewhere.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Four sentences, front-loaded with the core action, and the privacy/alias caveat is well-placed at the end. The first two sentences restate the same idea slightly, costing a bit of tightness.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

With an output schema present and no parameters, the description need not explain return values; instead it supplies the one thing the schema cannot - the masking caveat and alias convention. Nothing an agent needs to call and use this tool is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The tool takes zero parameters, so the baseline is 4. The description correctly implies no input is required and instead guides how the output identifiers should be used downstream.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('List connected Salesforce Orgs') and clarifies the scope as Orgs connected to the Salesforce CLI. It is clearly distinguishable from write/mutation siblings, though it does not explicitly name related read tools like get_default_org.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

'Use this command to see which Salesforce Orgs you have access to and can interact with' gives an implied usage context, but there are no when-not conditions, prerequisites, or named alternatives among the many sibling org tools. Adequate but leaves routing to inference.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.