Bot
Represents a definition of an Einstein Bot configuration that can have one or more versions. Only one version can be active.
This type extends Metadata and inherits its fields.
Bot components have the suffix .bot and are stored in the bots folder.
Introduced in API version 43.0.
Bot is available only if Chat and Einstein Bots are enabled in your org.
Bot metadata deployment and retrieval are not supported for Lead Nurturing and Sales Coach Agents.
- Type: boolean
- Required: No
- Description: Reserved for internal use.
- Type: string
- Required: No
- Introduced: API version 64.0
- Description: If this Bot represents an agent, this field represents the name of the agent template used to create it.
- Type: GenAiAgentType
- Required: No
- Introduced: API version 64.0
- Description: Specifies the agent type for this agent. For example,
AgentforceServiceAgent.
- Type: LocalMlDomain
- Required: No
- Introduced: API version 44.0
- Description: Represents the Einstein intent set that groups intents, entities, and variables associated with a bot. All Einstein Bot versions under the same bot now share an intent set.
- Type: BotSourceType (enumeration of type string)
- Required: No
- Type: string
- Required: No
- Introduced: API version 46.0
- Description: Specifies the username of the user account, not the first and last name or the user ID.
- Type: BotVersion[]
- Required: No
- Description: Represents the configuration details for a specific Einstein Bots version, including dialogs, intents, entities, and variables.
- Type: ConversationContextVariable[]
- Required: No
- Description: Represents the context variables that enable your bot to gather customer information regardless of channel. Available in API 45.0 and later.
- Type: ConversationDefinitionChannelProvider[]
- Required: No
- Introduced: API version 51.0
- Description: Represents a list of the conversation channels linked to the bot.
- Type: string
- Required: No
- Introduced: API version 65.0
- Description: Specifies a fallback escalation behavior if the primary agent escalation behavior is not available. For example, Agentforce Service Agents can route conversations to human service reps.
- Type: string
- Required: No
- Description: A description of the bot.
- Type: string
- Required: No
- Description: Label that identifies the bot throughout the Salesforce user interface.
- Type: boolean
- Required: No
- Introduced: API version 48.0
- Description: Specifies whether to log customer inputs as part of conversation data (
true) or not (false).
- Type: PageContextVariable[]
- Required: No
- Introduced: API version 64.0
- Description: Provides page-level context variables for the bot.
- Type: boolean
- Required: No
- Type: int
- Required: No
- Introduced: API version 58.0
- Description: Represents the maximum amount of minutes that a bot session can be idle.
- Type: BotType (enumeration of type string)
- Required: No
- Description: Required. The default value is
Bot. This field represents the configuration type of the bot. - Possible values:
- Bot — Default Einstein Bot configuration.
- ExternalCopilot — An external-facing agent. For example, an Agentforce Service agent.
- InternalCopilot — An internal-facing agent. For example, an Agentforce Employee agent.
- Type: string
- Required: No
- Type: BotStep[]
- Required: No
- Type: string
- Required: No
- Description: A description of this component. The description should explain the component’s purpose and behavior so that administrators and developers understand when to use it.
- Type: string
- Required: Yes
- Description: The unique developer name of this component. Used as an API reference and must follow Salesforce identifier rules.
- Type: boolean
- Required: No
- Type: string
- Required: Yes
- Description: The label that identifies this component in the Salesforce UI and in metadata listings. Character limits and translation behavior follow the enclosing type.
- Type: string
- Required: No
- Type: boolean
- Required: No
- Type: boolean
- Required: No
A context variable local to the current bot version.
Introduced in API version 45.0.
- Type: ConversationContextVariableMapping[]
- Required: No
- Description: Represents the mapping between a context variable, channel type, and sObject field.
- Type: ConversationDataType (enumeration of type string)
- Required: Yes
- Description: Required. Represents the data type of the context variable.
- Possible values:
- Text
- Number
- Boolean
- Object
- Date
- DateTime
- Currency
- Id
- Type: string
- Required: No
- Introduced: API version 63.0
- Description: A description of this variable. This value may be used by the Agentforce planner service.
- Type: string
- Required: Yes
- Description: Required. Represents the name of the context variable. Can contain only underscores and alphanumeric characters and must be unique in your org. It must begin with a letter, not include spaces, not end with an underscore, and not contain two consecutive underscores.
- Type: boolean
- Required: No
- Introduced: API version 63.0
- Description: Indicates whether the variable is injected into the prompt sent to the Agentforce model. If
true, the variable appears in the Included Fields section of the UI.
The default variables Id , EndUserId , and EndUserLanguage always appear in the Included Fields section of the UI, regardless of their value of includeInPrompt . We recommend that you don’t change the value of includeInPrompt for these default variables, as changing the value can prevent your agent from accessing important session data.
- Type: string
- Required: Yes
- Description: Required. A label that identifies the context variable throughout the Salesforce user interface.
- Type: string (enumeration of type string)
- Required: No
- Description: Valid values are: BotDefinition Queue
- Possible values:
- BotDefinition
- Queue
Represents the mapping between a context variable, channel type, and sObject field.
- Type: string
- Required: Yes
- Description: Required. The API name of an SObject field to be used as part of the mapping.
- Type: MessageType (enumeration of type string)
- Required: Yes
- Introduced: API version 50.0
- Description: Required. Represents the message channel.
- Possible values:
- Alexa
- AppleBusinessChat — Messages sent in enhanced Apple Messages for Business channels.
- EmbeddedMessaging — Messages sent in Messaging for In-App and Web channels. Available in API version 50.0 and later.
- GoogleChat — Available in API version 68.0 and later.
- GoogleHome
- InternalCopilot
- Line
- MsCopilot
- Omega
- Phone
- PstnVoice
- Rcs
- SipVoice
- Slack — Available in API version 68.0 and later.
- Text
- VoiceIntegrationPilot
- WebChat
- WhatsAppVoice
- Type: string (enumeration of type string)
- Required: Yes
- Description: Required. SObject type for the field property defined as part of the mapping.
- Possible values:
- LiveChatTranscript
- MessagingEndUser
- MessagingSession
The developer name of a conversation channel linked to the bot. :::note To add, edit, or remove a messaging channel, you must use the UI. If you deploy a bot with messaging channel providers, those providers aren’t visible in Metadata API. :::
Introduced in API version 51.0.
To add, edit, or remove a messaging channel, you must use the UI. If you deploy a bot with messaging channel providers, those providers aren’t visible in Metadata API.
- Type: boolean
- Required: No
- Description: Specifies whether an agent must be online for the bot to be active (
true) or not (false) The default isfalse.
- Type: string
- Required: Yes
- Description: Required. The developer name of a LiveChatButton metadata component.
- Type: ConversationVariableCollectionType (enumeration of type string)
- Required: No
- Type: ConversationDataType (enumeration of type string)
- Required: Yes
- Type: string
- Required: No
- Description: A description of this component. The description should explain the component’s purpose and behavior so that administrators and developers understand when to use it.
- Type: string
- Required: Yes
- Description: The unique developer name of this component. Used as an API reference and must follow Salesforce identifier rules.
- Type: boolean
- Required: No
- Type: string
- Required: Yes
- Description: The label that identifies this component in the Salesforce UI and in metadata listings. Character limits and translation behavior follow the enclosing type.
- Type: string
- Required: No
- Type: ConversationVariableVisibilityType (enumeration of type string)
- Required: No
An Einstein Intent Set local to the current bot version.
- Type: string
- Required: Yes
- Description: Label that represents an Einstein Intent Set local to the current bot version throughout the Salesforce user interface.
- Type: MlIntent[]
- Required: No
- Description: List of intents associated with this local intent set.
- Type: MlSlotClass[]
- Required: No
- Description: List of entities associated with this local intent set.
- Type: string
- Required: Yes
- Description: Required. This unique name prevents conflicts with other local Einstein Intent Sets. This name can contain only underscores and alphanumeric characters and must be unique in your org. It must begin with a letter, not include spaces, not end with an underscore, and not contain two consecutive underscores.
A page-level context variable used by the bot.
Introduced in API version 64.0.
- Type: ConversationDataType (enumeration of type string)
- Required: Yes
- Description: Required. Represents the data type of the page context variable.
- Possible values:
- Text
- Number
- Boolean
- Object
- Date
- DateTime
- Currency
- Id
- Type: string
- Required: No
- Description: A description of the page context variable.
- Type: string
- Required: Yes
- Description: Required. Represents the unique API name of the page context variable. Can contain only underscores and alphanumeric characters and must be unique in your org. It must begin with a letter, not include spaces, not end with an underscore, and not contain two consecutive underscores.
- Type: string
- Required: Yes
- Description: Required. A label that identifies the page context variable throughout the Salesforce user interface.
- Type: string
- Required: No
- Description: Specifies the sObject type associated with this page context variable.
Represents a group of synonymous words or phrases.
- Type: Language (enumeration of type string)[]
- Required: No
- Type: string[]
- Required: No
This type extends Metadata and inherits its fields.
- Type: string
- Required: No
The following is an example of a Bot. This example has been trimmed to make it easier to read.
The following is an example package.xml that references the previous definition.
This metadata type supports the wildcard character * (asterisk) in the package.xml manifest file. For information about using the manifest file, see Deploying and Retrieving Metadata with the Zip File.