Skip to main content
Glama
SolidworksMCP-python

SolidworksMCP-python

Calculate Mass Properties

calculate_mass_properties
Read-onlyIdempotent

Measure volume, surface area, mass, center of mass, and moments of inertia for the active SolidWorks part or assembly to check weight and balance.

Instructions

Measure the active part or assembly's mass properties: volume, surface area, mass, centre of mass and moments of inertia.

Use it to check weight or balance. To compare a model with the values you expect, use verify_model; get_mass_properties does the same as this tool. Mass depends on the assigned material (set_material). Needs: an open part or assembly. Read-only. It rebuilds first. Returns: mass_properties with volume (mm³), surface_area (mm²), mass (kg), center_of_mass (mm), moments_of_inertia (kg·mm², about the centre of mass) and principal_axes.

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

Input Schema

NameRequiredDescriptionDefault
input_dataYesNothing: it always measures the active model.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv2.0.0
    • changedInput schema / properties / input_data / description
      Previous value: -"The input data value."New value: +"Nothing: it always measures the active model."
    • removedInput schema / properties / input_data / properties / include_hidden
      Removed value: -{
      -  "default": false,
      -  "description": "Include hidden components",
      -  "type": "boolean"
      -}
    • removedInput schema / properties / input_data / properties / model_path
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "type": "string"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null,
      -  "description": "Path to the model file"
      -}
    • removedInput schema / properties / input_data / properties / reference_coordinate_system
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "type": "string"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null,
      -  "description": "Reference coordinate system alias"
      -}
    • removedInput schema / properties / input_data / properties / units
      Removed value: -{
      -  "default": "metric",
      -  "description": "Units for mass properties",
      -  "type": "string"
      -}
  2. First observedv1.0.0

TDQS

A4.5/5.0
Behavior4/5

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

Annotations already declare readOnlyHint, idempotentHint and destructiveHint=false, so the safety profile is covered; the description still adds real context beyond them: it requires an open part or assembly, it rebuilds the model first (a side effect on timing/state), and results depend on the assigned material via `set_material`. It does not mention failure modes when no document is open, which keeps it short of a 5.

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 outputs, then prerequisites and alternatives in short clauses. The return-value enumeration partially duplicates the output schema, which is the only wasted space in an otherwise tight definition.

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?

Covers prerequisites, the rebuild behavior, the material dependency, and the units of each returned quantity, which is more than enough for a zero-argument measurement tool. The return list is somewhat redundant given an output schema exists, but nothing an agent needs 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?

There is effectively one parameter, an empty `input_data` object, and the schema already says 'Nothing: it always measures the active model' at 100% coverage. The description reinforces that the active model is the implicit target, so no further parameter meaning is needed.

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 ('Measure the active part or assembly's mass properties') and enumerates exactly what is computed (volume, surface area, mass, centre of mass, moments of inertia). It also distinguishes itself from the sibling `get_mass_properties` and from `verify_model`, so an agent can pick it without opening a 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 use case ('check weight or balance') and names the alternative for a different intent ('To compare a model with the values you expect, use `verify_model`'). It also discloses that `get_mass_properties` is functionally identical, which prevents pointless tool-shopping.

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