insert_table_of_contents
Automatically generate and insert a table of contents in Google Docs based on document headings, with automatic updates when headings change.
Instructions
Insert a table of contents at the specified index.
The table of contents is auto-generated from document headings (HEADING_1 through HEADING_6). It updates automatically when headings change.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"document_id": "<document_id>",
"index": "<index>"
},
"name": "insert_table_of_contents"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| document_id | Yes | The ID of the Google Document | |
| index | Yes | Index where to insert TOC (1-based) |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |