Skip to main content
Glama
AutoCAD MCP

AutoCAD MCP

draw_line

Creates a line segment between two coordinate points on a specified AutoCAD layer and returns its handle.

Instructions

Отрезок из (x1,y1) в (x2,y2). layer: слой (по умолчанию '0'). Возвращает handle.

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": {
      "x1": "<x1>",
      "y1": "<y1>",
      "x2": "<x2>",
      "y2": "<y2>"
    },
    "name": "draw_line"
  }
}

Input Schema

NameRequiredDescriptionDefault
x1Yes
x2Yes
y1Yes
y2Yes
layerNo0

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.0

TDQS

C2.7/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden, yet it only notes that the call returns a handle. It does not say that the entity is permanently added to the drawing, whether the coordinate system is WCS, what units apply, whether the layer must already exist, or what happens on invalid coordinates. For a mutating drawing operation with zero annotation coverage, this is a significant gap.

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?

Three short sentences, front-loaded with the geometric operation, with no filler. It is telegraphic to the point that meaning is lost, but nothing is wasted or buried.

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?

An output schema exists, so the mention of returning a handle is a bonus rather than a requirement. However, for a mutating geometry tool with no annotations and 0% parameter documentation, the description omits the essential operational context: units, coordinate system, layer prerequisites, and failure behavior. It is too thin for the tool's complexity.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0%, so the description must compensate, and it only partially does: it maps x1/y1/x2/y2 into the segment notation and explains that layer is the target layer with default '0' (a default already visible in the schema). Nothing is said about coordinate units, whether the layer is auto-created, or whether layer names are case-sensitive. Four of the five parameters get no meaning beyond restatement.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description states a concrete verb and resource: draw a segment from (x1,y1) to (x2,y2). That is unambiguous on its own, but it does not distinguish itself from siblings like draw_polyline or draw_rectangle, so an agent still has to infer when a two-point segment is the right primitive. Clear, but not sibling-differentiated.

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?

There is no guidance on when to use this instead of draw_polyline (which can also draw a single segment) or the other primitives in the family. No prerequisites, no exclusions, no context about when a segment is preferable. The agent must infer usage entirely from the tool name.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.