AutoCAD MCP Ultra
Provides automation and integration with AutoCAD, enabling CAD drafting and editing, mechanical standards and GD&T annotations, P&ID process drafting, gear generation, and title block creation through COM and AutoLISP.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@AutoCAD MCP Ultra Draw a P&ID for a cooling water pump with ISO valves"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
AutoCAD MCP Ultra
Industrial-grade AutoCAD MCP server for AI agents — Dual live engines (ActiveX COM for full AutoCAD + File-IPC AutoLISP for AutoCAD LT 2024+) + Headless ezdxf + ISO GD&T + P&ID process drafting + Rhino.Inside Grasshopper Battery Bridge.
Key Features
AutoCAD 2024+ Universal Support: Full AutoCAD (COM) and AutoCAD LT (AutoLISP IPC).
Rhino.Inside Grasshopper Battery Bridge: Built-in adapter for all 87+ AutoCAD Tab Grasshopper components with TrackedBake idempotent live updates.
ISO/DIN Mechanical Standards: ISO 1101 GD&T, ISO 129 dimensions, ISO 286 fits (
H7), Involute gear generator with section A-A, DIN 6885 keyed bores, ISO 7200 title blocks.Process & P&ID Engineering: Dedicated P&ID symbols for pumps, valves, instruments, vessels, and automated piping routing.
Token Efficiency & Discovery Mode: Low token idle overhead (~356 tokens) with semantic search over 158 CAD commands and 87 GH batteries.
5-Step Agent Quality Loop: Preflight -> Plan -> Critique (0-100 score) -> Refine -> Finalize with SHA-256 delivery manifest.
Available Tools
162 toolsanalysis_bounding_boxDrawing Bounding BoxARead-only
Get the bounding box (extents) of all entities in the drawing.
Inputs: no named parameters. Returns: object
analysis_entity_statsEntity StatisticsARead-only
Analyze the drawing and return entity counts grouped by type and by layer.
Returns: total_entities, by_type (sorted by count), by_layer (sorted by count). This is unique to AutoCAD MCP Pro – no other MCP server provides this!
Inputs: no named parameters. Returns: object
analysis_find_in_regionFind Entities in RegionARead-only
Find all entities within a rectangular region (crossing selection).
Uncapped: a window over a busy drawing returns every hit. Project with
fields and/or compact before widening the window.
Inputs: x1 (required), x2 (required), y1 (required), y2 (required), +2 more. Returns: result
analysis_layer_statsLayer StatisticsARead-only
Return detailed statistics for each layer: entity count, types present.
Inputs: no named parameters. Returns: object
analysis_list_propertiesList Entity PropertiesARead-only
AutoCAD's LIST: the full DXF attribute set for one handle.
dxf_attributes is the raw attribute set entity_get deliberately does
not carry. Coordinates in it are WCS, like everywhere else in this server,
and extrusion is reported so the entity's own frame is still visible.
Inputs: handle (required). Returns: object
analysis_measure_areaMeasure AreaARead-onlyIdempotent
Area and perimeter of a polygon you supply the vertices for.
This measures the numbers in the call, NOT the drawing. To measure something
that exists, use analysis_measure_entity(handle) — it reads the real
geometry, including curvature this tool can only see if you pass it.
Straight-edged polygons are exact. Pass a third bulge element per vertex
for arc edges; omitting it on curved geometry under-reports (28% on a
semicircular edge), which is why assumes says what was taken on faith.
Inputs: points (required). Returns: object
analysis_measure_distanceMeasure DistanceARead-onlyIdempotent
Measure the Euclidean distance between two points.
Inputs: x1 (required), x2 (required), y1 (required), y2 (required). Returns: object
analysis_measure_entityMeasure EntityARead-onlyIdempotent
Measure something already in the drawing, by handle.
Reads the real geometry, so polyline bulges (arc edges) are included — reading vertices back and shoelacing them yourself loses 28% of the area on a semicircular edge, silently.
Measurable: LWPOLYLINE, 2D POLYLINE, CIRCLE, ELLIPSE, SPLINE, HATCH, SOLID,
TRACE, 3DFACE. REGION and 3DSOLID need the live COM backend (their area is
in ACIS data ezdxf cannot evaluate) and refuse with
capability: "measure_area_acis". LINE/TEXT/INSERT bound no area on any
engine and are a plain error, not a capability gap.
The payload states its own accuracy: exact is false when the shape had to
be flattened (then flatten_tolerance says how finely), assumed_closed is
true when an open boundary was closed the way AutoCAD's AREA does, and
self_intersecting warns when the shoelace cancelled crossed lobes — a
bowtie measures 0.0 and that number is worse than useless unflagged.
Inputs: handle (required), flatten_tolerance. Returns: object
analysis_select_by_layerSelect Entities By LayerARead-only
Get all entities on a specific layer. Returns entity list with handles.
Capped at MAX_LIST_LIMIT (default 5000). The plain list cannot say it was
capped — the warning goes to the log stream, which most clients never show
the model — so use compact=True when the count matters: its total is the
layer's real population and truncated states whether the cap fired.
Inputs: layer_name (required), fields, compact. Returns: result
analysis_select_by_typeSelect Entities By TypeARead-only
Get all entities of a specific type. Returns entity list with handles.
Capped at MAX_LIST_LIMIT (default 5000); as with analysis_select_by_layer,
compact=True is the only shape that reports total and truncated.
Inputs: entity_type (required), fields, compact. Returns: result
block_create_from_entitiesCreate Block From EntitiesA
Create a new block definition from existing entities in the drawing.
Works on both engines. The originals stay in model space — this defines a
reusable block from them rather than consuming them the way AutoCAD's BLOCK
command does; use block_insert to place copies, and delete the originals
yourself if you want the command's behaviour.
Handles that do not resolve are listed in skipped rather than silently
dropped, and a call where none resolve fails instead of leaving an empty
definition behind.
Inputs: name (required), handles (required), base_x, base_y. Returns: object
block_explodeExplode BlockADestructive
Explode a block reference into its individual component entities.
Inputs: handle (required). Returns: object
block_find_referencesFind Blocks By NameARead-only
Find all insert references to a specific block definition.
Bounded by the backend's own default entity_list page (200 INSERTs scanned),
which is a pre-existing limit, not a new one: the compact envelope's total
counts the references found within that scan.
Inputs: name (required), fields, compact. Returns: result
block_get_attributesGet Block AttributesARead-only
Get all attribute values from a block reference as {TAG: value} dict.
Inputs: handle (required). Returns: object
block_insertInsert BlockA
Insert a block and optionally set attribute values.
Inputs: x (required), y (required), name (required), layer, +4 more. Returns: object
block_listList BlocksARead-only
List all block definitions in the drawing (name, origin, attribute count, entity count).
Never truncated — the whole block table is returned — so a compact envelope here always reports truncated=false.
Inputs: fields, compact. Returns: result
block_set_attributesSet Block AttributesA
Update attribute values in a block reference.
Inputs: handle (required), attributes (required). Returns: object
boundary_from_entitiesBoundary from EntitiesA
Chain the given entities into one closed polyline.
The handles may arrive in any order — putting them in chain order is the tool's job. A chain that does not close is refused, and the error names the coordinates of the gap.
Inputs: handles (required), tolerance. Returns: object
boundary_traceTrace BoundaryA
AutoCAD's BOUNDARY/BPOLY: create a closed polyline around a seed point.
Returns the nearest enclosing loop, so a seed inside an island gives the island rather than the outer region. Straight edges are split where they cross, so a line drawn across a shape divides it the way it looks like it should. A seed with no enclosing loop is refused, and the error names the gap when the edges nearly close.
Inputs: x (required), y (required), layer, tolerance. Returns: object
cad_batchBatch: Run ToolsADestructive
Execute an ordered list of tool calls in ONE round trip.
N calls collapse into one request/response pair, and bind lets a later
step reference an earlier step's result so handles never have to be echoed
back through the model.
steps=[
{"tool": "entity_create_line", "args": {...}, "bind": "edge"},
{"tool": "point_from_snap", "args": {"handle": "$edge", "snap": "mid"},
"bind": "mid"},
{"tool": "entity_create_circle","args": {"cx": "$mid.x", "cy": "$mid.y",
"radius": 4}},
]Successful steps report only their handle; pass verbose=True for the full result. Anything without a handle is returned whole.
VALIDATION runs first, always: an unknown tool, a schema-invalid argument or
a reference no earlier step binds refuses the whole batch before anything
executes. on_error governs run-time failures only. dry_run=True returns
that validation report and executes nothing.
ERRORS are typed, never text: each failed step carries error.kind - one of
unsupported (with the backend capability), invalid_args, refused, failed,
unknown_tool, unresolved_ref, denied, malformed_step.
ATOMICITY is reported, not assumed. Read the atomicity block: on the
headless backend rollback restores a full document snapshot; on live AutoCAD
it sends an UNDO whose landing AutoCAD never confirms. The default
on_error="stop" claims nothing and is exact on both.
NOT CALLABLE from a batch: the raw command/LISP escape hatches, and cad_batch itself. Call those directly.
For a few hundred entities of the same kind, entity_batch_create is denser still (no per-step tool name) - and it can be one step of a cad_batch.
Inputs: steps (required), dry_run, verbose, on_error. Returns: object
construction_clearConstruction: Clear (delete scaffold)ADestructive
Delete every entity on the CONSTRUCTION layer. Idempotent.
Must be called before drawing_finalize to satisfy construction_left critique.
Inputs: layer. Returns: object
construction_xlineConstruction: XLine (infinite reference)A
Create an infinite construction line on the CONSTRUCTION layer.
Use as scaffolding; call construction_clear() before finalize.
Inputs: x (required), y (required), angle_deg (required), layer. Returns: object
datum_featureGD&T: Datum Feature (ISO 1101)A
Place a datum feature symbol (filled triangle + boxed letter).
Establishes the datum so a feature control frame referencing this letter
passes the gdt critique focus.
Inputs: x (required), y (required), letter (required), size, +1 more. Returns: object
dimension_alignedAligned DimensionA
Create an aligned dimension that measures the true distance between two points.
Inputs: x1 (required), x2 (required), y1 (required), y2 (required), +3 more. Returns: object
dimension_angularAngular DimensionA
Create an angular dimension measuring the angle between two lines from a vertex.
Inputs: x1 (required), x2 (required), y1 (required), y2 (required), +5 more. Returns: object
dimension_autoDimension: Auto (chain / baseline / ordinate)A
Generate ISO 129 dimensions across the listed entities in the chosen style. V1 supports LINE entities only.
Inputs: handles (required), style, offset. Returns: result
dimension_diameterDiameter DimensionA
Create a diameter dimension for a circle, optionally toleranced (e.g. ⌀20 H7).
Inputs: x1 (required), x2 (required), y1 (required), y2 (required), +7 more. Returns: object
dimension_linearLinear DimensionB
Create a linear dimension, optionally toleranced (ISO 129 or ISO 286 fit).
Inputs: x1 (required), x2 (required), y1 (required), y2 (required), +9 more. Returns: object
dimension_radiusRadius DimensionA
Create a radius dimension for a circle or arc, optionally toleranced.
Inputs: chord_x (required), chord_y (required), center_x (required), center_y (required), +7 more. Returns: object
drawing_apply_iso_layersDrawing: Apply ISO Layer Set (bootstrap)A
Bootstrap a full ISO-conformant layer set with correct colors and lineweights. Idempotent — existing layers are not modified.
Inputs: standard. Returns: object
drawing_auditAudit DrawingA
Audit the drawing: repair every fixable structural problem, and report it.
This mutates the drawing. fixes lists repairs that have ALREADY been
applied, so save afterwards to keep them; errors lists problems that could
not be repaired. On the live COM backend AutoCAD applies repairs but hands
back no counts, so they arrive as null with detail: "unavailable" rather
than as zero.
Inputs: no named parameters. Returns: object
drawing_closeClose DrawingADestructive
Close the current drawing. If save is True (default), the drawing is saved to its current path before closing. After this call, you must call drawing_new or drawing_open before any other tool.
Inputs: save. Returns: object
drawing_critiqueDrawing: Critique (premium quality checks)ARead-only
Run premium-quality checks. Returns zero issues for a clean drawing.
Standard production gate: must return [] before drawing_finalize.
Inputs: focus. Returns: result
drawing_deliverDrawing: Deliver Auditable BundleADestructive
Create a hashed, validated delivery bundle and verify DXF save/reopen parity.
The result status is success, failed_validation or failed_export.
Failure intentionally keeps all generated artifacts for diagnosis.
Inputs: output_dir (required), formats, expected, min_score, +1 more. Returns: object
drawing_export_dxfExport DXFA
Export the current drawing as a DXF file.
Inputs: path (required). Returns: object
drawing_export_pdfExport PDFA
Export the current drawing (or a paper-space layout) to PDF.
Inputs: path (required), layout. Returns: object
drawing_finalizeDrawing: Finalize (validate + save + screenshot)ADestructive
Premium completion gate: runs BOTH the 8-step validator AND the premium critique focuses (iso128, layer_color, dim_overlap, untrimmed_corner, duplicate_entities, construction_left), then saves to disk, exports a screenshot, and returns the DWG path.
Raises ToolError if any validator 'error' finding is present, or if critique reports an 'error' (or, with strict_critique=True, any critique issue). Critique warnings are surfaced under payload['critique'] without failing the gate by default.
Inputs: expected, save_path, screenshot_path, strict_critique. Returns: object
drawing_infoDrawing InfoARead-only
Get comprehensive metadata for the current drawing.
Returns: name, path, entity_count, layer_count, block_count, extents (min/max), units, version, backend name.
Inputs: no named parameters. Returns: object
drawing_newNew DrawingA
Create a new empty drawing, optionally from a template (.dwt).
When bootstrap=True (default), the drawing is also seeded with the
standard engineering linetypes (CENTER/HIDDEN/PHANTOM) and layers
(GEOMETRY, DIM, CENTER, HIDDEN, PHANTOM, HATCH, TEXT, TITLEBLOCK).
Inputs: template, bootstrap. Returns: object
drawing_openOpen DrawingA
Open an existing DXF drawing file (DWG too, on the live COM backend).
T0.2: a .dwg path is refused up front when the active backend has no dwg
capability. ezdxf sniffs content rather than extensions, so it would parse a
mislabelled DXF-in-a-.dwg and this tool would answer with a document that
does not exist in that format.
Inputs: path (required). Returns: object
drawing_planDrawing: Plan (commit intent before drawing)A
Commit a PlanSpec before any geometry is created.
The PlanSpec is stored on the backend and surfaced for reference during the workflow (it is not replayed as a critique). Always call this FIRST in a premium workflow.
Inputs: intent (required), notes, scale, dim_style, +5 more. Returns: object
drawing_preflightDrawing: PreflightARead-only
Validate and normalize requirements before committing a drawing plan.
Inputs: intent (required), scale, dim_style, sheet_size, +4 more. Returns: object
drawing_purgePurge DrawingA
Purge all unused objects (layers, blocks, linetypes, styles) from the drawing.
Inputs: no named parameters. Returns: object
drawing_redoRedoA
Reapply the operation you just undid.
Same history as drawing_undo, so the headless backend needs
EZDXF_UNDO_DEPTH set. Anything drawn after an undo discards the redo
branch — otherwise redo would restore a state that never existed, with
geometry you had removed reappearing beside geometry you drew afterwards.
Inputs: no named parameters. Returns: object
drawing_refineDrawing: RefineBDestructive
Run a bounded, transaction-safe critique/repair/re-critique loop.
Inputs: focus, dry_run, min_score, max_rounds, +1 more. Returns: object
drawing_saveSave DrawingB
Save the current drawing. Optionally specify a new path.
Inputs: path. Returns: object
drawing_save_asSave AsA
Save current drawing to a new path/format (DWG, DXF, or DWT template).
The on-disk format is derived from the file extension so the bytes always
match the name (N2) — e.g. 'part.dxf' writes DXF, not DWG. format overrides
only when the path has no recognised extension.
Inputs: path (required), format. Returns: object
drawing_settingsDrawing Settings (read / change)A
Read or change common AutoCAD drawing settings by friendly name.
A convenience facade over the system variables (INSUNITS, LUPREC, LTSCALE, DIMSCALE, DIMTXT, DIMASZ, DIMDEC, DIMDSEP, DIMZIN, TEXTSIZE, OSMODE, …) so the user can say "set units to mm and dimension text to 3.5" without memorising sysvar names. Call with no argument to get a full snapshot of the current settings.
dim_text_height / dim_arrow_size / dim_decimals / decimal_separator
/ zero_suppression shape the dimension — text_size is TEXTSIZE, the
height of a standalone TEXT entity, and does not touch dimensions.
Inputs: settings. Returns: object
drawing_undoUndoA
Undo the last drawing operation.
On the live COM backend this is AutoCAD's own undo. The headless backend has
no journal, so a step is a full DXF snapshot and history is off by
default — set EZDXF_UNDO_DEPTH to the number of steps you want. Measured
cost of switching it on: 37x on entity creation (0.18 -> 6.65 ms per call).
For a single checkpoint around a risky sequence, transaction_begin /
transaction_rollback is far cheaper.
Drawing something after an undo discards the redo branch, as in AutoCAD.
Inputs: no named parameters. Returns: object
entity_array_polarPolar ArrayA
Create a polar (circular) array of copies around a center point.
count is unbounded, so the same result-shaping applies as for the
rectangular array: fields=["handle"] when the geometry is already known.
Inputs: count (required), handle (required), center_x (required), center_y (required), +3 more. Returns: result
entity_array_rectangularRectangular ArrayA
Create a rectangular array of copies. Returns info of all created copies.
rows x cols is unbounded, so this is a result-heavy tool despite being a create: a 40x40 grid hands back 1600 full records. fields=["handle"] is usually all a caller needs from it.
Inputs: cols (required), rows (required), handle (required), col_spacing (required), +3 more. Returns: result
entity_batch_createBatch Create EntitiesA
Create multiple entities in a single call for better performance.
Each entity dict must have a 'type' key and the parameters for that type. Example: [{"type": "line", "x1": 0, "y1": 0, "x2": 100, "y2": 0}, {"type": "circle", "cx": 50, "cy": 50, "radius": 25}]
Denser than cad_batch for many entities of the same kind (no per-step tool name), and usable as one step of a cad_batch. Use cad_batch when the calls differ, must be ordered, or must feed each other.
Inputs: entities (required). Returns: object
entity_batch_modifyBatch Modify EntitiesA
Apply multiple modifications in a single call.
Example: [{"handle": "1A", "action": "move", "dx": 10, "dy": 20}, {"handle": "2B", "action": "delete"}]
Covers move/rotate/scale/delete/set_properties only. For anything else, for ordering, or to feed one step's result into the next, use cad_batch.
Inputs: operations (required). Returns: object
entity_chamferChamfer Two EntitiesA
Bevel a corner with a chamfer line. Returns info on the new chamfer LINE. V1 supports LINE+LINE only.
Inputs: dist1 (required), handle1 (required), handle2 (required), trim, +1 more. Returns: object
entity_change_spaceChange SpaceA
AutoCAD's CHSPACE: move entities across spaces, rescaled by the viewport.
Geometry is transformed by the viewport's own matrix so it stays the same size on screen — a move without that transform would leave a 100 mm feature as 100 mm of paper inside a 1:2 viewport.
Refused per entity for dimensions (unless freeze_dimensions), ACIS solids,
tables and proxies, viewports, and entities already in the target space;
refused outright for a twisted or non-plan viewport. Entities that end up
outside the viewport or off the sheet are moved and flagged, not refused.
Inputs: handles (required), viewport_handle (required), direction, freeze_dimensions. Returns: object
entity_copyCopy EntityA
Copy an entity and move the copy by (dx, dy, dz). Returns info of the new copy.
Inputs: dx (required), dy (required), handle (required), dz. Returns: object
entity_create_arcCreate ArcA
Create a circular arc. Angles are in degrees, measured counter-clockwise from the positive X axis.
Inputs: cx (required), cy (required), radius (required), end_angle (required), +3 more. Returns: object
entity_create_block_refInsert Block ReferenceB
Insert a block reference (instance of an existing block definition).
Inputs: x (required), y (required), name (required), layer, +3 more. Returns: object
entity_create_circleCreate CircleA
Create a circle at (cx, cy) with given radius.
Inputs: cx (required), cy (required), radius (required), color, +1 more. Returns: object
entity_create_ellipseCreate EllipseA
Create an ellipse. major_x/major_y define the major axis vector from the center.
Inputs: cx (required), cy (required), major_x (required), major_y (required), +3 more. Returns: object
entity_create_hatchCreate HatchB
Create a hatch fill pattern inside a closed boundary polygon.
Inputs: pattern (required), boundary_points (required), angle, color, +2 more. Returns: object
entity_create_lineCreate LineA
Create a line from (x1,y1) to (x2,y2). Returns entity info with handle.
Inputs: x1 (required), x2 (required), y1 (required), y2 (required), +5 more. Returns: object
entity_create_mtextCreate MTextA
Create a multi-line text entity (MTEXT) with word-wrap at the specified width.
Inputs: x (required), y (required), text (required), color, +4 more. Returns: object
entity_create_pointCreate PointB
Create a point marker entity at (x, y).
Inputs: x (required), y (required), color, layer. Returns: object
entity_create_polylineCreate PolylineA
Create a lightweight 2D polyline through the given points.
Example: points=[[0,0],[100,0],[100,100],[0,100]], closed=true → rectangle
Inputs: points (required), color, layer, closed. Returns: object
entity_create_rectangleCreate RectangleA
Create a closed rectangular polyline between two corner points.
Convenience wrapper around entity_create_polyline.
Inputs: x1 (required), x2 (required), y1 (required), y2 (required), +2 more. Returns: object
entity_create_revcloudCreate Revision CloudA
Draw a revision cloud: a polyline whose every segment carries an arc.
A segment_length longer than the shortest edge is refused — the result
would carry no arcs at all and would be a plain polyline reported as a
cloud.
Inputs: points (required), segment_length (required), layer, closed. Returns: object
entity_create_splineCreate SplineA
Create a NURBS spline curve passing through the specified fit points.
Inputs: fit_points (required), color, layer. Returns: object
entity_create_tableCreate TableB
Create a native COM table or an explicitly-labelled ezdxf composite table.
Inputs: x (required), y (required), rows (required), layer, +5 more. Returns: object
entity_create_textCreate TextA
Create a single-line text entity (DTEXT/TEXT).
Inputs: x (required), y (required), text (required), color, +3 more. Returns: object
entity_create_wipeoutCreate WipeoutA
Create a WIPEOUT that hides drawing content behind its outline.
Refuses fewer than three points: a zero-area mask hides nothing while reporting success.
Inputs: points (required), layer. Returns: object
entity_deleteDelete EntityADestructive
Permanently delete an entity by its handle.
Inputs: handle (required). Returns: object
entity_delete_manyDelete Multiple EntitiesADestructive
Delete multiple entities in one call. Returns count of deleted entities.
Inputs: handles (required). Returns: object
entity_edit_geometryEdit GeometryA
Edit the defining geometry of an existing entity in place (no delete/recreate).
CIRCLE: cx/cy/radius · LINE: x1/y1/x2/y2 · ARC: cx/cy/radius/start_angle/end_angle. Any argument left out is unchanged; the handle is preserved.
Inputs: handle (required), cx, cy, x1, +6 more. Returns: object
entity_edit_textEdit TextA
Edit an existing text label in place — change its content, height, or rotation.
Use this to rename/relabel without deleting and recreating (which would lose the handle). Works on both TEXT and MTEXT.
Inputs: handle (required), text, height, rotation. Returns: object
entity_extendExtend EntityA
Extend target to meet boundary. If end_x/end_y is None, the target
endpoint nearest the boundary is auto-selected.
V1 supports LINE+LINE only. Raises if the lines are parallel.
Inputs: target_handle (required), boundary_handle (required), end_x, end_y. Returns: object
entity_filletFillet Two EntitiesA
Round a corner with a tangent arc. Returns info on the new ARC entity (or the first source line for radius=0). V1 supports LINE+LINE only.
Inputs: radius (required), handle1 (required), handle2 (required), trim. Returns: object
entity_getGet EntityARead-only
Get all properties of a specific entity by its handle.
Inputs: handle (required). Returns: object
entity_listList EntitiesARead-only
List entities in the drawing with optional type and layer filters.
Returns handle, type, layer, color, and type-specific properties. Use handles with entity_get, entity_move, entity_delete, etc.
This is the most expensive result on the server — the full record runs
~250 characters per entity, and properties.bounding_box alone is about a
third of it. When all you need is handles, say so::
entity_list(layer_filter="GEOMETRY", fields=["handle", "type"], compact=True)Paging honesty: a plain list has nowhere to say that more entities followed
the page, so compact=True is the only mode that reports total,
truncated and next_offset — all measured against the same filters.
Inputs: limit, fields, offset, compact, +2 more. Returns: result
entity_mirrorMirror EntityA
Mirror an entity across a line defined by two points. Returns the mirrored copy.
Inputs: x1 (required), x2 (required), y1 (required), y2 (required), +2 more. Returns: object
entity_moveMove EntityA
Move an entity by the specified displacement vector (dx, dy, dz).
Inputs: dx (required), dy (required), handle (required), dz. Returns: object
entity_offsetOffset EntityB
Create a parallel copy of a line, circle, or polyline at the given distance.
Inputs: handle (required), distance (required), side_x, side_y. Returns: object
entity_rotateRotate EntityA
Rotate an entity around a base point by the specified angle.
Inputs: base_x (required), base_y (required), handle (required), angle_deg (required). Returns: object
entity_scaleScale EntityA
Scale an entity uniformly from a base point.
Inputs: base_x (required), base_y (required), factor (required), handle (required). Returns: object
entity_select_smartEntity: Smart Select (semantic predicate)ARead-only
Select entities by semantic predicate instead of memorising handles.
Uncapped. The usual next step is dimension_auto(handles), so fields=["handle"] is normally all this needs to return.
Inputs: predicate (required), fields, compact. Returns: result
entity_set_propertiesSet Entity PropertiesA
Change one or more properties of an entity (layer, color, linetype, lineweight, visibility).
Inputs: handle (required), color, layer, visible, +2 more. Returns: object
entity_trimTrim EntityA
Trim target against cutter, keeping the segment containing (keep_x, keep_y).
V1 supports LINE+LINE only. Cutter is treated as an infinite ray (AutoCAD's default 'implied extend' trim mode). Raises if the lines are parallel.
Inputs: keep_x (required), keep_y (required), cutter_handle (required), target_handle (required). Returns: object
gd_frameGD&T: Feature Control Frame (ISO 1101)A
Draw an ISO 1101 feature control frame from LINE + TEXT primitives.
Renders identically on COM and ezdxf. Referenced datums are recorded so the
gdt critique focus flags any datum with no matching datum feature.
Inputs: x (required), y (required), symbol (required), tolerance (required), +5 more. Returns: object
gear_draw_helical_front_viewGear: Helical Front ViewA
Deterministic helical gear front view: full involute outline (40 pts/flank), pitch/base/outer/root circles, helix symbol, optional bore + keyway.
Returns a handle bundle plus 'metadata' for downstream gear_draw_section_aa.
Inputs: teeth (required), module (required), helix_angle (required), hand, +6 more. Returns: object
gear_draw_section_aaGear: Section A-A ViewA
Deterministic side cross-section of a gear created by gear_draw_*_front_view. Includes top/bottom/left/right boundaries, bore lines, keyway notch, ANSI31 hatch.
Inputs: x_offset (required), face_width (required), gear_metadata (required). Returns: object
gear_draw_spur_front_viewGear: Spur Front ViewB
Deterministic spur gear front view (no helix symbol).
Inputs: teeth (required), module (required), center_x, center_y, +4 more. Returns: object
gh_cad_build_pipelineC
Build a structured Grasshopper computational pipeline connecting AutoCAD geometry to parametric algorithms.
Inputs: color, operations, source_layer, target_layer. Returns: object
gh_cad_query_componentsC
Query the 87+ AutoCAD Grasshopper battery components from Rhino.Inside.AutoCAD.
Inputs: search, subcategory. Returns: object
gh_cad_set_param_and_solveB
Set a Grasshopper parameter slider and re-solve with live AutoCAD TrackedBake update.
Inputs: value (required), pipeline_id (required), slider_name (required), auto_bake. Returns: object
gh_cad_sync_dynamic_blockC
Drive AutoCAD dynamic block properties via Grasshopper parameter definitions.
Inputs: block_name (required), properties (required). Returns: object
gh_cad_tracked_bakeB
Register and track baked AutoCAD entity handles for idempotent Grasshopper updates.
Inputs: handles (required), group_id (required), layer. Returns: object
hatch_add_boundaryAdd Hatch BoundaryA
Add one boundary path built from typed edges.
Typed edges exist because a boundary that only accepts vertex lists silently straightens every curve it is given. Every edge is validated before any is written, so a malformed list refuses instead of leaving a half-built path.
Inputs: edges (required), handle (required). Returns: object
hatch_editEdit HatchA
Edit an existing hatch in place.
Omitted parameters are left alone — a partial edit that resets the rest is
data loss. changed reports which attributes actually moved, so re-setting
a value to what it already was comes back as an empty list rather than a
false positive.
Inputs: handle (required), angle, color, scale, +2 more. Returns: object
hatch_set_gradientSet Hatch GradientA
Fill a hatch with a gradient instead of a pattern.
Inputs: color1 (required), color2 (required), handle (required), name, +4 more. Returns: object
keyway_draw_keyed_boreKeyway: Keyed Bore (front view)A
Bore + DIN 6885 keyway in front view. Auto-sizes keyway from bore if width/depth omitted.
Inputs: center_x (required), center_y (required), bore_diameter (required), layer, +2 more. Returns: object
keyway_draw_sectionKeyway: Side SectionC
Side cross-section view of a keyed bore.
Inputs: center_x (required), center_y (required), face_width (required), bore_diameter (required), +2 more. Returns: object
layer_createCreate LayerB
Create a new layer with specified properties.
Inputs: name (required), color, linetype, lineweight. Returns: object
layer_deleteDelete LayerADestructive
Delete a layer. The layer must have no entities. Layer '0' cannot be deleted.
Inputs: name (required). Returns: object
layer_freezeFreeze LayerA
Freeze a layer (makes it invisible and unselectable, faster regeneration).
Inputs: name (required). Returns: object
layer_hideHide LayerA
Turn off a layer (entities invisible but still processed in regeneration).
Inputs: name (required). Returns: object
layer_isolateIsolate LayerA
Hide all layers except the specified one (layer isolation).
Inputs: name (required). Returns: object
layer_listList LayersARead-only
List all layers with their properties (color, linetype, frozen, locked, visibility).
Never truncated — a drawing's whole layer table is returned — so a compact envelope here always reports truncated=false.
Inputs: fields, compact. Returns: result
layer_lockLock LayerA
Lock a layer (entities visible but cannot be selected or modified).
Inputs: name (required). Returns: object
layer_modifyModify LayerA
Modify an existing layer's color, linetype, and/or lineweight.
Inputs: name (required), color, linetype, lineweight. Returns: object
layer_set_currentSet Current LayerA
Set the active/current layer for new entities.
Inputs: name (required). Returns: object
layer_showShow LayerA
Turn on a layer that was previously turned off.
Inputs: name (required). Returns: object
layer_thawThaw LayerA
Thaw a frozen layer, making it visible and selectable again.
Inputs: name (required). Returns: object
layer_unlockUnlock LayerA
Unlock a layer to allow entity selection and modification.
Inputs: name (required). Returns: object
layout_copyCopy LayoutA
Copy a paper-space layout: page setup, plot settings and all geometry.
skipped names any DXF types that could not be cloned — check it rather
than trusting ok alone. Associative hatch boundaries are re-pointed at the
cloned entities; associativity_dropped counts those that referenced
something outside the source layout and had to be cleared.
Inputs: source (required), new_name (required). Returns: object
layout_createCreate LayoutA
Create a new paper-space layout tab.
Inputs: name (required). Returns: object
layout_deleteDelete LayoutADestructive
Delete a paper-space layout and every entity on it.
Refuses model space, a blank name, and the last remaining sheet. If the
deleted tab was the current one, the returned current is where geometry
goes next — and handles from the deleted sheet stop resolving.
Inputs: name (required). Returns: object
layout_listList LayoutsARead-only
List all layout tabs (Model + paper-space layouts) and the current one.
Inputs: no named parameters. Returns: object
layout_renameRename LayoutA
Rename a paper-space layout. Entity handles are unaffected.
Inputs: new_name (required), old_name (required). Returns: object
layout_set_currentSet Current LayoutB
Activate a layout tab.
Inputs: name (required). Returns: object
leader_create_mleaderCreate MultileaderC
Create a native COM MLeader or an explicitly-labelled ezdxf composite.
Inputs: text (required), points (required), layer, arrow_size, +2 more. Returns: object
linetype_listList Loaded LinetypesARead-only
Return the names of all linetypes currently loaded in the active drawing.
Inputs: no named parameters. Returns: result
linetype_loadLoad LinetypeA
Load a single linetype safely.
Use this instead of system_run_command('_-LINETYPE _LOAD ...') — that
raw form can deadlock on the FILEDIA file-picker dialog and on the
-LINETYPE option-menu prompt. This tool sets FILEDIA=0 around the call,
picks the right .lin file from MEASUREMENT, and verifies the linetype
actually loaded.
Inputs: name (required), file. Returns: object
lisp_execute_codeC
Execute arbitrary AutoLISP code directly inside AutoCAD 2024+.
Inputs: code (required). Returns: object
lisp_load_macroB
Load and execute an external .lsp AutoLISP macro file.
Inputs: file_path (required). Returns: object
pid_insert_instrumentB
Insert an ISA 5.1 instrument bubble (e.g. TT-101, PT-204, FIC-301).
Inputs: tag (required), x, y, radius, +1 more. Returns: object
pid_insert_pumpB
Insert an ISA 5.1 process pump (centrifugal, diaphragm, metering).
Inputs: x, y, radius, rotation, +1 more. Returns: object
pid_insert_tankB
Insert an ISA 5.1 process tank or vessel.
Inputs: x, y, width, height, +1 more. Returns: object
pid_insert_valveB
Insert an ISA 5.1 process valve (gate, globe, check, ball, butterfly).
Inputs: x, y, size, rotation, +1 more. Returns: object
pid_list_symbolsA
List available ISA 5.1 & CTO P&ID categories and symbols.
Inputs: category. Returns: object
pid_route_pipeC
Route a P&ID process line with flow arrow and pipe specification tag.
Inputs: end_x (required), end_y (required), start_x (required), start_y (required), +3 more. Returns: object
point_from_snapPoint: Snap (deterministic OSNAP)ARead-only
Compute a deterministic snap point on an entity. Use this INSTEAD OF guessing coordinates — eliminates the most common LLM drawing error.
Inputs: snap (required), handle (required), ref_x, ref_y. Returns: object
point_intersectionPoint: Intersection (deterministic)ARead-only
Compute the intersection of two geometry entities (LINE-LINE, LINE-CIRCLE, CIRCLE-CIRCLE). When two candidates exist, ref_x/ref_y selects the nearest. Returns {x, y}.
Inputs: handle1 (required), handle2 (required), ref_x, ref_y. Returns: object
point_tangentPoint: Tangent from external pointARead-only
Compute the tangent point on a circle from an external point. Returns {x, y}. Raises if the from-point is inside the circle.
Inputs: from_x (required), from_y (required), circle_handle (required), ref_x, +1 more. Returns: object
selection_filterSelect by PropertiesARead-only
AutoCAD's QSELECT: filter the drawing by properties.
Named parameters rather than a query string, deliberately — a mistyped
attribute name in a query language comes back as an empty result, which is
indistinguishable from "no matches". filtered_by reports which filters
actually ran.
Inputs: color, layer, linetype, min_area, +1 more. Returns: object
selection_getGet Viewport SelectionARead-only
Read the entities the user pre-selected in the AutoCAD viewport (COM backend only).
Returns the implied "pickfirst" selection — the entities highlighted with grips before invoking the AI — so work can be scoped to exactly those entities instead of the whole drawing. Typical use::
sel = selection_get()
dimension_auto(sel["handles"], style="chain")Result keys: ok — True on the COM backend (even for an empty selection) count — number of selected entities handles — list of entity handles (hex strings) to act on entities — full per-entity info (type, layer, color, ...) pickfirst — state of the PICKFIRST sysvar (None if unknown) message — guidance when nothing is selected
On the ezdxf headless backend there is no viewport, so this returns ok=False with an empty handles list.
fields / compact shape the "entities" collection — this tool already
returns an object, so the columnar envelope lands under that key rather
than replacing the result. handles is unaffected, so a caller that only
wants handles can pass fields=["handle"] and still read handles directly.
Inputs: fields, compact. Returns: object
selection_polygonSelect by PolygonARead-only
Window or crossing selection against a polygon rather than a rectangle.
Inputs: points (required), mode, layer, entity_type. Returns: object
selection_windowSelect by WindowARead-only
AutoCAD's ssget window/crossing selection.
Corners may be given in any order. Selection is by drawn position, so an
entity in a mirrored frame is found where entity_get reports it. A
zero-area box is refused rather than answered with an empty list.
Inputs: x1 (required), x2 (required), y1 (required), y2 (required), +3 more. Returns: object
system_aboutBackend InfoBRead-only
Get detailed information about AutoCAD MCP Pro capabilities and available tools.
Inputs: no named parameters. Returns: object
system_capabilitiesBackend CapabilitiesARead-only
Return machine-readable support modes for the active backend.
Inputs: no named parameters. Returns: object
system_get_variableGet System VariableBRead-only
Get an AutoCAD system variable value.
Inputs: name (required). Returns: object
system_run_commandRun AutoCAD CommandA
Execute an AutoCAD command string directly (COM backend only).
Append \n for Enter. Example: '_LINE 0,0 100,0 \n'.
IMPORTANT: commands that finish at an option menu (e.g. -LINETYPE, -LAYER, -STYLE return to '[?/Create/Load/Set]:' after their action) need an EXTRA blank line or 'X\n' to exit, otherwise AutoCAD stays at a prompt and the next COM call will deadlock. Example: '-LINETYPE _LOAD CENTER acad.lin\n\n'.
A verb denylist refuses obviously destructive commands, but it is a guardrail
against issuing ERASE ALL by accident, NOT a security boundary — AutoCAD
accepts hundreds of commands and any loaded ARX/LISP adds more. Prefer the
typed tools (entity_delete, drawing_save_as, block_insert, drawing_purge):
they validate their arguments, which a free-text command string cannot.
Inputs: command (required). Returns: object
system_run_lispExecute AutoLISPA
Execute an AutoLISP expression (COM backend only).
Example: '(setvar "DIMSCALE" 1.0)'
A symbol denylist refuses the known code-execution and file-I/O channels; text inside double quotes is treated as data, so drawing notes are not mistaken for code. It is a guardrail, NOT a security boundary — AutoLISP has more write channels than any denylist enumerates. Prefer the typed tools.
Inputs: expression (required). Returns: object
system_set_variableSet System VariableA
Set an AutoCAD system variable (e.g. DIMSCALE, LTSCALE, MEASUREMENT).
Inputs: name (required), value (required). Returns: object
system_statusServer StatusARead-only
Get full status of the AutoCAD MCP Pro server and backend connection.
Returns backend name, connection status, capabilities, document info.
Inputs: no named parameters. Returns: object
template_apply_layersApply Layer TemplateA
Apply a standard layer set from a predefined template.
Available templates: architectural, mechanical, electrical, piping. Creates all layers defined in the template with standard colors and lineweights.
Inputs: template (required). Returns: object
template_listList Available TemplatesARead-only
List all available layer templates and their contents.
Inputs: no named parameters. Returns: object
text_find_replaceFind and Replace TextA
Replace text in TEXT, MTEXT and block attributes (ATTRIB and ATTDEF).
searched_types is on the response because "no matches" and "that type was
never searched" are different answers. Block definitions are included, so
the next insert does not reintroduce the old text. DIMENSION text is out of
scope: its text field holds the <> override placeholder rather than the
measurement, so editing it would break the association.
Inputs: find (required), replace (required), layer, dry_run, +1 more. Returns: object
text_set_backgroundSet Text BackgroundA
Mask what is behind an MTEXT so it stays readable over hatch or geometry.
MTEXT only: TEXT has no background-fill attribute, so setting one on it would report success and change nothing.
Inputs: handle (required), color, scale, enabled. Returns: object
titleblock_apply_iso_a3TitleBlock: ISO A3A
ISO 7200 / A3 (420x297 mm) title block. Title text is used verbatim.
Pass layout to put the sheet on a paper-space layout, which is where a
title block belongs — the border frames the printed sheet, not the model.
Your current space is restored afterwards, so asking for a border does not
move you onto the sheet.
Inputs: title (required), drawing_no (required), date, scale, +11 more. Returns: object
transaction_beginBegin TransactionA
Begin a transaction (undo mark).
COM backend: Sets AutoCAD undo mark. All subsequent operations can be rolled back to this point with transaction_rollback.
ezdxf backend: Saves a DXF snapshot. Rollback restores the full document state to this point.
Always pair with transaction_commit or transaction_rollback.
Inputs: no named parameters. Returns: object
transaction_commitCommit TransactionA
Commit the current transaction.
COM: Ends the undo mark (changes are permanent but still undoable via drawing_undo). ezdxf: Discards the rollback snapshot (changes are kept).
Inputs: no named parameters. Returns: object
transaction_rollbackRollback TransactionADestructive
Rollback the current transaction to the point of transaction_begin.
COM: Undoes all operations back to the last undo mark. ezdxf: Restores the document from the saved DXF snapshot.
WARNING: This is destructive – all changes since transaction_begin are lost.
Inputs: no named parameters. Returns: object
validation_checkValidate DrawingARead-only
Run quality checks on the current drawing.
Available checks:
empty_layers: Find layers with no entities
zero_length: Find zero-length lines
duplicate_entities: Find entities at the same position
Inputs: checks. Returns: object
viewport_createCreate ViewportA
Place a scaled model-space viewport on a paper-space layout.
The viewport window shows the model region centered at (view_center_x, view_center_y); view height = height / scale.
Inputs: width (required), height (required), layout (required), center_x (required), +4 more. Returns: object
viewport_deleteDelete ViewportADestructive
Delete a viewport.
The layout's main viewport needs force=true; deleting it removes the tab's
own view state, and the layout's current-viewport pointer is repaired so the
file does not carry a dangling reference that only CAD would notice.
Inputs: handle (required), force. Returns: object
viewport_listList ViewportsARead-only
List paper-space viewports: handle, geometry, scale and lock state.
The layout's own main viewport is included with is_main: true — it is the
tab's pan/zoom state rather than a drafting viewport, and it is what remains
after every drafting viewport is deleted. scale and locked are null on
documents that cannot store them (R12) rather than fabricated.
Inputs: layout. Returns: object
viewport_lockLock ViewportA
Lock or unlock a viewport's display scale.
Inputs: handle (required), locked. Returns: object
viewport_set_scaleSet Viewport ScaleA
Rescale a viewport by adjusting its view height.
Geometric scale only: annotative text and dimensions do not resize with it. Refuses the layout's main viewport, whose view height is the tab's own pan/zoom state rather than a drafting scale.
Inputs: scale (required), handle (required). Returns: object
view_screenshotScreenshotARead-only
Capture a screenshot of the current drawing view.
COM backend: captures live AutoCAD window at current view. ezdxf backend: renders via matplotlib to PNG.
With overlay_handles, each entity is labelled with its handle at its own
centre — every modify tool takes a handle, and without the labels there is
nothing connecting "the circle at the top-left" to a hex string you can act
on. Crowded drawings are capped and the image says how many of how many were
labelled. Live AutoCAD captures its own window, so there is no render to
label there; it refuses with capability: "handle_overlay".
Returns an Image content block with the PNG data.
Inputs: overlay_handles.
view_zoom_and_screenshotZoom and ScreenshotARead-only
Zoom to extents (or window if coordinates given), then capture a screenshot.
The most useful tool for visually inspecting drawing state.
Inputs: x1, x2, y1, y2.
view_zoom_extentsZoom ExtentsA
Zoom to show all entities in the drawing (fit drawing in viewport).
Inputs: no named parameters. Returns: object
view_zoom_windowZoom WindowA
Zoom to display the specified rectangular window region.
Inputs: x1 (required), x2 (required), y1 (required), y2 (required). Returns: object
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 162 tools
Several tools are near-duplicates (block_insert vs entity_create_block_ref, system_run_lisp vs lisp_execute_code), and save/export and selection/query families overlap heavily (drawing_save vs drawing_save_as vs drawing_export_dxf; selection_window/polygon/filter/entity_select_smart/analysis_select_*). At 162 tools, an agent cannot reliably pick the intended tool without reading every description.
The server mostly uses readable snake_case and strong domain prefixes (drawing_, entity_, layer_, block_, dimension_), but the verb/object order and granularity vary: block_list vs block_create_from_entities, entity_create_block_ref vs block_insert, selection_window vs entity_select_smart, and drawing_audit vs validation_check vs drawing_critique. It is not chaotic, but the consistency is only partial.
162 tools is far beyond the 25+ threshold and well into extreme-mismatch territory for a single server. The surface mixes core CAD primitives with highly specialized one-off workflows (gear drawings, P&ID, Grasshopper, ISO title blocks), forcing enormous tool-selection overhead.
Core CAD lifecycle coverage is broad: files, entities, layers, blocks, text, dimensions, hatches, layouts, viewports, selection, transactions, validation, and export are all represented, and most create/read/update/delete paths are complete. Minor gaps exist (no rename for layers/blocks, no dimension text editing, limited geometry editing for polylines/splines), but agents can usually work around them by delete/recreate.
Related MCP Connectors
DXF and PDF/X-4 for AI agents: structured facts, PNG renders, an interactive in-chat viewer.
Headless CAD engine & MCP server for 2D/3D drafting, solids, DXF/SVG export, and automation.
CAD in ChatGPT and Claude: editable parts, STEP/STL/drawings, in-chat 3D, automatic checks.
Parametric 3D CAD for AI agents: build print-ready parts, check them, export STL, 3MF or STEP.
Related MCP Servers
- FlicenseNot gradedqualityAmaintenanceEnables AI agents to draft, edit, read, and validate CAD drawings either by driving a live AutoCAD session over COM or headlessly through ezdxf on any platform, spanning mechanical parts, architectural plans, P&IDs, ISO-compliant dimensioning and GD&T, and quantity takeoffs into spreadsheets.-
- FlicenseNot gradedqualityAmaintenanceEnables AI agents to automate AutoCAD through a typed contract with dual engines—live COM on Windows or headless ezdxf anywhere—supporting drafting, P&ID, mechanical parts, architecture, and drawing takeoffs.-
- FlicenseNot gradedqualityAmaintenanceEnables AI agents to drive production-grade CAD automation against live AutoCAD on Windows or headlessly through ezdxf anywhere, using one typed contract across both engines. It covers drawing and dimensioning, ISO GD&T and tolerance validation, P&ID drafting and reading, mechanical part sheets, architectural plans, and quantity takeoffs into workbooks.-
- FlicenseNot gradedqualityAmaintenanceEnables AI agents to drive AutoCAD either live through COM on Windows or headlessly via ezdxf on any OS, using a single typed contract across 247 tools. Supports drafting and reading mechanical, architectural and P&ID drawings with ISO GD&T and dimension-tolerance validation, standards-compliant sheets, and quantity takeoffs.-