Skip to main content
Glama

Run a machine action

RunMachineAction
Destructive

One machine action: add or remove the person's SSH public key (for SSH and SFTP to their projects' containers: Service.ssh_command), end a session, schedule or cancel a restart. Returns the machine.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "RunMachineAction"
  }
}

Input Schema

NameRequiredDescriptionDefault
workspaceNoThe workspace: its id or name (ListWorkspaces). Omit when the account has one.
add_ssh_keyNolabel: one line, ≤100 chars; empty = the key's comment. An existing key gets the new label.
cancel_restartNoTrue = cancels the scheduled restart.
end_session_idNoA Machine.sessions id: ends it now (its key can open new ones until removed). NOT_FOUND = ended.
restart_machineNoContainers come back per restart policy. A new call before the restart replaces it; after (Machine.boot_time changed), restarts again.
remove_ssh_key_fingerprintNoA Machine.ssh_keys fingerprint; its sessions end. NOT_FOUND = no such key.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • addedInput schema / properties / workspace
      Added value: +{
      +  "description": "The workspace: its id or name (ListWorkspaces). Omit when the account has one.",
      +  "type": "string"
      +}
  2. First observed

TDQS

A3.5/5.0
Behavior3/5

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

Annotations already declare destructiveHint=true, idempotentHint=false, readOnlyHint=false, so the risk profile is carried by structured data. The description adds genuinely useful context beyond that: it returns the machine, and it points at Service.ssh_command for the key's purpose. It does not add its own warning about irreversibility or the fact that removing a key terminates live sessions (that detail lives only in the schema).

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?

One dense sentence front-loads the action inventory, followed by a short return-value clause. Every clause carries information and nothing is padded, though the nested parenthetical ('(for SSH and SFTP to their projects' containers: Service.ssh_command)') interrupts the enumeration enough to require a second read.

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?

With 100% schema coverage, six optional parameters, nested objects and no output schema, the description does the remaining work: it lists every mutually-exclusive action and states the return type. The only gap is that 'Returns the machine' is not tied to GetMachine or told what the machine object contains, which an agent must infer.

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 six parameters including the nested add_ssh_key, restart_machine and end_session_id fields are already documented in structured data. The description only adds the SSH/SFTP use case for add_ssh_key and the Service.ssh_command cross-reference; the mutual-exclusivity constraint it mentions is also repeated verbatim in the schema. Baseline 3 is appropriate.

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) plus the resource (machine action) and then enumerates the concrete mutations: add/remove SSH key, end session, schedule/cancel restart. That enumeration makes the tool's scope unambiguous without needing to open the schema, though it never names a sibling like RunProjectAction or RunServiceCommand to sharpen the boundary.

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?

Implied guidance only: the enumeration tells the agent which operations belong here, and the SSH/SFTP parenthetical gives one context of use. There is no explicit when-to-use/when-not-to-use statement, no mention of prerequisites (e.g. needing an existing machine or key), and no routing to alternatives.

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