Set document page setup
set_page_setupSet page margins, paper size, and orientation for a Google Doc or tab to control print and layout geometry. Use presets or custom point sizes; changes apply directly.
Instructions
Set document-level page setup for a doc (or tab): page margins, page size, and orientation — the File > Page setup controls. Margins and explicit page sizes are in points (72 pt = 1 inch). pageSize is a preset (letter/legal/a4/tabloid) or an explicit {width,height} in points; orientation (portrait/landscape) swaps the page dimensions. Always a direct change: page geometry is a document-style change, so there is no suggest option.
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": {
"path": "<path>"
},
"name": "set_page_setup"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| path | Yes | The doc or tab: a Drive id or URL, /folder/doc, or /folder/doc/tab (nested: /folder/doc/tab/child). A doc with one tab needs no tab step; a doc with several is refused until one is named, and the refusal lists every tab path. | |
| account | No | Google account email to use. Defaults to GDOCS_DEFAULT_ACCOUNT, or the sole account. | |
| pageSize | No | a preset name, or {width,height} in points | |
| marginTop | No | top margin in points (72 = 1 inch) | |
| marginLeft | No | left margin in points | |
| marginRight | No | right margin in points | |
| orientation | No | portrait or landscape (orders the page width/height) | |
| marginBottom | No | bottom margin in points |