mcp-google-multi 6.0.0-beta.4 → 6.0.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/README.md +15 -1
- package/dist/discover.js +2 -3
- package/dist/fs-atomic.js +98 -12
- package/dist/hint-provider.d.ts +4 -1
- package/dist/mcp-token.d.ts +37 -3
- package/dist/mcp-token.js +105 -12
- package/dist/oauth-as.d.ts +5 -0
- package/dist/oauth-as.js +13 -5
- package/dist/registry.d.ts +2 -0
- package/dist/registry.js +59 -10
- package/dist/tools/accounts-tool.d.ts +7 -0
- package/dist/tools/accounts-tool.js +17 -6
- package/dist/tools/admin.js +6 -1
- package/dist/tools/analytics.js +28 -11
- package/dist/tools/calendar.d.ts +5 -0
- package/dist/tools/calendar.js +59 -0
- package/dist/tools/contacts.js +11 -5
- package/dist/tools/docs.js +41 -12
- package/dist/tools/drive.js +54 -12
- package/dist/tools/generated/gmail.js +0 -14
- package/dist/tools/generated/method-map.js +1 -1
- package/dist/tools/gmail.d.ts +1 -1
- package/dist/tools/gmail.js +109 -12
- package/dist/tools/sheets.d.ts +10 -0
- package/dist/tools/sheets.js +109 -2
- package/dist/write-control.js +15 -2
- package/package.json +4 -2
- package/skills/google-workspace/SKILL.md +162 -0
- package/skills/google-workspace/reference/admin.md +105 -0
- package/skills/google-workspace/reference/analytics.md +70 -0
- package/skills/google-workspace/reference/appsmarket.md +5 -0
- package/skills/google-workspace/reference/calendar.md +175 -0
- package/skills/google-workspace/reference/chat.md +59 -0
- package/skills/google-workspace/reference/classroom.md +5 -0
- package/skills/google-workspace/reference/cloudidentity.md +5 -0
- package/skills/google-workspace/reference/cloudsearch.md +5 -0
- package/skills/google-workspace/reference/contacts.md +138 -0
- package/skills/google-workspace/reference/docs.md +395 -0
- package/skills/google-workspace/reference/drive.md +485 -0
- package/skills/google-workspace/reference/driveactivity.md +5 -0
- package/skills/google-workspace/reference/drivelabels.md +5 -0
- package/skills/google-workspace/reference/forms.md +92 -0
- package/skills/google-workspace/reference/gmail.md +305 -0
- package/skills/google-workspace/reference/groupsmigration.md +5 -0
- package/skills/google-workspace/reference/groupssettings.md +5 -0
- package/skills/google-workspace/reference/keep.md +5 -0
- package/skills/google-workspace/reference/licensing.md +5 -0
- package/skills/google-workspace/reference/meet.md +68 -0
- package/skills/google-workspace/reference/postmaster.md +5 -0
- package/skills/google-workspace/reference/reseller.md +5 -0
- package/skills/google-workspace/reference/script.md +5 -0
- package/skills/google-workspace/reference/searchconsole.md +128 -0
- package/skills/google-workspace/reference/sheets.md +430 -0
- package/skills/google-workspace/reference/slides.md +67 -0
- package/skills/google-workspace/reference/tasks.md +167 -0
- package/skills/google-workspace/reference/vault.md +5 -0
- package/skills/google-workspace/reference/workspaceevents.md +5 -0
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
# contacts
|
|
2
|
+
|
|
3
|
+
<!-- GENERATED by scripts/gen-skill.ts, do not edit by hand. Regenerate: npm run gen:skill -->
|
|
4
|
+
|
|
5
|
+
10 curated tools, plus 14 generated tools (Google Discovery parameter names; see `contacts_discover`).
|
|
6
|
+
|
|
7
|
+
## `contacts_create`
|
|
8
|
+
|
|
9
|
+
Class: create
|
|
10
|
+
|
|
11
|
+
Create a new contact
|
|
12
|
+
|
|
13
|
+
| Argument | Type | Required | Description |
|
|
14
|
+
|---|---|---|---|
|
|
15
|
+
| `account` | string | optional | Google account alias |
|
|
16
|
+
| `givenName` | string | required | First name |
|
|
17
|
+
| `familyName` | string | optional | Last name |
|
|
18
|
+
| `email` | string | optional | Email address |
|
|
19
|
+
| `emailType` | enum | optional | Email type (default: work) |
|
|
20
|
+
| `phone` | string | optional | Phone number |
|
|
21
|
+
| `phoneType` | enum | optional | Phone type (default: mobile) |
|
|
22
|
+
| `organization` | string | optional | Company/organization name |
|
|
23
|
+
| `jobTitle` | string | optional | Job title |
|
|
24
|
+
|
|
25
|
+
## `contacts_delete`
|
|
26
|
+
|
|
27
|
+
Class: delete
|
|
28
|
+
|
|
29
|
+
Delete a contact (permanent, cannot be undone)
|
|
30
|
+
|
|
31
|
+
| Argument | Type | Required | Description |
|
|
32
|
+
|---|---|---|---|
|
|
33
|
+
| `account` | string | optional | Google account alias |
|
|
34
|
+
| `resourceName` | string | required | Contact resource name (e.g. "people/c1234567890") |
|
|
35
|
+
|
|
36
|
+
## `contacts_get`
|
|
37
|
+
|
|
38
|
+
Class: read
|
|
39
|
+
|
|
40
|
+
Get a single contact by resource name
|
|
41
|
+
|
|
42
|
+
| Argument | Type | Required | Description |
|
|
43
|
+
|---|---|---|---|
|
|
44
|
+
| `account` | string | optional | Google account alias; "*" = all accounts; omit for the default account |
|
|
45
|
+
| `resourceName` | string | required | Contact resource name (e.g. "people/c1234567890") |
|
|
46
|
+
|
|
47
|
+
## `contacts_group_create`
|
|
48
|
+
|
|
49
|
+
Class: create
|
|
50
|
+
|
|
51
|
+
Create a new contact group (label)
|
|
52
|
+
|
|
53
|
+
| Argument | Type | Required | Description |
|
|
54
|
+
|---|---|---|---|
|
|
55
|
+
| `account` | string | optional | Google account alias |
|
|
56
|
+
| `name` | string | required | Name for the contact group |
|
|
57
|
+
|
|
58
|
+
## `contacts_group_members`
|
|
59
|
+
|
|
60
|
+
Class: read
|
|
61
|
+
|
|
62
|
+
List members of a contact group
|
|
63
|
+
|
|
64
|
+
| Argument | Type | Required | Description |
|
|
65
|
+
|---|---|---|---|
|
|
66
|
+
| `account` | string | optional | Google account alias; "*" = all accounts; omit for the default account |
|
|
67
|
+
| `groupResourceName` | string | required | Contact group resource name (e.g. "contactGroups/abc123") |
|
|
68
|
+
| `maxMembers` | number | optional | Max member resource names to return (default: 100) |
|
|
69
|
+
|
|
70
|
+
## `contacts_groups_list`
|
|
71
|
+
|
|
72
|
+
Class: read
|
|
73
|
+
|
|
74
|
+
List all contact groups (labels)
|
|
75
|
+
|
|
76
|
+
| Argument | Type | Required | Description |
|
|
77
|
+
|---|---|---|---|
|
|
78
|
+
| `account` | string | optional | Google account alias; "*" = all accounts; omit for the default account |
|
|
79
|
+
| `pageSize` | number | optional | Max groups to return (default: 100) |
|
|
80
|
+
|
|
81
|
+
## `contacts_list`
|
|
82
|
+
|
|
83
|
+
Class: read
|
|
84
|
+
|
|
85
|
+
List all contacts (paginated)
|
|
86
|
+
|
|
87
|
+
| Argument | Type | Required | Description |
|
|
88
|
+
|---|---|---|---|
|
|
89
|
+
| `account` | string | optional | Google account alias; "*" = all accounts; omit for the default account |
|
|
90
|
+
| `pageSize` | number | optional | Number of contacts per page (default: 50) |
|
|
91
|
+
| `pageToken` | string | optional | Page token for pagination |
|
|
92
|
+
| `sortOrder` | enum | optional | Sort order (default: FIRST_NAME_ASCENDING) |
|
|
93
|
+
| `requireEmail` | boolean | optional | Only return contacts with at least one email address. Filtering happens after the page is fetched, so the returned page can hold fewer than pageSize contacts; nextPageToken still continues the underlying, unfiltered listing |
|
|
94
|
+
| `requireName` | boolean | optional | Only return contacts with a name. Filtering happens after the page is fetched, so the returned page can hold fewer than pageSize contacts; nextPageToken still continues the underlying, unfiltered listing |
|
|
95
|
+
|
|
96
|
+
## `contacts_resolve`
|
|
97
|
+
|
|
98
|
+
Class: read
|
|
99
|
+
|
|
100
|
+
Resolve a free-text name/alias to ONE canonical email address (ranked + tie-broken), so you need not hand-expand transliteration OR-queries. Returns a single confident match, an explicit ambiguous candidate list, or null when nothing matches. For picking a recipient before gmail_send.
|
|
101
|
+
|
|
102
|
+
| Argument | Type | Required | Description |
|
|
103
|
+
|---|---|---|---|
|
|
104
|
+
| `account` | string | optional | Google account alias; "*" = all accounts; omit for the default account |
|
|
105
|
+
| `name` | string | required | Free-text name or alias to resolve (e.g. "Zoe") |
|
|
106
|
+
| `maxCandidates` | number | optional | Max candidates to return when ambiguous (1-10, default: 5) |
|
|
107
|
+
| `includeOtherContacts` | boolean | optional | Also search auto-saved "other contacts" (people you have emailed but not saved). Default true. |
|
|
108
|
+
|
|
109
|
+
## `contacts_search`
|
|
110
|
+
|
|
111
|
+
Class: read
|
|
112
|
+
|
|
113
|
+
Search contacts by name, email, phone, or organization
|
|
114
|
+
|
|
115
|
+
| Argument | Type | Required | Description |
|
|
116
|
+
|---|---|---|---|
|
|
117
|
+
| `account` | string | optional | Google account alias; "*" = all accounts; omit for the default account |
|
|
118
|
+
| `query` | string | required | Search query (prefix matching on names, emails, phones, organizations) |
|
|
119
|
+
| `pageSize` | number | optional | Max results (1-30, default: 10) |
|
|
120
|
+
|
|
121
|
+
## `contacts_update`
|
|
122
|
+
|
|
123
|
+
Class: update
|
|
124
|
+
|
|
125
|
+
Update an existing contact (reads current etag automatically)
|
|
126
|
+
|
|
127
|
+
| Argument | Type | Required | Description |
|
|
128
|
+
|---|---|---|---|
|
|
129
|
+
| `account` | string | optional | Google account alias |
|
|
130
|
+
| `resourceName` | string | required | Contact resource name (e.g. "people/c1234567890") |
|
|
131
|
+
| `givenName` | string | optional | Updated first name |
|
|
132
|
+
| `familyName` | string | optional | Updated last name |
|
|
133
|
+
| `email` | string | optional | Updated email address |
|
|
134
|
+
| `emailType` | enum | optional | Email type |
|
|
135
|
+
| `phone` | string | optional | Updated phone number |
|
|
136
|
+
| `phoneType` | enum | optional | Phone type |
|
|
137
|
+
| `organization` | string | optional | Updated company/organization name |
|
|
138
|
+
| `jobTitle` | string | optional | Updated job title |
|
|
@@ -0,0 +1,395 @@
|
|
|
1
|
+
# docs
|
|
2
|
+
|
|
3
|
+
<!-- GENERATED by scripts/gen-skill.ts, do not edit by hand. Regenerate: npm run gen:skill -->
|
|
4
|
+
|
|
5
|
+
27 curated tools.
|
|
6
|
+
|
|
7
|
+
## `docs_add_tab`
|
|
8
|
+
|
|
9
|
+
Class: create
|
|
10
|
+
|
|
11
|
+
Add a new tab to a document. Can be a top-level tab or nested as a child of an existing tab.
|
|
12
|
+
|
|
13
|
+
| Argument | Type | Required | Description |
|
|
14
|
+
|---|---|---|---|
|
|
15
|
+
| `account` | string | optional | Google account alias |
|
|
16
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
17
|
+
| `title` | string | required | Tab title |
|
|
18
|
+
| `parentTabId` | string | optional | Parent tab ID (omit for top-level) |
|
|
19
|
+
| `index` | number | optional | Position among siblings |
|
|
20
|
+
|
|
21
|
+
## `docs_batch_update`
|
|
22
|
+
|
|
23
|
+
Class: update
|
|
24
|
+
|
|
25
|
+
Generic documents.batchUpdate pass-through. Accepts the full Request union (40 types). See https://developers.google.com/workspace/docs/api/reference/rest/v1/documents/request
|
|
26
|
+
|
|
27
|
+
| Argument | Type | Required | Description |
|
|
28
|
+
|---|---|---|---|
|
|
29
|
+
| `account` | string | optional | Google account alias |
|
|
30
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
31
|
+
| `requests` | array | required | Array of Request objects, each with one request-type key |
|
|
32
|
+
| `writeControl` | object | optional | Optional optimistic concurrency control |
|
|
33
|
+
|
|
34
|
+
## `docs_create`
|
|
35
|
+
|
|
36
|
+
Class: create
|
|
37
|
+
|
|
38
|
+
Create a new Google Docs document
|
|
39
|
+
|
|
40
|
+
| Argument | Type | Required | Description |
|
|
41
|
+
|---|---|---|---|
|
|
42
|
+
| `account` | string | optional | Google account alias |
|
|
43
|
+
| `title` | string | required | Document title |
|
|
44
|
+
|
|
45
|
+
## `docs_create_footer`
|
|
46
|
+
|
|
47
|
+
Class: create
|
|
48
|
+
|
|
49
|
+
Create a footer for the document or a specific section
|
|
50
|
+
|
|
51
|
+
| Argument | Type | Required | Description |
|
|
52
|
+
|---|---|---|---|
|
|
53
|
+
| `account` | string | optional | Google account alias |
|
|
54
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
55
|
+
| `sectionBreakIndex` | number | optional | |
|
|
56
|
+
|
|
57
|
+
## `docs_create_header`
|
|
58
|
+
|
|
59
|
+
Class: create
|
|
60
|
+
|
|
61
|
+
Create a header for the document or for a specific section. The new header is empty; insert text into it with docs_insert_text targeting its segmentId.
|
|
62
|
+
|
|
63
|
+
| Argument | Type | Required | Description |
|
|
64
|
+
|---|---|---|---|
|
|
65
|
+
| `account` | string | optional | Google account alias |
|
|
66
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
67
|
+
| `sectionBreakIndex` | number | optional | Anchor to a specific section break; omit to apply to the document |
|
|
68
|
+
|
|
69
|
+
## `docs_create_named_range`
|
|
70
|
+
|
|
71
|
+
Class: create
|
|
72
|
+
|
|
73
|
+
Tag a range of text with a name. Multiple ranges can share the same name. Used as a template anchor for docs_replace_named_range_content.
|
|
74
|
+
|
|
75
|
+
| Argument | Type | Required | Description |
|
|
76
|
+
|---|---|---|---|
|
|
77
|
+
| `account` | string | optional | Google account alias |
|
|
78
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
79
|
+
| `name` | string | required | Name (1-256 chars). Need not be unique. |
|
|
80
|
+
| `startIndex` | number | required | Range start (inclusive) |
|
|
81
|
+
| `endIndex` | number | required | Range end (exclusive) |
|
|
82
|
+
|
|
83
|
+
## `docs_create_paragraph_bullets`
|
|
84
|
+
|
|
85
|
+
Class: create
|
|
86
|
+
|
|
87
|
+
Turn paragraphs in a range into a bulleted or numbered list
|
|
88
|
+
|
|
89
|
+
| Argument | Type | Required | Description |
|
|
90
|
+
|---|---|---|---|
|
|
91
|
+
| `account` | string | optional | Google account alias |
|
|
92
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
93
|
+
| `startIndex` | number | required | |
|
|
94
|
+
| `endIndex` | number | required | |
|
|
95
|
+
| `bulletPreset` | enum | required | Bullet/numbering preset |
|
|
96
|
+
|
|
97
|
+
## `docs_delete_footer`
|
|
98
|
+
|
|
99
|
+
Class: delete
|
|
100
|
+
|
|
101
|
+
Delete a footer by its footerId
|
|
102
|
+
|
|
103
|
+
| Argument | Type | Required | Description |
|
|
104
|
+
|---|---|---|---|
|
|
105
|
+
| `account` | string | optional | Google account alias |
|
|
106
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
107
|
+
| `footerId` | string | required | Footer ID |
|
|
108
|
+
|
|
109
|
+
## `docs_delete_header`
|
|
110
|
+
|
|
111
|
+
Class: delete
|
|
112
|
+
|
|
113
|
+
Delete a header by its headerId
|
|
114
|
+
|
|
115
|
+
| Argument | Type | Required | Description |
|
|
116
|
+
|---|---|---|---|
|
|
117
|
+
| `account` | string | optional | Google account alias |
|
|
118
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
119
|
+
| `headerId` | string | required | Header ID (from docs_get or createHeader reply) |
|
|
120
|
+
|
|
121
|
+
## `docs_delete_named_range`
|
|
122
|
+
|
|
123
|
+
Class: delete
|
|
124
|
+
|
|
125
|
+
Delete a named range by its ID or by name. Removes every range matching the identifier.
|
|
126
|
+
|
|
127
|
+
| Argument | Type | Required | Description |
|
|
128
|
+
|---|---|---|---|
|
|
129
|
+
| `account` | string | optional | Google account alias |
|
|
130
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
131
|
+
| `namedRangeId` | string | optional | Specific named range ID |
|
|
132
|
+
| `name` | string | optional | Name (deletes ALL named ranges with this name) |
|
|
133
|
+
|
|
134
|
+
## `docs_delete_paragraph_bullets`
|
|
135
|
+
|
|
136
|
+
Class: delete
|
|
137
|
+
|
|
138
|
+
Strip bullet/number formatting from paragraphs in a range
|
|
139
|
+
|
|
140
|
+
| Argument | Type | Required | Description |
|
|
141
|
+
|---|---|---|---|
|
|
142
|
+
| `account` | string | optional | Google account alias |
|
|
143
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
144
|
+
| `startIndex` | number | required | |
|
|
145
|
+
| `endIndex` | number | required | |
|
|
146
|
+
|
|
147
|
+
## `docs_delete_range`
|
|
148
|
+
|
|
149
|
+
Class: delete
|
|
150
|
+
|
|
151
|
+
Delete content in a character index range within a document
|
|
152
|
+
|
|
153
|
+
| Argument | Type | Required | Description |
|
|
154
|
+
|---|---|---|---|
|
|
155
|
+
| `account` | string | optional | Google account alias |
|
|
156
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
157
|
+
| `startIndex` | number | required | Start index (inclusive, 1-based) |
|
|
158
|
+
| `endIndex` | number | required | End index (exclusive) |
|
|
159
|
+
|
|
160
|
+
## `docs_delete_tab`
|
|
161
|
+
|
|
162
|
+
Class: delete
|
|
163
|
+
|
|
164
|
+
Delete a tab and all of its descendant tabs
|
|
165
|
+
|
|
166
|
+
| Argument | Type | Required | Description |
|
|
167
|
+
|---|---|---|---|
|
|
168
|
+
| `account` | string | optional | Google account alias |
|
|
169
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
170
|
+
| `tabId` | string | required | Tab ID |
|
|
171
|
+
|
|
172
|
+
## `docs_get`
|
|
173
|
+
|
|
174
|
+
Class: read
|
|
175
|
+
|
|
176
|
+
Get document metadata (title, revision, named ranges). Optionally include tab content and choose a suggestionsViewMode.
|
|
177
|
+
|
|
178
|
+
| Argument | Type | Required | Description |
|
|
179
|
+
|---|---|---|---|
|
|
180
|
+
| `account` | string | optional | Google account alias; "*" = all accounts; omit for the default account |
|
|
181
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
182
|
+
| `includeTabsContent` | boolean | optional | Include full content for every tab (default: false — first tab only) |
|
|
183
|
+
| `suggestionsViewMode` | enum | optional | How suggestions render in the returned body |
|
|
184
|
+
|
|
185
|
+
## `docs_insert_inline_image`
|
|
186
|
+
|
|
187
|
+
Class: create
|
|
188
|
+
|
|
189
|
+
Insert a publicly-accessible image (PNG/JPEG/GIF, <50MB, <25MP, URL <2KB) inline at an index or at the document end
|
|
190
|
+
|
|
191
|
+
| Argument | Type | Required | Description |
|
|
192
|
+
|---|---|---|---|
|
|
193
|
+
| `account` | string | optional | Google account alias |
|
|
194
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
195
|
+
| `uri` | string | required | Public image URL |
|
|
196
|
+
| `index` | number | optional | Insert position; omit to append at the end |
|
|
197
|
+
| `width` | number | optional | Width in points (omit for natural size) |
|
|
198
|
+
| `height` | number | optional | Height in points |
|
|
199
|
+
|
|
200
|
+
## `docs_insert_page_break`
|
|
201
|
+
|
|
202
|
+
Class: create
|
|
203
|
+
|
|
204
|
+
Insert a page break at a position or at the document end
|
|
205
|
+
|
|
206
|
+
| Argument | Type | Required | Description |
|
|
207
|
+
|---|---|---|---|
|
|
208
|
+
| `account` | string | optional | Google account alias |
|
|
209
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
210
|
+
| `index` | number | optional | Insert position; omit to append |
|
|
211
|
+
|
|
212
|
+
## `docs_insert_section_break`
|
|
213
|
+
|
|
214
|
+
Class: create
|
|
215
|
+
|
|
216
|
+
Insert a section break at a position. CONTINUOUS keeps the same page; NEXT_PAGE starts a new page.
|
|
217
|
+
|
|
218
|
+
| Argument | Type | Required | Description |
|
|
219
|
+
|---|---|---|---|
|
|
220
|
+
| `account` | string | optional | Google account alias |
|
|
221
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
222
|
+
| `index` | number | optional | |
|
|
223
|
+
| `sectionType` | enum | optional | |
|
|
224
|
+
|
|
225
|
+
## `docs_insert_table`
|
|
226
|
+
|
|
227
|
+
Class: create
|
|
228
|
+
|
|
229
|
+
Insert a table into a document at a specific position
|
|
230
|
+
|
|
231
|
+
| Argument | Type | Required | Description |
|
|
232
|
+
|---|---|---|---|
|
|
233
|
+
| `account` | string | optional | Google account alias |
|
|
234
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
235
|
+
| `rows` | number | required | Number of rows |
|
|
236
|
+
| `columns` | number | required | Number of columns |
|
|
237
|
+
| `index` | number | optional | Character index to insert at. Omit to append at the end |
|
|
238
|
+
|
|
239
|
+
## `docs_insert_text`
|
|
240
|
+
|
|
241
|
+
Class: create
|
|
242
|
+
|
|
243
|
+
Insert text into a document at a specific position or at the end
|
|
244
|
+
|
|
245
|
+
| Argument | Type | Required | Description |
|
|
246
|
+
|---|---|---|---|
|
|
247
|
+
| `account` | string | optional | Google account alias |
|
|
248
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
249
|
+
| `text` | string | required | Text to insert |
|
|
250
|
+
| `index` | number | optional | Character index to insert at (1-based). Omit to append at the end |
|
|
251
|
+
|
|
252
|
+
## `docs_modify_table`
|
|
253
|
+
|
|
254
|
+
Class: update
|
|
255
|
+
|
|
256
|
+
Mutate a table by operation: insertRow, insertColumn, deleteRow, deleteColumn, mergeCells, unmergeCells. Locate the cell with tableStartIndex (the table's start index in the doc) plus rowIndex/columnIndex (0-based).
|
|
257
|
+
|
|
258
|
+
| Argument | Type | Required | Description |
|
|
259
|
+
|---|---|---|---|
|
|
260
|
+
| `account` | string | optional | Google account alias |
|
|
261
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
262
|
+
| `operation` | enum | required | |
|
|
263
|
+
| `tableStartIndex` | number | required | Start index of the table in the document |
|
|
264
|
+
| `rowIndex` | number | required | Target row (0-based) |
|
|
265
|
+
| `columnIndex` | number | required | Target column (0-based) |
|
|
266
|
+
| `insertBelow` | boolean | optional | insertRow only: insert below the target row (default: false) |
|
|
267
|
+
| `insertRight` | boolean | optional | insertColumn only: insert right of the target column (default: false) |
|
|
268
|
+
| `rowSpan` | number | optional | mergeCells only: how many rows the merged cell spans (default 1) |
|
|
269
|
+
| `columnSpan` | number | optional | mergeCells/unmergeCells: column span (default 1) |
|
|
270
|
+
|
|
271
|
+
## `docs_read`
|
|
272
|
+
|
|
273
|
+
Class: read
|
|
274
|
+
|
|
275
|
+
Read document content as plain text with a heading index (returns up to maxChars characters per call). Pass heading or headingIndex to read one section, tabId to read a specific tab.
|
|
276
|
+
|
|
277
|
+
| Argument | Type | Required | Description |
|
|
278
|
+
|---|---|---|---|
|
|
279
|
+
| `account` | string | optional | Google account alias; "*" = all accounts; omit for the default account |
|
|
280
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
281
|
+
| `heading` | string | optional | Read only the section under this heading (case-insensitive; exact match first, then substring) |
|
|
282
|
+
| `headingIndex` | integer | optional | Read only the section at this position in the headings array (the `i` field) |
|
|
283
|
+
| `tabId` | string | optional | Read a specific tab instead of the first tab |
|
|
284
|
+
| `maxChars` | number | optional | Max characters of text to return (default: 50000) |
|
|
285
|
+
| `offset` | number | optional | Character offset to continue a truncated read |
|
|
286
|
+
|
|
287
|
+
## `docs_replace_named_range_content`
|
|
288
|
+
|
|
289
|
+
Class: update
|
|
290
|
+
|
|
291
|
+
Replace the content of every named range matching the identifier with the supplied text. Real mail-merge primitive — far more robust than replaceAllText for templated docs.
|
|
292
|
+
|
|
293
|
+
| Argument | Type | Required | Description |
|
|
294
|
+
|---|---|---|---|
|
|
295
|
+
| `account` | string | optional | Google account alias |
|
|
296
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
297
|
+
| `namedRangeId` | string | optional | Specific named range ID |
|
|
298
|
+
| `namedRangeName` | string | optional | Name to match (replaces ALL ranges with this name) |
|
|
299
|
+
| `text` | string | required | Replacement text |
|
|
300
|
+
|
|
301
|
+
## `docs_replace_text`
|
|
302
|
+
|
|
303
|
+
Class: update
|
|
304
|
+
|
|
305
|
+
Find and replace text in a document. Pass findText/replaceText for a single pair, or replacements for several pairs applied in one batchUpdate.
|
|
306
|
+
|
|
307
|
+
| Argument | Type | Required | Description |
|
|
308
|
+
|---|---|---|---|
|
|
309
|
+
| `account` | string | optional | Google account alias |
|
|
310
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
311
|
+
| `findText` | string | optional | Text to search for. Use with replaceText; exactly one of this pair or `replacements` is required. |
|
|
312
|
+
| `replaceText` | string | optional | Replacement text for findText |
|
|
313
|
+
| `matchCase` | boolean | optional | Case-sensitive match (default: true) |
|
|
314
|
+
| `replacements` | array | optional | Several find/replace pairs applied in one batchUpdate, each returning its own count. Exactly one of this or findText/replaceText is required. |
|
|
315
|
+
|
|
316
|
+
## `docs_update_document_style`
|
|
317
|
+
|
|
318
|
+
Class: update
|
|
319
|
+
|
|
320
|
+
Update document-level styling (page size, margins, headers/footers behavior). Only supplied fields are applied.
|
|
321
|
+
|
|
322
|
+
| Argument | Type | Required | Description |
|
|
323
|
+
|---|---|---|---|
|
|
324
|
+
| `account` | string | optional | Google account alias |
|
|
325
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
326
|
+
| `pageWidth` | number | optional | Page width in points (e.g. 595 = A4) |
|
|
327
|
+
| `pageHeight` | number | optional | Page height in points (e.g. 842 = A4) |
|
|
328
|
+
| `marginTop` | number | optional | Margin in points |
|
|
329
|
+
| `marginBottom` | number | optional | |
|
|
330
|
+
| `marginLeft` | number | optional | |
|
|
331
|
+
| `marginRight` | number | optional | |
|
|
332
|
+
| `marginHeader` | number | optional | |
|
|
333
|
+
| `marginFooter` | number | optional | |
|
|
334
|
+
| `pageNumberStart` | number | optional | |
|
|
335
|
+
| `useFirstPageHeaderFooter` | boolean | optional | |
|
|
336
|
+
| `useEvenPageHeaderFooter` | boolean | optional | |
|
|
337
|
+
| `useCustomHeaderFooterMargins` | boolean | optional | |
|
|
338
|
+
|
|
339
|
+
## `docs_update_paragraph_style`
|
|
340
|
+
|
|
341
|
+
Class: update
|
|
342
|
+
|
|
343
|
+
Update paragraph styling (alignment, heading, indents, spacing) across a range. Only supplied fields are applied.
|
|
344
|
+
|
|
345
|
+
| Argument | Type | Required | Description |
|
|
346
|
+
|---|---|---|---|
|
|
347
|
+
| `account` | string | optional | Google account alias |
|
|
348
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
349
|
+
| `startIndex` | number | required | |
|
|
350
|
+
| `endIndex` | number | required | |
|
|
351
|
+
| `namedStyleType` | enum | optional | |
|
|
352
|
+
| `alignment` | enum | optional | |
|
|
353
|
+
| `lineSpacing` | number | optional | Line spacing as percent (100 = single-space) |
|
|
354
|
+
| `spaceAbove` | number | optional | Space above paragraph, in points |
|
|
355
|
+
| `spaceBelow` | number | optional | Space below paragraph, in points |
|
|
356
|
+
| `indentStart` | number | optional | Start indent in points |
|
|
357
|
+
| `indentEnd` | number | optional | End indent in points |
|
|
358
|
+
| `indentFirstLine` | number | optional | First-line indent in points |
|
|
359
|
+
| `direction` | enum | optional | |
|
|
360
|
+
| `keepLinesTogether` | boolean | optional | |
|
|
361
|
+
| `keepWithNext` | boolean | optional | |
|
|
362
|
+
| `avoidWidowAndOrphan` | boolean | optional | |
|
|
363
|
+
|
|
364
|
+
## `docs_update_style`
|
|
365
|
+
|
|
366
|
+
Class: update
|
|
367
|
+
|
|
368
|
+
Update text formatting (bold, italic, underline, font, size) for a range
|
|
369
|
+
|
|
370
|
+
| Argument | Type | Required | Description |
|
|
371
|
+
|---|---|---|---|
|
|
372
|
+
| `account` | string | optional | Google account alias |
|
|
373
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
374
|
+
| `startIndex` | number | required | Start index (inclusive, 1-based) |
|
|
375
|
+
| `endIndex` | number | required | End index (exclusive) |
|
|
376
|
+
| `bold` | boolean | optional | Set bold |
|
|
377
|
+
| `italic` | boolean | optional | Set italic |
|
|
378
|
+
| `underline` | boolean | optional | Set underline |
|
|
379
|
+
| `fontSize` | number | optional | Font size in points |
|
|
380
|
+
| `fontFamily` | string | optional | Font family name (e.g. "Arial", "Times New Roman") |
|
|
381
|
+
|
|
382
|
+
## `docs_update_tab_properties`
|
|
383
|
+
|
|
384
|
+
Class: update
|
|
385
|
+
|
|
386
|
+
Rename a tab, change its position, or move it under a different parent
|
|
387
|
+
|
|
388
|
+
| Argument | Type | Required | Description |
|
|
389
|
+
|---|---|---|---|
|
|
390
|
+
| `account` | string | optional | Google account alias |
|
|
391
|
+
| `documentId` | string | required | Google Docs document ID |
|
|
392
|
+
| `tabId` | string | required | Tab ID |
|
|
393
|
+
| `title` | string | optional | |
|
|
394
|
+
| `index` | number | optional | |
|
|
395
|
+
| `parentTabId` | string | optional | |
|