Skip to main content
Glama
SolidWorks MCP Python

SolidWorks MCP Python

by locense

Export PDF

export_pdf
DestructiveIdempotent

Save 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

NameRequiredDescriptionDefault
input_dataYesThe export. `file_path` (ending in .pdf) is required; `format_type` is not needed: the file extension decides the format.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.7/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations flag destructiveHint=true and idempotentHint=true, and the description explains exactly why: it writes the file, creates its folder, and replaces an existing file, while leaving the open document unchanged. The prerequisite (an open, active drawing) is also disclosed, which annotations cannot express.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded one-line purpose followed by labelled 'Needs', 'Changes' and 'Returns' clauses. Every sentence carries information an agent needs, with no filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Covers prerequisite, side effects, format determination and return shape; an output schema exists, so return values need only be named. Nothing needed to invoke it correctly is missing.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3; the description adds a concrete actionable rule the agent must honor ('end `file_path` in .pdf') and reaffirms that `format_type` is unnecessary. It largely restates the schema's own note on format_type rather than adding new semantics.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource ('Export the active document to PDF') and anchors it to a familiar operation ('like File > Save As with the PDF type'). It also distinguishes itself from the sibling that already produces a PDF.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

'Use it to share a drawing' gives the positive case, and the note that 'generate_drawing_package' already saves a PDF with the drawing it creates implicitly steers the agent away from this tool for that path. It never states an explicit exclusion, but the alternative and its condition are present.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools