Salesforce MCP

Salesforce MCP

The Salesforce MCP Connector is an MCP server that enables seamless integration between language models and Salesforce, allowing LLMs to query, manipulate, and interact with Salesforce data programmatically using the standardized Model Context Protocol.

Author: smn2gnt


View Protocol

What is Salesforce MCP Connector?

The Salesforce MCP Connector provides a bridge between AI applications and Salesforce, exposing Salesforce's data and APIs through the MCP standard. It enables LLMs and agentic workflows to securely access, analyze, search, and modify Salesforce records, metadata, and more, empowering AI-driven business automation and workflow augmentation.

How to Configure Salesforce MCP

To enable the Salesforce MCP Connector, update your claude_desktop_config.json as follows:

{
  "mcpServers": {
    "salesforce": {
      "command": "uvx",
      "args": [
        "--from",
        "mcp-salesforce-connector",
        "salesforce"
      ],
      "env": {
        "SALESFORCE_ACCESS_TOKEN": "SALESFORCE_ACCESS_TOKEN",
        "SALESFORCE_INSTANCE_URL": "SALESFORCE_INSTANCE_URL"
      }
    }
  }
}

Authentication Methods:

  • OAuth (Recommended):
    Set SALESFORCE_ACCESS_TOKEN and SALESFORCE_INSTANCE_URL as environment variables for secure, token-based authentication.
  • Username/Password (Legacy):
    If OAuth variables are absent, set SALESFORCE_USERNAME, SALESFORCE_PASSWORD, and SALESFORCE_SECURITY_TOKEN for legacy authentication. OAuth is strongly recommended for security and compatibility.

How to Use

  1. Start the Salesforce MCP server using your configuration.
  2. Connect your MCP-compatible host (such as Claude Desktop or a custom AI agent) to the Salesforce server.
  3. Use the host's UI or your agent's code to perform actions like querying, searching, retrieving metadata, or updating Salesforce records.
  4. Discover available tools via the tools/list endpoint, and invoke operations using tools/call.
  5. Responses and results will be returned directly to your LLM or client interface.

Key Features

  • Execute Salesforce Object Query Language (SOQL) queries to read Salesforce records.
  • Perform Salesforce Object Search Language (SOSL) searches across objects.
  • Retrieve rich metadata describing Salesforce objects, fields, and relationships.
  • Create, update, and delete records programmatically.
  • Access Salesforce Tooling API for advanced tasks.
  • Invoke custom Apex REST endpoints for tailored workflows.
  • Directly call any Salesforce REST API method from within the MCP framework.

Use Cases

  • Automate Salesforce data analysis by allowing LLMs to summarize, report, or visualize records.
  • Enable AI-powered assistants to update leads, contacts, or opportunities based on business logic.
  • Integrate natural language queries with Salesforce CRM for fast data retrieval in sales and support.
  • Build intelligent workflows that automatically take action on Salesforce data based on conversational input.
  • Prototype new AI features for CRM without building custom backend integrations.

FAQ

Q1: Which Salesforce editions are supported?
A: The connector supports all Salesforce editions that provide API access, including Enterprise, Unlimited, and Developer editions.

Q2: Is my Salesforce data safe when using this connector?
A: Yes. The connector runs locally or within your designated infrastructure and uses your explicit authentication. OAuth is the recommended method for maximum security.

Q3: What kinds of operations can I perform from an LLM?
A: You can query, search, create, update, delete records, access metadata, and call Tooling or custom REST APIs—as broadly as your Salesforce user's privileges allow.

Q4: Does this support custom Salesforce objects?
A: Absolutely. The connector exposes all standard and custom objects your authenticated user can access.

Q5: How does the connector handle API rate limits?
A: The connector relies on Salesforce API limits. Be mindful of your org's allocated API calls and design workflows to respect rate limitations.