UserMessage

ユーザーがエージェントに送信したメッセージ。

UserMessage は、エージェントが Google Pub/Sub サブスクリプションから受信する「message」オブジェクトの「data」フィールドに表示されます。「data」フィールドは、エージェントが UserMessage 構造と一致するようにデコードする必要がある base64 でエンコードされた文字列です。

JSON 表現
{
  "senderPhoneNumber": string,
  "messageId": string,
  "sendTime": string,
  "agentId": string,

  // Union field content can be only one of the following:
  "text": string,
  "userFile": {
    object (UserFile)
  },
  "location": {
    object (LatLng)
  },
  "suggestionResponse": {
    object (SuggestionResponse)
  }
  // End of list of possible types for union field content.
}
フィールド
senderPhoneNumber

string

メッセージを送信したユーザーの電話番号(E.164 形式)。

messageId

string

送信ユーザーの RCS クライアントによって割り当てられた一意のメッセージ ID。

sendTime

string (Timestamp format)

メッセージが送信された時刻。

RFC 3339 を使用します。生成された出力は常に Z 正規化され、小数点以下は 0、3、6、または 9 桁になります。「Z」以外のオフセットも使用できます。例: "2014-10-02T15:01:23Z""2014-10-02T15:01:23.045123456Z""2014-10-02T15:01:23+05:30"

agentId

string

エージェントの一意の識別子。RCS for Business によって設定されます。

共用体フィールド content。メッセージ content の内容は次のいずれかになります。
text

string

テキスト。具体的には、ユーザーが手入力した文字列であり、返信候補ではありません。

userFile

object (UserFile)

メディア ファイル。

location

object (LatLng)

位置情報] をタップします。 これは必ずしもユーザーの現在地ではありません。ユーザーは任意の位置情報をエージェントに送信できます。

suggestionResponse

object (SuggestionResponse)

ユーザーが返信候補またはアクションをタップして生成されたレスポンス。