Skip to content

Commit 9a80089

Browse files
feat: [chat] Add doc for Discoverable Space support for GA launch (#5525)
* feat: Add doc for Discoverable Space support for GA launch docs: Update resource naming formats PiperOrigin-RevId: 649131985 Source-Link: googleapis/googleapis@fd67cac Source-Link: googleapis/googleapis-gen@7c31c51 Copy-Tag: eyJwIjoicGFja2FnZXMvZ29vZ2xlLWNoYXQvLk93bEJvdC55YW1sIiwiaCI6IjdjMzFjNTFjZTU3YTRiM2JmOGFhMTFiZGU1YzE1NDRhZTY4OTg3M2MifQ== * 🦉 Updates from OwlBot post-processor See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md --------- Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com> Co-authored-by: sofisl <[email protected]>
1 parent 8983209 commit 9a80089

13 files changed

Lines changed: 653 additions & 36 deletions

packages/google-chat/protos/google/chat/v1/attachment.proto

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ message Attachment {
4848
}
4949

5050
// Resource name of the attachment, in the form
51-
// `spaces/*/messages/*/attachments/*`.
51+
// `spaces/{space}/messages/{message}/attachments/{attachment}`.
5252
string name = 1;
5353

5454
// Output only. The original file name for the content, not the full path.
@@ -103,7 +103,7 @@ message AttachmentDataRef {
103103
// Request to get an attachment.
104104
message GetAttachmentRequest {
105105
// Required. Resource name of the attachment, in the form
106-
// `spaces/*/messages/*/attachments/*`.
106+
// `spaces/{space}/messages/{message}/attachments/{attachment}`.
107107
string name = 1 [
108108
(google.api.field_behavior) = REQUIRED,
109109
(google.api.resource_reference) = { type: "chat.googleapis.com/Attachment" }

packages/google-chat/protos/google/chat/v1/chat_service.proto

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,11 @@ option ruby_package = "Google::Apps::Chat::V1";
4242
service ChatService {
4343
option (google.api.default_host) = "chat.googleapis.com";
4444
option (google.api.oauth_scopes) =
45+
"https://www.googleapis.com/auth/chat.admin.delete,"
46+
"https://www.googleapis.com/auth/chat.admin.memberships,"
47+
"https://www.googleapis.com/auth/chat.admin.memberships.readonly,"
48+
"https://www.googleapis.com/auth/chat.admin.spaces,"
49+
"https://www.googleapis.com/auth/chat.admin.spaces.readonly,"
4550
"https://www.googleapis.com/auth/chat.bot,"
4651
"https://www.googleapis.com/auth/chat.delete,"
4752
"https://www.googleapis.com/auth/chat.import,"
@@ -253,6 +258,9 @@ service ChatService {
253258
// Lists spaces visible to the caller or authenticated user. Group chats
254259
// and DMs aren't listed until the first message is sent.
255260
//
261+
// To list all named spaces by Google Workspace organization, use the
262+
// [`spaces.search()`](https://developers.google.com/workspace/chat/api/reference/rest/v1/spaces/search)
263+
// method using Workspace administrator privileges instead.
256264
rpc ListSpaces(ListSpacesRequest) returns (ListSpacesResponse) {
257265
option (google.api.http) = {
258266
get: "/v1/spaces"

packages/google-chat/protos/google/chat/v1/membership.proto

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -215,16 +215,23 @@ message ListMembershipsRequest {
215215
//
216216
// To filter by role, set `role` to `ROLE_MEMBER` or `ROLE_MANAGER`.
217217
//
218-
// To filter by type, set `member.type` to `HUMAN` or `BOT`.
218+
// To filter by type, set `member.type` to `HUMAN` or `BOT`. Developer
219+
// Preview: You can also filter for `member.type` using the `!=` operator.
219220
//
220221
// To filter by both role and type, use the `AND` operator. To filter by
221222
// either role or type, use the `OR` operator.
222223
//
224+
// Either `member.type = "HUMAN"` or `member.type != "BOT"` is required
225+
// when `use_admin_access` is set to true. Other member type filters will be
226+
// rejected.
227+
//
223228
// For example, the following queries are valid:
224229
//
225230
// ```
226231
// role = "ROLE_MANAGER" OR role = "ROLE_MEMBER"
227232
// member.type = "HUMAN" AND role = "ROLE_MANAGER"
233+
//
234+
// member.type != "BOT"
228235
// ```
229236
//
230237
// The following queries are invalid:
@@ -234,7 +241,6 @@ message ListMembershipsRequest {
234241
// role = "ROLE_MANAGER" AND role = "ROLE_MEMBER"
235242
// ```
236243
//
237-
//
238244
// Invalid queries are rejected by the server with an `INVALID_ARGUMENT`
239245
// error.
240246
string filter = 5 [(google.api.field_behavior) = OPTIONAL];

packages/google-chat/protos/google/chat/v1/space.proto

Lines changed: 63 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,39 @@ message Space {
103103
string guidelines = 2;
104104
}
105105

106+
// Represents the [access
107+
// setting](https://support.google.com/chat/answer/11971020) of the space.
108+
message AccessSettings {
109+
// Represents the access state of the space.
110+
enum AccessState {
111+
// Access state is unknown or not supported in this API.
112+
ACCESS_STATE_UNSPECIFIED = 0;
113+
114+
// Space is discoverable by added or invited members or groups.
115+
PRIVATE = 1;
116+
117+
// Space is discoverable by the selected [target
118+
// audience](https://support.google.com/a/answer/9934697), as well as
119+
// added or invited members or groups.
120+
DISCOVERABLE = 2;
121+
}
122+
123+
// Output only. Indicates the access state of the space.
124+
AccessState access_state = 1 [(google.api.field_behavior) = OUTPUT_ONLY];
125+
126+
// Optional. The resource name of the [target
127+
// audience](https://support.google.com/a/answer/9934697) who can discover
128+
// the space, join the space, and preview the messages in the space. For
129+
// details, see [Make a space discoverable to a target
130+
// audience](https://developers.google.com/workspace/chat/space-target-audience).
131+
//
132+
// Format: `audiences/{audience}`
133+
//
134+
// To use the default target audience for the Google Workspace organization,
135+
// set to `audiences/default`.
136+
string audience = 3 [(google.api.field_behavior) = OPTIONAL];
137+
}
138+
106139
// Resource name of the space.
107140
//
108141
// Format: `spaces/{space}`
@@ -192,6 +225,14 @@ message Space {
192225
//
193226
// To support admin install, your Chat app must feature direct messaging.
194227
bool admin_installed = 19 [(google.api.field_behavior) = OUTPUT_ONLY];
228+
229+
// Optional. Specifies the [access
230+
// setting](https://support.google.com/chat/answer/11971020) of the space.
231+
// Only populated when the `space_type` is `SPACE`.
232+
AccessSettings access_settings = 23 [(google.api.field_behavior) = OPTIONAL];
233+
234+
// Output only. The URI for a user to access the space.
235+
string space_uri = 25 [(google.api.field_behavior) = OUTPUT_ONLY];
195236
}
196237

197238
// A request to create a named space.
@@ -270,7 +311,7 @@ message ListSpacesResponse {
270311

271312
// A request to return a single space.
272313
message GetSpaceRequest {
273-
// Required. Resource name of the space, in the form "spaces/*".
314+
// Required. Resource name of the space, in the form `spaces/{space}`.
274315
//
275316
// Format: `spaces/{space}`
276317
string name = 1 [
@@ -325,6 +366,7 @@ message UpdateSpaceRequest {
325366
// the display name is optional if the existing space already has the `SPACE`
326367
// type. Trying to update the space type in other ways results in an invalid
327368
// argument error).
369+
// `space_type` is not supported with admin access.
328370
//
329371
// - `space_details`
330372
//
@@ -333,12 +375,27 @@ message UpdateSpaceRequest {
333375
// allows users to change their history
334376
// setting](https://support.google.com/a/answer/7664184).
335377
// Warning: mutually exclusive with all other field paths.)
378+
// `space_history_state` is not supported with admin access.
379+
//
380+
// - `access_settings.audience` (Supports changing the [access
381+
// setting](https://support.google.com/chat/answer/11971020) of who can
382+
// discover the space, join the space, and preview the messages in space. If
383+
// no audience is specified in the access setting, the space's access setting
384+
// is updated to private. Warning: mutually exclusive with all other field
385+
// paths.)
386+
// `access_settings.audience` is not supported with admin access.
336387
//
337-
// - Developer Preview: `access_settings.audience` (Supports changing the
338-
// [access setting](https://support.google.com/chat/answer/11971020) of a
339-
// space. If no audience is specified in the access setting, the space's
340-
// access setting is updated to restricted. Warning: mutually exclusive with
341-
// all other field paths.)
388+
// - Developer Preview: Supports changing the [permission
389+
// settings](https://support.google.com/chat/answer/13340792) of a space,
390+
// supported field paths
391+
// include: `permission_settings.manage_members_and_groups`,
392+
// `permission_settings.modify_space_details`,
393+
// `permission_settings.toggle_history`,
394+
// `permission_settings.use_at_mention_all`,
395+
// `permission_settings.manage_apps`, `permission_settings.manage_webhooks`,
396+
// `permission_settings.reply_messages`
397+
// (Warning: mutually exclusive with all other non-permission settings field
398+
// paths). `permission_settings` is not supported with admin access.
342399
google.protobuf.FieldMask update_mask = 2;
343400
}
344401

packages/google-chat/protos/protos.d.ts

Lines changed: 125 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)