Skip to end of metadata
Go to start of metadata

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

« Previous Version 2 Next »

Returns chat transcripts with the specified call data variables

HTTP POST /livechat/getChatTranscriptByCalldata

Request body:

Type: JSON

Name

Mandatory

Type

Description

<calldata_variable_name>

YES

STRING

Value of the call data variable for which you want to retrieve the chat transcripts

Response:

Type: JSON

Name

Type

Description

result

BOOLEAN

If true, the service response was performed correctly

chatTranscript

ARRAY

Array that contains chat transcripts with the specified nickname among the participants

error

NULL / STRING

Contains the error description if an error has occurred in the request

Example:

Request

http://<hostname>:<port>/livechat/getChatTranscriptByCalldata

Request body:

{
	"ECID" : "felixct7|1|22|15",
	"_CTHISTORY_1_Q_": "QUEUE42@acd.enghouse.com"
}

Response

{ 
   "result":true,
   "chatTranscripts":[ 
      { 
         "result":true,
         "transcript":{ 
            "messages":[ 
               { 
                  "data":{ 
                     "id":"551b9dbc-8de8-46a1-89c4-b617f9d7e98e",
                     "messageType":"TEXT",
                     "content":{ 
                        "text":"hello there",
                        "user":{ 
                           "id":"USER_c8e1eb84-60d3-4d69-b10b-96364845023e",
                           "isAgent":false
                        }
                     },
                     "ts":1569248228779
                  },
                  "_id":"5d88d3f91190da27f4fecee2",
                  "room":"CHAT_4910ea9a-0e43-4dea-9418-fb913cbf9a64"
               },
               { 
                  "data":{ 
                     "id":"e34246cf-e057-44e7-ba5b-45cd5be4c55f",
                     "messageType":"TEXT",
                     "content":{ 
                        "text":"hello",
                        "user":{ 
                           "id":"USER_gverde1@acd.enghouse.com",
                           "isAgent":true
                        }
                     },
                     "ts":1569248236845
                  },
                  "_id":"5d88d3f91190da27f4fecee1",
                  "room":"CHAT_4910ea9a-0e43-4dea-9418-fb913cbf9a64"
               },
               { 
                  "data":{ 
                     "id":"44c1c289-941a-4680-829f-9ea3757b7b78",
                     "messageType":"TEXT",
                     "content":{ 
                        "text":"bye",
                        "user":{ 
                           "id":"USER_c8e1eb84-60d3-4d69-b10b-96364845023e",
                           "isAgent":false
                        }
                     },
                     "ts":1569248242051
                  },
                  "_id":"5d88d3f91190da27f4fecee0",
                  "room":"CHAT_4910ea9a-0e43-4dea-9418-fb913cbf9a64"
               }
            ],
            "_id":"5d88d3f91190da27f4fecedf",
            "room":"CHAT_4910ea9a-0e43-4dea-9418-fb913cbf9a64",
            "__v":0
         }
      }
   ],
   "error":null
}

  • No labels