Skip to main content
Glama
semwalajay83-sem

salesforce-metadata-mcp

Create Agentforce Agent

sf_create_agent
Idempotent

Starts the Agentforce agent creation sequence by provisioning an agent shell in Salesforce. The agent remains non-functional until subsequent steps attach actions, topics, and a planner.

Instructions

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.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
toneNoCommunication tone for agent responsesNeutral
labelYesAgent display label shown to users, e.g. 'Sales Assistant'
companyNoCompany name for the agent's context
personaNoAgent persona/role description, e.g. 'A knowledgeable sales expert who helps close deals'. Deployed as the BotVersion <role>.
agentNameYesAgent API name — letters and numbers only, NO underscores (Salesforce rejects underscores in Bot developer names). Max 40 chars. e.g. 'SalesAgent', 'SupportBot'. Used in all subsequent calls (sf_create_agent_topic, sf_create_agent_planner).
descriptionNoAgent description
plannerNameNoAPI name of the GenAiPlannerBundle to attach this agent to. Normally omitted on the first call (the planner does not exist yet) — after sf_create_agent_planner succeeds, call this tool again with the same agentName plus plannerName to complete the agent→planner link. This tool is idempotent, so re-running it updates the existing agent.
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

The description goes far beyond the annotations: it discloses that calling this tool alone produces a non-functional shell, that it is idempotent (re-running updates the agent), that plannerName is normally omitted on first call, and that Salesforce rejects underscores in Bot developer names. These are non-obvious behavioral traits that the annotations (readOnlyHint=false, idempotentHint=true) do not fully capture. No contradiction with annotations.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is longer than typical but every sentence carries critical information. The numbered sequence (0–4) is logically organized, and the warnings about not stopping or asking for confirmation are all necessary for correct execution. No fluff or redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Given the tool's complexity (7 params, part of a 5-step workflow, no output schema), the description covers the full workflow: prerequisites, exact order, dependencies between tools, idempotent re-run behavior, and the final completion condition. An agent has everything needed to execute the sequence correctly without additional queries.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Although the schema covers 100% of parameters, the description adds substantial semantic value: it clarifies agentName must have NO underscores (with max length), explains that persona is 'Deployed as the BotVersion <role>', and details the dual-purpose plannerName (omitted first, reused on second call to link the planner). This meaningfully enriches the schema definitions.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description clearly states the tool 'Creates an Agentforce Agent (Einstein Copilot) shell in Salesforce' and explicitly marks it as 'STEP 1 OF A 5-STEP SEQUENCE', distinguishing it from sibling tools like sf_create_agent_action, sf_create_agent_topic, and sf_create_agent_planner. The verb-resource-scope combination is specific and unambiguous.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides explicit step-by-step ordering (0–4), instructs the agent to create flows/Apex classes first, names the exact sibling tools to call next, and states when to stop ('DO NOT report completion until sf_create_agent_planner succeeds'). This is a model example of when-to-use and how-to-proceed guidance.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Install Server

Other Tools

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