Skip to main content
Glama

run_command

Execute commands on any managed instance via SSH, with automatic fallback to AWS SSM if SSH is unreachable.

Instructions

Run a command on any managed instance. Defaults to SSH with automatic failover to AWS SSM when sshd is unreachable (e.g. under heavy load) on SSM-managed AWS instances.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
commandYesCommand to execute.
transportNoExecution channel. 'auto' (default) tries SSH then falls back to AWS SSM if the SSH connection fails; 'ssh' forces SSH; 'ssm' forces AWS Systems Manager (AWS-only).auto
instance_idYesInstance ID or name. '<account>/<name>' picks the server of one provider account; custom servers are 'custom/<name>'.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv2.28.0
    • changedInput schema / properties / instance_id / description
      Previous value: -"Instance ID, name, or custom-server name."New value: +"Instance ID or name. '<account>/<name>' picks the server of one provider account; custom servers are 'custom/<name>'."
  2. Addedv2.24.0
  3. Removedv2.23.8
  4. First observedv1.0.0

TDQS

A3.5/5.0
Behavior3/5

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

With no annotations, the description carries the full burden. It usefully discloses the SSH-to-SSM failover path, but says nothing about permissions required, command timeouts, whether the command is destructive, or what the response contains for an arbitrary-execution tool.

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 sentences, zero padding, and the core action is front-loaded before the transport nuance. Every sentence earns its place.

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?

For a tool that executes arbitrary shell commands with no annotations and no output schema, the definition should say more about output format, timeouts, or permission expectations. The transport story is covered, but the mutation risk and result shape are not.

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 100%, so all three parameters including the transport enum are already documented. The description only restates the default and failover behavior the transport field already specifies, adding no new syntax or format detail.

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 (run) and resource (command on any managed instance), and the failover clause distinguishes it from generic exec tools. It does not name or contrast a sibling, but no sibling in the list overlaps directly (mcp_tool_call and api_request target different resources).

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?

It explains the default transport behavior, which implicitly tells the agent when each channel applies, but offers no when-to-use guidance, prerequisites, or exclusions versus alternatives like mcp_tool_call or api_request. Usage is implied rather than stated.

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