QM 通話工作階段事件資料

本頁面說明 Contact Center AI Platform (CCAI Platform) 可匯出至品質管理 (QM) 應用程式的通話工作階段事件資料。如要進一步瞭解如何將 CCAI Platform 與 QM 應用程式整合,請參閱「QM 和 SIPREC 整合」。

如要瞭解即時通訊工作階段事件資料,請參閱「QM 即時通訊工作階段事件資料」。

呼叫工作階段事件和觸發條件

特定通話工作階段事件會觸發通話工作階段資料匯出至 QM 應用程式。本節列出通話事件類型,以及觸發各類型的動作。此外,每個工作階段事件類型也包含工作階段事件酬載範例。

客服人員登入

下列動作會觸發這項事件:

  • 客服人員使用 Contact Center AI 平台入口網站登入客服人員介面卡。

  • 代理使用 CRM 登入代理轉接程式。

以下程式碼範例顯示事件酬載:

{
 "type" : "AgentState",
 "item" : {
  "ParticipantID" : "1234",
  "Email" : "some.email@domain.com",
  "State" : "login"
 }
}

服務專員登出

下列動作會觸發這項事件:

  • 服務專員使用 Contact Center AI 平台入口網站登出服務專員介面卡。

  • 代理使用 CRM 登出代理轉接程式。

以下程式碼範例顯示事件酬載:

{
 "type" : "AgentState",
 "item" : {
  "ParticipantID" : "1234",
  "Email" : "some.email@domain.com",
  "State" : "logout"
 }
}

預計來電

當使用者撥打電話給聯絡中心,且電話轉接給服務專員時,系統就會觸發這個事件。

只有在通話投影至 deltacast 時,才會觸發這項事件。多點傳播投影不會觸發事件。只有在串聯群組中,對呼叫進行的第一次 deltacast 投影會觸發事件。

這類事件包括透過轉接、重新導向和轉移收到的通話預測。

以下程式碼範例顯示事件酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "846802bf90d1",
  "State" : "ringing",
  "Direction" : "incoming",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,
  "Participants" :
  [
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "connected"
   },
   {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "ringing"
   }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

接聽來電

當服務專員接聽預測來電時,系統會觸發這項事件。

無論是 delta 投射或多播投射,只要通話由服務專員接聽,就會觸發這個事件。這項事件適用於透過通話轉接和轉移接聽的來電。

以下程式碼範例顯示事件酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "846802bf90d1",
  "State" : "connected",
  "Direction" : "incoming",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,
  "Participants" :
  [
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "connected"
   },
  {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "connected"
   }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

撥出的電話正在響鈴

下列動作會觸發這項事件:

  • 服務專員撥打新的外撥電話,使用者正在接聽電話。

  • 服務專員撥打新增參與者通話,且通話正在響鈴,等待第三方接聽。

以下程式碼範例顯示事件酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "e9dd62bb",
  "State" : "dialing",
  "Direction" : "outgoing",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,
  "Participants" :
  [
   {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "connected"
   },
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "connected"
   }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

外撥電話已接通

下列動作會觸發這項事件:

  • 使用者接聽撥出電話。

  • 第三方接聽新增通話。

以下程式碼範例顯示事件酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "e9dd62bb",
  "State" : "connected",
  "Direction" : "outgoing",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,
  "Participants" :
  [
   {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "connected"
   },
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "connected"
   }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

通話已保留

下列動作會觸發這項事件:

  • 服務專員將使用者設為暫緩執行。

  • 代理人將第三方設為保留。

以下程式碼範例顯示事件酬載:

 "type" : "CallState",
 "item" : {
  "CallID" : "846802bf90d1",
  "State" : "held",
  "Direction" : "incoming",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,
  "Participants" :
  [
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "held"
   },
  {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "connected"
   }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

通話已從保留狀態移除

下列動作會觸發這項事件:

  • 服務專員將使用者從保留狀態移除。

  • 服務專員將第三方從保留狀態中移除。

以下程式碼範例顯示事件酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "846802bf90d1",
  "State" : "connected",
  "Direction" : "incoming",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,
  "Participants" :
  [
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "connected"
   },
  {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "connected"
   }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

發起並接受冷轉接

下列動作會觸發這項事件:

  • 服務專員向另一位服務專員發起冷轉接通話,且轉接要求已獲准。

  • 服務專員向其他佇列發起冷轉接通話,且該佇列的服務專員接受轉接。

  • 服務專員主動邀請其他服務專員加入電話會議,而對方接受並加入電話會議。

以下程式碼範例顯示事件酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "846802bf90d1",
  "State" : "transferred",
  "Direction" : "incoming",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,
  "Participants" :
  [
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "connected"
   },
  {
    "ParticipantID" : "4321",
    "Type" : "agent",
    "State" : "connected"
   }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

發起並接受溫轉

下列動作會觸發這項事件:

  • 服務專員向其他服務專員發起熱轉接通話,且對方接受轉接。

  • 服務專員向其他佇列發起熱轉接通話,且該佇列的服務專員接受轉接。

  • 服務專員熱情邀請其他服務專員加入電話會議,而對方接受並加入電話會議。

以下程式碼範例顯示事件酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "846802bf90d1",
  "State" : "conferenced",
  "Direction" : "incoming",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,
  "Participants" :
  [
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "connected"
   },
  {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "connected"
  },
  {
    "ParticipantID" : "4321",
    "Type" : "agent",
    "State" : "connected"
   }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

服務專員退出電話會議

通話會議中的服務專員離開通話會議,但未結束會議時,就會觸發這個事件。

以下程式碼範例顯示事件酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "846802bf90d1",
  "State" : "participantDisconnect",
  "Direction" : "incoming",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,
  "Participants" :
  [
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "connected"
   },
  {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "disconnected"
  },
  {
    "ParticipantID" : "4321",
    "Type" : "agent",
    "State" : "connected"
   }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

通話已設為靜音

下列動作會觸發這項事件:

  • 服務專員將通話設為靜音。

  • 服務專員將通話中的其他參與者設為靜音。

這項事件適用於所有通話。

以下程式碼範例顯示事件酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "846802bf90d1",
  "State" : "connected",
  "Direction" : "incoming",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,\
  "Participants" :
  [
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "connected"
   },
  {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "muted"
  },
  {
    "ParticipantID" : "4321",
    "Type" : "agent",
    "State" : "muted"
   }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

通話已取消靜音

下列動作會觸發這項事件:

  • 服務專員取消通話靜音。

  • 服務專員取消通話中其他參與者的靜音。

這項事件適用於所有通話。

以下程式碼範例顯示事件酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "846802bf90d1",
  "State" : "connected",
  "Direction" : "incoming",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,
  "Participants" :
  [
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "connected"
   },
  {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "unmuted"
  },
  {
    "ParticipantID" : "4321",
    "Type" : "agent",
    "State" : "unmuted"
   }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

通話已編輯

當服務專員編輯通話內容時,系統會觸發這項事件。

以下程式碼範例顯示事件酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "846802bf90d1",
  "State" : "connected",
  "Direction" : "incoming",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,
  "Participants" :
  [
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "redacted"
   },
  {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "redacted"
  }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

通話未經過編輯

當服務專員取消通話內容的遮蓋時,就會觸發這項事件。

以下程式碼範例顯示事件酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "846802bf90d1",
  "State" : "connected",
  "Direction" : "incoming",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,
  "Participants" :
  [
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "unredacted"
   },
  {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "unredacted"
  }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

通話已結束

下列動作會觸發這項事件:

  • 使用者結束通話。

  • 服務專員結束通話。

這項事件適用於所有通話。

以下程式碼範例顯示來電事件的酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "846802bf90d1",
  "State" : "disconnected",
  "Direction" : "incoming",
  "Initiator" : "+123456789",
  "Queue_path_ids": "1/2/3",
  "Queue_path_names" : "support/orders/status",
  "Language" : "en",
  "Queue_uuid" : 3,
  "Recording_permitted" : true,
  "Participants" :
  [
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "disconnected"
   },
   {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "disconnected"
   }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

以下程式碼範例顯示撥出電話事件的酬載:

{
 "type" : "CallState",
 "item" : {
  "CallID" : "e9dd62bb",
  "State" : "disconnected",
  "Direction" : "outgoing",
  "Initiator" : "1234",
  "Participants" :
  [
   {
    "ParticipantID" : "1234",
    "Type" : "agent",
    "State" : "disconnected"
   },
   {
    "ParticipantID" : "+123456789",
    "Type" : "external",
    "State" : "disconnected"
   }
  ],
  "MediaID" : "208188811_124248155@67.231.1.110"
 }
}

通話工作階段事件欄位

下表說明 Contact Center AI Platform 匯出至 QM 應用程式的通話資料欄位。

一般欄位

欄位名稱 允許值 說明 效果
type
  • AgentState
  • CallState

整體 JSON 酬載的事件類型。

  • 代理程式相關事件的傳遞 AgentState。
  • 傳遞 CallState 以取得通話相關事件。

item

含有活動資訊的物件。

代理程式狀態欄位

欄位名稱 值 說明 行為

ParticipantID

服務專員 ID

適用於 item 物件。

Contact Center AI 平台系統中的服務專員 ID。

  • 在 Contact Center AI Platform 會議中繼資料的 agent_info 物件中,傳遞 ID 欄位的值。

Email

電子郵件地址

適用於 item 物件。

服務專員的電子郵件地址。

  • 在工作階段中繼資料的 agent_info 物件中,傳遞電子郵件欄位的值。

State

  • login
  • logout

適用於 item 物件。

事件發生時代理程式的狀態。

  • 代理商登入時會傳遞 login。
  • 代理登出時會傳遞 logout。

通話狀態欄位

欄位名稱 值 說明 行為

CallID

通話 ID

適用於 item 物件。

Contact Center AI Platform 系統中的通話工作階段 ID。

  • 在 Contact Center AI Platform 會議中繼資料中,傳遞主要物件的 ID 欄位值。

State

  • dialing
  • waiting
  • ringing
  • connected
  • redirected
  • deflected
  • transferred
  • conferenced
  • disconnected

適用於 item 物件。

通話工作階段的目前狀態。

  • 當代理人或使用者撥打的出站電話處於鈴響狀態時,會傳遞 dialing。
  • 通話排入佇列,準備轉接給服務專員時,會傳遞 waiting。
  • 當來電/轉接電話處於代理程式的投影狀態時,會傳遞 ringing。
  • 當代理或一般使用者連上電話會議時,會傳遞 connected。
  • 如果系統自動重新導向通話,且未將通話轉接給服務專員,則會顯示「通過」redirected。
  • 如果通話是從一位服務專員冷轉接給另一位,則會傳遞 transferred。
  • 當通話從一位服務專員溫和轉接給另一位時,會傳遞 conferenced。
  • 當代理程式或使用者離開電話會議時,系統會傳遞 disconnected。

Direction

  • incoming
  • outgoing

適用於 item 物件。

從聯絡中心角度來看,通話工作階段的方向。

  • 通話工作階段為撥入時,會傳遞 incoming。
  • 通話工作階段為撥出時,會傳遞 outgoing。

Initiator

  • 服務專員 ID
  • 虛擬服務專員 ID
  • 使用者的電話號碼

適用於 item 物件。

初始化通話狀態的當事人 ID。

  • 真人服務專員

    在工作階段中繼資料中,傳遞 agent_info 物件的 ID 欄位值。

  • 虛擬服務專員

    在工作階段中繼資料的參與者物件中,傳遞 virtual_agent_id 欄位的值。

  • 使用者專用

    傳遞使用者的電話號碼 (如有)。

    否則,請在工作階段中繼資料的 end_user 物件中傳遞 ID 欄位的值。

Queue_path_ids

佇列 ID 路徑

適用於 item 物件。

使用者在通話中與第一位服務專員通話前,所瀏覽的佇列路徑。

這個值是使用導覽佇列的佇列 ID 建構而成。

這項功能僅適用於接聽來電。

Queue_path_names

佇列名稱路徑

適用於 item 物件。

使用者在通話中與第一位服務專員通話前,所瀏覽的佇列路徑。

這個值是使用導覽佇列的佇列名稱建構而成。

這項功能僅適用於接聽來電。

Language

語言代碼

適用於 item 物件。

使用者所選語言的語言代碼。

這項功能僅適用於接聽來電。

Queue_uuid

佇列 ID

適用於 item 物件。

通話抵達佇列的 UUID。

這項功能僅適用於來電和轉接至佇列的通話。

Recording_permitted

一個布林值

適用於 item 物件。

指出是否允許錄製特定通話

  • 如果允許通話錄音,則會傳遞 true。
  • 如果系統不允許錄音,則會傳遞 false。

Custom_headers

自訂標頭

適用於 item 物件。

這個欄位用於傳遞自訂資料,例如 SIP 標頭

Participants

這個物件會巢狀內嵌在 item 物件中。

包含通話參與者資訊的物件。

ParticipantID

  • agent_id
  • virtual_agent_id
  • consumer_phoneNumber
  • thirdParty_phoneNumber

適用於 Participants 物件。

通話參與者的 ID。

  • 真人服務專員
  • 在 Contact Center AI Platform 工作階段中繼資料的 agent_info 物件中,傳遞 ID 欄位的值。

  • 虛擬服務專員
  • 在 Contact Center AI Platform 會議中繼資料的參與者物件中,傳遞 virtual_agent_id 欄位的值

  • 使用者專用
  • 傳遞使用者的電話號碼 (如有)。

    否則,系統會將 end_user object 中的 id 欄位值傳遞至 Contact Center AI Platform 會議中繼資料。

  • 第三方
  • 傳遞第三方電話號碼 (如有)。

    否則,會傳遞值:null。

Type

  • agent
  • external

適用於 Participants 物件。

通話參與者類型。

  • 如果通話參與者是 Contact Center AI 平台服務專員,則會傳遞 agent。
  • 如果通話參與者是使用者或第三方,則會傳遞 external。

State

  • dialing
  • ringing
  • connected
  • held
  • disconnected
  • callback
  • deflected
  • transferred
  • redacted
  • unredacted
  • muted
  • unmuted

適用於 Participants 物件。

參與者在電話會議中的目前狀態。

  • 當外撥電話區隔處於代理商、使用者或第三方鈴響狀態時,會傳遞 dialing。
  • 當轉接或來電的通話片段處於投影狀態時,會將 ringing 傳遞給服務專員。
  • 當服務專員、一般使用者或第三方連線至電話會議時,會傳遞 connected。
  • 當服務專員在電話會議中暫停通話時,系統會傳遞 held 給使用者或第三方。
  • 當代理程式、使用者或第三方離開電話會議時,會傳遞 disconnected。
  • 在代理程式、使用者或第三方通話區隔中啟用通話內容編輯功能時,傳遞 redacted
  • 在代理、使用者或第三方通話區隔中停用通話內容遮蓋功能時,會傳遞 unredacted
  • 代理設為靜音時,會傳遞 muted
  • 代理人解除靜音時傳遞 unmuted

MediaID

  • twilio_mediaID
  • nexmo_mediaID

適用於 Participants 物件。

電信業者提供的通話工作階段媒體 ID。

  • 當發起者撥打或接聽 Twilio 號碼的電話時,會傳遞 twilio_mediaID
  • 當發起者撥打或接聽 Nexmo 號碼的電話時,會傳遞 nexmo_mediaID