Skip to main content
Glama
SolidWorks MCP Python

SolidWorks MCP Python

by locense

Add Mate

add_mate

Create coincident, concentric, parallel, perpendicular, tangent, distance, or angle mates between two components in an active SolidWorks assembly to position and align them.

Instructions

Mate two components of the active assembly: coincident, concentric, parallel, perpendicular, tangent, distance or angle.

Each side is a named reference plane or axis (entity_a, e.g. "Front Plane"), or a face given by a point on it (face_a, mm, in that part's own coordinates): a pin's round face and a hole's face make a concentric mate. Get instance names from list_components. Needs: an open assembly with both components. Changes: adds a mate and may move components. Returns: mate with mate_type, components, entities, geometry_moved and moved_components.

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

Input Schema

NameRequiredDescriptionDefault
input_dataYesThe mate. `component_a` and `component_b` are required; each side takes `entity_*` or `face_*` (default "Front Plane"); `mate_type` (coincident), `alignment`, `distance` (mm) and `angle` (degrees) have defaults.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.4/5.0
Behavior4/5

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

Annotations already declare readOnly=false, idempotent=false, destructive=false; the description adds the key consequence 'adds a mate and may move components', which is the real behavioral risk. It also lists the return fields, though that overlaps the output schema.

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-loads the action, then preconditions, effects and return value in a tight labelled pattern. Slightly dense prose but every sentence carries information; the return-field list is mildly redundant with the output schema.

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?

For a mutation tool with nested params, it covers preconditions, both ways of specifying a side, side effects, and the response shape; nothing an agent needs to call 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 baseline is 3; the description earns more by explaining that face points are in that part's own coordinates and by giving a concrete concentric pin/hole example that clarifies how face_a and face_b pair up.

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?

Opens with a specific verb+resource ('Mate two components of the active assembly') and enumerates the mate types, which distinguishes it from sibling sketch-constraint tools. An agent can tell exactly what operation is being performed.

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?

States preconditions ('open assembly with both components') and routes the agent to list_components for instance names, plus explains the entity-vs-face alternative for specifying each side. It stops short of explicit when-not-to-use guidance or naming a sibling alternative.

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