Skip to main content
Glama

get_godot_version

Retrieve the installed Godot engine version to verify compatibility and ensure proper project setup.

Instructions

Get the installed Godot version

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The handler function that detects the Godot executable path if needed, executes it with the --version flag using execAsync, trims the stdout, and returns it as text content. Handles errors by providing helpful messages.
    private async handleGetGodotVersion() {
      try {
        // Ensure godotPath is set
        if (!this.godotPath) {
          await this.detectGodotPath();
          if (!this.godotPath) {
            return this.createErrorResponse(
              'Could not find a valid Godot executable path',
              [
                'Ensure Godot is installed correctly',
                'Set GODOT_PATH environment variable to specify the correct path',
              ]
            );
          }
        }
    
        this.logDebug('Getting Godot version');
        const { stdout } = await execAsync(`"${this.godotPath}" --version`);
        return {
          content: [
            {
              type: 'text',
              text: stdout.trim(),
            },
          ],
        };
      } catch (error: unknown) {
        const errorMessage = error instanceof Error ? error.message : 'Unknown error';
        return this.createErrorResponse(
          `Failed to get Godot version: ${errorMessage}`,
          [
            'Ensure Godot is installed correctly',
            'Check if the GODOT_PATH environment variable is set correctly',
          ]
        );
      }
    }
  • The schema definition for the get_godot_version tool, including name, description, and empty input schema (no parameters required). This is returned in the ListTools response.
      name: 'get_godot_version',
      description: 'Get the installed Godot version',
      inputSchema: {
        type: 'object',
        properties: {},
        required: [],
      },
    },
  • src/index.ts:942-943 (registration)
    The switch case registration that maps the 'get_godot_version' tool call to the handleGetGodotVersion handler method in the CallToolRequestSchema request handler.
    case 'get_godot_version':
      return await this.handleGetGodotVersion();

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.8/5.0
Behavior2/5

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

No annotations are provided, so the description bears full responsibility for behavioral disclosure. It only states what it does, without mentioning side effects, error handling (e.g., if Godot is not installed), or whether any configuration is modified. For a simple getter this is a gap, but the lack of side effects is implicit.

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?

A single, clear sentence with no redundancy. The information is front-loaded and every word earns its place. Perfectly concise.

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 zero-parameter getter with no output schema, the description is largely sufficient. It identifies what is retrieved, but does not explicitly describe the return format (e.g., version string) or behavior if Godot is absent. Given the simplicity, this is a minor omission.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

The tool has zero parameters, and the input schema confirms this with an empty properties object. Per the rubric, 0 parameters warrants a baseline of 4. The description does not need to add parameter details, and it correctly does not.

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?

The description clearly states the action ('Get') and the resource ('installed Godot version'). It is specific and distinguishes itself from sibling tools like add_node or launch_editor, which are about different operations. No ambiguity.

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 description does not explicitly mention when to use this tool versus alternatives. However, given its singular purpose and the lack of overlapping sibling getters, the usage is implied. There is no guidance on prerequisites or conditions, which could be added but is not critical.

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