Export PDF
export_pdfSave the active SolidWorks document as a PDF at a specified path to share drawings or views; creates folders and replaces existing files.
Instructions
Export the active document to PDF, like File > Save As with the PDF type.
Use it to share a drawing; generate_drawing_package (drawing toolset) already
saves a PDF with the drawing it creates. SolidWorks picks the format from the file's extension,
so end file_path in .pdf. Needs: an open, active drawing (a part or assembly
gives a PDF of the view). Changes: writes the file, creating its folder and
replacing a file already there; the open document is unchanged. Returns:
export with file_path and format.
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_data": "<input_data>"
},
"name": "export_pdf"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| input_data | Yes | The export. `file_path` (ending in .pdf) is required; `format_type` is not needed: the file extension decides the format. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||