mcp-salesforce-connector
v0.1.18A Model Context Protocol (MCP) server implementation for Salesforce integration
These tools were reported by the server itself during our smoke test (tools/list), not copied from the README.
run_soql_query
Executes a SOQL query against Salesforce. TOKEN OPTIMIZATION GUIDELINES: - Always SELECT only the fields you need (never SELECT *) - Use LIMIT to restrict results (start with LIMIT 10, increase if needed) - Use WHERE clauses to filter data server-side - Default output is CSV format (most token-efficient) - Use format='json' only when you need nested data structure - You can always run additional queries if you need more data Example efficient query: SELECT Id, Name FROM Account WHERE IsActive = true LIMIT 20
| Parameter | Type | Description |
|---|---|---|
query * | string | The SOQL query to execute. Always include LIMIT clause and select only needed fields. |
format | string | Output format: 'csv' (default, most compact), 'compact' (JSON no whitespace), 'json' (full JSON) |
run_sosl_search
Executes a SOSL search against Salesforce. TOKEN OPTIMIZATION: Use RETURNING clause to limit fields and objects. Example: FIND {searchterm} RETURNING Account(Id, Name), Contact(Id, Name) LIMIT 10
| Parameter | Type | Description |
|---|---|---|
search * | string | The SOSL search to execute. Use RETURNING to specify fields and LIMIT for result count. |
format | string | Output format: 'csv' (default), 'compact', 'json' |
get_object_fields
Retrieves field names and types for a Salesforce object. Use this to discover available fields before writing SOQL queries. Output is CSV format: name,label,type,updateable
| Parameter | Type | Description |
|---|---|---|
object_name * | string | The Salesforce object API name (e.g., 'Account', 'Contact', 'Store__c') |
get_record
Retrieves a specific record by ID. Returns all fields - prefer SOQL with specific fields for token efficiency.
| Parameter | Type | Description |
|---|---|---|
object_name * | string | The Salesforce object API name (e.g., 'Account', 'Contact') |
record_id * | string | The 15 or 18 character Salesforce record ID |
format | string | Output format: 'compact' (default), 'json' |
create_record
Creates a new record
| Parameter | Type | Description |
|---|---|---|
data * | object | The data for the new record |
object_name * | string | The name of the Salesforce object (e.g., 'Account', 'Contact') |
update_record
Updates an existing record
| Parameter | Type | Description |
|---|---|---|
data * | object | The updated data for the record |
object_name * | string | The name of the Salesforce object (e.g., 'Account', 'Contact') |
record_id * | string | The ID of the record to update |
delete_record
Deletes a record
| Parameter | Type | Description |
|---|---|---|
object_name * | string | The name of the Salesforce object (e.g., 'Account', 'Contact') |
record_id * | string | The ID of the record to delete |
tooling_execute
Executes a Tooling API request
| Parameter | Type | Description |
|---|---|---|
action * | string | The Tooling API endpoint to call (e.g., 'sobjects/ApexClass') |
data | object | Data for POST/PATCH requests |
method | string | The HTTP method (default: 'GET') |
apex_execute
Executes an Apex REST request
| Parameter | Type | Description |
|---|---|---|
action * | string | The Apex REST endpoint to call (e.g., '/MyApexClass') |
data | object | Data for POST/PATCH requests |
method | string | The HTTP method (default: 'GET') |
restful
Makes a direct REST API call to Salesforce
| Parameter | Type | Description |
|---|---|---|
path * | string | The path of the REST API endpoint (e.g., 'sobjects/Account/describe') |
data | object | Data for POST/PATCH requests |
method | string | The HTTP method (default: 'GET') |
params | object | Query parameters for the request |
list_sobjects
Retrieves a list of all available Salesforce SObjects (standard and custom).
bulk_create_records
Creates multiple records of a specified SObject type in bulk.
| Parameter | Type | Description |
|---|---|---|
data * | array | A list of records to create. Each record is a dictionary of field names and values. |
object_name * | string | The API name of the Salesforce SObject (e.g., 'Account', 'MyCustomObject__c'). |
bulk_update_records
Updates multiple records of a specified SObject type in bulk. Each record must have an 'Id' field.
| Parameter | Type | Description |
|---|---|---|
data * | array | A list of records to update. Each record is a dictionary of field names and values, and *must* include an 'Id' field. |
object_name * | string | The API name of the Salesforce SObject (e.g., 'Account', 'MyCustomObject__c'). |
bulk_delete_records
Deletes multiple records of a specified SObject type in bulk, given their IDs.
| Parameter | Type | Description |
|---|---|---|
object_name * | string | The API name of the Salesforce SObject (e.g., 'Account', 'MyCustomObject__c'). |
record_ids * | array | A list of record IDs (strings) to delete. |