Configure external routing of Salesforce messaging

注意: 本文适用于适用于 Salesforce 的 Genesys 云。

必备
  • 外部路由 作为路由模型的 Salesforce 路由配置。
  • A Salesforce queue linked with the external routing configuration and the Messaging Session object assigned to the queue.

After you install and configure the Omni-Channel external routing package, create a flow in Salesforce to route a Salesforce messaging through Genesys Cloud. Genesys Cloud routes and delivers the message to the appropriate agent. The agent handles the message within Salesforce and can also transfer the message to another agent. Genesys Cloud for Salesforce handles the life cycle of the message within Genesys Cloud and creates an activity record in Salesforce to log all critical information.

创建流程

Salesforce 中的流程可自动执行路由过程。 您可以使用元素、连接器和资源来构建流程。 有关更多信息,请参阅 Salesforce 文档 中的 流程。

  1. 在 Salesforce 中,使用 全渠道流程(测试版)模板创建流程。 
    1. 设置中,在快速查找框中搜索流程,然后选择 流程
    2. 单击 “ 新建流程”
    3. 选择从头开始并点击下一个
    4. Under All Flow Types, select Omni-Channel Flow as the flow type and click Create.
    5. To add elements to the canvas, select Free-Form.
  2. 按照 Salesforce 文档中的说明创建 records IDinput_record 变量。
  3. 将 “ 路线工作 (测试版)” 操作拖动到工作区上,然后输入新操作的值。
    1. 为操作提供 标签API 名称以 及可选的 描述
    2. 在 “ 设置输入值” > “ RecordID” 下,选择您创建的 RecordID。
    3. Under Service Channel, select the channel created for Messaging.
    4. 在 “ 路由到” 下,选择 “ 队列”
    5. Under Queue, enter the Salesforce queue ID that you want to route through Genesys Cloud.
    6. 单击 “ 完成”
  4. 将 “ 创建记录” 操作拖动到工作区上,然后输入记录的详细信息。 This image is a screenshot of the create resource record in Salesforce Flow.
      1. 键入记录的名称。
      2. Select the option Manually to configure the record fields.
      3. 从列表中选择对象 “ 外部路由选择请求”。
      4. 添加 open_messaging_Integration__Cwork_item_ID__C 这两个字段, 然后设置这两个字段的值。
        • 开放式消息集成 — 选择从 Genesys Cloud 检索的选择列表值
        • Work Item ID – Select the recordId variable that you created for the messaging session object.
      5. Optionally, you can also add the field Custom_Attributes__c and the values in the format customAttribute1=customAttr1, customAttribute2=customAttr2. If you are adding any Salesforce objects, use the format customAttribute={!Object.Value}.
      6. 单击 “ 完成”
    Note: You can add or edit the external routing package message attributes in the OpenMessageService.apxc file except for the custom attribute, SF_ExternalRoutingWorkItemId. Ensure that you do not edit or remove the custom attribute, SF_ExternalRoutingWorkItemId. See Inbound open messages for more information about the API referenced by the routing package.
  5. 将 开始 元素连接到流程中的 “ 路线工作 (测试版) ” 操作元素。 
  6. Connect the Route Work action element to the Create Record element in the flow. This image is a screenshot of the Omno-Channel flow created in Salesforce flow builder.
  7. 单击 “ 保存”
  8. 单击 “ 激活”

激活请求删除流程

用于外部路由的程序包包括外部路由请求删除流程。 此流程会清理发生以下任一情况时创建的请求记录:

  • 已断开连接已成功路由并完成的工作项。
  • The user closes the message before it is routed to an agent.

在使用外部路由之前激活此流程。

  1. 在 Salesforce 设置中,搜索 流程
  2. 在流程列表中,单击 外部路由选择请求删除
  3. 单击 “ 激活”

Set up for Messaging for In-App and Web

Create a messaging channel for Messaging for In-App and Web and ensure that you select the following details for the messaging channel:

  • Select Omni-Queue as the Routing Type. Select the flow created to route a Salesforce messaging through Genesys Cloud.
  • Select the fallback queue created for Messaging for In-App and Web.This image is a screenshot of the messaging setting option in Salesforce.

Create Embedded Service Deployment

After creating the messaging channel, you can connect it to a website with a new embedded deployment:

  1. Enable Digital Experiences. See Enable Digital Experiences.
  2. Create a web deployment for the messaging session with your end user. Ensure to select the Messaging for In-App and Web option and the messaging channel. See Configure a Messaging for Web Deployment.
  3. Publish the web deployment. 
  4. Add your code snippet for embedding messaging on an external website.
  5. Add your domain to the CORS allowlist.
  6. Add the messaging console to your agent. See Add Messaging to the Service Console.

Create chat buttons (Legacy)

在 Salesforce 中创建 聊天按钮时,您可以 指定传入的聊天请求如何定向到座席。 在 Salesforce 聊天按钮设置中,在 “ 路由类型” 字段 中选择 “ 全渠道”,然后使用为路由特定队列而创建的 Omni-Channel 流程。

该图显示了在 Salesforce 中创建聊天按钮时选择的路由信息。

有关如何使用 Omni-Channel 同步设置的更多信息,请参阅 如何使用 Omni-Channel 同步

有关集成的更多信息,请参阅 关于适用于 Salesforce 的 Genesys Cloud