Discussions
How to get the text that the avatar is speaking
In a recent question (https://docs.heygen.com/discuss/682ed16fea72c90053c11ff1), Gokce claims that we can listen for the AVATAR_TALKING_MESSAGE event to get the text. But I have listened for this event and logged the message object, and there does not appear to be any actual text. Here's what it looks like:
CustomEvent {isTrusted: false, detail: {…}, type: 'avatar_start_talking', target: EventTarget, currentTarget: EventTarget, …}
isTrusted:false
bubbles:false
cancelBubble:false
cancelable:false
composed:false
currentTarget:EventTarget
[[Prototype]]:EventTarget
defaultPrevented:false
detail:
task_id:"063cfff1-38ac-11f0-bce1-8ecfec24b150"
type:"avatar_start_talking"
[[Prototype]]:Object
eventPhase:0
returnValue:true
srcElement:EventTarget
[[Prototype]]:EventTarget
target:EventTarget
[[Prototype]]:EventTarget
timeStamp:108331.70000000298
type:"avatar_start_talking"
[[Prototype]]:CustomEvent
Please tell us where to find the actual text that the avatar is speaking, and update the documentation.
Thanks