Skip to main content
Glama

List instances

instances_list
Read-only

List known GMod instances with IDs, modes, ports, maps, roles, and live health metrics to monitor running, hung, unresponsive, or crashed games; filter by owner when needed.

Instructions

Known gmod-mcp instances (this one, and on the coordinator every registered member): id, mode (client/srcds), port, pid, map, realms (client true = the client is in game), role, heartbeat age and health: agent_version, uptime_s, fps (over the last 3 s), main_thread_stalled, stalled_s (seconds the main thread has been blocked, 0 when it ticks), silent_s (seconds since its last heartbeat, 0 for this game: it grows for a frozen one, state "unresponsive", and is the number the instance_hung error gives; heartbeat_age_s is the same figure unrounded), fps_low_s (seconds the frame rate has stayed under 10 fps, 0 when fine or while the game loads: measurements taken meanwhile are suspect), loading (true while a map load is in progress, whatever started it: console, Lua, map_load, which counts from its first moment, while it still waits for the menu and the engine has not started the load; sent at once when it starts and ends; it ends when the server state that started it is gone, e.g. a disconnect right after map, and a load whose loading screen has been down for 30 s no longer counts; a loading screen with nothing behind it for 12 s (no server or client realm, not connected, no load starting: the engine's stuck state after map then disconnect at once) is not a load: loading is false and the entry carries loading_stuck: true, and map_load clears it (disconnect does not); status reports the same flags), lua_errors (count since start; errors_since for the details). The instance with role "coordinator" (also named by coordinator_id) holds the directory: when it ends, another takes over within about a second, and during the hand-over coordinator_changing: true (calls with instance answer the retryable error coordinator_changing, with retry_after_s). Instances whose process ended are removed, except those that crashed: they stay an hour with state "crashed" and crash {dump (crashes/*.mdmp file name or null), exit_code, evidence}; relaunch with instances_launch, the dump is for a human. States: "running" (live); "hung" (main thread blocked for 60 s, 180 s during a map load, or no heartbeat for that long while the process lives: a load that never ends, an infinite loop, a crash dialog; it will not recover: the note says to close it with instances_close {pids} or game_terminate {instance} and relaunch, and what was measured on it since is void); "unresponsive" (no heartbeat for 10 s but the process lives: busy or frozen, becomes hung after the limit); "crashed". A call in flight to an instance that dies is answered at once with client_crashed / server_crashed, and one whose process is frozen with no heartbeat for 30 s with instance_hung. Any tool accepts an instance argument: the coordinator relays the call to that instance. Through the plugin's bridge, entries also carry the owner label given to instances_launch (sent by the game itself, so it shows for every instance whichever bridge session launched it) and test_client (true for clients started by instances_launch), owner filters on it, and launched_not_answering lists the clients it launched that never answered (close them with instances_close {pids}); with no game running the list is empty, with a note.

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": "instances_list"
  }
}

Input Schema

NameRequiredDescriptionDefault
ownerNoOnly the clients launched with this owner label (bridge only).

Output Schema

NameRequiredDescriptionDefault
nextNo
noteNo
warningNo
instancesYes
next_callNo
answered_byNo
coordinatorNo
truncated_noteNo
version_warningNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.3.7

TDQS

A3.8/5.0
Behavior5/5

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

Beyond the annotations (readOnlyHint/openWorldHint), the description discloses a large amount of non-obvious behavior: the hung/unresponsive/crashed state machine and its 60s/180s/10s thresholds, the coordinator hand-over window with retryable `coordinator_changing` and `retry_after_s`, the one-hour retention of crashed entries with dumps, and the in-flight error mapping (client_crashed/server_crashed/instance_hung). This is exactly the kind of operational context the annotations cannot carry, and it does not contradict them.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness2/5

Is the description appropriately sized, front-loaded, and free of redundancy?

A single ~450-word run-on paragraph with deeply nested parentheses and semicolons; the `loading` and `loading_stuck` explanation in particular sprawls across multiple clauses. Because an output schema exists, much of the field-by-field enumeration duplicates structured data rather than earning its place, and the genuinely critical routing facts (coordinator relay, retryable errors) are buried mid-paragraph.

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

Completeness5/5

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

For a read-only list tool on a multi-process coordinator, the definition covers the hard parts: state taxonomy, crash retention and relaunch path, coordinator failover and retry behavior, error responses for calls to dead instances, and the empty-list case. Little an agent needs in order to interpret the result is missing.

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?

There is one optional parameter with 100% schema description coverage, so the schema already explains `owner` and its '(bridge only)' scope. The description restates that 'owner filters on it' and adds nothing about matching semantics or the maxLength constraint. Baseline 3 is correct when the schema does the work.

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 states a specific verb and resource ('Known gmod-mcp instances ... this one, and on the coordinator every registered member') and enumerates the identity fields returned (id, mode, port, pid, map, role). It also hints at the sibling relationship by noting that 'status reports the same flags' and that `instance`-scoped calls are relayed by the coordinator, so an agent can partly distinguish this from `status` without opening another schema.

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: the agent must infer that this is the discovery call for instance ids used by `instances_close`, `game_terminate`, `map_load`, etc. There is no explicit 'call this before X' or 'use `status` when you already know the instance'. It does state one concrete precondition (empty list with a note when no game is running) and one filter case (`owner`, bridge only).

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