Save document
doc_saveSaves an open KOMPAS-3D document in place or to a new path, blocks unintended overwrites unless explicitly allowed, and verifies the file after saving.
Instructions
Save a document in place, or Save As to a new path (the handle changes: use the returned one). An existing file is never replaced without overwrite=true. PDM folders and read-only files are refused. The file on disk is verified after 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": {
"doc": "<doc>"
},
"name": "doc_save"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| doc | Yes | Document handle from doc_list/doc_open, e.g. 'doc:12001:0a1b2c3d' | |
| path | No | Save As target (absolute, inside the allowed roots). Omit to save in place. | |
| overwrite | No | Allow replacing an existing file (only after the user explicitly agreed) |