Salesforce Metadata Tool icon

Salesforce Metadata Tool

AI Tool: retrieve Salesforce metadata & limits for LLM agents

Overview

This node, named Salesforce Metadata Tool, is designed to interact with Salesforce metadata and organizational limits. It supports multiple operations such as describing global Salesforce objects, describing a single Salesforce object in detail, listing metadata components, executing read-only Tooling API queries, and fetching current org limits and available API versions. It is useful for scenarios where users need to retrieve Salesforce metadata information for automation, integration, or AI agent reasoning, such as listing all Salesforce objects with filters, inspecting fields of a specific object, or querying metadata components like Apex classes or flows.

Use Case Examples

  1. Listing all Salesforce objects that are searchable and creatable for an AI agent to understand available data structures.
  2. Retrieving detailed field and record type information for a specific Salesforce object like 'Account'.
  3. Listing metadata components such as Apex classes and flows to manage Salesforce development artifacts.
  4. Running a Tooling API SOQL query to fetch specific metadata records without modifying data, useful for reporting or analysis tasks.

Properties

Name Meaning
Authentication Method of authentication to connect to Salesforce, either OAuth2 or JWT Bearer.
API Version Salesforce API version to use, either a specific version like 'v60.0' or 'auto' to use the latest.
Include Standard Objects Whether to include standard Salesforce objects in the describe global operation.
Include Custom Objects Whether to include custom Salesforce objects in the describe global operation.
Searchable Only Filter to include only searchable objects in the describe global operation.
Creatable Only Filter to include only creatable objects in the describe global operation.
Raw Response Whether to return the raw Salesforce API response for inspection or debugging.

Output

JSON

  • name - Name of the Salesforce object or metadata component.
  • label - Label or display name of the object or component.
  • custom - Boolean indicating if the object is custom.
  • searchable - Boolean indicating if the object is searchable.
  • createable - Boolean indicating if the object is creatable.
  • queryable - Boolean indicating if the object is queryable.
  • updateable - Boolean indicating if the object is updateable.
  • keyPrefix - Key prefix for the object, if applicable.
  • fields - Array of field details for a described Salesforce object, including name, label, type, and permissions.
  • recordTypeInfos - Information about record types for a described Salesforce object.
  • limits - Current Salesforce org limits when fetching org limits operation.
  • apiVersions - Available Salesforce API versions when fetching org limits operation.

Dependencies

  • Salesforce API connection via OAuth2 or JWT Bearer authentication

Troubleshooting

  • Ensure correct Salesforce credentials are provided and have sufficient permissions for the requested operations.
  • If the node throws an error about missing SObject API name, verify that the 'SObject API Name' property is correctly set for the 'Describe One SObject' operation.
  • For API version issues, try setting the 'API Version' property explicitly instead of 'auto'.
  • If the node returns unexpected empty results, check the filters such as 'Include Standard Objects', 'Include Custom Objects', 'Searchable Only', and 'Creatable Only' to ensure they match the desired data.
  • When using the 'Tooling SOQL Query' operation, ensure the SOQL query is SELECT-only and does not perform DML operations, as this is a read-only query.

Links

Discussion