Daigo | 2023-03-03 05:05:06 UTC | #1
I am fetching chat transcripts from the recording API api/v2/conversations/{conversationId}/recordings and would like to understand who the senders are for each messages. Most messages have the field fromUser and fromExternalContact which I assume are from an agent and a customer, respectively. The problem is with messages that don't have those fields. How can I tell who they're from? Will they always be from bots?
Ebenezer_Osei | 2023-03-10 16:33:04 UTC | #2
Hi,
For v2 chats, you can take advantage of the participantPurpose field which should state if that message's origin is customer, agent, acd, etc. For v1, here is an explanation from one of the engineers:
"The logic we use for v1 chat playback in the UI is that the message is from a customer if the message.from includes "@guest" or "@conference.guest", and is from an agent if the message.from includes "orgspan.com", and is from a system both if the message.from is "System". The UI just displays the message.fromUser in all other cases, and the downloaded chat recording just returns the participant as "Unknown" in those cases So these steps may help determine some cases for messages that don't have this field set, but in other cases I'm not sure if it's necessarily guaranteed that they are from bots or not"
Best
system | 2023-04-10 16:33:15 UTC | #3
This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.
This post was migrated from the old Developer Forum.
ref: 18698