Skip to main content
Glama
U-C4N
by U-C4N

Run AutoCAD Command

system_run_command

Execute any AutoCAD command string directly via COM to automate drawing operations and control the CAD application in real time.

Instructions

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.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
commandYesAutoCAD command string (e.g. '_ZOOM E', '_REGEN', '_EXPLODE')

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Behavior5/5

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

Annotations only provide readOnlyHint: false, but the description adds critical behavioral context: COM backend only, the deadlock risk at option-menu prompts, the denylist being a guardrail not a security boundary, and the fact that ARX/LISP can extend available commands. This goes well beyond the minimal annotation.

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?

Even though the description is longer than average, every sentence earns its place. It flows from core purpose to usage examples to critical warnings to safety and alternative recommendations. It is front-loaded with the main purpose and structured in digestible paragraphs without waste.

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?

Given the complexity of a raw command runner and the existing output schema (which covers return values), the description fully covers usage mechanics, edge cases, safety posture, and alternative tools. It is complete and self-sufficient for an agent to decide when and how to invoke it.

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

Parameters5/5

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

Schema coverage is 100% but only lists example commands. The description adds meaning to the 'command' parameter by explaining the newline convention, the extra-line requirement for prompt-terminated commands, and the denylist guardrail. This significantly enriches param understanding.

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 opens with a specific verb+resource statement: 'Execute an AutoCAD command string directly (COM backend only).' It clearly distinguishes this from the many typed sibling tools by framing it as the raw, low-level command interface. Sibling differentiation is explicit with 'Prefer the typed tools...'.

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

Usage Guidelines5/5

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

The description provides concrete usage instructions: append \n for Enter, use an extra blank line or '_X\n' to exit option menus and avoid deadlock. It also explicitly says when NOT to use it ('refuses obviously destructive commands') and names alternative typed tools that validate arguments. This is exemplary when-to-use versus alternatives guidance.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/U-C4N/Autocad-MCP'

If you have feedback or need assistance with the MCP directory API, please join our Discord server