Skip to main content
Glama
SolidWorks MCP Python

SolidWorks MCP Python

by locense

Create Extrusion

create_extrusion

Extrudes a closed sketch into a solid boss on the active part after exiting the sketch; supports blind, mid-plane, through-all, up-to-next, thin-wall, and draft options.

Instructions

Extrude the sketch you just closed into a solid boss, added to the active part.

Use it after exit_sketch; to remove material, use create_cut_extrude. It extrudes the sketch sketch_name names, or the one exit_sketch closed last; a name that isn't in the feature tree fails before anything is built. End conditions: Blind (default), MidPlane, ThroughAll, UpToNext; both_directions means MidPlane. With thin_feature and thin_thickness it makes a wall from the sketch's outline, and an open chain works (a bent plate from its centreline). Needs: an open part and a closed profile (open is fine when thin). Changes: adds a Boss-Extrude feature. Returns: extrusion (name, sketch when one was named, depth, the end_condition SolidWorks used, both_directions, and thin when thin) and measured_change (volume, bounding box and solid-body count before and after; left out when the model can't be read).

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": "create_extrusion"
  }
}

Input Schema

NameRequiredDescriptionDefault
input_dataYesThe extrusion. `depth` (mm) is required; `sketch_name`, `end_condition`, `both_directions`, `reverse_direction`, `draft_angle`, `thin_feature`/`thin_thickness` and `merge_result` have defaults.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.6/5.0
Behavior4/5

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

Annotations only declare the safety profile (readOnly false, idempotent false, destructive false); the description adds a failure mode ('a name that isn't in the feature tree fails before anything is built'), the resulting model change (adds a Boss-Extrude feature), and how end conditions and thin walls behave. It stops short of saying whether the operation is reversible or what happens on partial failure, so it is strong but not exhaustive for a mutation tool.

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

Conciseness4/5

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

Front-loaded with the action and the routing to create_cut_extrude, then folds constraints into compact segments. The trailing 'Returns:' enumeration largely restates the output schema and the long parenthetical makes some sentences dense, but there is little outright waste.

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 prerequisites, failure behavior, model effects, and the measured_change readout, which is enough for an agent to call this correctly even on a complex nested schema. Because an output schema exists, the return-value sentence is redundant but harmless rather than a gap.

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, but the description adds genuine meaning: it enumerates the valid end conditions (Blind default, MidPlane, ThroughAll, UpToNext), explains that both_directions means MidPlane, and clarifies that thin_feature permits an open chain. Minor params such as draft_angle, merge_result and the reverse aliases are left entirely to the schema.

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 concrete verb and result: 'Extrude the sketch you just closed into a solid boss, added to the active part.' It names the sibling it is not (create_cut_extrude for material removal), so an agent can distinguish the two without opening either schema.

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

Usage Guidelines5/5

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

Gives an explicit prerequisite ('Use it after exit_sketch') and an explicit alternative with its selecting condition ('to remove material, use create_cut_extrude'). It also states the preconditions that gate a successful call: an open part and a closed profile, with the thin-feature exception spelled out.

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