mcp-google-multi 5.2.0-alpha.2 → 5.2.0-alpha.3

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.
Files changed (56) hide show
  1. package/dist/auth.js +33 -0
  2. package/dist/discovery-client.js +13 -0
  3. package/dist/index.js +25 -3
  4. package/dist/tools/generated/admin.d.ts +2 -0
  5. package/dist/tools/generated/admin.js +1937 -0
  6. package/dist/tools/generated/appsmarket.d.ts +2 -0
  7. package/dist/tools/generated/appsmarket.js +33 -0
  8. package/dist/tools/generated/calendar.d.ts +2 -0
  9. package/dist/tools/generated/calendar.js +428 -0
  10. package/dist/tools/generated/chat.d.ts +2 -0
  11. package/dist/tools/generated/chat.js +666 -0
  12. package/dist/tools/generated/classroom.d.ts +2 -0
  13. package/dist/tools/generated/classroom.js +1610 -0
  14. package/dist/tools/generated/cloudidentity.d.ts +2 -0
  15. package/dist/tools/generated/cloudidentity.js +955 -0
  16. package/dist/tools/generated/cloudsearch.d.ts +2 -0
  17. package/dist/tools/generated/cloudsearch.js +754 -0
  18. package/dist/tools/generated/contacts.d.ts +2 -0
  19. package/dist/tools/generated/contacts.js +215 -0
  20. package/dist/tools/generated/drive.d.ts +2 -0
  21. package/dist/tools/generated/drive.js +543 -0
  22. package/dist/tools/generated/driveactivity.d.ts +2 -0
  23. package/dist/tools/generated/driveactivity.js +19 -0
  24. package/dist/tools/generated/drivelabels.d.ts +2 -0
  25. package/dist/tools/generated/drivelabels.js +389 -0
  26. package/dist/tools/generated/forms.d.ts +2 -0
  27. package/dist/tools/generated/forms.js +49 -0
  28. package/dist/tools/generated/gmail.d.ts +2 -0
  29. package/dist/tools/generated/gmail.js +835 -0
  30. package/dist/tools/generated/groupsmigration.d.ts +2 -0
  31. package/dist/tools/generated/groupsmigration.js +18 -0
  32. package/dist/tools/generated/groupssettings.d.ts +2 -0
  33. package/dist/tools/generated/groupssettings.js +47 -0
  34. package/dist/tools/generated/index.js +50 -0
  35. package/dist/tools/generated/keep.d.ts +2 -0
  36. package/dist/tools/generated/keep.js +102 -0
  37. package/dist/tools/generated/licensing.d.ts +2 -0
  38. package/dist/tools/generated/licensing.js +116 -0
  39. package/dist/tools/generated/meet.d.ts +2 -0
  40. package/dist/tools/generated/meet.js +186 -0
  41. package/dist/tools/generated/postmaster.d.ts +2 -0
  42. package/dist/tools/generated/postmaster.js +66 -0
  43. package/dist/tools/generated/reseller.d.ts +2 -0
  44. package/dist/tools/generated/reseller.js +249 -0
  45. package/dist/tools/generated/script.d.ts +2 -0
  46. package/dist/tools/generated/script.js +249 -0
  47. package/dist/tools/generated/searchconsole.d.ts +2 -0
  48. package/dist/tools/generated/searchconsole.js +19 -0
  49. package/dist/tools/generated/sheets.d.ts +2 -0
  50. package/dist/tools/generated/sheets.js +105 -0
  51. package/dist/tools/generated/vault.d.ts +2 -0
  52. package/dist/tools/generated/vault.js +479 -0
  53. package/dist/tools/generated/workspaceevents.d.ts +2 -0
  54. package/dist/tools/generated/workspaceevents.js +223 -0
  55. package/dist/tools/google-api.js +1 -0
  56. package/package.json +1 -1
@@ -0,0 +1,666 @@
1
+ // GENERATED by scripts/gen-tools.ts — do not edit. Regenerate: npm run gen:tools
2
+ import { z } from 'zod';
3
+ import { coerceArray, coerceBoolean, coerceJson } from '../_coerce.js';
4
+ import { accountField, registerGeneratedTool } from './_shared.js';
5
+ export function registerChatGeneratedTools(registry) {
6
+ registerGeneratedTool(registry, {
7
+ name: "chat_custom_emojis_create",
8
+ cud: "create",
9
+ description: "Creates a custom emoji. Custom emojis are only available for Google Workspace accounts, and the administrator must turn custom emojis on for the organization. F",
10
+ method: { id: "chat.customEmojis.create", httpMethod: "POST", path: "v1/customEmojis", baseUrl: "https://chat.googleapis.com/", requiredParams: [] },
11
+ params: [{ "field": "fields", "api": "fields", "location": "query" }],
12
+ hasBody: true,
13
+ shape: {
14
+ account: accountField(),
15
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("CustomEmoji JSON request body. Top-level fields: emojiName, name, payload, temporaryImageUri, uid."),
16
+ fields: z.string().optional().describe('Response field mask.'),
17
+ },
18
+ });
19
+ registerGeneratedTool(registry, {
20
+ name: "chat_custom_emojis_delete",
21
+ cud: "delete",
22
+ description: "Deletes a custom emoji. By default, users can only delete custom emoji they created. [Emoji managers](https://support.google.com/a/answer/12850085) assigned by",
23
+ method: { id: "chat.customEmojis.delete", httpMethod: "DELETE", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
24
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
25
+ hasBody: false,
26
+ shape: {
27
+ account: accountField(),
28
+ name: z.string().describe("Required. Resource name of the custom emoji to delete. Format: `customEmojis/{customEmoji}` You can use the emoji name as an alias for `{customEmoji}`. For example, `customEmojis/:example-emoji:` wher"),
29
+ fields: z.string().optional().describe('Response field mask.'),
30
+ },
31
+ });
32
+ registerGeneratedTool(registry, {
33
+ name: "chat_custom_emojis_get",
34
+ cud: "read",
35
+ description: "Returns details about a custom emoji. Custom emojis are only available for Google Workspace accounts, and the administrator must turn custom emojis on for the o",
36
+ method: { id: "chat.customEmojis.get", httpMethod: "GET", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
37
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
38
+ hasBody: false,
39
+ shape: {
40
+ account: accountField(),
41
+ name: z.string().describe("Required. Resource name of the custom emoji. Format: `customEmojis/{customEmoji}` You can use the emoji name as an alias for `{customEmoji}`. For example, `customEmojis/:example-emoji:` where `:exampl"),
42
+ fields: z.string().optional().describe('Response field mask.'),
43
+ },
44
+ });
45
+ registerGeneratedTool(registry, {
46
+ name: "chat_custom_emojis_list",
47
+ cud: "read",
48
+ description: "Lists custom emojis visible to the authenticated user. Custom emojis are only available for Google Workspace accounts, and the administrator must turn custom em",
49
+ method: { id: "chat.customEmojis.list", httpMethod: "GET", path: "v1/customEmojis", baseUrl: "https://chat.googleapis.com/", requiredParams: [] },
50
+ params: [{ "field": "filter", "api": "filter", "location": "query" }, { "field": "pageSize", "api": "pageSize", "location": "query" }, { "field": "pageToken", "api": "pageToken", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
51
+ hasBody: false,
52
+ shape: {
53
+ account: accountField(),
54
+ filter: z.string().describe("Optional. A query filter. Supports filtering by creator. To filter by creator, you must specify a valid value. Currently only `creator(\"users/me\")` and `NOT creator(\"users/me\")` are accepted to filter").optional(),
55
+ pageSize: z.number().describe("Optional. The maximum number of custom emojis returned. The service can return fewer custom emojis than this value. If unspecified, the default value is 25. The maximum value is 200; values above 200 ").optional(),
56
+ pageToken: z.string().describe("Optional. (If resuming from a previous query.) A page token received from a previous list custom emoji call. Provide this to retrieve the subsequent page. When paginating, the filter value should matc").optional(),
57
+ fields: z.string().optional().describe('Response field mask.'),
58
+ },
59
+ });
60
+ registerGeneratedTool(registry, {
61
+ name: "chat_media_download",
62
+ cud: "read",
63
+ description: "Downloads media. Download is supported on the URI `/v1/media/{+name}?alt=media`.",
64
+ method: { id: "chat.media.download", httpMethod: "GET", path: "v1/media/{+resourceName}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["resourceName"] },
65
+ params: [{ "field": "resourceName", "api": "resourceName", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
66
+ hasBody: false,
67
+ shape: {
68
+ account: accountField(),
69
+ resourceName: z.string().describe("Name of the media that is being downloaded. See ReadRequest.resource_name."),
70
+ fields: z.string().optional().describe('Response field mask.'),
71
+ },
72
+ });
73
+ registerGeneratedTool(registry, {
74
+ name: "chat_media_upload",
75
+ cud: "create",
76
+ description: "Uploads an attachment. For an example, see [Upload media as a file attachment](https://developers.google.com/workspace/chat/upload-media-attachments). Requires",
77
+ method: { id: "chat.media.upload", httpMethod: "POST", path: "v1/{+parent}/attachments:upload", baseUrl: "https://chat.googleapis.com/", requiredParams: ["parent"] },
78
+ params: [{ "field": "parent", "api": "parent", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
79
+ hasBody: true,
80
+ shape: {
81
+ account: accountField(),
82
+ parent: z.string().describe("Required. Resource name of the Chat space in which the attachment is uploaded. Format \"spaces/{space}\"."),
83
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("UploadAttachmentRequest JSON request body. Top-level fields: filename."),
84
+ fields: z.string().optional().describe('Response field mask.'),
85
+ },
86
+ });
87
+ registerGeneratedTool(registry, {
88
+ name: "chat_spaces_complete_import",
89
+ cud: "create",
90
+ description: "Completes the [import process](https://developers.google.com/workspace/chat/import-data) for the specified space and makes it visible to users. Requires [user a",
91
+ method: { id: "chat.spaces.completeImport", httpMethod: "POST", path: "v1/{+name}:completeImport", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
92
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
93
+ hasBody: true,
94
+ shape: {
95
+ account: accountField(),
96
+ name: z.string().describe("Required. Resource name of the import mode space. Format: `spaces/{space}`"),
97
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("CompleteImportSpaceRequest JSON request body."),
98
+ fields: z.string().optional().describe('Response field mask.'),
99
+ },
100
+ });
101
+ registerGeneratedTool(registry, {
102
+ name: "chat_spaces_create",
103
+ cud: "create",
104
+ description: "Creates a space. Can be used to create a named space, or a group chat in `Import mode`. For an example, see [Create a space](https://developers.google.com/works",
105
+ method: { id: "chat.spaces.create", httpMethod: "POST", path: "v1/spaces", baseUrl: "https://chat.googleapis.com/", requiredParams: [] },
106
+ params: [{ "field": "requestId", "api": "requestId", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
107
+ hasBody: true,
108
+ shape: {
109
+ account: accountField(),
110
+ requestId: z.string().describe("Optional. A unique identifier for this request. A random UUID is recommended. Specifying an existing request ID returns the space created with that ID instead of creating a new space. Specifying an ex").optional(),
111
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("Space JSON request body. Top-level fields: accessSettings, adminInstalled, createTime, customer, displayName, externalUserAllowed, importMode, importModeExpireTime, lastActiveTime, membershipCount, name, permissionSettings, +9 more."),
112
+ fields: z.string().optional().describe('Response field mask.'),
113
+ },
114
+ });
115
+ registerGeneratedTool(registry, {
116
+ name: "chat_spaces_delete",
117
+ cud: "delete",
118
+ description: "Deletes a named space. Always performs a cascading delete, which means that the space's child resources—like messages posted in the space and memberships in the",
119
+ method: { id: "chat.spaces.delete", httpMethod: "DELETE", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
120
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "useAdminAccess", "api": "useAdminAccess", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
121
+ hasBody: false,
122
+ shape: {
123
+ account: accountField(),
124
+ name: z.string().describe("Required. Resource name of the space to delete. Format: `spaces/{space}`"),
125
+ useAdminAccess: coerceBoolean.describe("Optional. When `true`, the method runs using the user's Google Workspace administrator privileges. The calling user must be a Google Workspace administrator with the [manage chat and spaces conversati").optional(),
126
+ fields: z.string().optional().describe('Response field mask.'),
127
+ },
128
+ });
129
+ registerGeneratedTool(registry, {
130
+ name: "chat_spaces_find_direct_message",
131
+ cud: "read",
132
+ description: "Returns the existing direct message with the specified user. If no direct message space is found, returns a `404 NOT_FOUND` error. For an example, see [Find a d",
133
+ method: { id: "chat.spaces.findDirectMessage", httpMethod: "GET", path: "v1/spaces:findDirectMessage", baseUrl: "https://chat.googleapis.com/", requiredParams: [] },
134
+ params: [{ "field": "name", "api": "name", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
135
+ hasBody: false,
136
+ shape: {
137
+ account: accountField(),
138
+ name: z.string().describe("Required. Resource name of the user to find direct message with. Format: `users/{user}`, where `{user}` is either the `id` for the [person](https://developers.google.com/people/api/rest/v1/people) fro").optional(),
139
+ fields: z.string().optional().describe('Response field mask.'),
140
+ },
141
+ });
142
+ registerGeneratedTool(registry, {
143
+ name: "chat_spaces_find_group_chats",
144
+ cud: "read",
145
+ description: "Returns all spaces with `spaceType == GROUP_CHAT`, whose human memberships contain exactly the calling user, and the users specified in `FindGroupChatsRequest.u",
146
+ method: { id: "chat.spaces.findGroupChats", httpMethod: "GET", path: "v1/spaces:findGroupChats", baseUrl: "https://chat.googleapis.com/", requiredParams: [] },
147
+ params: [{ "field": "pageSize", "api": "pageSize", "location": "query" }, { "field": "pageToken", "api": "pageToken", "location": "query" }, { "field": "spaceView", "api": "spaceView", "location": "query" }, { "field": "users", "api": "users", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
148
+ hasBody: false,
149
+ shape: {
150
+ account: accountField(),
151
+ pageSize: z.number().describe("Optional. The maximum number of spaces to return. The service might return fewer than this value. If unspecified, at most 10 spaces are returned. The maximum value is 30. If you use a value more than ").optional(),
152
+ pageToken: z.string().describe("Optional. A page token, received from a previous call to find group chats. Provide this parameter to retrieve the subsequent page. When paginating, all other parameters provided should match the call ").optional(),
153
+ spaceView: z.enum(["SPACE_VIEW_UNSPECIFIED", "SPACE_VIEW_RESOURCE_NAME_ONLY", "SPACE_VIEW_EXPANDED"]).describe("Requested space view type. If unset, defaults to `SPACE_VIEW_RESOURCE_NAME_ONLY`. Requests that specify `SPACE_VIEW_EXPANDED` must include scopes that allow reading space data, for example, https://ww").optional(),
154
+ users: coerceArray(z.string()).describe("Optional. Resource names of all human users in group chat with the calling user. Chat apps can't be included in the request. The maximum number of users that can be specified in a single request is `4").optional(),
155
+ fields: z.string().optional().describe('Response field mask.'),
156
+ },
157
+ });
158
+ registerGeneratedTool(registry, {
159
+ name: "chat_spaces_members_create",
160
+ cud: "create",
161
+ description: "Creates a membership for the calling Chat app, a user, or a Google Group. Creating memberships for other Chat apps isn't supported. When creating a membership,",
162
+ method: { id: "chat.spaces.members.create", httpMethod: "POST", path: "v1/{+parent}/members", baseUrl: "https://chat.googleapis.com/", requiredParams: ["parent"] },
163
+ params: [{ "field": "parent", "api": "parent", "location": "path" }, { "field": "useAdminAccess", "api": "useAdminAccess", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
164
+ hasBody: true,
165
+ shape: {
166
+ account: accountField(),
167
+ parent: z.string().describe("Required. The resource name of the space for which to create the membership. Format: spaces/{space}"),
168
+ useAdminAccess: coerceBoolean.describe("Optional. When `true`, the method runs using the user's Google Workspace administrator privileges. The calling user must be a Google Workspace administrator with the [manage chat and spaces conversati").optional(),
169
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("Membership JSON request body. Top-level fields: affiliation, createTime, deleteTime, groupMember, member, name, role, state."),
170
+ fields: z.string().optional().describe('Response field mask.'),
171
+ },
172
+ });
173
+ registerGeneratedTool(registry, {
174
+ name: "chat_spaces_members_delete",
175
+ cud: "delete",
176
+ description: "Deletes a membership. For an example, see [Remove a user or a Google Chat app from a space](https://developers.google.com/workspace/chat/delete-members). Suppor",
177
+ method: { id: "chat.spaces.members.delete", httpMethod: "DELETE", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
178
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "useAdminAccess", "api": "useAdminAccess", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
179
+ hasBody: false,
180
+ shape: {
181
+ account: accountField(),
182
+ name: z.string().describe("Required. Resource name of the membership to delete. Chat apps can delete human users' or their own memberships. Chat apps can't delete other apps' memberships. When deleting a human membership, requi"),
183
+ useAdminAccess: coerceBoolean.describe("Optional. When `true`, the method runs using the user's Google Workspace administrator privileges. The calling user must be a Google Workspace administrator with the [manage chat and spaces conversati").optional(),
184
+ fields: z.string().optional().describe('Response field mask.'),
185
+ },
186
+ });
187
+ registerGeneratedTool(registry, {
188
+ name: "chat_spaces_members_get",
189
+ cud: "read",
190
+ description: "Returns details about a membership. For an example, see [Get details about a user's or Google Chat app's membership](https://developers.google.com/workspace/cha",
191
+ method: { id: "chat.spaces.members.get", httpMethod: "GET", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
192
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "useAdminAccess", "api": "useAdminAccess", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
193
+ hasBody: false,
194
+ shape: {
195
+ account: accountField(),
196
+ name: z.string().describe("Required. Resource name of the membership to retrieve. To get the app's own membership [by using user authentication](https://developers.google.com/workspace/chat/authenticate-authorize-chat-user), yo"),
197
+ useAdminAccess: coerceBoolean.describe("Optional. When `true`, the method runs using the user's Google Workspace administrator privileges. The calling user must be a Google Workspace administrator with the [manage chat and spaces conversati").optional(),
198
+ fields: z.string().optional().describe('Response field mask.'),
199
+ },
200
+ });
201
+ registerGeneratedTool(registry, {
202
+ name: "chat_spaces_members_list",
203
+ cud: "read",
204
+ description: "Lists memberships in a space. For an example, see [List users and Google Chat apps in a space](https://developers.google.com/workspace/chat/list-members). Listi",
205
+ method: { id: "chat.spaces.members.list", httpMethod: "GET", path: "v1/{+parent}/members", baseUrl: "https://chat.googleapis.com/", requiredParams: ["parent"] },
206
+ params: [{ "field": "parent", "api": "parent", "location": "path" }, { "field": "filter", "api": "filter", "location": "query" }, { "field": "pageSize", "api": "pageSize", "location": "query" }, { "field": "pageToken", "api": "pageToken", "location": "query" }, { "field": "showGroups", "api": "showGroups", "location": "query" }, { "field": "showInvited", "api": "showInvited", "location": "query" }, { "field": "useAdminAccess", "api": "useAdminAccess", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
207
+ hasBody: false,
208
+ shape: {
209
+ account: accountField(),
210
+ parent: z.string().describe("Required. The resource name of the space for which to fetch a membership list. Format: spaces/{space}"),
211
+ filter: z.string().describe("Optional. A query filter. You can filter memberships by a member's role ([`role`](https://developers.google.com/workspace/chat/api/reference/rest/v1/spaces.members#membershiprole)) and type ([`member.").optional(),
212
+ pageSize: z.number().describe("Optional. The maximum number of memberships to return. The service might return fewer than this value. If unspecified, at most 100 memberships are returned. The maximum value is 1000. If you use a val").optional(),
213
+ pageToken: z.string().describe("Optional. A page token, received from a previous call to list memberships. Provide this parameter to retrieve the subsequent page. When paginating, all other parameters provided should match the call ").optional(),
214
+ showGroups: coerceBoolean.describe("Optional. When `true`, also returns memberships associated with a Google Group, in addition to other types of memberships. If a filter is set, Google Group memberships that don't match the filter crit").optional(),
215
+ showInvited: coerceBoolean.describe("Optional. When `true`, also returns memberships associated with invited members, in addition to other types of memberships. If a filter is set, invited memberships that don't match the filter criteria").optional(),
216
+ useAdminAccess: coerceBoolean.describe("Optional. When `true`, the method runs using the user's Google Workspace administrator privileges. The calling user must be a Google Workspace administrator with the [manage chat and spaces conversati").optional(),
217
+ fields: z.string().optional().describe('Response field mask.'),
218
+ },
219
+ });
220
+ registerGeneratedTool(registry, {
221
+ name: "chat_spaces_members_patch",
222
+ cud: "update",
223
+ description: "Updates a membership. For an example, see [Update a user's membership in a space](https://developers.google.com/workspace/chat/update-members). Supports the fol",
224
+ method: { id: "chat.spaces.members.patch", httpMethod: "PATCH", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
225
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "updateMask", "api": "updateMask", "location": "query" }, { "field": "useAdminAccess", "api": "useAdminAccess", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
226
+ hasBody: true,
227
+ shape: {
228
+ account: accountField(),
229
+ name: z.string().describe("Identifier. Resource name of the membership, assigned by the server. Format: `spaces/{space}/members/{member}`"),
230
+ updateMask: z.string().describe("Required. The field paths to update. Separate multiple values with commas or use `*` to update all field paths. Currently supported field paths: - `role`").optional(),
231
+ useAdminAccess: coerceBoolean.describe("Optional. When `true`, the method runs using the user's Google Workspace administrator privileges. The calling user must be a Google Workspace administrator with the [manage chat and spaces conversati").optional(),
232
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("Membership JSON request body. Top-level fields: affiliation, createTime, deleteTime, groupMember, member, name, role, state."),
233
+ fields: z.string().optional().describe('Response field mask.'),
234
+ },
235
+ });
236
+ registerGeneratedTool(registry, {
237
+ name: "chat_spaces_messages_attachments_get",
238
+ cud: "read",
239
+ description: "Gets the metadata of a message attachment. The attachment data is fetched using the [media API](https://developers.google.com/workspace/chat/api/reference/rest/",
240
+ method: { id: "chat.spaces.messages.attachments.get", httpMethod: "GET", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
241
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
242
+ hasBody: false,
243
+ shape: {
244
+ account: accountField(),
245
+ name: z.string().describe("Required. Resource name of the attachment, in the form `spaces/{space}/messages/{message}/attachments/{attachment}`."),
246
+ fields: z.string().optional().describe('Response field mask.'),
247
+ },
248
+ });
249
+ registerGeneratedTool(registry, {
250
+ name: "chat_spaces_messages_delete",
251
+ cud: "delete",
252
+ description: "Deletes a message. For an example, see [Delete a message](https://developers.google.com/workspace/chat/delete-messages). Supports the following types of [authen",
253
+ method: { id: "chat.spaces.messages.delete", httpMethod: "DELETE", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
254
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "force", "api": "force", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
255
+ hasBody: false,
256
+ shape: {
257
+ account: accountField(),
258
+ name: z.string().describe("Required. Resource name of the message. Format: `spaces/{space}/messages/{message}` If you've set a custom ID for your message, you can use the value from the `clientAssignedMessageId` field for `{mes"),
259
+ force: coerceBoolean.describe("Optional. When `true`, deleting a message also deletes its threaded replies. When `false`, if a message has threaded replies, deletion fails. Only applies when [authenticating as a user](https://devel").optional(),
260
+ fields: z.string().optional().describe('Response field mask.'),
261
+ },
262
+ });
263
+ registerGeneratedTool(registry, {
264
+ name: "chat_spaces_messages_get",
265
+ cud: "read",
266
+ description: "Returns details about a message. For an example, see [Get details about a message](https://developers.google.com/workspace/chat/get-messages). Supports the foll",
267
+ method: { id: "chat.spaces.messages.get", httpMethod: "GET", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
268
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
269
+ hasBody: false,
270
+ shape: {
271
+ account: accountField(),
272
+ name: z.string().describe("Required. Resource name of the message. Format: `spaces/{space}/messages/{message}` If you've set a custom ID for your message, you can use the value from the `clientAssignedMessageId` field for `{mes"),
273
+ fields: z.string().optional().describe('Response field mask.'),
274
+ },
275
+ });
276
+ registerGeneratedTool(registry, {
277
+ name: "chat_spaces_messages_patch",
278
+ cud: "update",
279
+ description: "Updates a message. There's a difference between the `patch` and `update` methods. The `patch` method uses a `patch` request while the `update` method uses a `pu",
280
+ method: { id: "chat.spaces.messages.patch", httpMethod: "PATCH", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
281
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "allowMissing", "api": "allowMissing", "location": "query" }, { "field": "updateMask", "api": "updateMask", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
282
+ hasBody: true,
283
+ shape: {
284
+ account: accountField(),
285
+ name: z.string().describe("Identifier. Resource name of the message. Format: `spaces/{space}/messages/{message}` Where `{space}` is the ID of the space where the message is posted and `{message}` is a system-assigned ID for the"),
286
+ allowMissing: coerceBoolean.describe("Optional. If `true` and the message isn't found, a new message is created and `updateMask` is ignored. The specified message ID must be [client-assigned](https://developers.google.com/workspace/chat/c").optional(),
287
+ updateMask: z.string().describe("Required. The field paths to update. Separate multiple values with commas or use `*` to update all field paths. Currently supported field paths: - `text` - `attachment` - `cards` (Requires [app authen").optional(),
288
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("Message JSON request body. Top-level fields: accessoryWidgets, actionResponse, annotations, argumentText, attachedGifs, attachment, cards, cardsV2, clientAssignedMessageId, createTime, deleteTime, deletionMetadata, +15 more."),
289
+ fields: z.string().optional().describe('Response field mask.'),
290
+ },
291
+ });
292
+ registerGeneratedTool(registry, {
293
+ name: "chat_spaces_messages_reactions_create",
294
+ cud: "create",
295
+ description: "Creates a reaction and adds it to a message. For an example, see [Add a reaction to a message](https://developers.google.com/workspace/chat/create-reactions). R",
296
+ method: { id: "chat.spaces.messages.reactions.create", httpMethod: "POST", path: "v1/{+parent}/reactions", baseUrl: "https://chat.googleapis.com/", requiredParams: ["parent"] },
297
+ params: [{ "field": "parent", "api": "parent", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
298
+ hasBody: true,
299
+ shape: {
300
+ account: accountField(),
301
+ parent: z.string().describe("Required. The message where the reaction is created. Format: `spaces/{space}/messages/{message}`"),
302
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("Reaction JSON request body. Top-level fields: emoji, name, user."),
303
+ fields: z.string().optional().describe('Response field mask.'),
304
+ },
305
+ });
306
+ registerGeneratedTool(registry, {
307
+ name: "chat_spaces_messages_reactions_delete",
308
+ cud: "delete",
309
+ description: "Deletes a reaction to a message. For an example, see [Delete a reaction](https://developers.google.com/workspace/chat/delete-reactions). Requires [user authenti",
310
+ method: { id: "chat.spaces.messages.reactions.delete", httpMethod: "DELETE", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
311
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
312
+ hasBody: false,
313
+ shape: {
314
+ account: accountField(),
315
+ name: z.string().describe("Required. Name of the reaction to delete. Format: `spaces/{space}/messages/{message}/reactions/{reaction}`"),
316
+ fields: z.string().optional().describe('Response field mask.'),
317
+ },
318
+ });
319
+ registerGeneratedTool(registry, {
320
+ name: "chat_spaces_messages_reactions_list",
321
+ cud: "read",
322
+ description: "Lists reactions to a message. For an example, see [List reactions for a message](https://developers.google.com/workspace/chat/list-reactions). Requires [user au",
323
+ method: { id: "chat.spaces.messages.reactions.list", httpMethod: "GET", path: "v1/{+parent}/reactions", baseUrl: "https://chat.googleapis.com/", requiredParams: ["parent"] },
324
+ params: [{ "field": "parent", "api": "parent", "location": "path" }, { "field": "filter", "api": "filter", "location": "query" }, { "field": "pageSize", "api": "pageSize", "location": "query" }, { "field": "pageToken", "api": "pageToken", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
325
+ hasBody: false,
326
+ shape: {
327
+ account: accountField(),
328
+ parent: z.string().describe("Required. The message users reacted to. Format: `spaces/{space}/messages/{message}`"),
329
+ filter: z.string().describe("Optional. A query filter. You can filter reactions by [emoji](https://developers.google.com/workspace/chat/api/reference/rest/v1/Emoji) (either `emoji.unicode` or `emoji.custom_emoji.uid`) and [user](").optional(),
330
+ pageSize: z.number().describe("Optional. The maximum number of reactions returned. The service can return fewer reactions than this value. If unspecified, the default value is 25. The maximum value is 200; values above 200 are chan").optional(),
331
+ pageToken: z.string().describe("Optional. (If resuming from a previous query.) A page token received from a previous list reactions call. Provide this to retrieve the subsequent page. When paginating, the filter value should match t").optional(),
332
+ fields: z.string().optional().describe('Response field mask.'),
333
+ },
334
+ });
335
+ registerGeneratedTool(registry, {
336
+ name: "chat_spaces_messages_update",
337
+ cud: "update",
338
+ description: "Updates a message. There's a difference between the `patch` and `update` methods. The `patch` method uses a `patch` request while the `update` method uses a `pu",
339
+ method: { id: "chat.spaces.messages.update", httpMethod: "PUT", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
340
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "allowMissing", "api": "allowMissing", "location": "query" }, { "field": "updateMask", "api": "updateMask", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
341
+ hasBody: true,
342
+ shape: {
343
+ account: accountField(),
344
+ name: z.string().describe("Identifier. Resource name of the message. Format: `spaces/{space}/messages/{message}` Where `{space}` is the ID of the space where the message is posted and `{message}` is a system-assigned ID for the"),
345
+ allowMissing: coerceBoolean.describe("Optional. If `true` and the message isn't found, a new message is created and `updateMask` is ignored. The specified message ID must be [client-assigned](https://developers.google.com/workspace/chat/c").optional(),
346
+ updateMask: z.string().describe("Required. The field paths to update. Separate multiple values with commas or use `*` to update all field paths. Currently supported field paths: - `text` - `attachment` - `cards` (Requires [app authen").optional(),
347
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("Message JSON request body. Top-level fields: accessoryWidgets, actionResponse, annotations, argumentText, attachedGifs, attachment, cards, cardsV2, clientAssignedMessageId, createTime, deleteTime, deletionMetadata, +15 more."),
348
+ fields: z.string().optional().describe('Response field mask.'),
349
+ },
350
+ });
351
+ registerGeneratedTool(registry, {
352
+ name: "chat_spaces_patch",
353
+ cud: "update",
354
+ description: "Updates a space. For an example, see [Update a space](https://developers.google.com/workspace/chat/update-spaces). If you're updating the `displayName` field an",
355
+ method: { id: "chat.spaces.patch", httpMethod: "PATCH", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
356
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "updateMask", "api": "updateMask", "location": "query" }, { "field": "useAdminAccess", "api": "useAdminAccess", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
357
+ hasBody: true,
358
+ shape: {
359
+ account: accountField(),
360
+ name: z.string().describe("Identifier. Resource name of the space. Format: `spaces/{space}` Where `{space}` represents the system-assigned ID for the space. You can obtain the space ID by calling the [`spaces.list()`](https://d"),
361
+ updateMask: z.string().describe("Required. The updated field paths, comma separated if there are multiple. You can update the following fields for a space: `space_details`: Updates the space's description and guidelines. You must pas").optional(),
362
+ useAdminAccess: coerceBoolean.describe("Optional. When `true`, the method runs using the user's Google Workspace administrator privileges. The calling user must be a Google Workspace administrator with the [manage chat and spaces conversati").optional(),
363
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("Space JSON request body. Top-level fields: accessSettings, adminInstalled, createTime, customer, displayName, externalUserAllowed, importMode, importModeExpireTime, lastActiveTime, membershipCount, name, permissionSettings, +9 more."),
364
+ fields: z.string().optional().describe('Response field mask.'),
365
+ },
366
+ });
367
+ registerGeneratedTool(registry, {
368
+ name: "chat_spaces_search",
369
+ cud: "read",
370
+ description: "Returns a list of spaces in a Google Workspace organization. For an example, see [Search for and manage spaces](https://developers.google.com/workspace/chat/sea",
371
+ method: { id: "chat.spaces.search", httpMethod: "GET", path: "v1/spaces:search", baseUrl: "https://chat.googleapis.com/", requiredParams: [] },
372
+ params: [{ "field": "orderBy", "api": "orderBy", "location": "query" }, { "field": "pageSize", "api": "pageSize", "location": "query" }, { "field": "pageToken", "api": "pageToken", "location": "query" }, { "field": "query", "api": "query", "location": "query" }, { "field": "useAdminAccess", "api": "useAdminAccess", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
373
+ hasBody: false,
374
+ shape: {
375
+ account: accountField(),
376
+ orderBy: z.string().describe("Optional. How the list of spaces is ordered. Supported attributes to order by are: - `membership_count.joined_direct_human_user_count` — Denotes the count of human users that have directly joined a sp").optional(),
377
+ pageSize: z.number().describe("The maximum number of spaces to return. The service may return fewer than this value. If unspecified, at most 100 spaces are returned. The maximum value is 1000. If you use a value more than 1000, it'").optional(),
378
+ pageToken: z.string().describe("A token, received from the previous search spaces call. Provide this parameter to retrieve the subsequent page. When paginating, all other parameters provided should match the call that provided the p").optional(),
379
+ query: z.string().describe("Required. A search query. You can search by using the following parameters when `useAdminAccess` is set to `true`: - `create_time` - `customer` - `display_name` - `external_user_allowed` - `last_activ").optional(),
380
+ useAdminAccess: coerceBoolean.describe("When `true`, the method runs using the user's Google Workspace administrator privileges. The calling user must be a Google Workspace administrator with the [manage chat and spaces conversations privil").optional(),
381
+ fields: z.string().optional().describe('Response field mask.'),
382
+ },
383
+ });
384
+ registerGeneratedTool(registry, {
385
+ name: "chat_spaces_setup",
386
+ cud: "update",
387
+ description: "Creates a space and adds specified users to it. The calling user is automatically added to the space, and shouldn't be specified as a membership in the request.",
388
+ method: { id: "chat.spaces.setup", httpMethod: "POST", path: "v1/spaces:setup", baseUrl: "https://chat.googleapis.com/", requiredParams: [] },
389
+ params: [{ "field": "fields", "api": "fields", "location": "query" }],
390
+ hasBody: true,
391
+ shape: {
392
+ account: accountField(),
393
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("SetUpSpaceRequest JSON request body. Top-level fields: memberships, requestId, space."),
394
+ fields: z.string().optional().describe('Response field mask.'),
395
+ },
396
+ });
397
+ registerGeneratedTool(registry, {
398
+ name: "chat_spaces_space_events_get",
399
+ cud: "read",
400
+ description: "Returns an event from a Google Chat space. The [event payload](https://developers.google.com/workspace/chat/api/reference/rest/v1/spaces.spaceEvents#SpaceEvent.",
401
+ method: { id: "chat.spaces.spaceEvents.get", httpMethod: "GET", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
402
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
403
+ hasBody: false,
404
+ shape: {
405
+ account: accountField(),
406
+ name: z.string().describe("Required. The resource name of the space event. Format: `spaces/{space}/spaceEvents/{spaceEvent}`"),
407
+ fields: z.string().optional().describe('Response field mask.'),
408
+ },
409
+ });
410
+ registerGeneratedTool(registry, {
411
+ name: "chat_spaces_space_events_list",
412
+ cud: "read",
413
+ description: "Lists events from a Google Chat space. For each event, the [payload](https://developers.google.com/workspace/chat/api/reference/rest/v1/spaces.spaceEvents#Space",
414
+ method: { id: "chat.spaces.spaceEvents.list", httpMethod: "GET", path: "v1/{+parent}/spaceEvents", baseUrl: "https://chat.googleapis.com/", requiredParams: ["parent"] },
415
+ params: [{ "field": "parent", "api": "parent", "location": "path" }, { "field": "filter", "api": "filter", "location": "query" }, { "field": "pageSize", "api": "pageSize", "location": "query" }, { "field": "pageToken", "api": "pageToken", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
416
+ hasBody: false,
417
+ shape: {
418
+ account: accountField(),
419
+ parent: z.string().describe("Required. Resource name of the [Google Chat space](https://developers.google.com/workspace/chat/api/reference/rest/v1/spaces) where the events occurred. Format: `spaces/{space}`."),
420
+ filter: z.string().describe("Required. A query filter. You must specify at least one event type (`event_type`) using the has `:` operator. To filter by multiple event types, use the `OR` operator. Omit batch event types in your f").optional(),
421
+ pageSize: z.number().describe("Optional. The maximum number of space events returned. The service might return fewer than this value. Negative values return an `INVALID_ARGUMENT` error.").optional(),
422
+ pageToken: z.string().describe("Optional. A page token, received from a previous list space events call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided to list space events must match th").optional(),
423
+ fields: z.string().optional().describe('Response field mask.'),
424
+ },
425
+ });
426
+ registerGeneratedTool(registry, {
427
+ name: "chat_users_availability_get",
428
+ cud: "read",
429
+ description: "Returns availability information for a human user in Google Chat. For example, this can be used to check if a user is online or away, or to retrieve their custo",
430
+ method: { id: "chat.users.availability.get", httpMethod: "GET", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
431
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
432
+ hasBody: false,
433
+ shape: {
434
+ account: accountField(),
435
+ name: z.string().describe("Required. The resource name of the availability to retrieve. Format: users/{user}/availability `{user}` is the id for the Person in the People API or Admin SDK directory API. For example, `users/12345"),
436
+ fields: z.string().optional().describe('Response field mask.'),
437
+ },
438
+ });
439
+ registerGeneratedTool(registry, {
440
+ name: "chat_users_availability_mark_as_active",
441
+ cud: "create",
442
+ description: "Marks user as `ACTIVE` in Google Chat. Sets the user's availability state to `ACTIVE`. The `ACTIVE` state lasts until the specified expiration, at which point t",
443
+ method: { id: "chat.users.availability.markAsActive", httpMethod: "POST", path: "v1/{+name}:markAsActive", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
444
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
445
+ hasBody: true,
446
+ shape: {
447
+ account: accountField(),
448
+ name: z.string().describe("Required. The resource name of the availability to mark as active. Format: users/{user}/availability `{user}` is the id for the Person in the People API or Admin SDK directory API. For example, `users"),
449
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("MarkAsActiveRequest JSON request body. Top-level fields: expireTime, ttl."),
450
+ fields: z.string().optional().describe('Response field mask.'),
451
+ },
452
+ });
453
+ registerGeneratedTool(registry, {
454
+ name: "chat_users_availability_mark_as_away",
455
+ cud: "create",
456
+ description: "Marks user as `AWAY` in Google Chat. Sets the user's state to away and is not affected by the user's activity. This method only updates the authenticated user's",
457
+ method: { id: "chat.users.availability.markAsAway", httpMethod: "POST", path: "v1/{+name}:markAsAway", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
458
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
459
+ hasBody: true,
460
+ shape: {
461
+ account: accountField(),
462
+ name: z.string().describe("Required. The resource name of the availability to mark as away. Format: users/{user}/availability `{user}` is the id for the Person in the People API or Admin SDK directory API. For example, `users/1"),
463
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("MarkAsAwayRequest JSON request body."),
464
+ fields: z.string().optional().describe('Response field mask.'),
465
+ },
466
+ });
467
+ registerGeneratedTool(registry, {
468
+ name: "chat_users_availability_mark_as_do_not_disturb",
469
+ cud: "create",
470
+ description: "Marks user as `DO_NOT_DISTURB` in Google Chat. Sets a user's availability state to `DO_NOT_DISTURB` until a specified expiration time. When in `DO_NOT_DISTURB`,",
471
+ method: { id: "chat.users.availability.markAsDoNotDisturb", httpMethod: "POST", path: "v1/{+name}:markAsDoNotDisturb", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
472
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
473
+ hasBody: true,
474
+ shape: {
475
+ account: accountField(),
476
+ name: z.string().describe("Required. The resource name of the availability to mark as Do Not Disturb. Format: users/{user}/availability `{user}` is the id for the Person in the People API or Admin SDK directory API. For example"),
477
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("MarkAsDoNotDisturbRequest JSON request body. Top-level fields: expireTime, ttl."),
478
+ fields: z.string().optional().describe('Response field mask.'),
479
+ },
480
+ });
481
+ registerGeneratedTool(registry, {
482
+ name: "chat_users_availability_patch",
483
+ cud: "update",
484
+ description: "Updates availability information for a human user. Only the `custom_status` field can be updated through this method. This method only updates the authenticated",
485
+ method: { id: "chat.users.availability.patch", httpMethod: "PATCH", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
486
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "updateMask", "api": "updateMask", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
487
+ hasBody: true,
488
+ shape: {
489
+ account: accountField(),
490
+ name: z.string().describe("Identifier. Resource name of the user's availability. Format: `users/{user}/availability` `{user}` is the id for the Person in the People API or Admin SDK directory API. For example, `users/123456789`"),
491
+ updateMask: z.string().describe("Required. The list of fields to update. The only field that can be updated is `custom_status`.").optional(),
492
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("Availability JSON request body. Top-level fields: customStatus, doNotDisturbMetadata, name, state."),
493
+ fields: z.string().optional().describe('Response field mask.'),
494
+ },
495
+ });
496
+ registerGeneratedTool(registry, {
497
+ name: "chat_users_sections_create",
498
+ cud: "create",
499
+ description: "Creates a section in Google Chat. Sections help users group conversations and customize the list of spaces displayed in Chat navigation panel. Only sections of",
500
+ method: { id: "chat.users.sections.create", httpMethod: "POST", path: "v1/{+parent}/sections", baseUrl: "https://chat.googleapis.com/", requiredParams: ["parent"] },
501
+ params: [{ "field": "parent", "api": "parent", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
502
+ hasBody: true,
503
+ shape: {
504
+ account: accountField(),
505
+ parent: z.string().describe("Required. The parent resource name where the section is created. Format: `users/{user}`"),
506
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("GoogleChatV1Section JSON request body. Top-level fields: displayName, name, sortOrder, type."),
507
+ fields: z.string().optional().describe('Response field mask.'),
508
+ },
509
+ });
510
+ registerGeneratedTool(registry, {
511
+ name: "chat_users_sections_delete",
512
+ cud: "delete",
513
+ description: "Deletes a section of type `CUSTOM_SECTION`. If the section contains items, such as spaces, the items are moved to Google Chat's default sections and are not del",
514
+ method: { id: "chat.users.sections.delete", httpMethod: "DELETE", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
515
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
516
+ hasBody: false,
517
+ shape: {
518
+ account: accountField(),
519
+ name: z.string().describe("Required. The name of the section to delete. Format: `users/{user}/sections/{section}`"),
520
+ fields: z.string().optional().describe('Response field mask.'),
521
+ },
522
+ });
523
+ registerGeneratedTool(registry, {
524
+ name: "chat_users_sections_items_list",
525
+ cud: "read",
526
+ description: "Lists items in a section. Only spaces can be section items. For details, see [Create and organize sections in Google Chat](https://support.google.com/chat/answe",
527
+ method: { id: "chat.users.sections.items.list", httpMethod: "GET", path: "v1/{+parent}/items", baseUrl: "https://chat.googleapis.com/", requiredParams: ["parent"] },
528
+ params: [{ "field": "parent", "api": "parent", "location": "path" }, { "field": "filter", "api": "filter", "location": "query" }, { "field": "pageSize", "api": "pageSize", "location": "query" }, { "field": "pageToken", "api": "pageToken", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
529
+ hasBody: false,
530
+ shape: {
531
+ account: accountField(),
532
+ parent: z.string().describe("Required. The parent, which is the section resource name that owns this collection of section items. Only supports listing section items for the calling user. When you're filtering by space, use the w"),
533
+ filter: z.string().describe("Optional. A query filter. Currently only supports filtering by space. For example, `space = spaces/{space}`. Invalid queries are rejected with an `INVALID_ARGUMENT` error.").optional(),
534
+ pageSize: z.number().describe("Optional. The maximum number of section items to return. The service may return fewer than this value. If unspecified, at most 10 section items will be returned. The maximum value is 100. If you use a").optional(),
535
+ pageToken: z.string().describe("Optional. A page token, received from a previous list section items call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided should match the call that provid").optional(),
536
+ fields: z.string().optional().describe('Response field mask.'),
537
+ },
538
+ });
539
+ registerGeneratedTool(registry, {
540
+ name: "chat_users_sections_items_move",
541
+ cud: "update",
542
+ description: "Moves an item from one section to another. For example, if a section contains spaces, this method can be used to move a space to a different section. For detail",
543
+ method: { id: "chat.users.sections.items.move", httpMethod: "POST", path: "v1/{+name}:move", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
544
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
545
+ hasBody: true,
546
+ shape: {
547
+ account: accountField(),
548
+ name: z.string().describe("Required. The resource name of the section item to move. Format: `users/{user}/sections/{section}/items/{item}`"),
549
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("MoveSectionItemRequest JSON request body. Top-level fields: targetSection."),
550
+ fields: z.string().optional().describe('Response field mask.'),
551
+ },
552
+ });
553
+ registerGeneratedTool(registry, {
554
+ name: "chat_users_sections_list",
555
+ cud: "read",
556
+ description: "Lists sections available to the Chat user. Sections help users group their conversations and customize the list of spaces displayed in Chat navigation panel. Fo",
557
+ method: { id: "chat.users.sections.list", httpMethod: "GET", path: "v1/{+parent}/sections", baseUrl: "https://chat.googleapis.com/", requiredParams: ["parent"] },
558
+ params: [{ "field": "parent", "api": "parent", "location": "path" }, { "field": "pageSize", "api": "pageSize", "location": "query" }, { "field": "pageToken", "api": "pageToken", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
559
+ hasBody: false,
560
+ shape: {
561
+ account: accountField(),
562
+ parent: z.string().describe("Required. The parent, which is the user resource name that owns this collection of sections. Only supports listing sections for the calling user. To refer to the calling user, set one of the following"),
563
+ pageSize: z.number().describe("Optional. The maximum number of sections to return. The service may return fewer than this value. If unspecified, at most 10 sections will be returned. The maximum value is 100. If you use a value mor").optional(),
564
+ pageToken: z.string().describe("Optional. A page token, received from a previous list sections call. Provide this to retrieve the subsequent page. When paginating, all other parameters provided should match the call that provided th").optional(),
565
+ fields: z.string().optional().describe('Response field mask.'),
566
+ },
567
+ });
568
+ registerGeneratedTool(registry, {
569
+ name: "chat_users_sections_patch",
570
+ cud: "update",
571
+ description: "Updates a section. Only sections of type `CUSTOM_SECTION` can be updated. For details, see [Create and organize sections in Google Chat](https://support.google.",
572
+ method: { id: "chat.users.sections.patch", httpMethod: "PATCH", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
573
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "updateMask", "api": "updateMask", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
574
+ hasBody: true,
575
+ shape: {
576
+ account: accountField(),
577
+ name: z.string().describe("Identifier. Resource name of the section. For system sections, the section ID is a constant string: - DEFAULT_DIRECT_MESSAGES: `users/{user}/sections/default-direct-messages` - DEFAULT_SPACES: `users/"),
578
+ updateMask: z.string().describe("Required. The mask to specify which fields to update. Currently supported field paths: - `display_name`").optional(),
579
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("GoogleChatV1Section JSON request body. Top-level fields: displayName, name, sortOrder, type."),
580
+ fields: z.string().optional().describe('Response field mask.'),
581
+ },
582
+ });
583
+ registerGeneratedTool(registry, {
584
+ name: "chat_users_sections_position",
585
+ cud: "create",
586
+ description: "Changes the sort order of a section. For details, see [Create and organize sections in Google Chat](https://support.google.com/chat/answer/16059854). Requires [",
587
+ method: { id: "chat.users.sections.position", httpMethod: "POST", path: "v1/{+name}:position", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
588
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
589
+ hasBody: true,
590
+ shape: {
591
+ account: accountField(),
592
+ name: z.string().describe("Required. The resource name of the section to position. Format: `users/{user}/sections/{section}`"),
593
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("PositionSectionRequest JSON request body. Top-level fields: relativePosition, sortOrder."),
594
+ fields: z.string().optional().describe('Response field mask.'),
595
+ },
596
+ });
597
+ registerGeneratedTool(registry, {
598
+ name: "chat_users_spaces_get_space_read_state",
599
+ cud: "read",
600
+ description: "Returns details about a user's read state within a space, used to identify read and unread messages. For an example, see [Get details about a user's space read",
601
+ method: { id: "chat.users.spaces.getSpaceReadState", httpMethod: "GET", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
602
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
603
+ hasBody: false,
604
+ shape: {
605
+ account: accountField(),
606
+ name: z.string().describe("Required. Resource name of the space read state to retrieve. Only supports getting read state for the calling user. To refer to the calling user, set one of the following: - The `me` alias. For exampl"),
607
+ fields: z.string().optional().describe('Response field mask.'),
608
+ },
609
+ });
610
+ registerGeneratedTool(registry, {
611
+ name: "chat_users_spaces_space_notification_setting_get",
612
+ cud: "read",
613
+ description: "Gets the space notification setting. For an example, see [Get the caller's space notification setting](https://developers.google.com/workspace/chat/get-space-no",
614
+ method: { id: "chat.users.spaces.spaceNotificationSetting.get", httpMethod: "GET", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
615
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
616
+ hasBody: false,
617
+ shape: {
618
+ account: accountField(),
619
+ name: z.string().describe("Required. Format: users/{user}/spaces/{space}/spaceNotificationSetting - `users/me/spaces/{space}/spaceNotificationSetting`, OR - `users/user@example.com/spaces/{space}/spaceNotificationSetting`, OR -"),
620
+ fields: z.string().optional().describe('Response field mask.'),
621
+ },
622
+ });
623
+ registerGeneratedTool(registry, {
624
+ name: "chat_users_spaces_space_notification_setting_patch",
625
+ cud: "update",
626
+ description: "Updates the space notification setting. For an example, see [Update the caller's space notification setting](https://developers.google.com/workspace/chat/update",
627
+ method: { id: "chat.users.spaces.spaceNotificationSetting.patch", httpMethod: "PATCH", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
628
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "updateMask", "api": "updateMask", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
629
+ hasBody: true,
630
+ shape: {
631
+ account: accountField(),
632
+ name: z.string().describe("Identifier. The resource name of the space notification setting. Format: `users/{user}/spaces/{space}/spaceNotificationSetting`."),
633
+ updateMask: z.string().describe("Required. Supported field paths: - `notification_setting` - `mute_setting`").optional(),
634
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("SpaceNotificationSetting JSON request body. Top-level fields: muteSetting, name, notificationSetting."),
635
+ fields: z.string().optional().describe('Response field mask.'),
636
+ },
637
+ });
638
+ registerGeneratedTool(registry, {
639
+ name: "chat_users_spaces_threads_get_thread_read_state",
640
+ cud: "read",
641
+ description: "Returns details about a user's read state within a thread, used to identify read and unread messages. For an example, see [Get details about a user's thread rea",
642
+ method: { id: "chat.users.spaces.threads.getThreadReadState", httpMethod: "GET", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
643
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "fields", "api": "fields", "location": "query" }],
644
+ hasBody: false,
645
+ shape: {
646
+ account: accountField(),
647
+ name: z.string().describe("Required. Resource name of the thread read state to retrieve. Only supports getting read state for the calling user. To refer to the calling user, set one of the following: - The `me` alias. For examp"),
648
+ fields: z.string().optional().describe('Response field mask.'),
649
+ },
650
+ });
651
+ registerGeneratedTool(registry, {
652
+ name: "chat_users_spaces_update_space_read_state",
653
+ cud: "update",
654
+ description: "Updates a user's read state within a space, used to identify read and unread messages. For an example, see [Update a user's space read state](https://developers",
655
+ method: { id: "chat.users.spaces.updateSpaceReadState", httpMethod: "PATCH", path: "v1/{+name}", baseUrl: "https://chat.googleapis.com/", requiredParams: ["name"] },
656
+ params: [{ "field": "name", "api": "name", "location": "path" }, { "field": "updateMask", "api": "updateMask", "location": "query" }, { "field": "fields", "api": "fields", "location": "query" }],
657
+ hasBody: true,
658
+ shape: {
659
+ account: accountField(),
660
+ name: z.string().describe("Resource name of the space read state. Format: `users/{user}/spaces/{space}/spaceReadState`"),
661
+ updateMask: z.string().describe("Required. The field paths to update. Currently supported field paths: - `last_read_time` When the `last_read_time` is before the latest message create time, the space appears as unread in the UI. To m").optional(),
662
+ body: coerceJson(z.record(z.string(), z.unknown())).describe("SpaceReadState JSON request body. Top-level fields: lastReadTime, name."),
663
+ fields: z.string().optional().describe('Response field mask.'),
664
+ },
665
+ });
666
+ }