copy_file
Copies a SOLIDWORKS file to a new path while keeping its extension, blocking overwrites of existing targets and copies of files open with unsaved changes.
Instructions
Copy a file to a new path, keeping the extension. Refused when the target exists (unless overwrite), when the source is open with unsaved changes, when the target is open, and for protected folders. Files that reference the source keep pointing at the source.
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": {
"source": "<source>",
"target": "<target>"
},
"name": "copy_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| source | Yes | Full path of the file to copy | |
| target | Yes | Full path of the copy (same extension; a missing folder is created) | |
| overwrite | No | Replace an existing target |