Skip to main content
Glama
SolidworksMCP-python

SolidworksMCP-python

Add Mate

add_mate

Constrains two components in an active SolidWorks assembly by adding coincident, concentric, parallel, perpendicular, tangent, distance, or angle mates to control their relative position and motion.

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. Changed11 schema fields changedv2.0.0
    • changedInput schema / properties / input_data / description
      Previous value: -"Components, entities and mate type."New value: +"The mate. `component_a` and `component_b` are required;\neach side takes `entity_*` or `face_*` (default \"Front Plane\");\n`mate_type` (coincident), `alignment`, `distance` (mm) and `angle`\n(degrees) have defaults."
    • addedInput schema / properties / input_data / properties / entity_a / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedInput schema / properties / input_data / properties / entity_a / default
      Previous value: -"Front Plane"New value: +null
    • changedInput schema / properties / input_data / properties / entity_a / description
      Previous value: -"Named feature on the first component. Only tree features (reference planes and axes) can be selected"New value: +"Named reference plane or axis on the first component, e.g. 'Front Plane'; defaults to 'Front Plane' when face_a is not given either"
    • removedInput schema / properties / input_data / properties / entity_a / type
      Removed value: -"string"
    • addedInput schema / properties / input_data / properties / entity_b / anyOf
      Added value: +[
      +  {
      +    "type": "string"
      +  },
      +  {
      +    "type": "null"
      +  }
      +]
    • changedInput schema / properties / input_data / properties / entity_b / default
      Previous value: -"Front Plane"New value: +null
    • changedInput schema / properties / input_data / properties / entity_b / description
      Previous value: -"Named feature on the second component"New value: +"Named reference plane or axis on the second component; defaults to 'Front Plane' when face_b is not given either"
    • removedInput schema / properties / input_data / properties / entity_b / type
      Removed value: -"string"
    • addedInput schema / properties / input_data / properties / face_a
      Added value: +{
      +  "anyOf": [
      +    {
      +      "items": {
      +        "type": "number"
      +      },
      +      "type": "array"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "[x, y, z] in mm on a face of the first component, in that part's own coordinates (as it was modelled), instead of entity_a: e.g. a point on a pin's round face for a concentric mate"
      +}
    • addedInput schema / properties / input_data / properties / face_b
      Added value: +{
      +  "anyOf": [
      +    {
      +      "items": {
      +        "type": "number"
      +      },
      +      "type": "array"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "[x, y, z] in mm on a face of the second component, in its own part coordinates, instead of entity_b"
      +}
  2. Addedv1.5.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