Skip to main content
Glama
SolidworksMCP-python

SolidworksMCP-python

Create Sweep

create_sweep

Adds material by sweeping a closed profile along a sketch or curve path, optionally using a circular profile for spring wire and returning volume change.

Instructions

Sweep a closed profile along a path to add material (Insert > Boss/Base > Sweep).

The path is a sketch or a curve such as a helix from create_helix. The profile is a circle of circular_profile_diameter mm (a spring's wire, no sketch needed), the sketch named profile, or else the sketch you closed last that isn't the path; draw a profile sketch where the path starts. The volume must grow, or the sweep is removed and the call fails. Needs: an open part with the path (and the profile sketch). Changes: adds a Sweep feature. Returns: sweep with name, profile, path and volume_before, volume_after, volume_change (mm³).

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_sweep"
  }
}

Input Schema

NameRequiredDescriptionDefault
input_dataYesThe sweep. `path` is required; `profile`, `circular_profile_diameter`, `twist_along_path`, `twist_angle` (degrees) and `merge_result` have defaults.

Output Schema

NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changedv2.2.0
    • changedInput schema / properties / input_data / description
      Previous value: -"The sweep. `path` (the path sketch's name) is required;\n`twist_along_path`, `twist_angle` (degrees) and `merge_result` have\ndefaults."New value: +"The sweep. `path` is required; `profile`,\n`circular_profile_diameter`, `twist_along_path`, `twist_angle`\n(degrees) and `merge_result` have defaults."
    • addedInput schema / properties / input_data / properties / circular_profile_diameter
      Added value: +{
      +  "anyOf": [
      +    {
      +      "exclusiveMinimum": 0,
      +      "type": "number"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "Sweep a circle this wide, mm, with no profile sketch (a spring's wire); overrides profile"
      +}
    • changedInput schema / properties / input_data / properties / path / description
      Previous value: -"Name or ID of the sweep path"New value: +"The path: a sketch's name, or a curve's such as 'Helix/Spiral1' from create_helix"
    • addedInput schema / properties / input_data / properties / profile
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "The closed profile sketch's name; when omitted, the sketch closed last that isn't the path"
      +}
  2. Changed1 schema field changedv2.0.0
    • changedInput schema / properties / input_data / description
      Previous value: -"Path name and twist/merge options."New value: +"The sweep. `path` (the path sketch's name) is required;\n`twist_along_path`, `twist_angle` (degrees) and `merge_result` have\ndefaults."
  3. First observedv1.0.0

TDQS

A4.4/5.0
Behavior5/5

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

Beyond the annotations (which only declare this is not read-only and not idempotent), the description discloses the atomic failure rule — 'The volume must grow, or the sweep is removed and the call fails' — which is exactly the kind of side-effect detail annotations cannot carry. It also states the resulting document change ('adds a Sweep feature') and preconditions.

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, then path/profile sourcing, then the failure rule, then preconditions and returns — a logical order. It is dense but nearly every clause carries information; the parenthetical 'Insert > Boss/Base > Sweep' and the restated return fields are the only mild redundancy.

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 a nested input object, the description covers what it creates, the required inputs and their fallbacks, preconditions, failure behavior, and the resulting document change. Return values are already in the output schema, so the brief note about the `sweep` object is sufficient and nothing critical is missing.

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 description coverage is 100%, so the schema already defines path, profile fallback, the circular_profile_diameter override, and the twist/merge options. The description restates the path/profile alternatives and the override rule in prose without adding syntax or semantics beyond the schema, so the baseline of 3 applies.

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 (sweep a closed profile along a path to add material) and immediately disambiguates from the sibling that removes material by saying 'add material' with the Insert > Boss/Base > Sweep reference. An agent can distinguish this from create_cut_sweep and create_extrusion 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 Guidelines4/5

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

Names concrete prerequisites ('an open part with the path (and the profile sketch)') and enumerates the three acceptable profile sources, including the no-sketch case and the sibling that produces a helix path. It stops short of an explicit statement of when to pick create_cut_sweep instead, leaving that to the phrase 'add material'.

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