MCP.so
Sign In
Servers

Salesforce MCP Server

@jaworjar95

A comprehensive Model Context Protocol (MCP) server that provides seamless Salesforce integration for AI development tools like Claude Desktop, Cline, and other MCP-compatible clients.

Overview

What is Salesforce MCP Server?

Salesforce MCP Server is a Model Context Protocol (MCP) server that provides comprehensive Salesforce integration for AI development tools such as Claude Desktop, Cline, and other MCP-compatible clients. It offers 17 tools covering query, Apex development, data management, metadata operations, and connection health monitoring.

How to use Salesforce MCP Server?

Install via npx by adding the server configuration to your MCP client’s JSON settings file (e.g., Claude Desktop, Cline, or Cursor). Provide authentication using either Username/Password (with optional security token) or OAuth 2.0 credentials as environment variables. Once configured, you can invoke any of the 17 available tools, such as execute-soql, execute-apex, or deploy-metadata.

Key features of Salesforce MCP Server

  • 17 comprehensive tools for Salesforce operations
  • Auto-bulk switching for optimal performance
  • Dual authentication: OAuth2 and Username/Password
  • Intelligent caching with 1‑hour TTL for SObject metadata
  • Full TypeScript implementation with runtime validation
  • Raw Salesforce errors preserved for debugging

Use cases of Salesforce MCP Server

  • Query Salesforce data using SOQL and SOSL from an AI assistant
  • Run anonymous Apex code and retrieve debug logs
  • Create, update, delete, and upsert records with auto‑bulk support
  • Deploy and retrieve metadata components like Apex classes or CustomObjects
  • Validate and monitor Salesforce connection health

FAQ from Salesforce MCP Server

What authentication methods are supported?

Supports both Username/Password (with optional security token) and OAuth 2.0 authentication. Set the corresponding environment variables (SF_USERNAME, SF_PASSWORD, etc. for password auth; SF_CLIENT_ID, SF_REFRESH_TOKEN, etc. for OAuth2).

Where do I configure the server for Claude Desktop or other clients?

Configuration files vary per client: for Claude Desktop on macOS it’s ~/Library/Application Support/Claude/claude_desktop_config.json; for Cline (VS Code) it’s in the globalStorage settings; for Cursor it’s ~/.cursor/mcp.json.

Which tools can be auto‑approved?

Tools marked as “safe for auto‑approval” include test-connection, execute-soql, describe-sobject, get-record, get-apex-logs, and list-metadata-types. All other tools (data modification, code execution, metadata deployment) require manual approval.

How long is metadata cached?

SObject metadata is cached with a 1‑hour time‑to‑live (TTL) for performance optimization.

What is auto‑bulk switching?

The server automatically uses the Bulk API for large operations (e.g., bulk record creation or updates) and the standard REST API for smaller ones, optimizing performance without manual selection.

More from Data & Analytics