Skip to main content
Glama
semwalajay83-sem

salesforce-metadata-mcp

Server Configuration

Describes the environment variables required to run the server.

NameRequiredDescriptionDefault
PORTNoHTTP server port (default: 3000)
SF_ALIASNoSalesforce CLI org alias
TRANSPORTNostdio or http (default: stdio)
SF_CLIENT_IDNoConnected App client ID
SF_ACCESS_TOKENNoStatic access token (expires ~1hr)
SF_INSTANCE_URLYesYour org URL (e.g. https://org.salesforce.com)
SF_CLIENT_SECRETNoConnected App client secret
SF_REFRESH_TOKENNoOAuth refresh token

Capabilities

Features and capabilities supported by this server

CapabilityDetails
tools
{
  "listChanged": true
}

Tools

Functions exposed to the LLM to take actions

NameDescription
sf_create_custom_objectA

Creates a new Salesforce Custom Object using the Metadata API. The object name must end with '__c'. Use this when a user asks to create a new object, entity, or table in Salesforce.

sf_create_custom_fieldA

Creates a new custom field on an existing Salesforce object. The field API name must end with '__c'. Supports all field types: Text, Number, Picklist, Lookup, etc.

sf_add_picklist_valuesA

Adds new picklist values to an existing Picklist or MultiselectPicklist field without removing existing values. Use when a user wants to add new options to a dropdown.

sf_create_flowA

Creates or updates a Salesforce Flow via the Metadata API. Supports AutoLaunchedFlow (required for Agentforce actions), Screen Flow, RecordTriggeredFlow, and ScheduledFlow. Supports advanced elements: Decision, GetRecords, CreateRecords, DeleteRecords, SendEmailAlert, ApexAction, Subflow, Loop, Assignment, Screen via the 'elements' array. GetRecords filter operators supported: EqualTo, NotEqualTo, GreaterThan, LessThan, GreaterThanOrEqualTo, LessThanOrEqualTo, IsNull, StartsWith, EndsWith. Contains is NOT supported by Salesforce Flow record lookups and will return an error. IMPORTANT for Agentforce: set flowType to 'AutoLaunchedFlow' and status to 'Active' — Draft flows and Screen flows cannot be invoked by agents.

sf_create_approval_processA

Creates or updates a Salesforce Approval Process via the Metadata API. Define who can submit, approval steps with approvers, entry criteria, and what happens on approval or rejection.

sf_create_validation_ruleA

Creates or updates a Salesforce Validation Rule on any object via the Metadata API. The errorConditionFormula returns TRUE when data is INVALID. Use for data quality enforcement.

sf_create_workflow_field_updateA

Creates a Workflow Field Update action that can be referenced by Approval Processes, Workflow Rules, or Flows. Sets a field to a literal value, formula result, or null.

sf_create_formula_fieldA

Creates a formula field on any Salesforce object. Supports all return types (Text, Number, Currency, Date, DateTime, Checkbox, Percent) and the full Salesforce formula language: IF/AND/OR/NOT, BLANKVALUE, TEXT, VALUE, DATE, DATEVALUE, TODAY, NOW, date functions (MONTH/YEAR/DAY), math (FLOOR/CEILING/MOD), string functions (LEN/LEFT/RIGHT/MID/TRIM/UPPER/LOWER/CONTAINS/BEGINS), record type and picklist functions (ISPICKVAL, ISNULL, ISBLANK), cross-object field references (e.g. Account.Owner.Name), and VLOOKUP. Complex multi-line formulas are fully supported.

sf_create_custom_metadata_typeA

Creates a new Custom Metadata Type (ending in __mdt) with optional custom fields. Custom Metadata Types store configuration data that can be packaged and deployed. Use when a user wants to store configuration in metadata rather than custom objects.

sf_create_custom_metadata_recordA

Creates a record within an existing Custom Metadata Type (__mdt). Custom metadata records store configuration values that can be read in Apex, Flows, and formulas. Provide typeName (e.g., 'Config__mdt'), a record name, and field values.

sf_create_custom_labelA

Creates or updates a Salesforce Custom Label. Custom Labels are text values accessible in Apex, Visualforce, LWC, and Flows, with support for translation. Use for internationalizable text strings, error messages, or UI labels.

sf_create_custom_settingA

Creates a Custom Setting object (ending in __c) with Hierarchy or List type. Custom Settings store data accessible via Apex without SOQL queries. Hierarchy type supports org/profile/user level overrides. Use for feature flags, thresholds, or configurable constants.

sf_create_global_value_setA

Creates a Global Value Set — a shared picklist definition that can be referenced by multiple Picklist fields across different objects. Any change to the Global Value Set is reflected in all fields that use it. Use when the same set of values (like Status, Priority, Region) should be shared and kept in sync across multiple objects. fullName must end with __gvs, e.g. 'Industry_Types__gvs'.

sf_create_record_typeA

Creates a Record Type on a Salesforce object. Record Types allow different page layouts, picklist values, and business processes for different types of records on the same object. For example, create 'Enterprise' and 'SMB' record types on Opportunity with different Stage values.

sf_create_business_processA

Creates a Business Process for Opportunity (Stage values), Lead (Status values), Case (Status values), or Solution (Status values). Business Processes define which picklist values are available for a given Record Type. Must be created before assigning to a Record Type.

sf_create_page_layoutA

Creates a Page Layout for a Salesforce object. Page Layouts control what fields, related lists, and buttons appear on record detail and edit pages. Layouts are assigned to user profiles and record types. Define sections with fields and the related lists to include.

sf_create_sharing_ruleA

Creates a Sharing Rule for a Salesforce object. Sharing Rules extend the OWD by automatically sharing records with users who meet criteria (criteria-based) or who own records (ownership-based). Use to give specific roles/groups access to records they wouldn't normally see based on OWD.

sf_create_field_dependencyA

Creates a field dependency between a controlling picklist and a dependent picklist on the same object. When a user selects a value in the controlling field, only the relevant dependent field values appear. Example: when Country = 'USA', State shows only US states.

sf_create_email_alertA

Creates a Workflow Email Alert action that can be triggered by Flows, Approval Processes, or Workflow Rules. Specify the email template to use and recipients (owner, creator, users, roles, or custom email addresses). Use when you need to send notification emails as part of automation.

sf_create_platform_eventA

Creates a Platform Event object (ending in __e) for event-driven architecture. Platform Events enable real-time publish/subscribe communication between systems. Publishers fire events and subscribers (Flows, Apex triggers, external systems) react to them. PublishAfterCommit waits for DML to commit; PublishImmediately fires right away.

sf_create_assignment_ruleA

Creates an Assignment Rule for Leads or Cases. Assignment rules automatically route new records to the appropriate owner (user or queue) based on matching criteria. Only one rule can be active at a time per object. Rule entries are evaluated top-to-bottom and the first match wins.

sf_create_escalation_ruleA

Creates an Escalation Rule for Cases. Escalation rules automatically escalate cases that haven't been closed within a specified time, reassigning them to other users or queues and optionally sending notifications. Based on business hours and a configurable start date (creation time or last modification).

sf_create_auto_response_ruleA

Creates an Auto-Response Rule for Web-to-Lead or Web-to-Case. When a lead or case is created via a web form, this rule automatically sends a confirmation email using the specified template. Rule entries define which template to use based on criteria.

sf_create_matching_ruleA

Creates a Matching Rule used by Duplicate Rules to detect potential duplicate records. Define which fields to match on and which matching algorithm to use (Exact, FirstName, LastName, Company, Email, Phone, etc.). Must be created before creating a Duplicate Rule that references it.

sf_create_duplicate_ruleA

Creates a Duplicate Rule that uses Matching Rules to detect potential duplicates when records are saved. Can block duplicates, allow with a warning, or allow silently. Works for Leads, Contacts, Accounts, and custom objects. Requires existing Matching Rules.

sf_create_apex_email_serviceA

Creates an Apex Email Service that processes inbound emails via an Apex class implementing Messaging.InboundEmailHandler. Useful for creating support cases from emails, parsing email content, or triggering workflows from inbound messages. The Apex class must exist before creating the service.

sf_create_scheduled_jobA

Schedules an Apex class that implements the Schedulable interface to run on a cron schedule. Use for batch processing, nightly data cleanup, report generation, or any periodic automation. The Apex class must already exist in the org. Example cron: '0 0 2 * * ?' = daily at 2 AM.

sf_create_scheduled_flowA

Creates a Schedule-Triggered Flow that runs automatically on a recurring schedule (e.g., daily, weekly) against a batch of matching records. Use for nightly batch processing, periodic data updates, or scheduled notifications.

fullName: Flow API name label: Flow display label objectApiName: object whose records to process scheduledPaths: array defining when the flow runs (offsetNumber, offsetUnit, timeSource) description: optional description

sf_create_platform_event_triggerA

Creates an Apex trigger that fires when a Platform Event message is received (after insert). Use to process incoming platform events with Apex logic — e.g., creating records, sending notifications, or calling external APIs when an event is published.

triggerName: Apex trigger name eventApiName: Platform event API name, e.g. 'MyEvent__e' body: Apex code body for the trigger apiVersion: Salesforce API version

sf_create_workflow_ruleA

Creates a Workflow Rule (legacy automation) that evaluates criteria and triggers actions. Use for simple automations that don't require the power of Flows. Supports formula or criteria-based evaluation. Workflow rules can trigger field updates, email alerts, outbound messages, and tasks.

objectName: object the rule applies to fullName: rule developer name triggerType: when to evaluate (onCreateOnly, onCreateOrTriggeringUpdate, onAllChanges) active: whether the rule is active formula or criteriaItems: define when the rule fires

sf_create_field_updateA

Creates a standalone Workflow Field Update action that sets a field to a formula, literal value, or null when triggered. Can be associated with Workflow Rules, Approval Process steps, or used independently.

objectName: object the field update applies to fullName: developer name of the field update name: display name field: field API name to update operation: Formula, Literal, LiteralBlank, or Null formula: Apex formula (for Formula operation) literalValue: static value to set (for Literal operation)

sf_create_outbound_messageA

Creates a Workflow Outbound Message that sends a SOAP XML payload to an external endpoint when triggered by a Workflow Rule or Approval Process. Use for real-time integration with external systems that need to be notified of record changes.

objectName: object the message is for fullName: developer name for the outbound message name: display name endpointUrl: external SOAP endpoint URL fields: field API names to include in the message integrationUser: optional username to authenticate the callout

sf_create_permission_setA

Creates a Permission Set with object permissions, field permissions, Apex class access, and user permissions. Permission Sets extend a user's access without changing their profile. Use when you need to grant specific permissions to a subset of users (e.g., a 'Sales Manager' permission set that allows deleting opportunities).

sf_create_roleA

Creates a Role in the Salesforce role hierarchy. Roles control record visibility through role-based sharing. Users in higher roles can see records owned by users in subordinate roles. Specify a parentRole to place this role in the hierarchy, or omit it for a top-level role.

sf_create_queueA

Creates a Queue in Salesforce. Queues are groups of users that can be assigned records (Cases, Leads, etc.). When a record is assigned to a queue, any queue member can work on it. Use for support teams, sales teams, or any scenario where multiple people share a pool of records to process.

sf_create_named_credentialA

Creates a Named Credential for making authenticated callouts to external systems from Apex or Flows. Named Credentials store the endpoint URL and authentication details securely, so developers don't hardcode credentials. Supports NoAuthentication, Basic (username/password), OAuth, and more. Use with sf_create_remote_site_setting to also allow the URL.

sf_create_role_hierarchyA

Creates multiple Salesforce roles in the role hierarchy in a single call. Roles control record visibility — users in higher roles see records owned by subordinate-role users (depending on OWD settings). Use to set up an entire hierarchy at once.

roles: array of {fullName, name, parentRole?, description?}

  • fullName: role API name (e.g. 'VP_Sales')

  • name: display label

  • parentRole: API name of parent role (omit for top-level)

sf_create_field_level_securityA

Sets field-level security (FLS) for a field across one or more profiles, controlling whether each profile can read and/or edit the field. Use after creating a custom field to make it visible and editable to the right profiles.

objectName: object API name fieldName: field API name (e.g. 'Revenue__c') profiles: array of {profileName, readable, editable}

sf_get_field_permissionsA

Reads the current field-level security grants for a field across all Profiles and Permission Sets that reference it, via the FieldPermissions query object. Use to audit who can currently see or edit a field before changing access, or to answer "which profiles can edit this field?". Complements sf_create_field_level_security, which sets grants but doesn't report the current state.

objectName: object API name, e.g. 'Account' fieldName: field API name, e.g. 'Revenue__c'

sf_create_custom_permissionA

Creates a Custom Permission that can be checked in formulas with $Permission.MyPerm or in Apex with FeatureManagement.checkPermission('MyPerm'). Assign custom permissions to users via Permission Sets. Use for feature flags, conditional UI rendering, or access gates.

fullName: permission API name (e.g. 'Can_Approve_Discounts') label: display label description: optional description requiredPermissions: other custom permissions required before this one can be granted

sf_create_muting_permission_setA

Creates a Muting Permission Set that removes specific permissions from users in a Permission Set Group. Use to create exceptions — e.g., a Permission Set Group grants broad access, and a Muting Permission Set removes a subset of that access for specific users.

fullName: muting permission set API name label: display label description: optional description

sf_create_permission_set_groupA

Creates a Permission Set Group that aggregates multiple Permission Sets into a single assignable unit. Users assigned the group receive all permissions from all included permission sets. Simplifies administration when users need a combination of permissions.

fullName: Permission Set Group API name label: display label permissionSets: array of Permission Set API names to include

sf_create_lightning_appA

Creates a Lightning App in Salesforce — a branded navigation container with a custom navigation bar, utility bar, and logo. Choose between Standard (tabs) and Console (split view) navigation. Specify navItems to populate the navigation bar with objects, home, reports, etc. Use when a user wants a custom app experience for a specific team or use case.

sf_create_tabA

Creates a Custom Tab for a custom object so it appears in the navigation bar and App Launcher. Tabs are required to make custom objects accessible from the UI. Specify the object API name and choose a motif/icon from Salesforce's icon library (e.g., 'Custom64: Coin').

sf_create_compact_layoutA

Creates a Compact Layout for a Salesforce object. Compact Layouts define which fields appear in the highlights panel at the top of a record page (up to 10 fields), in Salesforce Mobile, and in related list cards. Use when you want to surface the most important fields at a glance.

sf_create_list_viewA

Creates a List View for any Salesforce object. List Views are saved filters that display a subset of records with specific columns, filters, and sorting. Use to create shared views like 'My Open Cases', 'High Priority Leads', or 'Deals Closing This Month' that appear in the object's list view selector.

sf_create_email_templateA

Creates an HTML or text email template that can be used in Workflow Email Alerts, Approval Processes, or sent manually. Templates support merge fields like {!Account.Name} for personalization. Specify a folder path (e.g., 'unfiled$public/MyTemplate') or 'MyFolder/MyTemplate'. Use relatedEntityType to enable object-specific merge fields.

sf_create_static_resourceA

Creates a Static Resource from text/JSON/JS/CSS content. Static Resources are files stored in Salesforce and served via a CDN URL — ideal for JavaScript libraries, CSS stylesheets, JSON configuration, or any other file that needs to be served from Salesforce. Content is provided as a string and deployed via the Metadata API.

sf_create_custom_notification_typeA

Creates a Custom Notification Type that can be sent from Flows, Apex, or Process Builder using the Send Custom Notification action. Custom Notifications appear in Salesforce notification bell (and optionally mobile push). Use to create in-app alerts for important business events.

sf_create_report_typeA

Creates a Custom Report Type that defines what objects and fields are available when building reports. A report type specifies a primary object and optionally related objects (joined via relationships). Use when the standard report types don't include the data you need, or when you want to create a specialized reporting structure.

sf_create_dashboardA

Creates a Salesforce Dashboard with components (charts, metrics, tables, gauges) powered by reports. Dashboards provide visual summaries of key business data. Specify the folder path as 'FolderName/DashboardName' and add components linked to existing reports. Use when a team needs a visual summary of their metrics.

sf_create_apex_classA

Creates and deploys an Apex class to the Salesforce org using the Metadata API. Accepts the full Apex source code including the class declaration. Use for any type of Apex class: service classes, controllers, batch classes, schedulable classes, queueable classes, test utilities, etc. IMPORTANT — If this class will be used as an Agentforce agent action: it MUST contain a public static method annotated with @InvocableMethod. Classes without @InvocableMethod cannot be invoked by agents and will silently fail at runtime. Example minimum structure: public class MyClass { @InvocableMethod(label='Do Thing' description='Does the thing') public static List doThing(List input) { ... } }

sf_create_apex_triggerA

Creates and deploys an Apex Trigger on any Salesforce object. Specify the trigger events (before insert, after update, etc.) and the trigger body code. The trigger declaration (trigger Name on Object (events)) is auto-generated — just provide the code that goes inside the trigger body. Deployed via Metadata API SOAP deploy.

sf_create_apex_test_classA

Creates and deploys an Apex Test Class (annotated with @isTest). Provide the full test class source code. Optionally run the tests immediately after deployment. Test classes are required for Salesforce deployments to production (minimum 75% code coverage). Use for unit testing Apex classes, triggers, and business logic.

sf_run_apex_testsA

Runs one or more Apex test classes and returns pass/fail results with any error messages. Uses the Salesforce Tooling API runTestsAsynchronous endpoint and polls for results. Use after deploying Apex code to verify test coverage, or to run regression tests before a release.

sf_execute_anonymous_apexA

Executes anonymous Apex code in the Salesforce org using the Tooling API executeAnonymous endpoint. Returns compile errors, runtime exceptions, and debug log output. Use for one-off data fixes, testing Apex snippets, creating test data, running utilities, or debugging. Code runs in the context of the authenticated user.

sf_scan_apex_antipatternsA

Scans Apex classes in the org for common anti-patterns using the Tooling API. Detects SOQL/DML in loops, hardcoded Salesforce IDs, and debug statements left in production code. Use before deploying to catch performance and quality issues early.

classNames: optional list of class names to scan (omits test classes with __Test suffix) maxClasses: maximum classes to scan (default 20, max 200)

sf_run_code_scannerA

Runs Salesforce Code Analyzer against Apex classes in the org — a real multi-engine static analysis scan (PMD rules including ApexCRUDViolation and OperationWithLimitsInLoop, SFGE data-flow analysis for SOQL injection, RetireJS for vulnerable JS libraries, ESLint, and Salesforce's regex engine), on top of the lighter-weight sf_scan_apex_antipatterns heuristic check. Retrieves class bodies via the Tooling API into a temp workspace, runs the scanner, and cleans up afterward. PMD/CPD/SFGE engines require Java 11+ on the host running this MCP server — if Java isn't detected, the scan automatically falls back to the Java-free engines (eslint, retire-js, regex, flow) and flags this in the response rather than failing.

classNames: optional list of class names to scan (omit to scan all active classes) maxClasses: maximum classes to scan (default 20, max 200) ruleSelector: optional override, e.g. ['pmd:Security'] — defaults to 'Recommended' rules (auto-restricted per the Java note above)

sf_get_apex_classA

Retrieves the full source code of an existing Apex class by exact name, via the Tooling API. Use before modifying a class (to see current logic), when debugging, or when a user asks "show me the X class" / "what does this class do". Returns the class body, API version, and status. Not to be confused with sf_create_apex_class, which deploys new or updated code — this tool only reads.

sf_get_apex_triggerA

Retrieves the full source code of an existing Apex trigger by exact name, via the Tooling API. Returns the trigger body, the object it fires on, its active status, and which trigger events (before/after insert/update/delete/undelete) it's registered for. Use before modifying a trigger, or when a user asks to see or explain an existing trigger.

sf_create_lwcA

Creates and deploys a new Lightning Web Component (LWC) to the Salesforce org. Provide the HTML template, JavaScript controller, optional CSS, and component metadata. The component is packaged into a deployment zip and deployed via the Metadata API. Specify targets to make the component available in Lightning App Builder (AppPage, RecordPage, HomePage), Flow Screen, Utility Bar, or Experience Cloud. Use isExposed:true to make it drag-and-drop in App Builder.

sf_update_lwcA

Updates an existing Lightning Web Component by redeploying it with updated HTML, JavaScript, or CSS. Provide only the files you want to update — any files omitted will use empty placeholders (so you should provide all files you want to keep). The component is redeployed via the Metadata API.

sf_create_lwc_jest_testA

Creates a Jest test file for an existing LWC component using @salesforce/lwc-jest conventions. The test file is placed in the tests subfolder of the component bundle and deployed via the Metadata API.

componentName: LWC component name in camelCase, e.g. 'myButton' testContent: Jest test file content (JavaScript) apiVersion: Salesforce API version

sf_guide_lwc_accessibilityA

Returns guidance and a checklist for LWC accessibility best practices covering ARIA attributes, keyboard navigation, focus management, and screen reader support. A read-only advisory tool — does not modify the org.

componentName: optional component name for context checklistOnly: return only the checklist items without detailed guidance

sf_migrate_aura_to_lwcA

Analyzes an Aura component and returns a comprehensive migration guide with Aura-to-LWC concept mappings, key differences, and an optional LWC scaffold. A read-only advisory tool — does not modify the org.

auraComponentName: the Aura component name to analyze includeScaffold: whether to generate equivalent LWC template, JS, CSS, and meta files

sf_create_lwc_from_requirementsA

Generates a complete LWC component scaffold (HTML template, JS controller, CSS, and meta XML) from a plain-English requirements description. Returns the generated code for review before deploying with sf_create_lwc.

componentName: LWC component name in camelCase requirements: plain-English description of what the component should do includeWireAdapters: include @wire adapter examples for data fetching targetObject: optional Salesforce object to bind to

sf_explore_slds_blueprintsA

Returns Salesforce Lightning Design System (SLDS) component examples, best practices, and usage guidance for a given UI pattern. A read-only reference tool — does not modify the org.

componentType: SLDS component type, e.g. 'data-table', 'modal', 'combobox' includeExampleCode: whether to include example LWC code snippets

sf_create_experience_siteA

Creates an Experience Cloud site (formerly Community) using a specified template. Supported templates: CustomerService (B2C self-service), Partner (B2B partner portal), LWR (Lightning Web Runtime — high performance), Aloha (App Launcher), Microsites (standalone pages). The urlPathPrefix appears in the site URL (e.g., 'customers' → org.force.com/customers). Site starts in UnderConstruction status by default.

sf_create_experience_pageA

Creates a page within an existing Experience Cloud site. Pages can be standard (home, login, profile, object detail, object list) or custom. The page URL path is relative to the site's URL prefix. Use after creating the site to add additional pages for different content sections.

sf_create_agentA

Creates an Agentforce Agent (Einstein Copilot) shell in Salesforce. THIS IS STEP 1 OF A 5-STEP SEQUENCE — calling this tool alone produces a non-functional agent shell. You MUST continue calling tools in this exact order without stopping: (0) FIRST create the backing flows (sf_create_flow, flowType=AutoLaunchedFlow, status=Active) and/or Apex classes (sf_create_apex_class with @InvocableMethod) for each capability. (1) THIS TOOL — sf_create_agent. (2) sf_create_agent_action — one call per flow/apex. (3) sf_create_agent_topic — group actions into topics; pass all action API names in the 'actions' array. (4) sf_create_agent_planner — wire topics to the agent. DO NOT report completion to the user until sf_create_agent_planner succeeds. Do not ask the user for confirmation between steps — proceed through all steps autonomously.

sf_create_agent_topicA

Creates a Topic (GenAiPlugin) for an Agentforce Agent — step 3 of the agent setup sequence. Call this AFTER all actions have been created with sf_create_agent_action. CRITICAL: pass ALL action API names in the 'actions' array — omitting it creates a topic with no executable actions and the agent silently does nothing. agentName is informational only (not written to XML) — the actual agent→topic wiring happens in sf_create_agent_planner which you MUST call immediately after this step. Do not stop between steps.

sf_create_agent_plannerA

Creates a GenAiPlanner that connects an Agentforce Agent (Bot) to its Topics — STEP 4 (FINAL) of the agent setup sequence. Without this step the agent cannot route ANY request regardless of how many topics and actions were created. Also known as: linking topics to agent, connecting topics, finishing agent setup, wiring topics, registering topics. CRITICAL: topicNames must be the COMPLETE list of all topics — this REPLACES any existing planner, so omitting a topic removes it from the agent. When adding a new topic to an existing agent, include ALL previous topic names plus the new one. Only AFTER this step succeeds should you report completion to the user.

sf_create_agent_actionA

Creates an Agentforce Action (GenAiFunction) — step 2 of the agent setup sequence. Call this once per capability (once per flow, once per Apex class). IMPORTANT by type: For Flow — the flow must already exist as an Active AutoLaunchedFlow (use sf_create_flow with flowType='AutoLaunchedFlow' and status='Active' first). For ApexClass — the class must already exist AND have @InvocableMethod (use sf_create_apex_class first). The 'reference' is the exact API name of the flow or class. After ALL actions are created, call sf_create_agent_topic (passing all action API names in 'actions' array), then sf_create_agent_planner. Do not stop between steps.

sf_create_outbound_change_setA

Creates an Outbound Change Set in the org — a container for metadata components that can be deployed to connected orgs (sandbox → production). Optionally adds specified components immediately. Returns the change set ID and a link to view it in Setup. Use this before deploying to production when using the change set deployment model.

sf_add_to_change_setA

Adds one or more metadata components to an existing Outbound Change Set by change set name. Supports all metadata types: CustomObject, CustomField, ApexClass, ApexTrigger, Flow, ValidationRule, PermissionSet, etc. Use after creating a change set to add the metadata you want to deploy.

sf_deploy_metadataA

Deploys a set of metadata components directly to the org using the Metadata API SOAP deploy operation. Builds a package.xml and deployment zip in memory. Supports validate-only (checkOnly:true) for pre-deployment validation without making changes. Specify runTests to execute test classes during deployment (required for production). Polls until complete or timeout.

sf_check_deploy_statusA

Checks the status of an in-progress or recently completed metadata deployment by async job ID. Returns the status (Pending, InProgress, Succeeded, Failed, Canceled), component successes, failures, and test results. Use with the deploy ID returned from sf_deploy_metadata.

sf_retrieve_metadataA

Retrieves metadata components from the org and returns their actual file contents. Use this to read existing configuration before making changes, to back up metadata, or to check what is really deployed rather than what you think is deployed. Waits for the async retrieve to finish and unpacks the resulting zip, returning each file's path and source. Large files are truncated.

sf_create_mcp_serverA

Generates a complete, working MCP server project structure on disk targeting a Salesforce org. Creates package.json, tsconfig.json, src/index.ts entry point, .env.example, and README.md. The generated server uses the MCP SDK and includes a sample 'hello_world' tool. Provide an outputDirectory (absolute path) where the files will be written. After generation, run 'npm install' then 'npm run build' in that directory.

sf_create_mcp_toolA

Adds a new tool definition to an existing MCP server project by reading the src/index.ts file and appending the tool registration. Provide the tool name, description, input schema as a JSON object (field names to {type, description}), and handler code. The tool code is inserted before the 'Start server' section. Run 'npm run build' after adding tools.

sf_list_mcp_toolsA

Lists all tools currently registered in a given MCP server project by reading and parsing its src/index.ts file. Returns the tool names in the order they are registered. Use to audit what tools exist before adding new ones.

sf_create_connected_appA

Creates a Connected App in Salesforce to enable OAuth authentication for external applications. Connected Apps are required for any external system that wants to connect to Salesforce via OAuth 2.0. Specify callback URLs for the OAuth flow, OAuth scopes (api, web, full, offline_access, etc.), and contact email. Used for web apps, mobile apps, desktop apps, or server-to-server integrations.

sf_create_external_data_sourceA

Creates an External Data Source for Salesforce Connect, enabling read-write access to data stored outside Salesforce without importing it. Supports OData 2.0/4.0 for standard REST services, SimpleURL for basic access, Apex for custom adapters. The external data then appears as External Objects (__x) in Salesforce.

sf_create_external_objectA

Creates an External Object (ending in __x) linked to an External Data Source. External Objects look like regular Salesforce objects but their data lives in an external system. They support lookups from standard/custom objects, appear in related lists, and can be used in reports. Requires an existing External Data Source.

sf_create_remote_site_settingA

Creates a Remote Site Setting to allow an external URL for Apex callouts. Salesforce blocks outbound HTTP calls by default — adding a Remote Site Setting allows Apex code to call that URL. Required for any external API callout from Apex or Flows. Use with sf_create_named_credential for authenticated callouts.

sf_create_csp_settingA

Creates a Content Security Policy trusted site, allowing LWC components and Visualforce pages to load resources from external URLs. CSP settings are needed when your LWC uses external JavaScript libraries, fonts, images, or APIs. Specify which directives (connect-src, script-src, style-src, img-src, etc.) the URL is trusted for.

sf_create_reportA

Creates a Salesforce Report using the Report metadata type. Supports Tabular, Summary, Matrix, and Joined formats. Specify the report type (e.g., Accounts, Opportunities), columns to display, and optional filters. Reports are created in the specified folder or your personal folder by default.

sf_update_dashboardB

Updates an existing Dashboard's title or description by reading the current configuration from the org and applying changes. The dashboard must already exist. For structural changes (adding/removing components), use sf_create_dashboard to create a new version.

sf_create_report_folderA

Creates a folder for organizing Reports or Dashboards. Folder access types: Hidden (only owner), Shared (explicit sharing), Public (all users). After creating, use sf_share_report_folder to grant access to specific users, roles, or groups.

sf_share_report_folderA

Shares a Report or Dashboard folder with users, roles, groups, or territories. Sets access levels (View, Edit, Manage) per share recipient. Use after creating a folder to grant team members access.

sf_create_userA

Creates a new Salesforce user via the REST API. Requires username (must be unique and email-like), lastName, email, and profileName. The profile must already exist. Optionally assign a role by roleApiName (DeveloperName of the UserRole). The user will receive a welcome email unless email confirmations are suppressed in org settings.

sf_update_userA

Updates an existing Salesforce user's properties via the REST API. Look up the user by username and update fields like firstName, lastName, email, title, department, phone, or isActive (to deactivate/reactivate). Only fields you provide are updated.

sf_assign_queue_memberA

Adds a user to an existing Queue (GroupMember SObject) by username and queue DeveloperName. The queue must already exist (create via sf_create_queue). Users in queues can be assigned records and receive queue notification emails.

sf_create_public_groupA

Creates a Public Group (Group SObject with Type=Regular) for sharing rules, email distribution, or queue membership. Public groups can include users, roles, and other groups. Use as a sharing target in sf_create_sharing_rule.

sf_query_recordsA

Executes a SOQL query against the org and returns matching records. Provide the full SOQL string in the query param. Use for reading data, checking existing records before creating, or verifying changes.

Supports aggregate queries — GROUP BY with COUNT(), SUM(), AVG(), MAX(), MIN(), e.g.: 'SELECT StageName, COUNT(Id), SUM(Amount) FROM Opportunity GROUP BY StageName' Aggregate results come back as regular records with the aggregate expressions as field keys (e.g. "expr0").

sf_describe_objectA

Retrieves schema metadata for a Salesforce object via the REST Describe API: fields (name, label, type, required, picklist values, length, references), child relationships, and record type info. Call this before querying or creating records on an unfamiliar object, or when a user asks what fields exist on an object.

objectApiName: SObject API name, e.g. 'Account', 'My_Object__c' fieldsOnly: set true for a smaller/faster response with just the field list, omitting child relationships and record types

sf_create_recordA

Creates a single SObject record via the Salesforce REST API. Provide the object API name and a fields object with field API names and values. For bulk creation (100+ records), use sf_bulk_import_records instead.

sf_update_recordA

Updates an existing SObject record by record ID via the Salesforce REST API. Provide the object API name, the 15 or 18 character record ID, and the fields to update. Only provided fields are changed — omitted fields retain their current values.

sf_bulk_import_recordsB

Bulk imports records using the Salesforce Bulk API 2.0. Supports insert, upsert, update, and delete operations on large datasets (thousands to millions of records). Provide CSV data with a header row. For upsert, set externalIdField to the field used for matching. Polls until the job completes and returns success/failure counts.

sf_delete_recordA

Deletes a single SObject record by record ID via the Salesforce REST API. The deletion is permanent and cannot be undone (the record goes to the Recycle Bin for objects that support it, from where it can be undeleted within 15 days).

Provide the object API name and the 15 or 18 character record ID. For bulk deletions (100+ records), use sf_bulk_import_records with operation='delete'.

Prompts

Interactive templates invoked by user choice

NameDescription

No prompts

Resources

Contextual data attached and managed by the client

NameDescription

No resources

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/semwalajay83-sem/salesforce-metadata-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server