diff --git a/AppsChat/metadata/Chat/V1/Message.php b/AppsChat/metadata/Chat/V1/Message.php index 55b315ee5a9f..d188d7201f67 100644 --- a/AppsChat/metadata/Chat/V1/Message.php +++ b/AppsChat/metadata/Chat/V1/Message.php @@ -30,7 +30,7 @@ public static function initOnce() { \GPBMetadata\Google\Protobuf\FieldMask::initOnce(); \GPBMetadata\Google\Protobuf\Timestamp::initOnce(); $pool->internalAddGeneratedFile( - "\x0A\xA2'\x0A\x1Cgoogle/chat/v1/message.proto\x12\x0Egoogle.chat.v1\x1A\x19google/api/resource.proto\x1A\x1Egoogle/apps/card/v1/card.proto\x1A\"google/chat/v1/action_status.proto\x1A\x1Fgoogle/chat/v1/annotation.proto\x1A\x1Fgoogle/chat/v1/attachment.proto\x1A%google/chat/v1/contextual_addon.proto\x1A&google/chat/v1/deletion_metadata.proto\x1A google/chat/v1/matched_url.proto\x1A\x1Dgoogle/chat/v1/reaction.proto\x1A\"google/chat/v1/slash_command.proto\x1A\x1Agoogle/chat/v1/space.proto\x1A\x19google/chat/v1/user.proto\x1A google/protobuf/field_mask.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"\xD4\x0A\x0A\x07Message\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12)\x0A\x06sender\x18\x02 \x01(\x0B2\x14.google.chat.v1.UserB\x03\xE0A\x03\x127\x0A\x0Bcreate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x06\xE0A\x05\xE0A\x01\x129\x0A\x10last_update_time\x18\x17 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bdelete_time\x18\x1A \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x11\x0A\x04text\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x1B\x0A\x0Eformatted_text\x18+ \x01(\x09B\x03\xE0A\x03\x12=\x0A\x05cards\x18\x05 \x03(\x0B2*.google.chat.v1.ContextualAddOnMarkup.CardB\x02\x18\x01\x121\x0A\x08cards_v2\x18\x16 \x03(\x0B2\x1A.google.chat.v1.CardWithIdB\x03\xE0A\x01\x124\x0A\x0Bannotations\x18\x0A \x03(\x0B2\x1A.google.chat.v1.AnnotationB\x03\xE0A\x03\x12&\x0A\x06thread\x18\x0B \x01(\x0B2\x16.google.chat.v1.Thread\x12)\x0A\x05space\x18\x0C \x01(\x0B2\x15.google.chat.v1.SpaceB\x03\xE0A\x03\x12\x1A\x0A\x0Dfallback_text\x18\x0D \x01(\x09B\x03\xE0A\x01\x12<\x0A\x0Faction_response\x18\x0E \x01(\x0B2\x1E.google.chat.v1.ActionResponseB\x03\xE0A\x04\x12\x1A\x0A\x0Dargument_text\x18\x0F \x01(\x09B\x03\xE0A\x03\x128\x0A\x0Dslash_command\x18\x11 \x01(\x0B2\x1C.google.chat.v1.SlashCommandB\x03\xE0A\x03\x123\x0A\x0Aattachment\x18\x12 \x03(\x0B2\x1A.google.chat.v1.AttachmentB\x03\xE0A\x01\x124\x0A\x0Bmatched_url\x18\x14 \x01(\x0B2\x1A.google.chat.v1.MatchedUrlB\x03\xE0A\x03\x12\x19\x0A\x0Cthread_reply\x18\x19 \x01(\x08B\x03\xE0A\x03\x12'\x0A\x1Aclient_assigned_message_id\x18 \x01(\x09B\x03\xE0A\x01\x12K\x0A\x18emoji_reaction_summaries\x18! \x03(\x0B2\$.google.chat.v1.EmojiReactionSummaryB\x03\xE0A\x03\x12<\x0A\x16private_message_viewer\x18\$ \x01(\x0B2\x14.google.chat.v1.UserB\x06\xE0A\x05\xE0A\x01\x12@\x0A\x11deletion_metadata\x18& \x01(\x0B2 .google.chat.v1.DeletionMetadataB\x03\xE0A\x03\x12K\x0A\x17quoted_message_metadata\x18' \x01(\x0B2%.google.chat.v1.QuotedMessageMetadataB\x03\xE0A\x01\x127\x0A\x0Dattached_gifs\x18* \x03(\x0B2\x1B.google.chat.v1.AttachedGifB\x03\xE0A\x03\x12?\x0A\x11accessory_widgets\x18, \x03(\x0B2\x1F.google.chat.v1.AccessoryWidgetB\x03\xE0A\x01:C\xEAA@\x0A\x1Bchat.googleapis.com/Message\x12!spaces/{space}/messages/{message}\"\x1F\x0A\x0BAttachedGif\x12\x10\x0A\x03uri\x18\x01 \x01(\x09B\x03\xE0A\x03\"\x98\x04\x0A\x15QuotedMessageMetadata\x121\x0A\x04name\x18\x01 \x01(\x09B#\xE0A\x02\xFAA\x1D\x0A\x1Bchat.googleapis.com/Message\x129\x0A\x10last_update_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x02\x12H\x0A\x0Aquote_type\x18\x04 \x01(\x0E2/.google.chat.v1.QuotedMessageMetadata.QuoteTypeB\x03\xE0A\x01\x12K\x0A\x17quoted_message_snapshot\x18\x05 \x01(\x0B2%.google.chat.v1.QuotedMessageSnapshotB\x03\xE0A\x03\x12B\x0A\x12forwarded_metadata\x18\x06 \x01(\x0B2!.google.chat.v1.ForwardedMetadataB\x03\xE0A\x03\"2\x0A\x09QuoteType\x12\x1A\x0A\x16QUOTE_TYPE_UNSPECIFIED\x10\x00\x12\x09\x0A\x05REPLY\x10\x01:\x81\x01\xEAA~\x0A)chat.googleapis.com/QuotedMessageMetadata\x12Qspaces/{space}/messages/{message}/quotedMessageMetadata/{quoted_message_metadata}\"\xC8\x01\x0A\x15QuotedMessageSnapshot\x12\x13\x0A\x06sender\x18\x01 \x01(\x09B\x03\xE0A\x03\x12\x11\x0A\x04text\x18\x02 \x01(\x09B\x03\xE0A\x03\x12\x1B\x0A\x0Eformatted_text\x18\x03 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bannotations\x18\x04 \x03(\x0B2\x1A.google.chat.v1.AnnotationB\x03\xE0A\x03\x124\x0A\x0Battachments\x18\x05 \x03(\x0B2\x1A.google.chat.v1.AttachmentB\x03\xE0A\x03\"f\x0A\x11ForwardedMetadata\x120\x0A\x05space\x18\x01 \x01(\x09B!\xE0A\x03\xFAA\x1B\x0A\x19chat.googleapis.com/Space\x12\x1F\x0A\x12space_display_name\x18\x02 \x01(\x09B\x03\xE0A\x03\"v\x0A\x06Thread\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12\x17\x0A\x0Athread_key\x18\x03 \x01(\x09B\x03\xE0A\x01:@\xEAA=\x0A\x1Achat.googleapis.com/Thread\x12\x1Fspaces/{space}/threads/{thread}\"\xD2\x04\x0A\x0EActionResponse\x12>\x0A\x04type\x18\x01 \x01(\x0E2+.google.chat.v1.ActionResponse.ResponseTypeB\x03\xE0A\x04\x12\x10\x0A\x03url\x18\x02 \x01(\x09B\x03\xE0A\x04\x128\x0A\x0Ddialog_action\x18\x03 \x01(\x0B2\x1C.google.chat.v1.DialogActionB\x03\xE0A\x04\x12I\x0A\x0Eupdated_widget\x18\x04 \x01(\x0B2,.google.chat.v1.ActionResponse.UpdatedWidgetB\x03\xE0A\x04\x1AR\x0A\x0ESelectionItems\x12@\x0A\x05items\x18\x01 \x03(\x0B21.google.apps.card.v1.SelectionInput.SelectionItem\x1Aw\x0A\x0DUpdatedWidget\x12D\x0A\x0Bsuggestions\x18\x01 \x01(\x0B2-.google.chat.v1.ActionResponse.SelectionItemsH\x00\x12\x0E\x0A\x06widget\x18\x02 \x01(\x09B\x10\x0A\x0Eupdated_widget\"\x9B\x01\x0A\x0CResponseType\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x0F\x0A\x0BNEW_MESSAGE\x10\x01\x12\x12\x0A\x0EUPDATE_MESSAGE\x10\x02\x12\x1D\x0A\x19UPDATE_USER_MESSAGE_CARDS\x10\x06\x12\x12\x0A\x0EREQUEST_CONFIG\x10\x03\x12\x0A\x0A\x06DIALOG\x10\x04\x12\x11\x0A\x0DUPDATE_WIDGET\x10\x07\"S\x0A\x0FAccessoryWidget\x126\x0A\x0Bbutton_list\x18\x01 \x01(\x0B2\x1F.google.apps.card.v1.ButtonListH\x00B\x08\x0A\x06action\"F\x0A\x11GetMessageRequest\x121\x0A\x04name\x18\x01 \x01(\x09B#\xE0A\x02\xFAA\x1D\x0A\x1Bchat.googleapis.com/Message\"]\x0A\x14DeleteMessageRequest\x121\x0A\x04name\x18\x01 \x01(\x09B#\xE0A\x02\xFAA\x1D\x0A\x1Bchat.googleapis.com/Message\x12\x12\x0A\x05force\x18\x02 \x01(\x08B\x03\xE0A\x01\"\x97\x01\x0A\x14UpdateMessageRequest\x12-\x0A\x07message\x18\x01 \x01(\x0B2\x17.google.chat.v1.MessageB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x1A\x0A\x0Dallow_missing\x18\x04 \x01(\x08B\x03\xE0A\x01\"\xA4\x03\x0A\x14CreateMessageRequest\x123\x0A\x06parent\x18\x01 \x01(\x09B#\xE0A\x02\xFAA\x1D\x12\x1Bchat.googleapis.com/Message\x12-\x0A\x07message\x18\x04 \x01(\x0B2\x17.google.chat.v1.MessageB\x03\xE0A\x02\x12\x19\x0A\x0Athread_key\x18\x06 \x01(\x09B\x05\x18\x01\xE0A\x01\x12\x17\x0A\x0Arequest_id\x18\x07 \x01(\x09B\x03\xE0A\x01\x12Z\x0A\x14message_reply_option\x18\x08 \x01(\x0E27.google.chat.v1.CreateMessageRequest.MessageReplyOptionB\x03\xE0A\x01\x12\x17\x0A\x0Amessage_id\x18\x09 \x01(\x09B\x03\xE0A\x01\"\x7F\x0A\x12MessageReplyOption\x12\$\x0A MESSAGE_REPLY_OPTION_UNSPECIFIED\x10\x00\x12(\x0A\$REPLY_MESSAGE_FALLBACK_TO_NEW_THREAD\x10\x01\x12\x19\x0A\x15REPLY_MESSAGE_OR_FAIL\x10\x02\"\xC2\x01\x0A\x13ListMessagesRequest\x123\x0A\x06parent\x18\x01 \x01(\x09B#\xE0A\x02\xFAA\x1D\x12\x1Bchat.googleapis.com/Message\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\x12\x19\x0A\x0Cshow_deleted\x18\x06 \x01(\x08B\x03\xE0A\x01\"Z\x0A\x14ListMessagesResponse\x12)\x0A\x08messages\x18\x01 \x03(\x0B2\x17.google.chat.v1.Message\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"\x81\x01\x0A\x0CDialogAction\x12-\x0A\x06dialog\x18\x01 \x01(\x0B2\x16.google.chat.v1.DialogB\x03\xE0A\x04H\x00\x128\x0A\x0Daction_status\x18\x02 \x01(\x0B2\x1C.google.chat.v1.ActionStatusB\x03\xE0A\x04B\x08\x0A\x06action\"6\x0A\x06Dialog\x12,\x0A\x04body\x18\x01 \x01(\x0B2\x19.google.apps.card.v1.CardB\x03\xE0A\x04\"F\x0A\x0ACardWithId\x12\x0F\x0A\x07card_id\x18\x01 \x01(\x09\x12'\x0A\x04card\x18\x02 \x01(\x0B2\x19.google.apps.card.v1.CardB\xA5\x01\x0A\x12com.google.chat.v1B\x0CMessageProtoP\x01Z,cloud.google.com/go/chat/apiv1/chatpb;chatpb\xA2\x02\x0BDYNAPIProto\xAA\x02\x13Google.Apps.Chat.V1\xCA\x02\x13Google\\Apps\\Chat\\V1\xEA\x02\x16Google::Apps::Chat::V1b\x06proto3" + "\x0A\x90*\x0A\x1Cgoogle/chat/v1/message.proto\x12\x0Egoogle.chat.v1\x1A\x19google/api/resource.proto\x1A\x1Egoogle/apps/card/v1/card.proto\x1A\"google/chat/v1/action_status.proto\x1A\x1Fgoogle/chat/v1/annotation.proto\x1A\x1Fgoogle/chat/v1/attachment.proto\x1A%google/chat/v1/contextual_addon.proto\x1A&google/chat/v1/deletion_metadata.proto\x1A google/chat/v1/matched_url.proto\x1A\x1Dgoogle/chat/v1/reaction.proto\x1A\"google/chat/v1/slash_command.proto\x1A\x1Agoogle/chat/v1/space.proto\x1A\x19google/chat/v1/user.proto\x1A google/protobuf/field_mask.proto\x1A\x1Fgoogle/protobuf/timestamp.proto\"\xE9\x0A\x0A\x07Message\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12)\x0A\x06sender\x18\x02 \x01(\x0B2\x14.google.chat.v1.UserB\x03\xE0A\x03\x127\x0A\x0Bcreate_time\x18\x03 \x01(\x0B2\x1A.google.protobuf.TimestampB\x06\xE0A\x05\xE0A\x01\x129\x0A\x10last_update_time\x18\x17 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x124\x0A\x0Bdelete_time\x18\x1A \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x03\x12\x11\x0A\x04text\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x1B\x0A\x0Eformatted_text\x18+ \x01(\x09B\x03\xE0A\x03\x12=\x0A\x05cards\x18\x05 \x03(\x0B2*.google.chat.v1.ContextualAddOnMarkup.CardB\x02\x18\x01\x121\x0A\x08cards_v2\x18\x16 \x03(\x0B2\x1A.google.chat.v1.CardWithIdB\x03\xE0A\x01\x124\x0A\x0Bannotations\x18\x0A \x03(\x0B2\x1A.google.chat.v1.AnnotationB\x03\xE0A\x03\x12&\x0A\x06thread\x18\x0B \x01(\x0B2\x16.google.chat.v1.Thread\x12)\x0A\x05space\x18\x0C \x01(\x0B2\x15.google.chat.v1.SpaceB\x03\xE0A\x03\x12\x1A\x0A\x0Dfallback_text\x18\x0D \x01(\x09B\x03\xE0A\x01\x12<\x0A\x0Faction_response\x18\x0E \x01(\x0B2\x1E.google.chat.v1.ActionResponseB\x03\xE0A\x04\x12\x1A\x0A\x0Dargument_text\x18\x0F \x01(\x09B\x03\xE0A\x03\x128\x0A\x0Dslash_command\x18\x11 \x01(\x0B2\x1C.google.chat.v1.SlashCommandB\x03\xE0A\x03\x123\x0A\x0Aattachment\x18\x12 \x03(\x0B2\x1A.google.chat.v1.AttachmentB\x03\xE0A\x01\x124\x0A\x0Bmatched_url\x18\x14 \x01(\x0B2\x1A.google.chat.v1.MatchedUrlB\x03\xE0A\x03\x12\x19\x0A\x0Cthread_reply\x18\x19 \x01(\x08B\x03\xE0A\x03\x12\x13\x0A\x06silent\x18. \x01(\x08B\x03\xE0A\x03\x12'\x0A\x1Aclient_assigned_message_id\x18 \x01(\x09B\x03\xE0A\x01\x12K\x0A\x18emoji_reaction_summaries\x18! \x03(\x0B2\$.google.chat.v1.EmojiReactionSummaryB\x03\xE0A\x03\x12<\x0A\x16private_message_viewer\x18\$ \x01(\x0B2\x14.google.chat.v1.UserB\x06\xE0A\x05\xE0A\x01\x12@\x0A\x11deletion_metadata\x18& \x01(\x0B2 .google.chat.v1.DeletionMetadataB\x03\xE0A\x03\x12K\x0A\x17quoted_message_metadata\x18' \x01(\x0B2%.google.chat.v1.QuotedMessageMetadataB\x03\xE0A\x01\x127\x0A\x0Dattached_gifs\x18* \x03(\x0B2\x1B.google.chat.v1.AttachedGifB\x03\xE0A\x03\x12?\x0A\x11accessory_widgets\x18, \x03(\x0B2\x1F.google.chat.v1.AccessoryWidgetB\x03\xE0A\x01:C\xEAA@\x0A\x1Bchat.googleapis.com/Message\x12!spaces/{space}/messages/{message}\"\x1F\x0A\x0BAttachedGif\x12\x10\x0A\x03uri\x18\x01 \x01(\x09B\x03\xE0A\x03\"\x98\x04\x0A\x15QuotedMessageMetadata\x121\x0A\x04name\x18\x01 \x01(\x09B#\xE0A\x02\xFAA\x1D\x0A\x1Bchat.googleapis.com/Message\x129\x0A\x10last_update_time\x18\x02 \x01(\x0B2\x1A.google.protobuf.TimestampB\x03\xE0A\x02\x12H\x0A\x0Aquote_type\x18\x04 \x01(\x0E2/.google.chat.v1.QuotedMessageMetadata.QuoteTypeB\x03\xE0A\x01\x12K\x0A\x17quoted_message_snapshot\x18\x05 \x01(\x0B2%.google.chat.v1.QuotedMessageSnapshotB\x03\xE0A\x03\x12B\x0A\x12forwarded_metadata\x18\x06 \x01(\x0B2!.google.chat.v1.ForwardedMetadataB\x03\xE0A\x03\"2\x0A\x09QuoteType\x12\x1A\x0A\x16QUOTE_TYPE_UNSPECIFIED\x10\x00\x12\x09\x0A\x05REPLY\x10\x01:\x81\x01\xEAA~\x0A)chat.googleapis.com/QuotedMessageMetadata\x12Qspaces/{space}/messages/{message}/quotedMessageMetadata/{quoted_message_metadata}\"\xC8\x01\x0A\x15QuotedMessageSnapshot\x12\x13\x0A\x06sender\x18\x01 \x01(\x09B\x03\xE0A\x03\x12\x11\x0A\x04text\x18\x02 \x01(\x09B\x03\xE0A\x03\x12\x1B\x0A\x0Eformatted_text\x18\x03 \x01(\x09B\x03\xE0A\x03\x124\x0A\x0Bannotations\x18\x04 \x03(\x0B2\x1A.google.chat.v1.AnnotationB\x03\xE0A\x03\x124\x0A\x0Battachments\x18\x05 \x03(\x0B2\x1A.google.chat.v1.AttachmentB\x03\xE0A\x03\"f\x0A\x11ForwardedMetadata\x120\x0A\x05space\x18\x01 \x01(\x09B!\xE0A\x03\xFAA\x1B\x0A\x19chat.googleapis.com/Space\x12\x1F\x0A\x12space_display_name\x18\x02 \x01(\x09B\x03\xE0A\x03\"v\x0A\x06Thread\x12\x11\x0A\x04name\x18\x01 \x01(\x09B\x03\xE0A\x08\x12\x17\x0A\x0Athread_key\x18\x03 \x01(\x09B\x03\xE0A\x01:@\xEAA=\x0A\x1Achat.googleapis.com/Thread\x12\x1Fspaces/{space}/threads/{thread}\"\xD2\x04\x0A\x0EActionResponse\x12>\x0A\x04type\x18\x01 \x01(\x0E2+.google.chat.v1.ActionResponse.ResponseTypeB\x03\xE0A\x04\x12\x10\x0A\x03url\x18\x02 \x01(\x09B\x03\xE0A\x04\x128\x0A\x0Ddialog_action\x18\x03 \x01(\x0B2\x1C.google.chat.v1.DialogActionB\x03\xE0A\x04\x12I\x0A\x0Eupdated_widget\x18\x04 \x01(\x0B2,.google.chat.v1.ActionResponse.UpdatedWidgetB\x03\xE0A\x04\x1AR\x0A\x0ESelectionItems\x12@\x0A\x05items\x18\x01 \x03(\x0B21.google.apps.card.v1.SelectionInput.SelectionItem\x1Aw\x0A\x0DUpdatedWidget\x12D\x0A\x0Bsuggestions\x18\x01 \x01(\x0B2-.google.chat.v1.ActionResponse.SelectionItemsH\x00\x12\x0E\x0A\x06widget\x18\x02 \x01(\x09B\x10\x0A\x0Eupdated_widget\"\x9B\x01\x0A\x0CResponseType\x12\x14\x0A\x10TYPE_UNSPECIFIED\x10\x00\x12\x0F\x0A\x0BNEW_MESSAGE\x10\x01\x12\x12\x0A\x0EUPDATE_MESSAGE\x10\x02\x12\x1D\x0A\x19UPDATE_USER_MESSAGE_CARDS\x10\x06\x12\x12\x0A\x0EREQUEST_CONFIG\x10\x03\x12\x0A\x0A\x06DIALOG\x10\x04\x12\x11\x0A\x0DUPDATE_WIDGET\x10\x07\"S\x0A\x0FAccessoryWidget\x126\x0A\x0Bbutton_list\x18\x01 \x01(\x0B2\x1F.google.apps.card.v1.ButtonListH\x00B\x08\x0A\x06action\"F\x0A\x11GetMessageRequest\x121\x0A\x04name\x18\x01 \x01(\x09B#\xE0A\x02\xFAA\x1D\x0A\x1Bchat.googleapis.com/Message\"]\x0A\x14DeleteMessageRequest\x121\x0A\x04name\x18\x01 \x01(\x09B#\xE0A\x02\xFAA\x1D\x0A\x1Bchat.googleapis.com/Message\x12\x12\x0A\x05force\x18\x02 \x01(\x08B\x03\xE0A\x01\"\x97\x01\x0A\x14UpdateMessageRequest\x12-\x0A\x07message\x18\x01 \x01(\x0B2\x17.google.chat.v1.MessageB\x03\xE0A\x02\x124\x0A\x0Bupdate_mask\x18\x02 \x01(\x0B2\x1A.google.protobuf.FieldMaskB\x03\xE0A\x02\x12\x1A\x0A\x0Dallow_missing\x18\x04 \x01(\x08B\x03\xE0A\x01\"\x88\x04\x0A\x14CreateMessageRequest\x123\x0A\x06parent\x18\x01 \x01(\x09B#\xE0A\x02\xFAA\x1D\x12\x1Bchat.googleapis.com/Message\x12-\x0A\x07message\x18\x04 \x01(\x0B2\x17.google.chat.v1.MessageB\x03\xE0A\x02\x12\x19\x0A\x0Athread_key\x18\x06 \x01(\x09B\x05\x18\x01\xE0A\x01\x12\x17\x0A\x0Arequest_id\x18\x07 \x01(\x09B\x03\xE0A\x01\x12Z\x0A\x14message_reply_option\x18\x08 \x01(\x0E27.google.chat.v1.CreateMessageRequest.MessageReplyOptionB\x03\xE0A\x01\x12\x17\x0A\x0Amessage_id\x18\x09 \x01(\x09B\x03\xE0A\x01\x12b\x0A#create_message_notification_options\x18\x0A \x01(\x0B20.google.chat.v1.CreateMessageNotificationOptionsB\x03\xE0A\x01\"\x7F\x0A\x12MessageReplyOption\x12\$\x0A MESSAGE_REPLY_OPTION_UNSPECIFIED\x10\x00\x12(\x0A\$REPLY_MESSAGE_FALLBACK_TO_NEW_THREAD\x10\x01\x12\x19\x0A\x15REPLY_MESSAGE_OR_FAIL\x10\x02\"\xF2\x01\x0A CreateMessageNotificationOptions\x12\\\x0A\x11notification_type\x18\x01 \x01(\x0E2A.google.chat.v1.CreateMessageNotificationOptions.NotificationType\"p\x0A\x10NotificationType\x12\x1A\x0A\x16NOTIFICATION_TYPE_NONE\x10\x00\x12\"\x0A\x1ENOTIFICATION_TYPE_FORCE_NOTIFY\x10\x02\x12\x1C\x0A\x18NOTIFICATION_TYPE_SILENT\x10\x03\"\xC2\x01\x0A\x13ListMessagesRequest\x123\x0A\x06parent\x18\x01 \x01(\x09B#\xE0A\x02\xFAA\x1D\x12\x1Bchat.googleapis.com/Message\x12\x16\x0A\x09page_size\x18\x02 \x01(\x05B\x03\xE0A\x01\x12\x17\x0A\x0Apage_token\x18\x03 \x01(\x09B\x03\xE0A\x01\x12\x13\x0A\x06filter\x18\x04 \x01(\x09B\x03\xE0A\x01\x12\x15\x0A\x08order_by\x18\x05 \x01(\x09B\x03\xE0A\x01\x12\x19\x0A\x0Cshow_deleted\x18\x06 \x01(\x08B\x03\xE0A\x01\"Z\x0A\x14ListMessagesResponse\x12)\x0A\x08messages\x18\x01 \x03(\x0B2\x17.google.chat.v1.Message\x12\x17\x0A\x0Fnext_page_token\x18\x02 \x01(\x09\"\x81\x01\x0A\x0CDialogAction\x12-\x0A\x06dialog\x18\x01 \x01(\x0B2\x16.google.chat.v1.DialogB\x03\xE0A\x04H\x00\x128\x0A\x0Daction_status\x18\x02 \x01(\x0B2\x1C.google.chat.v1.ActionStatusB\x03\xE0A\x04B\x08\x0A\x06action\"6\x0A\x06Dialog\x12,\x0A\x04body\x18\x01 \x01(\x0B2\x19.google.apps.card.v1.CardB\x03\xE0A\x04\"F\x0A\x0ACardWithId\x12\x0F\x0A\x07card_id\x18\x01 \x01(\x09\x12'\x0A\x04card\x18\x02 \x01(\x0B2\x19.google.apps.card.v1.CardB\xA5\x01\x0A\x12com.google.chat.v1B\x0CMessageProtoP\x01Z,cloud.google.com/go/chat/apiv1/chatpb;chatpb\xA2\x02\x0BDYNAPIProto\xAA\x02\x13Google.Apps.Chat.V1\xCA\x02\x13Google\\Apps\\Chat\\V1\xEA\x02\x16Google::Apps::Chat::V1b\x06proto3" , true); static::$is_initialized = true; diff --git a/AppsChat/src/Chat/V1/CreateMessageNotificationOptions.php b/AppsChat/src/Chat/V1/CreateMessageNotificationOptions.php new file mode 100644 index 000000000000..6b144c91c393 --- /dev/null +++ b/AppsChat/src/Chat/V1/CreateMessageNotificationOptions.php @@ -0,0 +1,67 @@ +google.chat.v1.CreateMessageNotificationOptions + */ +class CreateMessageNotificationOptions extends \Google\Protobuf\Internal\Message +{ + /** + * The notification type for the message. + * + * Generated from protobuf field .google.chat.v1.CreateMessageNotificationOptions.NotificationType notification_type = 1; + */ + protected $notification_type = 0; + + /** + * Constructor. + * + * @param array $data { + * Optional. Data for populating the Message object. + * + * @type int $notification_type + * The notification type for the message. + * } + */ + public function __construct($data = NULL) { + \GPBMetadata\Google\Chat\V1\Message::initOnce(); + parent::__construct($data); + } + + /** + * The notification type for the message. + * + * Generated from protobuf field .google.chat.v1.CreateMessageNotificationOptions.NotificationType notification_type = 1; + * @return int + */ + public function getNotificationType() + { + return $this->notification_type; + } + + /** + * The notification type for the message. + * + * Generated from protobuf field .google.chat.v1.CreateMessageNotificationOptions.NotificationType notification_type = 1; + * @param int $var + * @return $this + */ + public function setNotificationType($var) + { + GPBUtil::checkEnum($var, \Google\Apps\Chat\V1\CreateMessageNotificationOptions\NotificationType::class); + $this->notification_type = $var; + + return $this; + } + +} + diff --git a/AppsChat/src/Chat/V1/CreateMessageNotificationOptions/NotificationType.php b/AppsChat/src/Chat/V1/CreateMessageNotificationOptions/NotificationType.php new file mode 100644 index 000000000000..6b71e84da553 --- /dev/null +++ b/AppsChat/src/Chat/V1/CreateMessageNotificationOptions/NotificationType.php @@ -0,0 +1,72 @@ +google.chat.v1.CreateMessageNotificationOptions.NotificationType + */ +class NotificationType +{ + /** + * Default behavior. Notification behavior is similar to when the human user + * sends the message using the Chat UI: no notification is sent to the + * human sender. + * + * Generated from protobuf enum NOTIFICATION_TYPE_NONE = 0; + */ + const NOTIFICATION_TYPE_NONE = 0; + /** + * Force notify recipients. This bypasses users' space notification settings + * and [Chat Do Not Disturb + * settings](https://support.google.com/chat/answer/9093489). This option + * does not bypass device-level Do Not Disturb settings. + * Requires [app authentication] + * (https://developers.google.com/workspace/chat/authenticate-authorize-chat-app). + * + * Generated from protobuf enum NOTIFICATION_TYPE_FORCE_NOTIFY = 2; + */ + const NOTIFICATION_TYPE_FORCE_NOTIFY = 2; + /** + * Silence the notification as if the recipients have [Chat Do Not + * Disturb](https://support.google.com/chat/answer/9093489) enabled or + * have muted the space. + * Requires [app authentication] + * (https://developers.google.com/workspace/chat/authenticate-authorize-chat-app). + * + * Generated from protobuf enum NOTIFICATION_TYPE_SILENT = 3; + */ + const NOTIFICATION_TYPE_SILENT = 3; + + private static $valueToName = [ + self::NOTIFICATION_TYPE_NONE => 'NOTIFICATION_TYPE_NONE', + self::NOTIFICATION_TYPE_FORCE_NOTIFY => 'NOTIFICATION_TYPE_FORCE_NOTIFY', + self::NOTIFICATION_TYPE_SILENT => 'NOTIFICATION_TYPE_SILENT', + ]; + + public static function name($value) + { + if (!isset(self::$valueToName[$value])) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no name defined for value %s', __CLASS__, $value)); + } + return self::$valueToName[$value]; + } + + + public static function value($name) + { + $const = __CLASS__ . '::' . strtoupper($name); + if (!defined($const)) { + throw new UnexpectedValueException(sprintf( + 'Enum %s has no value defined for name %s', __CLASS__, $name)); + } + return constant($const); + } +} + diff --git a/AppsChat/src/Chat/V1/CreateMessageRequest.php b/AppsChat/src/Chat/V1/CreateMessageRequest.php index e540331e6e3d..3c9681463758 100644 --- a/AppsChat/src/Chat/V1/CreateMessageRequest.php +++ b/AppsChat/src/Chat/V1/CreateMessageRequest.php @@ -78,6 +78,14 @@ class CreateMessageRequest extends \Google\Protobuf\Internal\Message * Generated from protobuf field string message_id = 9 [(.google.api.field_behavior) = OPTIONAL]; */ protected $message_id = ''; + /** + * Optional. Controls the notification behavior when the message is posted. + * To learn more, see [Force notifications or send silent + * messages](https://developer.google.com/workspace/chat/create-messages#force-notify-silent). + * + * Generated from protobuf field .google.chat.v1.CreateMessageNotificationOptions create_message_notification_options = 10 [(.google.api.field_behavior) = OPTIONAL]; + */ + protected $create_message_notification_options = null; /** * @param string $parent Required. The resource name of the space in which to create a message. @@ -157,6 +165,10 @@ public static function build(string $parent, \Google\Apps\Chat\V1\Message $messa * different messages. * For details, see [Name a * message](https://developers.google.com/workspace/chat/create-messages#name_a_created_message). + * @type \Google\Apps\Chat\V1\CreateMessageNotificationOptions $create_message_notification_options + * Optional. Controls the notification behavior when the message is posted. + * To learn more, see [Force notifications or send silent + * messages](https://developer.google.com/workspace/chat/create-messages#force-notify-silent). * } */ public function __construct($data = NULL) { @@ -388,5 +400,45 @@ public function setMessageId($var) return $this; } + /** + * Optional. Controls the notification behavior when the message is posted. + * To learn more, see [Force notifications or send silent + * messages](https://developer.google.com/workspace/chat/create-messages#force-notify-silent). + * + * Generated from protobuf field .google.chat.v1.CreateMessageNotificationOptions create_message_notification_options = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @return \Google\Apps\Chat\V1\CreateMessageNotificationOptions|null + */ + public function getCreateMessageNotificationOptions() + { + return $this->create_message_notification_options; + } + + public function hasCreateMessageNotificationOptions() + { + return isset($this->create_message_notification_options); + } + + public function clearCreateMessageNotificationOptions() + { + unset($this->create_message_notification_options); + } + + /** + * Optional. Controls the notification behavior when the message is posted. + * To learn more, see [Force notifications or send silent + * messages](https://developer.google.com/workspace/chat/create-messages#force-notify-silent). + * + * Generated from protobuf field .google.chat.v1.CreateMessageNotificationOptions create_message_notification_options = 10 [(.google.api.field_behavior) = OPTIONAL]; + * @param \Google\Apps\Chat\V1\CreateMessageNotificationOptions $var + * @return $this + */ + public function setCreateMessageNotificationOptions($var) + { + GPBUtil::checkMessage($var, \Google\Apps\Chat\V1\CreateMessageNotificationOptions::class); + $this->create_message_notification_options = $var; + + return $this; + } + } diff --git a/AppsChat/src/Chat/V1/Message.php b/AppsChat/src/Chat/V1/Message.php index add652b081d3..9f8b51bd86e5 100644 --- a/AppsChat/src/Chat/V1/Message.php +++ b/AppsChat/src/Chat/V1/Message.php @@ -205,6 +205,13 @@ class Message extends \Google\Protobuf\Internal\Message * Generated from protobuf field bool thread_reply = 25 [(.google.api.field_behavior) = OUTPUT_ONLY]; */ protected $thread_reply = false; + /** + * Output only. Whether this is a silent message. Silent messages are messages + * where Chat suppresses push notifications for recipients. + * + * Generated from protobuf field bool silent = 46 [(.google.api.field_behavior) = OUTPUT_ONLY]; + */ + protected $silent = false; /** * Optional. A custom ID for the message. You can use field to identify a * message, or to get, delete, or update a message. To set a custom ID, @@ -395,6 +402,9 @@ class Message extends \Google\Protobuf\Internal\Message * either the first message of a thread or a message with no threaded replies. * If the space doesn't support reply in threads, this field is always * `false`. + * @type bool $silent + * Output only. Whether this is a silent message. Silent messages are messages + * where Chat suppresses push notifications for recipients. * @type string $client_assigned_message_id * Optional. A custom ID for the message. You can use field to identify a * message, or to get, delete, or update a message. To set a custom ID, @@ -1186,6 +1196,34 @@ public function setThreadReply($var) return $this; } + /** + * Output only. Whether this is a silent message. Silent messages are messages + * where Chat suppresses push notifications for recipients. + * + * Generated from protobuf field bool silent = 46 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @return bool + */ + public function getSilent() + { + return $this->silent; + } + + /** + * Output only. Whether this is a silent message. Silent messages are messages + * where Chat suppresses push notifications for recipients. + * + * Generated from protobuf field bool silent = 46 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * @param bool $var + * @return $this + */ + public function setSilent($var) + { + GPBUtil::checkBool($var); + $this->silent = $var; + + return $this; + } + /** * Optional. A custom ID for the message. You can use field to identify a * message, or to get, delete, or update a message. To set a custom ID, diff --git a/AppsChat/tests/Unit/V1/Client/ChatServiceClientTest.php b/AppsChat/tests/Unit/V1/Client/ChatServiceClientTest.php index d9da4bebf102..6f1ae3f42efc 100644 --- a/AppsChat/tests/Unit/V1/Client/ChatServiceClientTest.php +++ b/AppsChat/tests/Unit/V1/Client/ChatServiceClientTest.php @@ -351,6 +351,7 @@ public function createMessageTest() $fallbackText = 'fallbackText563106922'; $argumentText = 'argumentText-39826065'; $threadReply = false; + $silent = false; $clientAssignedMessageId = 'clientAssignedMessageId-1116632848'; $expectedResponse = new Message(); $expectedResponse->setName($name); @@ -359,6 +360,7 @@ public function createMessageTest() $expectedResponse->setFallbackText($fallbackText); $expectedResponse->setArgumentText($argumentText); $expectedResponse->setThreadReply($threadReply); + $expectedResponse->setSilent($silent); $expectedResponse->setClientAssignedMessageId($clientAssignedMessageId); $transport->addResponse($expectedResponse); // Mock request @@ -1393,6 +1395,7 @@ public function getMessageTest() $fallbackText = 'fallbackText563106922'; $argumentText = 'argumentText-39826065'; $threadReply = false; + $silent = false; $clientAssignedMessageId = 'clientAssignedMessageId-1116632848'; $expectedResponse = new Message(); $expectedResponse->setName($name2); @@ -1401,6 +1404,7 @@ public function getMessageTest() $expectedResponse->setFallbackText($fallbackText); $expectedResponse->setArgumentText($argumentText); $expectedResponse->setThreadReply($threadReply); + $expectedResponse->setSilent($silent); $expectedResponse->setClientAssignedMessageId($clientAssignedMessageId); $transport->addResponse($expectedResponse); // Mock request @@ -2726,6 +2730,7 @@ public function updateMessageTest() $fallbackText = 'fallbackText563106922'; $argumentText = 'argumentText-39826065'; $threadReply = false; + $silent = false; $clientAssignedMessageId = 'clientAssignedMessageId-1116632848'; $expectedResponse = new Message(); $expectedResponse->setName($name); @@ -2734,6 +2739,7 @@ public function updateMessageTest() $expectedResponse->setFallbackText($fallbackText); $expectedResponse->setArgumentText($argumentText); $expectedResponse->setThreadReply($threadReply); + $expectedResponse->setSilent($silent); $expectedResponse->setClientAssignedMessageId($clientAssignedMessageId); $transport->addResponse($expectedResponse); // Mock request