diff --git a/AppsChat/metadata/Chat/V1/Message.php b/AppsChat/metadata/Chat/V1/Message.php index 9c6f17aad0c3..02825f5f39b1 100644 Binary files a/AppsChat/metadata/Chat/V1/Message.php and b/AppsChat/metadata/Chat/V1/Message.php differ diff --git a/AppsChat/src/Chat/V1/Message.php b/AppsChat/src/Chat/V1/Message.php index 2a9ed327d956..7856cb5338ac 100644 --- a/AppsChat/src/Chat/V1/Message.php +++ b/AppsChat/src/Chat/V1/Message.php @@ -245,10 +245,16 @@ class Message extends \Google\Protobuf\Internal\Message */ protected $deletion_metadata = null; /** - * Output only. Information about a message that's quoted by a Google Chat - * user in a space. Google Chat users can quote a message to reply to it. + * Optional. Information about a message that another message quotes. + * When you create a message, you can quote messages within the same + * thread, or quote a root message to create a new root message. + * However, you can't quote a message reply from a different thread. + * When you update a message, you can't add or replace the + * `quotedMessageMetadata` field, but you can remove it. + * For example usage, see [Quote another + * message](https://developers.google.com/workspace/chat/create-messages#quote-a-message). * - * Generated from protobuf field .google.chat.v1.QuotedMessageMetadata quoted_message_metadata = 39 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * Generated from protobuf field .google.chat.v1.QuotedMessageMetadata quoted_message_metadata = 39 [(.google.api.field_behavior) = OPTIONAL]; */ protected $quoted_message_metadata = null; /** @@ -414,8 +420,14 @@ class Message extends \Google\Protobuf\Internal\Message * Output only. Information about a deleted message. A message is deleted when * `delete_time` is set. * @type \Google\Apps\Chat\V1\QuotedMessageMetadata $quoted_message_metadata - * Output only. Information about a message that's quoted by a Google Chat - * user in a space. Google Chat users can quote a message to reply to it. + * Optional. Information about a message that another message quotes. + * When you create a message, you can quote messages within the same + * thread, or quote a root message to create a new root message. + * However, you can't quote a message reply from a different thread. + * When you update a message, you can't add or replace the + * `quotedMessageMetadata` field, but you can remove it. + * For example usage, see [Quote another + * message](https://developers.google.com/workspace/chat/create-messages#quote-a-message). * @type array<\Google\Apps\Chat\V1\AttachedGif>|\Google\Protobuf\Internal\RepeatedField $attached_gifs * Output only. GIF images that are attached to the message. * @type array<\Google\Apps\Chat\V1\AccessoryWidget>|\Google\Protobuf\Internal\RepeatedField $accessory_widgets @@ -1331,10 +1343,16 @@ public function setDeletionMetadata($var) } /** - * Output only. Information about a message that's quoted by a Google Chat - * user in a space. Google Chat users can quote a message to reply to it. + * Optional. Information about a message that another message quotes. + * When you create a message, you can quote messages within the same + * thread, or quote a root message to create a new root message. + * However, you can't quote a message reply from a different thread. + * When you update a message, you can't add or replace the + * `quotedMessageMetadata` field, but you can remove it. + * For example usage, see [Quote another + * message](https://developers.google.com/workspace/chat/create-messages#quote-a-message). * - * Generated from protobuf field .google.chat.v1.QuotedMessageMetadata quoted_message_metadata = 39 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * Generated from protobuf field .google.chat.v1.QuotedMessageMetadata quoted_message_metadata = 39 [(.google.api.field_behavior) = OPTIONAL]; * @return \Google\Apps\Chat\V1\QuotedMessageMetadata|null */ public function getQuotedMessageMetadata() @@ -1353,10 +1371,16 @@ public function clearQuotedMessageMetadata() } /** - * Output only. Information about a message that's quoted by a Google Chat - * user in a space. Google Chat users can quote a message to reply to it. + * Optional. Information about a message that another message quotes. + * When you create a message, you can quote messages within the same + * thread, or quote a root message to create a new root message. + * However, you can't quote a message reply from a different thread. + * When you update a message, you can't add or replace the + * `quotedMessageMetadata` field, but you can remove it. + * For example usage, see [Quote another + * message](https://developers.google.com/workspace/chat/create-messages#quote-a-message). * - * Generated from protobuf field .google.chat.v1.QuotedMessageMetadata quoted_message_metadata = 39 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * Generated from protobuf field .google.chat.v1.QuotedMessageMetadata quoted_message_metadata = 39 [(.google.api.field_behavior) = OPTIONAL]; * @param \Google\Apps\Chat\V1\QuotedMessageMetadata $var * @return $this */ diff --git a/AppsChat/src/Chat/V1/QuotedMessageMetadata.php b/AppsChat/src/Chat/V1/QuotedMessageMetadata.php index 776a4ab987d7..e12bff01fb75 100644 --- a/AppsChat/src/Chat/V1/QuotedMessageMetadata.php +++ b/AppsChat/src/Chat/V1/QuotedMessageMetadata.php @@ -9,24 +9,35 @@ use Google\Protobuf\Internal\GPBUtil; /** - * Information about a quoted message. + * Information about a message that another message quotes. + * When you create a message, you can quote messages within the same + * thread, or quote a root message to create a new root message. + * However, you can't quote a message reply from a different thread. + * When you update a message, you can't add or replace the + * `quotedMessageMetadata` field, but you can remove it. + * For example usage, see [Quote another + * message](https://developers.google.com/workspace/chat/create-messages#quote-a-message). * * Generated from protobuf message google.chat.v1.QuotedMessageMetadata */ class QuotedMessageMetadata extends \Google\Protobuf\Internal\Message { /** - * Output only. Resource name of the quoted message. + * Required. Resource name of the message that is quoted. * Format: `spaces/{space}/messages/{message}` * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { */ protected $name = ''; /** - * Output only. The timestamp when the quoted message was created or when the + * Required. The timestamp when the quoted message was created or when the * quoted message was last updated. + * If the message was edited, use this field, `last_update_time`. + * If the message was never edited, use `create_time`. + * If `last_update_time` doesn't match the latest version of the quoted + * message, the request fails. * - * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 2 [(.google.api.field_behavior) = REQUIRED]; */ protected $last_update_time = null; @@ -37,11 +48,15 @@ class QuotedMessageMetadata extends \Google\Protobuf\Internal\Message * Optional. Data for populating the Message object. * * @type string $name - * Output only. Resource name of the quoted message. + * Required. Resource name of the message that is quoted. * Format: `spaces/{space}/messages/{message}` * @type \Google\Protobuf\Timestamp $last_update_time - * Output only. The timestamp when the quoted message was created or when the + * Required. The timestamp when the quoted message was created or when the * quoted message was last updated. + * If the message was edited, use this field, `last_update_time`. + * If the message was never edited, use `create_time`. + * If `last_update_time` doesn't match the latest version of the quoted + * message, the request fails. * } */ public function __construct($data = NULL) { @@ -50,10 +65,10 @@ public function __construct($data = NULL) { } /** - * Output only. Resource name of the quoted message. + * Required. Resource name of the message that is quoted. * Format: `spaces/{space}/messages/{message}` * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { * @return string */ public function getName() @@ -62,10 +77,10 @@ public function getName() } /** - * Output only. Resource name of the quoted message. + * Required. Resource name of the message that is quoted. * Format: `spaces/{space}/messages/{message}` * - * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { + * Generated from protobuf field string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { * @param string $var * @return $this */ @@ -78,10 +93,14 @@ public function setName($var) } /** - * Output only. The timestamp when the quoted message was created or when the + * Required. The timestamp when the quoted message was created or when the * quoted message was last updated. + * If the message was edited, use this field, `last_update_time`. + * If the message was never edited, use `create_time`. + * If `last_update_time` doesn't match the latest version of the quoted + * message, the request fails. * - * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 2 [(.google.api.field_behavior) = REQUIRED]; * @return \Google\Protobuf\Timestamp|null */ public function getLastUpdateTime() @@ -100,10 +119,14 @@ public function clearLastUpdateTime() } /** - * Output only. The timestamp when the quoted message was created or when the + * Required. The timestamp when the quoted message was created or when the * quoted message was last updated. + * If the message was edited, use this field, `last_update_time`. + * If the message was never edited, use `create_time`. + * If `last_update_time` doesn't match the latest version of the quoted + * message, the request fails. * - * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; + * Generated from protobuf field .google.protobuf.Timestamp last_update_time = 2 [(.google.api.field_behavior) = REQUIRED]; * @param \Google\Protobuf\Timestamp $var * @return $this */ diff --git a/AppsChat/src/Chat/V1/Space.php b/AppsChat/src/Chat/V1/Space.php index b7cfffae837c..3e44d9d28fc3 100644 --- a/AppsChat/src/Chat/V1/Space.php +++ b/AppsChat/src/Chat/V1/Space.php @@ -161,8 +161,8 @@ class Space extends \Google\Protobuf\Internal\Message * authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) * and `SpaceType` is `SPACE`, otherwise should not be set. * In the format `customers/{customer}`, where `customer` is the `id` from the - * [Admin SDK customer resource]( - * https://developers.google.com/admin-sdk/directory/reference/rest/v1/customers). + * [Admin SDK customer + * resource](https://developers.google.com/admin-sdk/directory/reference/rest/v1/customers). * Private apps can also use the `customers/my_customer` alias to create * the space in the same Google Workspace organization as the app. * For DMs, this field isn't populated. @@ -273,8 +273,8 @@ class Space extends \Google\Protobuf\Internal\Message * authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) * and `SpaceType` is `SPACE`, otherwise should not be set. * In the format `customers/{customer}`, where `customer` is the `id` from the - * [Admin SDK customer resource]( - * https://developers.google.com/admin-sdk/directory/reference/rest/v1/customers). + * [Admin SDK customer + * resource](https://developers.google.com/admin-sdk/directory/reference/rest/v1/customers). * Private apps can also use the `customers/my_customer` alias to create * the space in the same Google Workspace organization as the app. * For DMs, this field isn't populated. @@ -885,8 +885,8 @@ public function setAccessSettings($var) * authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) * and `SpaceType` is `SPACE`, otherwise should not be set. * In the format `customers/{customer}`, where `customer` is the `id` from the - * [Admin SDK customer resource]( - * https://developers.google.com/admin-sdk/directory/reference/rest/v1/customers). + * [Admin SDK customer + * resource](https://developers.google.com/admin-sdk/directory/reference/rest/v1/customers). * Private apps can also use the `customers/my_customer` alias to create * the space in the same Google Workspace organization as the app. * For DMs, this field isn't populated. @@ -915,8 +915,8 @@ public function clearCustomer() * authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app) * and `SpaceType` is `SPACE`, otherwise should not be set. * In the format `customers/{customer}`, where `customer` is the `id` from the - * [Admin SDK customer resource]( - * https://developers.google.com/admin-sdk/directory/reference/rest/v1/customers). + * [Admin SDK customer + * resource](https://developers.google.com/admin-sdk/directory/reference/rest/v1/customers). * Private apps can also use the `customers/my_customer` alias to create * the space in the same Google Workspace organization as the app. * For DMs, this field isn't populated. diff --git a/AppsChat/src/Chat/V1/UpdateMessageRequest.php b/AppsChat/src/Chat/V1/UpdateMessageRequest.php index 009c4836a1b1..e7ee8e19b23a 100644 --- a/AppsChat/src/Chat/V1/UpdateMessageRequest.php +++ b/AppsChat/src/Chat/V1/UpdateMessageRequest.php @@ -33,6 +33,7 @@ class UpdateMessageRequest extends \Google\Protobuf\Internal\Message * authentication](/chat/api/guides/auth/service-accounts).) * - `accessory_widgets` (Requires [app * authentication](/chat/api/guides/auth/service-accounts).) + * - `quoted_message_metadata` (Only allows removal of the quoted message.) * * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; */ @@ -67,6 +68,8 @@ class UpdateMessageRequest extends \Google\Protobuf\Internal\Message * - `accessory_widgets` (Requires [app * authentication](/chat/api/guides/auth/service-accounts).) * + * - `quoted_message_metadata` (Only allows removal of the quoted message.) + * * @return \Google\Apps\Chat\V1\UpdateMessageRequest * * @experimental @@ -98,6 +101,7 @@ public static function build(\Google\Apps\Chat\V1\Message $message, \Google\Prot * authentication](/chat/api/guides/auth/service-accounts).) * - `accessory_widgets` (Requires [app * authentication](/chat/api/guides/auth/service-accounts).) + * - `quoted_message_metadata` (Only allows removal of the quoted message.) * @type bool $allow_missing * Optional. If `true` and the message isn't found, a new message is created * and `updateMask` is ignored. The specified message ID must be @@ -158,6 +162,7 @@ public function setMessage($var) * authentication](/chat/api/guides/auth/service-accounts).) * - `accessory_widgets` (Requires [app * authentication](/chat/api/guides/auth/service-accounts).) + * - `quoted_message_metadata` (Only allows removal of the quoted message.) * * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; * @return \Google\Protobuf\FieldMask|null @@ -189,6 +194,7 @@ public function clearUpdateMask() * authentication](/chat/api/guides/auth/service-accounts).) * - `accessory_widgets` (Requires [app * authentication](/chat/api/guides/auth/service-accounts).) + * - `quoted_message_metadata` (Only allows removal of the quoted message.) * * Generated from protobuf field .google.protobuf.FieldMask update_mask = 2 [(.google.api.field_behavior) = REQUIRED]; * @param \Google\Protobuf\FieldMask $var