Skip to main content
Glama
SolidWorks MCP Python

SolidWorks MCP Python

by locense

Get Dimension

get_dimension
Read-onlyIdempotent

Reads a named dimension from the active SolidWorks model's active configuration, returning its value and units; find dimension names with list_model_dimensions.

Instructions

Read one dimension of the active model by its full name, e.g. "D1@Sketch1".

Find names with list_model_dimensions. It reads the active configuration's value; activate_configuration to read another. Needs: an open part or assembly. Read-only. Returns: dimension with name, value and units: "mm" for a length, "deg" for an angle, and null for a count (such as a pattern's instance count).

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

Input Schema

NameRequiredDescriptionDefault
input_dataYesThe dimension. Give `name` (or `dimension_name`), e.g. "D1@Boss-Extrude1".

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare readOnlyHint/idempotentHint/non-destructive, yet the description still adds real context: the value read comes from the active configuration, an open part or assembly is required, and units resolve per dimension type (mm, deg, null for counts). That last detail is behavioral nuance beyond the safety flags, though the 'Read-only' sentence merely restates annotations.

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 core action and example, followed by name discovery, configuration scope, precondition, and return units. Tight overall, with only minor redundancy in the 'Read-only' line already covered by annotations.

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

Completeness4/5

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

For a single-parameter read tool with an output schema and rich annotations, the description covers naming source, configuration scope, preconditions, and unit semantics. Only the alias-field relationship is left implicit, a small gap given the schema already describes both fields.

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

Parameters3/5

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

Schema coverage is 100% and the nested input_data object already documents `name` with the same 'D1@Sketch1' style example, so the description adds little parameter meaning. It correctly reinforces the full-name format but does not explain the `dimension_name` alias or how the two fields interact.

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 — 'Read one dimension of the active model by its full name' — with a concrete name example ('D1@Sketch1'). It is clearly distinguishable from the sibling list_model_dimensions (enumeration) and set_dimension (mutation).

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 explicit routing: find names with `list_model_dimensions`, and use `activate_configuration` to read a non-active configuration's value. It also states the precondition 'Needs: an open part or assembly', so an agent knows when the call will fail.

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