Skip to main content
Glama

device_exec

Executes commands on a network device console in an eNSP topology, with optional authentication and save settings.

Instructions

在已启动的 eNSP 设备 console 上逐条执行命令。

target 为设备名(配 topo_path)或端口号。view 为 keep/user/system。 username/password 用于需要登录的 console,只有密码的 console 可只给 password。 new_password 仅在设备要求初次设置或修改密码时使用;不主动修改已有密码。 stop_on_error 默认遇错停止;失败时不 save。confirm 为 Y/N/YES/NO。 返回 ok、逐条 results、errorCount、stoppedEarly 和 saveStatus;超时断线不会重试命令。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
hostNo127.0.0.1
saveNo
viewNokeep
targetYes
confirmNoY
commandsYes
passwordNo
usernameNo
topo_pathNo
new_passwordNo
stop_on_errorNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.2.0

TDQS

A3.8/5.0
Behavior4/5

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

Discloses behavior: executes commands one by one, returns ok/results/errorCount/stoppedEarly/saveStatus, and no retry on timeout. No annotations exist, so description carries full burden; side effects are not detailed but inherent to command execution.

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?

Description is a compact bullet-like list of parameter meanings, directly relevant and without fluff. It effectively conveys the necessary information in a structured manner.

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

Completeness3/5

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

Provides output field names and some edge-case behavior, but lacks details on 'host', 'save' semantics, and the output schema structure is not fully elaborated. Gaps exist for full context, though core usage is covered.

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?

Many parameters are explained (target, view, username/password, new_password, stop_on_error, confirm), but 'host' and 'save' are not described at all, and 'commands' is implied only. Schema coverage is partial, leaving clear gaps.

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?

Description clearly states it executes commands on a started eNSP device console, with a specific verb and resource. It does not explicitly compare to sibling tools like device_push_config, but the action is distinct enough from context.

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?

Provides parameter guidance (target, view, credentials, confirm, stop_on_error) and notes that timeout disconnection will not retry commands. However, it does not explicitly state when to prefer this tool over alternatives.

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