Skip to main content
Glama
gpambrozio

onshape-mcp

by gpambrozio

Sketch a rectangle

onshape_sketch_rectangle

Add a sketch with a single closed rectangle defined by two opposite corner points in inches, ready to extrude.

Instructions

Add a sketch holding one closed rectangle, ready to extrude. Corners are opposite, in inches.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
wsYesWorkspace id — the <ws> segment of the document URL.
docYesDocument id — the <doc> in cad.onshape.com/documents/<doc>/w/<ws>/e/<elem>.
elemYesElement id (tab) — the <elem> segment of the document URL.
nameNoFeature name shown in the tree (default "Sketch").
planeNoDefault plane to sketch on (default Front).
corner1YesFirst corner. As [x, y] inches or "x,y".
corner2YesOpposite corner. As [x, y] inches or "x,y".
validateNoRe-read the feature list afterwards and fail if the feature regenerated with an error (default true).
plane_featureNoSketch on a face created by this feature id instead of a default plane.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

B3.2/5.0
Behavior2/5

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

With no readOnly or destructive annotations, the description carries the full burden, but it only says the sketch is 'ready to extrude'. It does not disclose that this creates a feature in the document, whether the operation is reversible, or what side effects occur on the Onshape element.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is a single sentence with no filler. It front-loads the core purpose and includes the essential geometric constraint without waste.

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

Completeness2/5

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

The parameter schema is thorough, but no output schema exists and no annotations are provided. The description does not explain what the agent should expect after calling it, such as the created feature or errors, leaving the context incomplete for a mutation tool.

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 fully documents all nine parameters. The description's mention of inches and opposite corners mostly repeats schema information rather than adding new meaning; baseline 3 is appropriate.

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?

The description states a specific verb and resource: 'Add a sketch holding one closed rectangle'. It also clarifies the geometry ('Corners are opposite') and intent ('ready to extrude'), which distinguishes it from sibling sketch tools like onshape_sketch_circle and onshape_sketch_line.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

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

The description implies a use case—creating a rectangular sketch for extrusion—but gives no explicit guidance on when to choose this tool over alternatives like onshape_sketch_line or onshape_create_sketch. There are no exclusions or alternative routing.

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