Skip to main content
Glama
network-terminal-mcp

network-terminal-mcp

by evgenyzh

open_session

Open persistent SSH, Telnet, or serial terminal sessions to network devices. Enables raw command execution and output reading without prompt format requirements.

Instructions

Open a persistent terminal: ssh, telnet, or serial DEVICE [BAUDRATE].

No shell is involved. SSH uses the local client, config, agent and keys.

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": {
      "command": "<command>"
    },
    "name": "open_session"
  }
}

Input Schema

NameRequiredDescriptionDefault
commandYes

Output Schema

NameRequiredDescriptionDefault
errorNo
stateYes
warningsNo
session_idYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed12 schema fields changedv0.5.0
    • removedOutput schema / description
      Removed value: -"Serializable session metadata returned by MCP tools."
    • removedOutput schema / properties / command
      Removed value: -{
      -  "title": "Command",
      -  "type": "string"
      -}
    • removedOutput schema / properties / created_at
      Removed value: -{
      -  "format": "date-time",
      -  "title": "Created At",
      -  "type": "string"
      -}
    • removedOutput schema / properties / error / anyOf
      Removed value: -[
      -  {
      -    "type": "string"
      -  },
      -  {
      -    "type": "null"
      -  }
      -]
    • removedOutput schema / properties / error / default
      Removed value: -null
    • addedOutput schema / properties / error / type
      Added value: +"string"
    • removedOutput schema / properties / exit_code
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "type": "integer"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null,
      -  "title": "Exit Code"
      -}
    • removedOutput schema / properties / idle_seconds
      Removed value: -{
      -  "default": 0,
      -  "description": "Seconds since the last output, or since session creation when no output has arrived yet.",
      -  "minimum": 0,
      -  "title": "Idle Seconds",
      -  "type": "number"
      -}
    • removedOutput schema / properties / last_output_at
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "format": "date-time",
      -      "type": "string"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null,
      -  "description": "UTC timestamp when output was last received; null if the session has not produced any output yet.",
      -  "title": "Last Output At"
      -}
    • removedOutput schema / properties / last_used_at
      Removed value: -{
      -  "format": "date-time",
      -  "title": "Last Used At",
      -  "type": "string"
      -}
    • changedOutput schema / required
      Previous value: -[
      -  "session_id",
      -  "command",
      -  "state",
      -  "created_at",
      -  "last_used_at"
      -]New value: +[
      +  "session_id",
      +  "state"
      +]
    • changedOutput schema / title
      Previous value: -"SessionInfo"New value: +"OpenReply"
  2. Changed24 schema fields changedv0.2.1
    • removedInput schema / $defs
      Removed value: -{
      -  "CredentialSpec": {
      -    "additionalProperties": false,
      -    "description": "One credential source for a target or a route hop.\n\n``pass`` reads the password from a local password-store entry, ``ssh_key``\nuses an explicit local private key file, and ``plaintext`` carries a\npassword in the call itself and requires an explicit insecure opt-in on\nthe enclosing :class:`OpenSpec`.",
      -    "properties": {
      -      "backend": {
      -        "default": "pass",
      -        "enum": [
      -          "pass",
      -          "ssh_key",
      -          "plaintext"
      -        ],
      -        "title": "Backend",
      -        "type": "string"
      -      },
      -      "entry": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "default": null,
      -        "title": "Entry"
      -      },
      -      "key_file": {
      -        "anyOf": [
      -          {
      -            "format": "path",
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "default": null,
      -        "title": "Key File"
      -      },
      -      "key_passphrase_entry": {
      -        "anyOf": [
      -          {
      -            "type": "string"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "default": null,
      -        "title": "Key Passphrase Entry"
      -      },
      -      "password": {
      -        "anyOf": [
      -          {
      -            "format": "password",
      -            "type": "string",
      -            "writeOnly": true
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "default": null,
      -        "title": "Password"
      -      },
      -      "username": {
      -        "minLength": 1,
      -        "title": "Username",
      -        "type": "string"
      -      }
      -    },
      -    "required": [
      -      "username"
      -    ],
      -    "title": "CredentialSpec",
      -    "type": "object"
      -  },
      -  "LegacyAlgorithms": {
      -    "additionalProperties": false,
      -    "description": "Per-call allowlists for legacy SSH algorithms on an explicit host.\n\nOnly the listed categories are restricted; the remaining categories keep\nParamiko's defaults. Host key checking is never disabled.",
      -    "properties": {
      -      "ciphers": {
      -        "anyOf": [
      -          {
      -            "items": {
      -              "type": "string"
      -            },
      -            "type": "array"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "default": null,
      -        "title": "Ciphers"
      -      },
      -      "host_key_algorithms": {
      -        "anyOf": [
      -          {
      -            "items": {
      -              "type": "string"
      -            },
      -            "type": "array"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "default": null,
      -        "title": "Host Key Algorithms"
      -      },
      -      "kex_algorithms": {
      -        "anyOf": [
      -          {
      -            "items": {
      -              "type": "string"
      -            },
      -            "type": "array"
      -          },
      -          {
      -            "type": "null"
      -          }
      -        ],
      -        "default": null,
      -        "title": "Kex Algorithms"
      -      }
      -    },
      -    "title": "LegacyAlgorithms",
      -    "type": "object"
      -  },
      -  "ProxyJumpRoute": {
      -    "additionalProperties": false,
      -    "description": "Reach the final target through one SSH-only jump host.",
      -    "properties": {
      -      "credentials": {
      -        "$ref": "#/$defs/CredentialSpec"
      -      },
      -      "host": {
      -        "minLength": 1,
      -        "title": "Host",
      -        "type": "string"
      -      },
      -      "host_key_policy": {
      -        "default": "strict",
      -        "enum": [
      -          "strict",
      -          "accept_new",
      -          "accept_changed"
      -        ],
      -        "title": "Host Key Policy",
      -        "type": "string"
      -      },
      -      "port": {
      -        "default": 22,
      -        "maximum": 65535,
      -        "minimum": 1,
      -        "title": "Port",
      -        "type": "integer"
      -      },
      -      "type": {
      -        "const": "proxyjump",
      -        "default": "proxyjump",
      -        "title": "Type",
      -        "type": "string"
      -      }
      -    },
      -    "required": [
      -      "host",
      -      "credentials"
      -    ],
      -    "title": "ProxyJumpRoute",
      -    "type": "object"
      -  },
      -  "SerialParams": {
      -    "additionalProperties": false,
      -    "description": "Local serial console parameters for ``/dev/tty*`` transports.",
      -    "properties": {
      -      "baudrate": {
      -        "default": 9600,
      -        "maximum": 4000000,
      -        "minimum": 1,
      -        "title": "Baudrate",
      -        "type": "integer"
      -      },
      -      "bytesize": {
      -        "default": 8,
      -        "enum": [
      -          5,
      -          6,
      -          7,
      -          8
      -        ],
      -        "title": "Bytesize",
      -        "type": "integer"
      -      },
      -      "parity": {
      -        "default": "N",
      -        "enum": [
      -          "N",
      -          "E",
      -          "O",
      -          "M",
      -          "S"
      -        ],
      -        "title": "Parity",
      -        "type": "string"
      -      },
      -      "stopbits": {
      -        "default": 1,
      -        "title": "Stopbits",
      -        "type": "number"
      -      }
      -    },
      -    "title": "SerialParams",
      -    "type": "object"
      -  },
      -  "SocksRoute": {
      -    "additionalProperties": false,
      -    "description": "Reach the final target through a local SOCKS5 proxy.",
      -    "properties": {
      -      "host": {
      -        "minLength": 1,
      -        "title": "Host",
      -        "type": "string"
      -      },
      -      "port": {
      -        "maximum": 65535,
      -        "minimum": 1,
      -        "title": "Port",
      -        "type": "integer"
      -      },
      -      "type": {
      -        "const": "socks",
      -        "default": "socks",
      -        "title": "Type",
      -        "type": "string"
      -      }
      -    },
      -    "required": [
      -      "host",
      -      "port"
      -    ],
      -    "title": "SocksRoute",
      -    "type": "object"
      -  }
      -}
    • addedInput schema / additionalProperties
      Added value: +false
    • removedInput schema / properties / allow_plaintext_password
      Removed value: -{
      -  "default": false,
      -  "title": "Allow Plaintext Password",
      -  "type": "boolean"
      -}
    • removedInput schema / properties / allow_serial
      Removed value: -{
      -  "default": false,
      -  "title": "Allow Serial",
      -  "type": "boolean"
      -}
    • removedInput schema / properties / allow_telnet
      Removed value: -{
      -  "default": false,
      -  "title": "Allow Telnet",
      -  "type": "boolean"
      -}
    • addedInput schema / properties / command
      Added value: +{
      +  "title": "Command",
      +  "type": "string"
      +}
    • removedInput schema / properties / credentials
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "$ref": "#/$defs/CredentialSpec"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null
      -}
    • removedInput schema / properties / host
      Removed value: -{
      -  "title": "Host",
      -  "type": "string"
      -}
    • removedInput schema / properties / host_key_policy
      Removed value: -{
      -  "default": "strict",
      -  "enum": [
      -    "strict",
      -    "accept_new",
      -    "accept_changed"
      -  ],
      -  "title": "Host Key Policy",
      -  "type": "string"
      -}
    • removedInput schema / properties / legacy
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "$ref": "#/$defs/LegacyAlgorithms"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null
      -}
    • removedInput schema / properties / port
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "type": "integer"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null,
      -  "title": "Port"
      -}
    • removedInput schema / properties / protocol
      Removed value: -{
      -  "default": "ssh",
      -  "enum": [
      -    "ssh",
      -    "telnet",
      -    "console",
      -    "serial"
      -  ],
      -  "title": "Protocol",
      -  "type": "string"
      -}
    • removedInput schema / properties / route
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "discriminator": {
      -        "mapping": {
      -          "proxyjump": "#/$defs/ProxyJumpRoute",
      -          "socks": "#/$defs/SocksRoute"
      -        },
      -        "propertyName": "type"
      -      },
      -      "oneOf": [
      -        {
      -          "$ref": "#/$defs/SocksRoute"
      -        },
      -        {
      -          "$ref": "#/$defs/ProxyJumpRoute"
      -        }
      -      ]
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null,
      -  "title": "Route"
      -}
    • removedInput schema / properties / serial
      Removed value: -{
      -  "anyOf": [
      -    {
      -      "$ref": "#/$defs/SerialParams"
      -    },
      -    {
      -      "type": "null"
      -    }
      -  ],
      -  "default": null
      -}
    • changedInput schema / required
      Previous value: -[
      -  "host"
      -]New value: +[
      +  "command"
      +]
    • addedOutput schema / properties / command
      Added value: +{
      +  "title": "Command",
      +  "type": "string"
      +}
    • addedOutput schema / properties / error
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Error"
      +}
    • addedOutput schema / properties / exit_code
      Added value: +{
      +  "anyOf": [
      +    {
      +      "type": "integer"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "title": "Exit Code"
      +}
    • removedOutput schema / properties / host
      Removed value: -{
      -  "title": "Host",
      -  "type": "string"
      -}
    • addedOutput schema / properties / idle_seconds
      Added value: +{
      +  "default": 0,
      +  "description": "Seconds since the last output, or since session creation when no output has arrived yet.",
      +  "minimum": 0,
      +  "title": "Idle Seconds",
      +  "type": "number"
      +}
    • addedOutput schema / properties / last_output_at
      Added value: +{
      +  "anyOf": [
      +    {
      +      "format": "date-time",
      +      "type": "string"
      +    },
      +    {
      +      "type": "null"
      +    }
      +  ],
      +  "default": null,
      +  "description": "UTC timestamp when output was last received; null if the session has not produced any output yet.",
      +  "title": "Last Output At"
      +}
    • removedOutput schema / properties / prompt
      Removed value: -{
      -  "default": "",
      -  "title": "Prompt",
      -  "type": "string"
      -}
    • removedOutput schema / properties / route
      Removed value: -{
      -  "title": "Route",
      -  "type": "string"
      -}
    • changedOutput schema / required
      Previous value: -[
      -  "session_id",
      -  "route",
      -  "host",
      -  "state",
      -  "created_at",
      -  "last_used_at"
      -]New value: +[
      +  "session_id",
      +  "command",
      +  "state",
      +  "created_at",
      +  "last_used_at"
      +]
  3. First observedv0.1.1

TDQS

A3.6/5.0
Behavior3/5

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

No annotations exist, so the description carries the full burden, and it delivers two meaningful details: no shell is involved, and SSH delegates to the local client, config, agent, and keys (so no password credential is passed). It says nothing about session persistence, timeouts, how the resulting session is referenced later, or failure behavior, which an agent needs before relying on it.

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?

Two compact sentences with the primary action and accepted command forms front-loaded, and the behavioral caveats placed second. Nothing is redundant or padded.

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 single-parameter session-opening tool with an output schema covering return values, the description supplies the transport options and the key auth assumption. The remaining gaps (session lifecycle, error/timeout handling) are modest given the sibling tools session_status and close_session that presumably handle lifecycle.

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?

Schema description coverage is 0% and the sole required parameter "command" is undocumented, so the description must compensate. It partially does by listing value forms (ssh, telnet, serial DEVICE [BAUDRATE]), but it is ambiguous whether the string includes the transport keyword as a literal prefix or is only the destination, which leaves the exact syntax underspecified.

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 opens with a specific verb and resource, "Open a persistent terminal," and enumerates the three supported transports (ssh, telnet, serial). That verb plus the listed transports separates it from terminal_write, terminal_read, and close_session, though it never explicitly contrasts itself with those tools by name.

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?

The allowed command forms (ssh, telnet, serial DEVICE [BAUDRATE]) imply the tool's job as the setup step, but the description never states when to choose this over alternatives, whether it must precede terminal_write/terminal_read, or what prerequisites are needed. Usage is inferable rather than guided.

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