Gearset uses the Salesforce Metadata API to retrieve metadata from Salesforce orgs. Some metadata items can't be retrieved over the Metadata API, or only parts of them can be retrieved. This can mean your comparisons don't show a particular item you're looking for.
This article explains how to use Salesforce CLI to check what the Metadata API returns. This helps you work out whether the issue is a limitation of the API or something Gearset can improve on.
You can also follow these steps using Workbench if you prefer a browser-based tool.
Why Salesforce CLI?
Salesforce CLI is Salesforce's official command-line tool for working with orgs. Like Gearset, it talks to Salesforce via the Metadata API.
If a component can be listed or retrieved by the CLI, Gearset can retrieve it too. If the CLI can't retrieve the metadata, Gearset won't be able to either. This makes it a good tool for working out why items aren't showing up in your comparisons.
Note: Salesforce recommends using Salesforce CLI (or VS Code with the Salesforce Extension Pack) instead of Workbench. Workbench is an open-source community tool that Salesforce does not maintain.
Prerequisites
You'll need Salesforce CLI installed.
Check the CLI is available and up to date:
sf --version
sf update
You can run these commands from any terminal (Terminal on macOS, Command Prompt or PowerShell on Windows, or the integrated terminal in VS Code if you use it).
Step 1: Set up the CLI and authenticate
The CLI needs a Salesforce project to work from, even for simple operations. To create one:
sf project generate --name my-project
cd my-project
Then authenticate with the org you want to investigate:
sf org login web --alias my-org --set-default
This opens a browser window. Log in with the same credentials you use in Gearset. This is important for an accurate comparison.
Tip: If you hit login or redirect issues, specify the instance URL:
sf org login web \
--instance-url https://my-sandbox.my.salesforce.com \
--alias my-org \
--set-default
Step 2: Check the list metadata call
A quick way to confirm whether the item you're looking for exists on the Metadata API is to run a list metadata call.
In Gearset, you can see the list of named items via the metadata filter dialog. To see the same list via the CLI, run:
sf org list metadata --metadata-type CustomObject
Replace CustomObject with the metadata type you're investigating (e.g. Flow, ApexClass).
This returns the API names of all items of that type in the org. The list should match what you see in Gearset's metadata filter.
If you're not sure what metadata types are available:
sf org list metadata-types
If an item does not appear in the CLI output, it won't appear in Gearset either.
Step 3: Retrieve the metadata
If the item appears in the list but isn't showing in your Gearset comparison results, you can retrieve it directly to see what the API returns.
Create a package.xml file in your project's manifest/ folder:
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<Package xmlns="http://soap.sforce.com/2006/04/metadata">
<types>
<members>*</members>
<name>Flow</name>
</types>
<version>66.0</version>
</Package>
Change the metadata type and version as needed.
Then retrieve:
sf project retrieve start --manifest manifest/package.xml
The retrieved files appear in force-app/main/default/ within your project. You can open the files to see exactly what the Metadata API returned.
The items returned via the CLI should match what Gearset shows in its comparison results.
Summary
These steps let you confirm that Gearset returns the same data as the Salesforce Metadata API. If the items are not returned by the CLI either, the issue is with the API, not with Gearset.
Note: Gearset breaks some metadata type components down into smaller subcomponents, so you may see fewer individual items when retrieving via the CLI.
If your item is not returned by either Gearset or the CLI, you could:
Check if the item is supported by the Metadata API
Check if your item is part of a managed package
Raise a case with Salesforce to find out why the metadata isn't being returned
If you have concerns not covered by this article, please let us know!





