@google-apps/chat 0.17.0 → 0.18.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/build/protos/google/chat/v1/chat_service.proto +344 -57
- package/build/protos/google/chat/v1/deletion_metadata.proto +13 -7
- package/build/protos/google/chat/v1/membership.proto +7 -5
- package/build/protos/google/chat/v1/slash_command.proto +2 -2
- package/build/protos/google/chat/v1/space.proto +41 -5
- package/build/protos/google/chat/v1/space_setup.proto +1 -1
- package/build/protos/google/chat/v1/user.proto +0 -1
- package/build/protos/protos.d.ts +6 -0
- package/build/protos/protos.js +33 -0
- package/build/protos/protos.json +14 -1
- package/build/src/v1/chat_service_client.d.ts +348 -63
- package/build/src/v1/chat_service_client.js +4 -0
- package/build/src/v1/chat_service_client.js.map +1 -1
- package/package.json +1 -1
|
@@ -29,7 +29,9 @@ option ruby_package = "Google::Apps::Chat::V1";
|
|
|
29
29
|
// is set.
|
|
30
30
|
message DeletionMetadata {
|
|
31
31
|
// Who deleted the message and how it was deleted. More values may be added in
|
|
32
|
-
// the future.
|
|
32
|
+
// the future. See [Edit or delete a message in Google
|
|
33
|
+
// Chat](https://support.google.com/chat/answer/7653281) for details on when
|
|
34
|
+
// messages can be deleted.
|
|
33
35
|
enum DeletionType {
|
|
34
36
|
// This value is unused.
|
|
35
37
|
DELETION_TYPE_UNSPECIFIED = 0;
|
|
@@ -37,23 +39,27 @@ message DeletionMetadata {
|
|
|
37
39
|
// User deleted their own message.
|
|
38
40
|
CREATOR = 1;
|
|
39
41
|
|
|
40
|
-
//
|
|
42
|
+
// A space manager deleted the message.
|
|
41
43
|
SPACE_OWNER = 2;
|
|
42
44
|
|
|
43
|
-
// A Google Workspace
|
|
45
|
+
// A Google Workspace administrator deleted the message. Administrators can
|
|
46
|
+
// delete any message in the space, including messages sent by any space
|
|
47
|
+
// member or Chat app.
|
|
44
48
|
ADMIN = 3;
|
|
45
49
|
|
|
46
50
|
// A Chat app deleted its own message when it expired.
|
|
47
51
|
APP_MESSAGE_EXPIRY = 4;
|
|
48
52
|
|
|
49
|
-
// A Chat app deleted the message on behalf of the user
|
|
53
|
+
// A Chat app deleted the message on behalf of the creator (using user
|
|
54
|
+
// authentication).
|
|
50
55
|
CREATOR_VIA_APP = 5;
|
|
51
56
|
|
|
52
|
-
// A Chat app deleted the message on behalf of
|
|
57
|
+
// A Chat app deleted the message on behalf of a space manager (using user
|
|
58
|
+
// authentication).
|
|
53
59
|
SPACE_OWNER_VIA_APP = 6;
|
|
54
60
|
|
|
55
|
-
// A member of the space deleted the message.
|
|
56
|
-
//
|
|
61
|
+
// A member of the space deleted the message. Users can delete messages sent
|
|
62
|
+
// by apps.
|
|
57
63
|
SPACE_MEMBER = 7;
|
|
58
64
|
}
|
|
59
65
|
|
|
@@ -156,8 +156,6 @@ message CreateMembershipRequest {
|
|
|
156
156
|
// - When [authenticating as an
|
|
157
157
|
// app](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app),
|
|
158
158
|
// the `chat.app.memberships` authorization scope is required.
|
|
159
|
-
// Authenticating as an app is available in [Developer
|
|
160
|
-
// Preview](https://developers.google.com/workspace/preview).
|
|
161
159
|
//
|
|
162
160
|
// - Set `user.type` to `HUMAN`, and set `user.name` with format
|
|
163
161
|
// `users/{user}`, where `{user}` can be the email address for the user. For
|
|
@@ -377,9 +375,13 @@ message DeleteMembershipRequest {
|
|
|
377
375
|
// human users' or their own memberships. Chat apps can't delete other apps'
|
|
378
376
|
// memberships.
|
|
379
377
|
//
|
|
380
|
-
// When deleting a human membership, requires the `chat.memberships` scope
|
|
381
|
-
//
|
|
382
|
-
//
|
|
378
|
+
// When deleting a human membership, requires the `chat.memberships` scope
|
|
379
|
+
// with [user
|
|
380
|
+
// authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user)
|
|
381
|
+
// or the `chat.memberships.app` scope with [app
|
|
382
|
+
// authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app)
|
|
383
|
+
// and the `spaces/{space}/members/{member}` format.
|
|
384
|
+
// You can use the email as an alias for `{member}`. For example,
|
|
383
385
|
// `spaces/{space}/members/example@gmail.com` where `example@gmail.com` is the
|
|
384
386
|
// email of the Google Chat user.
|
|
385
387
|
//
|
|
@@ -25,10 +25,10 @@ option objc_class_prefix = "DYNAPIProto";
|
|
|
25
25
|
option php_namespace = "Google\\Apps\\Chat\\V1";
|
|
26
26
|
option ruby_package = "Google::Apps::Chat::V1";
|
|
27
27
|
|
|
28
|
-
//
|
|
28
|
+
// Metadata about a [slash
|
|
29
29
|
// command](https://developers.google.com/workspace/chat/commands) in
|
|
30
30
|
// Google Chat.
|
|
31
31
|
message SlashCommand {
|
|
32
|
-
// The ID of the slash command
|
|
32
|
+
// The ID of the slash command.
|
|
33
33
|
int64 command_id = 1;
|
|
34
34
|
}
|
|
@@ -163,8 +163,7 @@ message Space {
|
|
|
163
163
|
// authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app)
|
|
164
164
|
// with [administrator
|
|
165
165
|
// approval](https://support.google.com/a?p=chat-app-auth)
|
|
166
|
-
// with the `chat.app.spaces` scope
|
|
167
|
-
// Preview](https://developers.google.com/workspace/preview).
|
|
166
|
+
// with the `chat.app.spaces` scope.
|
|
168
167
|
//
|
|
169
168
|
// This field is not populated when using the `chat.bot` scope with [app
|
|
170
169
|
// authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app).
|
|
@@ -350,20 +349,45 @@ message Space {
|
|
|
350
349
|
// Only populated when the `space_type` is `SPACE`.
|
|
351
350
|
AccessSettings access_settings = 23 [(google.api.field_behavior) = OPTIONAL];
|
|
352
351
|
|
|
352
|
+
// Optional. Immutable. The customer id of the domain of the space.
|
|
353
|
+
// Required only when creating a space with [app
|
|
354
|
+
// authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app)
|
|
355
|
+
// and `SpaceType` is `SPACE`, otherwise should not be set.
|
|
356
|
+
//
|
|
357
|
+
// In the format `customers/{customer}`, where `customer` is the `id` from the
|
|
358
|
+
// [Admin SDK customer resource](
|
|
359
|
+
// https://developers.google.com/admin-sdk/directory/reference/rest/v1/customers).
|
|
360
|
+
// Private apps can also use the `customers/my_customer` alias to create
|
|
361
|
+
// the space in the same Google Workspace organization as the app.
|
|
362
|
+
//
|
|
363
|
+
// For DMs, this field isn't populated.
|
|
364
|
+
optional string customer = 24 [
|
|
365
|
+
(google.api.field_behavior) = IMMUTABLE,
|
|
366
|
+
(google.api.field_behavior) = OPTIONAL
|
|
367
|
+
];
|
|
368
|
+
|
|
353
369
|
// Output only. The URI for a user to access the space.
|
|
354
370
|
string space_uri = 25 [(google.api.field_behavior) = OUTPUT_ONLY];
|
|
355
371
|
|
|
356
372
|
// Represents the [permission settings]
|
|
357
373
|
// (https://support.google.com/chat/answer/13340792) of a space. Only
|
|
358
374
|
// populated when the `space_type` is `SPACE`.
|
|
359
|
-
//
|
|
360
|
-
// Requires [user
|
|
361
|
-
// authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user).
|
|
362
375
|
oneof space_permission_settings {
|
|
363
376
|
// Optional. Input only. Predefined space permission settings, input only
|
|
364
377
|
// when creating a space. If the field is not set, a collaboration space is
|
|
365
378
|
// created. After you create the space, settings are populated in the
|
|
366
379
|
// `PermissionSettings` field.
|
|
380
|
+
//
|
|
381
|
+
// Setting predefined permission settings supports:
|
|
382
|
+
//
|
|
383
|
+
// - [App
|
|
384
|
+
// authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app)
|
|
385
|
+
// with [administrator
|
|
386
|
+
// approval](https://support.google.com/a?p=chat-app-auth) with the
|
|
387
|
+
// `chat.app.spaces` or `chat.app.spaces.create` scopes.
|
|
388
|
+
//
|
|
389
|
+
// - [User
|
|
390
|
+
// authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user)
|
|
367
391
|
PredefinedPermissionSettings predefined_permission_settings = 26 [
|
|
368
392
|
(google.api.field_behavior) = INPUT_ONLY,
|
|
369
393
|
(google.api.field_behavior) = OPTIONAL
|
|
@@ -372,6 +396,18 @@ message Space {
|
|
|
372
396
|
// Optional. Space permission settings for existing spaces. Input for
|
|
373
397
|
// updating exact space permission settings, where existing permission
|
|
374
398
|
// settings are replaced. Output lists current permission settings.
|
|
399
|
+
//
|
|
400
|
+
// Reading and updating permission settings supports:
|
|
401
|
+
//
|
|
402
|
+
// - [App
|
|
403
|
+
// authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-app)
|
|
404
|
+
// with [administrator
|
|
405
|
+
// approval](https://support.google.com/a?p=chat-app-auth) with the
|
|
406
|
+
// `chat.app.spaces` scope. Only populated and settable when the Chat app
|
|
407
|
+
// created the space.
|
|
408
|
+
//
|
|
409
|
+
// - [User
|
|
410
|
+
// authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user)
|
|
375
411
|
PermissionSettings permission_settings = 27
|
|
376
412
|
[(google.api.field_behavior) = OPTIONAL];
|
|
377
413
|
}
|
|
@@ -67,7 +67,7 @@ message SetUpSpaceRequest {
|
|
|
67
67
|
// Optional. The Google Chat users or groups to invite to join the space. Omit
|
|
68
68
|
// the calling user, as they are added automatically.
|
|
69
69
|
//
|
|
70
|
-
// The set currently allows up to
|
|
70
|
+
// The set currently allows up to 49 memberships (in addition to the caller).
|
|
71
71
|
//
|
|
72
72
|
// For human membership, the `Membership.member` field must contain a `user`
|
|
73
73
|
// with `name` populated (format: `users/{user}`) and `type` set to
|
package/build/protos/protos.d.ts
CHANGED
|
@@ -19171,6 +19171,9 @@ export namespace google {
|
|
|
19171
19171
|
/** Space accessSettings */
|
|
19172
19172
|
accessSettings?: (google.chat.v1.Space.IAccessSettings|null);
|
|
19173
19173
|
|
|
19174
|
+
/** Space customer */
|
|
19175
|
+
customer?: (string|null);
|
|
19176
|
+
|
|
19174
19177
|
/** Space spaceUri */
|
|
19175
19178
|
spaceUri?: (string|null);
|
|
19176
19179
|
|
|
@@ -19241,6 +19244,9 @@ export namespace google {
|
|
|
19241
19244
|
/** Space accessSettings. */
|
|
19242
19245
|
public accessSettings?: (google.chat.v1.Space.IAccessSettings|null);
|
|
19243
19246
|
|
|
19247
|
+
/** Space customer. */
|
|
19248
|
+
public customer?: (string|null);
|
|
19249
|
+
|
|
19244
19250
|
/** Space spaceUri. */
|
|
19245
19251
|
public spaceUri: string;
|
|
19246
19252
|
|
package/build/protos/protos.js
CHANGED
|
@@ -49682,6 +49682,7 @@
|
|
|
49682
49682
|
* @property {boolean|null} [adminInstalled] Space adminInstalled
|
|
49683
49683
|
* @property {google.chat.v1.Space.IMembershipCount|null} [membershipCount] Space membershipCount
|
|
49684
49684
|
* @property {google.chat.v1.Space.IAccessSettings|null} [accessSettings] Space accessSettings
|
|
49685
|
+
* @property {string|null} [customer] Space customer
|
|
49685
49686
|
* @property {string|null} [spaceUri] Space spaceUri
|
|
49686
49687
|
* @property {google.chat.v1.Space.PredefinedPermissionSettings|null} [predefinedPermissionSettings] Space predefinedPermissionSettings
|
|
49687
49688
|
* @property {google.chat.v1.Space.IPermissionSettings|null} [permissionSettings] Space permissionSettings
|
|
@@ -49831,6 +49832,14 @@
|
|
|
49831
49832
|
*/
|
|
49832
49833
|
Space.prototype.accessSettings = null;
|
|
49833
49834
|
|
|
49835
|
+
/**
|
|
49836
|
+
* Space customer.
|
|
49837
|
+
* @member {string|null|undefined} customer
|
|
49838
|
+
* @memberof google.chat.v1.Space
|
|
49839
|
+
* @instance
|
|
49840
|
+
*/
|
|
49841
|
+
Space.prototype.customer = null;
|
|
49842
|
+
|
|
49834
49843
|
/**
|
|
49835
49844
|
* Space spaceUri.
|
|
49836
49845
|
* @member {string} spaceUri
|
|
@@ -49866,6 +49875,12 @@
|
|
|
49866
49875
|
// OneOf field names bound to virtual getters and setters
|
|
49867
49876
|
var $oneOfFields;
|
|
49868
49877
|
|
|
49878
|
+
// Virtual OneOf for proto3 optional field
|
|
49879
|
+
Object.defineProperty(Space.prototype, "_customer", {
|
|
49880
|
+
get: $util.oneOfGetter($oneOfFields = ["customer"]),
|
|
49881
|
+
set: $util.oneOfSetter($oneOfFields)
|
|
49882
|
+
});
|
|
49883
|
+
|
|
49869
49884
|
/**
|
|
49870
49885
|
* Space spacePermissionSettings.
|
|
49871
49886
|
* @member {"predefinedPermissionSettings"|"permissionSettings"|undefined} spacePermissionSettings
|
|
@@ -49933,6 +49948,8 @@
|
|
|
49933
49948
|
$root.google.chat.v1.Space.MembershipCount.encode(message.membershipCount, writer.uint32(/* id 20, wireType 2 =*/162).fork()).ldelim();
|
|
49934
49949
|
if (message.accessSettings != null && Object.hasOwnProperty.call(message, "accessSettings"))
|
|
49935
49950
|
$root.google.chat.v1.Space.AccessSettings.encode(message.accessSettings, writer.uint32(/* id 23, wireType 2 =*/186).fork()).ldelim();
|
|
49951
|
+
if (message.customer != null && Object.hasOwnProperty.call(message, "customer"))
|
|
49952
|
+
writer.uint32(/* id 24, wireType 2 =*/194).string(message.customer);
|
|
49936
49953
|
if (message.spaceUri != null && Object.hasOwnProperty.call(message, "spaceUri"))
|
|
49937
49954
|
writer.uint32(/* id 25, wireType 2 =*/202).string(message.spaceUri);
|
|
49938
49955
|
if (message.predefinedPermissionSettings != null && Object.hasOwnProperty.call(message, "predefinedPermissionSettings"))
|
|
@@ -50041,6 +50058,10 @@
|
|
|
50041
50058
|
message.accessSettings = $root.google.chat.v1.Space.AccessSettings.decode(reader, reader.uint32());
|
|
50042
50059
|
break;
|
|
50043
50060
|
}
|
|
50061
|
+
case 24: {
|
|
50062
|
+
message.customer = reader.string();
|
|
50063
|
+
break;
|
|
50064
|
+
}
|
|
50044
50065
|
case 25: {
|
|
50045
50066
|
message.spaceUri = reader.string();
|
|
50046
50067
|
break;
|
|
@@ -50177,6 +50198,11 @@
|
|
|
50177
50198
|
if (error)
|
|
50178
50199
|
return "accessSettings." + error;
|
|
50179
50200
|
}
|
|
50201
|
+
if (message.customer != null && message.hasOwnProperty("customer")) {
|
|
50202
|
+
properties._customer = 1;
|
|
50203
|
+
if (!$util.isString(message.customer))
|
|
50204
|
+
return "customer: string expected";
|
|
50205
|
+
}
|
|
50180
50206
|
if (message.spaceUri != null && message.hasOwnProperty("spaceUri"))
|
|
50181
50207
|
if (!$util.isString(message.spaceUri))
|
|
50182
50208
|
return "spaceUri: string expected";
|
|
@@ -50348,6 +50374,8 @@
|
|
|
50348
50374
|
throw TypeError(".google.chat.v1.Space.accessSettings: object expected");
|
|
50349
50375
|
message.accessSettings = $root.google.chat.v1.Space.AccessSettings.fromObject(object.accessSettings);
|
|
50350
50376
|
}
|
|
50377
|
+
if (object.customer != null)
|
|
50378
|
+
message.customer = String(object.customer);
|
|
50351
50379
|
if (object.spaceUri != null)
|
|
50352
50380
|
message.spaceUri = String(object.spaceUri);
|
|
50353
50381
|
switch (object.predefinedPermissionSettings) {
|
|
@@ -50448,6 +50476,11 @@
|
|
|
50448
50476
|
object.membershipCount = $root.google.chat.v1.Space.MembershipCount.toObject(message.membershipCount, options);
|
|
50449
50477
|
if (message.accessSettings != null && message.hasOwnProperty("accessSettings"))
|
|
50450
50478
|
object.accessSettings = $root.google.chat.v1.Space.AccessSettings.toObject(message.accessSettings, options);
|
|
50479
|
+
if (message.customer != null && message.hasOwnProperty("customer")) {
|
|
50480
|
+
object.customer = message.customer;
|
|
50481
|
+
if (options.oneofs)
|
|
50482
|
+
object._customer = "customer";
|
|
50483
|
+
}
|
|
50451
50484
|
if (message.spaceUri != null && message.hasOwnProperty("spaceUri"))
|
|
50452
50485
|
object.spaceUri = message.spaceUri;
|
|
50453
50486
|
if (message.predefinedPermissionSettings != null && message.hasOwnProperty("predefinedPermissionSettings")) {
|
package/build/protos/protos.json
CHANGED
|
@@ -3332,7 +3332,7 @@
|
|
|
3332
3332
|
"ChatService": {
|
|
3333
3333
|
"options": {
|
|
3334
3334
|
"(google.api.default_host)": "chat.googleapis.com",
|
|
3335
|
-
"(google.api.oauth_scopes)": "https://www.googleapis.com/auth/chat.admin.delete,https://www.googleapis.com/auth/chat.admin.memberships,https://www.googleapis.com/auth/chat.admin.memberships.readonly,https://www.googleapis.com/auth/chat.admin.spaces,https://www.googleapis.com/auth/chat.admin.spaces.readonly,https://www.googleapis.com/auth/chat.bot,https://www.googleapis.com/auth/chat.customemojis,https://www.googleapis.com/auth/chat.customemojis.readonly,https://www.googleapis.com/auth/chat.delete,https://www.googleapis.com/auth/chat.import,https://www.googleapis.com/auth/chat.memberships,https://www.googleapis.com/auth/chat.memberships.app,https://www.googleapis.com/auth/chat.memberships.readonly,https://www.googleapis.com/auth/chat.messages,https://www.googleapis.com/auth/chat.messages.create,https://www.googleapis.com/auth/chat.messages.reactions,https://www.googleapis.com/auth/chat.messages.reactions.create,https://www.googleapis.com/auth/chat.messages.reactions.readonly,https://www.googleapis.com/auth/chat.messages.readonly,https://www.googleapis.com/auth/chat.spaces,https://www.googleapis.com/auth/chat.spaces.create,https://www.googleapis.com/auth/chat.spaces.readonly,https://www.googleapis.com/auth/chat.users.readstate,https://www.googleapis.com/auth/chat.users.readstate.readonly,https://www.googleapis.com/auth/chat.users.spacesettings"
|
|
3335
|
+
"(google.api.oauth_scopes)": "https://www.googleapis.com/auth/chat.admin.delete,https://www.googleapis.com/auth/chat.admin.memberships,https://www.googleapis.com/auth/chat.admin.memberships.readonly,https://www.googleapis.com/auth/chat.admin.spaces,https://www.googleapis.com/auth/chat.admin.spaces.readonly,https://www.googleapis.com/auth/chat.app.delete,https://www.googleapis.com/auth/chat.app.memberships,https://www.googleapis.com/auth/chat.app.spaces,https://www.googleapis.com/auth/chat.app.spaces.create,https://www.googleapis.com/auth/chat.bot,https://www.googleapis.com/auth/chat.customemojis,https://www.googleapis.com/auth/chat.customemojis.readonly,https://www.googleapis.com/auth/chat.delete,https://www.googleapis.com/auth/chat.import,https://www.googleapis.com/auth/chat.memberships,https://www.googleapis.com/auth/chat.memberships.app,https://www.googleapis.com/auth/chat.memberships.readonly,https://www.googleapis.com/auth/chat.messages,https://www.googleapis.com/auth/chat.messages.create,https://www.googleapis.com/auth/chat.messages.reactions,https://www.googleapis.com/auth/chat.messages.reactions.create,https://www.googleapis.com/auth/chat.messages.reactions.readonly,https://www.googleapis.com/auth/chat.messages.readonly,https://www.googleapis.com/auth/chat.spaces,https://www.googleapis.com/auth/chat.spaces.create,https://www.googleapis.com/auth/chat.spaces.readonly,https://www.googleapis.com/auth/chat.users.readstate,https://www.googleapis.com/auth/chat.users.readstate.readonly,https://www.googleapis.com/auth/chat.users.spacesettings"
|
|
3336
3336
|
},
|
|
3337
3337
|
"methods": {
|
|
3338
3338
|
"CreateMessage": {
|
|
@@ -5176,6 +5176,11 @@
|
|
|
5176
5176
|
"(google.api.resource).pattern": "spaces/{space}"
|
|
5177
5177
|
},
|
|
5178
5178
|
"oneofs": {
|
|
5179
|
+
"_customer": {
|
|
5180
|
+
"oneof": [
|
|
5181
|
+
"customer"
|
|
5182
|
+
]
|
|
5183
|
+
},
|
|
5179
5184
|
"spacePermissionSettings": {
|
|
5180
5185
|
"oneof": [
|
|
5181
5186
|
"predefinedPermissionSettings",
|
|
@@ -5298,6 +5303,14 @@
|
|
|
5298
5303
|
"(google.api.field_behavior)": "OPTIONAL"
|
|
5299
5304
|
}
|
|
5300
5305
|
},
|
|
5306
|
+
"customer": {
|
|
5307
|
+
"type": "string",
|
|
5308
|
+
"id": 24,
|
|
5309
|
+
"options": {
|
|
5310
|
+
"(google.api.field_behavior)": "OPTIONAL",
|
|
5311
|
+
"proto3_optional": true
|
|
5312
|
+
}
|
|
5313
|
+
},
|
|
5301
5314
|
"spaceUri": {
|
|
5302
5315
|
"type": "string",
|
|
5303
5316
|
"id": 25,
|