Skip to main content
Glama

get_godot_version

Retrieve the installed Godot engine version to verify compatibility and ensure proper setup for game development projects.

Instructions

Get the installed Godot version

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The main handler function for the 'get_godot_version' tool. It ensures the Godot path is detected and valid, then executes Godot with the --version flag using execAsync, and returns the trimmed stdout as the response. 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 tool schema definition returned by ListToolsRequestSchema, including name, description, and empty input schema (no parameters required).
    name: 'get_godot_version', description: 'Get the installed Godot version', inputSchema: { type: 'object', properties: {}, required: [], },
  • src/index.ts:942-943 (registration)
    Registration of the tool handler in the CallToolRequestSchema switch statement, dispatching calls to the handleGetGodotVersion method.
    case 'get_godot_version': return await this.handleGetGodotVersion();

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Coding-Solo/godot-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server