Skip to main content
Glama

Recent commands (history)

get_recent_commands
Read-onlyIdempotent

Returns the commands recently run on one server through Opservo (terminal, quick actions, approved fixes, automation), sorted newest to oldest, with source, exit code and the start of their output.

Input Schema

NameRequiredDescriptionDefault
limitNoMax commands to return (1-50, default 20).
agent_idYesThe server/agent UUID to query.

Output Schema

NameRequiredDescriptionDefault
errorNoPresent only when the call failed: why, in plain English (unknown server, server from another workspace, not a Kubernetes cluster).
commandsNoNewest first.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "additionalProperties": true,
      +  "properties": {
      +    "commands": {
      +      "description": "Newest first.",
      +      "items": {
      +        "additionalProperties": true,
      +        "properties": {
      +          "command": {
      +            "description": "Command text as run.",
      +            "type": "string"
      +          },
      +          "completed_at": {
      +            "description": "When it finished, ISO 8601.",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "created_at": {
      +            "description": "When it was queued, ISO 8601.",
      +            "type": "string"
      +          },
      +          "exit_code": {
      +            "description": "Process exit code, null while running.",
      +            "type": [
      +              "integer",
      +              "null"
      +            ]
      +          },
      +          "source": {
      +            "description": "Where it came from: terminal, quick_action, ai_fix, fleet_run and so on.",
      +            "type": "string"
      +          },
      +          "status": {
      +            "description": "queued, dispatched, done, error, expired or cancelled.",
      +            "type": "string"
      +          },
      +          "stderr": {
      +            "description": "Start of standard error (truncated at 2000 characters).",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          },
      +          "stdout": {
      +            "description": "Start of standard output (truncated at 2000 characters).",
      +            "type": [
      +              "string",
      +              "null"
      +            ]
      +          }
      +        },
      +        "type": "object"
      +      },
      +      "type": "array"
      +    },
      +    "error": {
      +      "description": "Present only when the call failed: why, in plain English (unknown server, server from another workspace, not a Kubernetes cluster).",
      +      "type": "string"
      +    }
      +  },
      +  "type": "object"
      +}
  2. First observed

TDQS

A3.9/5.0
Behavior4/5

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

Annotations already declare readOnly, idempotent, non-destructive and closed-world, so the safety profile is covered. The description adds genuinely useful behavioral context beyond that: the feed aggregates four command sources and is sorted newest to oldest, telling the agent what population and ordering to expect.

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?

A single front-loaded sentence that moves from purpose to scope to ordering to returned fields with no filler. Slightly run-on with the parenthetical source list, but every clause earns its place.

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?

An output schema exists, so the description need not explain return values, and annotations cover the safety profile. Purpose, scope, ordering and cardinality hints are present; the only gap is explicit routing guidance versus sibling history/log tools.

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% for both parameters (agent_id UUID, limit 1-50 default 20), so the schema already carries full parameter meaning. The description adds nothing about parameter behavior, and per the baseline for high coverage a 3 is appropriate.

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?

States a specific verb (Returns) and resource (commands recently run on one server), plus the scope of what appears (terminal, quick actions, approved fixes, automation) and ordering. This clearly separates it from siblings like get_log_summary and get_incident_timeline without needing to name them.

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 only implied: an agent can infer this is the tool for command history on a given agent, but there is no explicit when-to-use, when-not-to-use, or pointer to alternatives such as get_log_summary or get_incident_timeline when a different view of activity is needed.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources