Message

Represents a message posted into a conversation.

JSON representation
{
  "name": string,
  "content": string,
  "languageCode": string,
  "participant": string,
  "participantRole": enum (Role),
  "createTime": string,
  "sendTime": string,
  "messageAnnotation": {
    object (MessageAnnotation)
  },
  "sentimentAnalysis": {
    object (SentimentAnalysisResult)
  }
}
Fields
name

string

Optional. The unique identifier of the message. Format: projects/<Project ID>/locations/<Location ID>/conversations/<Conversation ID>/messages/<Message ID>.

content

string

Required. The message content.

languageCode

string

Optional. The message language. This should be a BCP-47 language tag. Example: "en-US".

participant

string

Output only. The participant that sends this message.

participantRole

enum (Role)

Output only. The role of the participant.

createTime

string (Timestamp format)

Output only. The time when the message was created in Contact Center AI.

A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".

sendTime

string (Timestamp format)

Optional. The time when the message was sent.

A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".

messageAnnotation

object (MessageAnnotation)

Output only. The annotation for the message.

sentimentAnalysis

object (SentimentAnalysisResult)

Output only. The sentiment analysis result for the message.

MessageAnnotation

Represents the result of annotation for the message.

JSON representation
{
  "parts": [
    {
      object (AnnotatedMessagePart)
    }
  ],
  "containEntities": boolean
}
Fields
parts[]

object (AnnotatedMessagePart)

The collection of annotated message parts ordered by their position in the message. You can recover the annotated message by concatenating [AnnotatedMessagePart.text].

containEntities

boolean

Indicates whether the text message contains entities.

AnnotatedMessagePart

Represents a part of a message possibly annotated with an entity. The part can be an entity or purely a part of the message between two entities or message start/end.

JSON representation
{
  "text": string,
  "entityType": string,
  "formattedValue": value
}
Fields
text

string

A part of a message possibly annotated with an entity.

entityType

string

The Dialogflow system entity type of this message part. If this is empty, Dialogflow could not annotate the phrase part with a system entity.

formattedValue

value (Value format)

The Dialogflow system entity formatted value of this message part. For example for a system entity of type @sys.unit-currency, this may contain:

{
  "amount": 5,
  "currency": "USD"
}