pack_office_document
Repack unpacked Office document directories into .docx, .pptx, or .xlsx files, removing XML whitespace and optionally validating with LibreOffice.
Instructions
Pack a directory back into an Office document (.docx, .pptx, .xlsx). Removes pretty-printing whitespace from XML before packing. Can optionally validate the document before saving.
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": {
"input_dir": "<input_dir>",
"output_file": "<output_file>"
},
"name": "pack_office_document"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| input_dir | Yes | Directory containing unpacked Office document | |
| output_file | Yes | Path for the output Office file | |
| validate | No | Validate the document after packing (requires LibreOffice) | |
| force | No | Skip validation and pack anyway |