Skip to content

Commit 98fef44

Browse files
Google APIscopybara-github
authored andcommitted
feat: add ROLE_ASSISTANT_MANAGER to the MembershipRole enum in the Membership proto and assistant_managers_allowed to the PermissionSetting
docs: Update field documentations for space.proto and membership.proto PiperOrigin-RevId: 823185429
1 parent 4f79c85 commit 98fef44

File tree

3 files changed

+69
-9
lines changed

3 files changed

+69
-9
lines changed

google/chat/v1/deletion_metadata.proto

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ message DeletionMetadata {
3939
// User deleted their own message.
4040
CREATOR = 1;
4141

42-
// A space manager deleted the message.
42+
// An owner or manager deleted the message.
4343
SPACE_OWNER = 2;
4444

4545
// A Google Workspace administrator deleted the message. Administrators can

google/chat/v1/membership.proto

Lines changed: 56 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -66,16 +66,66 @@ message Membership {
6666
// assigned this role (other enum values might be used in the future).
6767
MEMBERSHIP_ROLE_UNSPECIFIED = 0;
6868

69-
// A member of the space. The user has basic permissions, like sending
70-
// messages to the space. In 1:1 and unnamed group conversations, everyone
69+
// A member of the space. In the Chat UI, this role is called Member.
70+
//
71+
// The user has basic permissions, like sending
72+
// messages to the space.
73+
// Managers and owners can grant members additional permissions in a space,
74+
// including:
75+
//
76+
// - Add or remove members.
77+
// - Modify space details.
78+
// - Turn history on or off.
79+
// - Mention everyone in the space with `@all`.
80+
// - Manage Chat apps and webhooks installed in the space.
81+
//
82+
// In direct messages and unnamed group conversations, everyone
7183
// has this role.
7284
ROLE_MEMBER = 1;
7385

74-
// A space manager. The user has all basic permissions plus administrative
75-
// permissions that let them manage the space, like adding or removing
76-
// members. Only supported in
77-
// [SpaceType.SPACE][google.chat.v1.Space.SpaceType].
86+
// A space owner. In the Chat UI, this role is called Owner.
87+
//
88+
// The user has the complete set of space permissions to manage the space,
89+
// including:
90+
//
91+
// - Change the role of other members in the space to member, manager, or
92+
// owner.
93+
// - Delete the space.
94+
//
95+
// Only supported in
96+
// [SpaceType.SPACE][google.chat.v1.Space.SpaceType] (named spaces).
97+
//
98+
// To learn more, see
99+
// [Learn more about your role as a space
100+
// owner or manager](https://support.google.com/chat/answer/11833441).
78101
ROLE_MANAGER = 2;
102+
103+
// A space manager. In the Chat UI, this role is called Manager.
104+
//
105+
// The user has all basic permissions of `ROLE_MEMBER`,
106+
// and can be granted a subset of administrative permissions by an owner.
107+
// By default, managers have all the permissions of an owner except for the
108+
// ability to:
109+
//
110+
// - Delete the space.
111+
// - Make another space member an owner.
112+
// - Change an owner's role.
113+
//
114+
// By default, managers permissions include but aren't limited to:
115+
//
116+
// - Make another member a manager.
117+
// - Delete messages in the space.
118+
// - Manage space permissions.
119+
// - Receive notifications for requests to join the space if the manager
120+
// has the "manage members" permission in the space settings.
121+
// - Make a space discoverable.
122+
//
123+
// Only supported in
124+
// [SpaceType.SPACE][google.chat.v1.Space.SpaceType] (named spaces).
125+
//
126+
// To learn more, see
127+
// [Manage space settings](https://support.google.com/chat/answer/13340792).
128+
ROLE_ASSISTANT_MANAGER = 4;
79129
}
80130

81131
// Identifier. Resource name of the membership, assigned by the server.

google/chat/v1/space.proto

Lines changed: 12 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -232,10 +232,20 @@ message Space {
232232

233233
// Represents a space permission setting.
234234
message PermissionSetting {
235-
// Optional. Whether spaces managers have this permission.
235+
// Optional. Whether space owners
236+
// ([`ROLE_MANAGER`][google.chat.v1.Membership.MembershipRole.ROLE_MANAGER])
237+
// have this permission.
236238
bool managers_allowed = 1 [(google.api.field_behavior) = OPTIONAL];
237239

238-
// Optional. Whether non-manager members have this permission.
240+
// Optional. Whether space managers
241+
// [`ROLE_ASSISTANT_MANAGER`][google.chat.v1.Membership.MembershipRole.ROLE_ASSISTANT_MANAGER])
242+
// have this permission.
243+
optional bool assistant_managers_allowed = 3
244+
[(google.api.field_behavior) = OPTIONAL];
245+
246+
// Optional. Whether basic space members
247+
// ([`ROLE_MEMBER`][google.chat.v1.Membership.MembershipRole.ROLE_MEMBER])
248+
// have this permission.
239249
bool members_allowed = 2 [(google.api.field_behavior) = OPTIONAL];
240250
}
241251

0 commit comments

Comments
 (0)