Skip to main content
Glama

pt_cli

Types IOS CLI commands into a router or switch console via API and returns each command's output, letting you configure and verify devices without taking over the screen.

Instructions

Types commands into a router/switch console (CLI tab) and returns each one's output. Same as typing in the IOS CLI: enable, configure terminal, interface..., show ip route, ping, copy run start...

Without taking the screen: it goes through PT's API, and what is typed shows up in the device's real CLI tab.

Parameters:

  • device: exact name (pt_query_topology).

  • commands: a list of commands, or a block of text with one per line. Typed in order, waiting for the prompt between them.

  • timeout: maximum seconds per command, up to 300 (ping/traceroute take a while). When it runs out the command is aborted with Ctrl+Shift+6.

  • auto_confirm: presses Enter on "[confirm]" and "Destination filename [..]?". [yes/no] and Password: questions are NOT answered automatically: put the answer as the next command (e.g. ["reload", "no", ""]).

  • show: True/False opens (or not) the device's window on the CLI tab. None = per pt_ui_mode.

  • capture: saves a PNG of the window when done (implies show).

Each command comes back marked: ok, ERROR (% Invalid input...), UNKNOWN COMMAND (IOS took it as a hostname: the DNS lookup is aborted), WAITING FOR ANSWER or TIMEOUT. A freshly created router is primed automatically (answers 'no' to the initial dialog).

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": {
      "device": "<device>",
      "commands": "<commands>"
    },
    "name": "pt_cli"
  }
}

Input Schema

NameRequiredDescriptionDefault
showNo
deviceYes
captureNo
timeoutNo
commandsYes
output_dirNoscreenshots
auto_confirmNo

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.12.0

TDQS

A4.1/5.0
Behavior5/5

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

With no annotations at all, the description carries the full burden and does so thoroughly: it discloses that the operation runs through PT's API without taking the screen, that typing appears in the real CLI tab, that a timeout aborts the command with Ctrl+Shift+6, exactly which prompts auto_confirm answers and which it deliberately refuses, and that capture implies show. It also notes that a freshly created router is auto-primed by answering 'no' to the initial dialog.

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 core behavior is front-loaded in the first two sentences, then parameters are enumerated in a compact labeled list, keeping the dense detail scannable. Length is justified by seven undocumented parameters and non-obvious semantics such as the Ctrl+Shift+6 abort and the [reload, "no", ""] pattern.

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

Completeness4/5

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

For a high-complexity, seven-parameter mutation tool with zero annotation and zero schema coverage, the description covers nearly everything an agent needs, including return status markers (ok, ERROR, UNKNOWN COMMAND, WAITING FOR ANSWER, TIMEOUT) even though an output schema exists. The one gap is output_dir, whose meaning and default destination for captured PNGs are never mentioned.

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

Parameters4/5

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

Schema description coverage is 0% across 7 parameters, so the description must compensate, and it defines six of them with real meaning beyond the schema: commands accepted as either a list or a newline-separated block typed in order with prompt waits, timeout up to 300 with described abort behavior, the scope of auto_confirm, and the show/capture interaction. Only output_dir goes entirely unexplained.

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?

States a specific verb and resource: it types commands into a router/switch console (CLI tab) and returns each command's output, clarified by 'Same as typing in the IOS CLI'. It does not, however, distinguish itself from the many pt_apply_* siblings that configure the same devices, so an agent still has to infer why raw CLI is preferable to a structured apply tool.

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

Usage Guidelines3/5

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

Usage is implied through concrete examples (enable, configure terminal, show ip route, ping, copy run start) and through cross-references such as taking the device name from pt_query_topology and letting show=None follow pt_ui_mode. There is no explicit when-to-use or when-not guidance versus the pt_apply_* configuration tools, leaving the choice to inference.

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