TranscriptMessage class - Android

  • Release version: Australia
  • Updated July 21, 2026
  • 1 minute to read
  • Represents a single message in the voice session transcript.

    TranscriptMessages are passed to NowVoiceCallbacks - onMessageReceived().

    Table 1. Properties
    Name Type Description
    role Role The Role object identifies the originator of the message.
    Possible values:
    • Role.Assistant: The message originated from the voice agent.
    • Role.User: The message originated from the app user.
    content String The text content of the message.

    The following code example shows TranscriptMessage used with NowVoiceCallbacks.

    override fun onMessageReceived(message: TranscriptMessage) {
        runOnUiThread { appendTranscript(message) }
    }