EmbeddedServiceLiveAgent

Represents a setup node for creating an embedded chat deployment.

Where possible, we changed noninclusive terms to align with our company value of Equality. We maintained certain terms to avoid any effect on customer implementations.

Important

Parent Type 

This type extends Metadata and inherits its fields.

File Suffix and Directory Location 

EmbeddedServiceLiveAgent components are stored in the developer_name.EmbeddedServiceLiveAgent file in the EmbeddedServiceLiveAgent folder.

Version 

Introduced in API version 38.0.

Fields 

avatarImg 

  • Type: string
  • Required: No
  • Description: Avatar image for this embedded chat deployment.

customPrechatComponent 

  • Type: string
  • Required: No
  • Description: The custom Lightning Component that’s used for the pre-chat page in this embedded chat deployment.

embeddedServiceConfig 

  • Type: string
  • Required: Yes
  • Description: Required. The name of the embedded service configuration node.

embeddedServiceQuickActions 

enabled 

  • Type: boolean
  • Required: Yes
  • Description: Required. Indicates whether this embedded chat deployment is enabled (true).

fontSize 

  • Type: EmbeddedServiceFontSize (enumeration of type string)
  • Required: Yes
  • Description: Required. The font size for the text in the embedded chat window. One of the following values:
  • Possible values:
    • Small
    • Medium
    • Large

headerBackgroundImg 

  • Type: string
  • Required: No
  • Version: Removed in API version 49.0.
  • Description: Header background image for this embedded chat window.

isOfflineCaseEnabled 

  • Type: boolean
  • Required: No
  • Introduced: API version 43.0
  • Description: Indicates whether offline support is enabled for this embedded chat deployment.

isQueuePositionEnabled 

  • Type: boolean
  • Required: No
  • Introduced: API version 43.0
  • Description: Indicates whether queue position (displaying the chat visitor’s place in line while they wait for an agent) is enabled for this embedded chat deployment.

liveAgentChatUrl 

  • Type: string
  • Required: No
  • Description: The rest endpoint for chats.

liveAgentContentUrl 

  • Type: string
  • Required: No
  • Description: The rest endpoint for cChat content.

liveChatButton 

  • Type: string
  • Required: Yes
  • Description: Required. Reference to a chat button created in Chat setup.

liveChatDeployment 

  • Type: string
  • Required: Yes
  • Description: Required. Reference to a deployment created in Chat setup.

masterLabel 

  • Type: string
  • Required: Yes
  • Description: Required. Name of the embedded chat deployment.

offlineCaseBackgroundImg 

  • Type: string
  • Required: No
  • Introduced: API version 43.0
  • Description: Offline support case form background image for this embedded chat window.

prechatBackgroundImg 

  • Type: string
  • Required: No
  • Description: Pre-chat background image for this embedded chat window.

prechatEnabled 

  • Type: boolean
  • Required: Yes
  • Description: Required. Indicates whether the embedded chat pre-chat form is enabled for this deployment.

prechatJson 

  • Type: string
  • Required: No
  • Description: JSON object of all the fields of the selected pre-chat form in Chat setup.

scenario 

  • Type: EmbeddedServiceScenario (enumeration of type string)
  • Required: Yes
  • Description: Required. The scenario for the embedded chat window that determines which objects to relate to the chat. One of the following values:
  • Possible values:
    • Sales
    • Service
    • Basic

smallCompanyLogoImg 

  • Type: string
  • Required: No
  • Description: Company logo image for this embedded chat window.

waitingStateBackgroundImg 

  • Type: string
  • Required: No
  • Description: Chat waiting image for this embedded chat window.

EmbeddedServiceQuickAction Type 

Returns a quick action that’s associated with an EmbeddedServiceLiveAgent setup. The quick action includes the pre-chat form fields that the embedded chat window displays and shows the order in which the fields are displayed.

Fields 

embeddedServiceLiveAgent 

  • Type: string
  • Required: Yes
  • Description: Reference to the embedded chat deployment.

order 

  • Type: int
  • Required: Yes
  • Description: Order in which this quick action appears in the embedded chat pre-chat form.

quickActionDefinition 

  • Type: string
  • Required: Yes
  • Description: Reference to a quick action.

quickActionType 

  • Type: EmbeddedServiceQuickActionType (enumeration of type string)
  • Required: No
  • Description: Quick action type. One of the following values: Available in API version 43.0 and later.
  • Possible values:
    • Prechat — Pre-chat
    • OfflineCase — Offline support (Cases)

Declarative Metadata Sample Definition 

The following is an example of an EmbeddedServiceLiveAgent file.

1<?xml version="1.0" encoding="UTF-8"?>
2<EmbeddedServiceLiveAgent xmlns="http://soap.sforce.com/2006/04/metadata">
3    <avatarImg>https://google.com/avatar.png</avatarImg>
4    <customPrechatComponent>auraCustomPrechat</customPrechatComponent>
5    <embeddedServiceConfig>EswConfig001</embeddedServiceConfig>
6    <embeddedServiceQuickActions>
7        <embeddedServiceLiveAgent>EmbeddedServiceLiveAgent_Parent04Ixx0000000001EAA_15ec5bd2971</embeddedServiceLiveAgent>
8        <order>1</order>
9        <quickActionDefinition>Snapins_Contact_QuickAction_08hRM000000001h</quickActionDefinition>
10    </embeddedServiceQuickActions>
11    <embeddedServiceQuickActions>
12        <embeddedServiceLiveAgent>EmbeddedServiceLiveAgent_Parent04Ixx0000000001EAA_15ec5bd2971</embeddedServiceLiveAgent>
13        <order>1</order>
14        <quickActionDefinition>Snapins_Case_OfflineCaseQuickAction_08hRM000000001h</quickActionDefinition>
15        <quickActionType>OfflineCase</quickActionType>
16    </embeddedServiceQuickActions>
17    <embeddedServiceQuickActions>
18        <embeddedServiceLiveAgent>EmbeddedServiceLiveAgent_Parent04Ixx0000000001EAA_15ec5bd2971</embeddedServiceLiveAgent>
19        <order>2</order>
20        <quickActionDefinition>Snapins_Case_QuickAction_08hRM000000001h</quickActionDefinition>
21    </embeddedServiceQuickActions>
22    <enabled>true</enabled>
23    <fontSize>Medium</fontSize>
24    <headerBackgroundImg>https://google.com/headerBackgroundImg.png</headerBackgroundIm>
25    <isOfflineCaseEnabled>true</isOfflineCaseEnabled>
26    <isQueuePositionEnabled>true</isQueuePositionEnabled>
27    <liveChatButton>chatButton01</liveChatButton>
28    <liveChatDeployment>liveAgentDeployment01</liveChatDeployment>
29    <masterLabel>EmbeddedServiceLiveAgent_Parent04Ixx0000000001EAA_15ec5bd2971</masterLabel>
30    <offlineCaseBackgroundImg>https://google.com/offlineCaseBackgroundImg.png</offlineCaseBackgroundImg>
31    <prechatBackgroundImg>https://google.com/prechatBackgroundImg.png</prechatBackgroundImg>
32    <prechatEnabled>true</prechatEnabled>
33    <scenario>Service</scenario>
34    <smallCompanyLogoImg>https://google.com/smallCompanyLogoImg.png</smallCompanyLogoImg>
35    <waitingStateBackgroundImg>https://google.com/waitingImage.png</waitingStateBackgroundImg>
36</EmbeddedServiceLiveAgent>

Usage 

EmbeddedServiceLiveAgent represents a Chat configuration that is added to your web page. The EmbeddedServiceLiveAgent record contains a unique combination of a chat button and the Chat deployment that the administrator selects during setup.

To create an EmbeddedServiceLiveAgent record:

  1. Create a Chat Deployment record.
  2. Create a Chat Button record.
  3. Create an EmbeddedServiceConfig record.
  4. Set the fields for the Chat Deployment record, Chat Button record, and EmbeddedServiceConfig record as references on the EmbeddedServiceLiveAgent record.

Any changes you make to the image fields override what you’ve entered in Setup. We recommend setting your image URLs in Setup.

Wildcard Support in the Manifest File 

This metadata type doesn’t support 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.