Skip to content

Commit 27c0c3c

Browse files
Google APIscopybara-github
authored andcommitted
feat: Add missing field annotations in space.proto, message.proto, reaction.proto, space_event.proto, membership.proto, attachment.proto
docs: Update field annotations in space.proto, message.proto, reaction.proto, space_event.proto, membership.proto, attachment.proto There are unrelated changes related to filed annotations, but verified those are in the public dev docs fix!: Changed field behavior for an existing field `update_mask` and `emoji` PiperOrigin-RevId: 704249815
1 parent 0f3a20e commit 27c0c3c

9 files changed

Lines changed: 407 additions & 241 deletions

File tree

google/chat/v1/BUILD.bazel

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ proto_library(
5050
"//google/api:annotations_proto",
5151
"//google/api:client_proto",
5252
"//google/api:field_behavior_proto",
53+
"//google/api:field_info_proto",
5354
"//google/api:resource_proto",
5455
"//google/apps/card/v1:card_proto",
5556
"//google/rpc:code_proto",
@@ -238,6 +239,7 @@ py_gapic_assembly_pkg(
238239
##############################################################################
239240
# PHP
240241
##############################################################################
242+
# buildifier: disable=same-origin-load
241243
load(
242244
"@com_google_googleapis_imports//:imports.bzl",
243245
"php_gapic_assembly_pkg",

google/chat/v1/attachment.proto

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -47,9 +47,9 @@ message Attachment {
4747
UPLOADED_CONTENT = 2;
4848
}
4949

50-
// Resource name of the attachment, in the form
50+
// Optional. Resource name of the attachment, in the form
5151
// `spaces/{space}/messages/{message}/attachments/{attachment}`.
52-
string name = 1;
52+
string name = 1 [(google.api.field_behavior) = OPTIONAL];
5353

5454
// Output only. The original file name for the content, not the full path.
5555
string content_name = 2 [(google.api.field_behavior) = OUTPUT_ONLY];
@@ -59,9 +59,11 @@ message Attachment {
5959

6060
// The data reference to the attachment.
6161
oneof data_ref {
62-
// A reference to the attachment data. This field is used with the media API
63-
// to download the attachment data.
64-
AttachmentDataRef attachment_data_ref = 4;
62+
// Optional. A reference to the attachment data. This field is used to
63+
// create or update messages with attachments, or with the media API to
64+
// download the attachment data.
65+
AttachmentDataRef attachment_data_ref = 4
66+
[(google.api.field_behavior) = OPTIONAL];
6567

6668
// Output only. A reference to the Google Drive attachment. This field is
6769
// used with the Google Drive API.
@@ -90,14 +92,14 @@ message DriveDataRef {
9092

9193
// A reference to the attachment data.
9294
message AttachmentDataRef {
93-
// The resource name of the attachment data. This field is used with the media
94-
// API to download the attachment data.
95-
string resource_name = 1;
96-
97-
// Opaque token containing a reference to an uploaded attachment. Treated by
98-
// clients as an opaque string and used to create or update Chat messages with
99-
// attachments.
100-
string attachment_upload_token = 2;
95+
// Optional. The resource name of the attachment data. This field is used with
96+
// the media API to download the attachment data.
97+
string resource_name = 1 [(google.api.field_behavior) = OPTIONAL];
98+
99+
// Optional. Opaque token containing a reference to an uploaded attachment.
100+
// Treated by clients as an opaque string and used to create or update Chat
101+
// messages with attachments.
102+
string attachment_upload_token = 2 [(google.api.field_behavior) = OPTIONAL];
101103
}
102104

103105
// Request to get an attachment.

0 commit comments

Comments
 (0)