Skip to main content
Glama

getServerInfo

Retrieve current server details including connection status, version, and available features for managing Minecraft gameplay remotely.

Instructions

Get information about the currently connected server

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • The asynchronous handler function that executes the logic for the getServerInfo tool. It verifies bot connection and returns detailed server and bot status information.
        async () => {
          if (!botState.isConnected || !botState.bot) {
            return createNotConnectedResponse()
          }
    
          try {
            return createSuccessResponse(`Server Info:
    Host: ${botState.connectionInfo.host}
    Port: ${botState.connectionInfo.port}
    Version: ${botState.bot.version}
    Game Mode: ${botState.bot.game.gameMode}
    Difficulty: ${botState.bot.game.difficulty}
    Time: ${botState.bot.time.timeOfDay}
    Players Online: ${Object.keys(botState.bot.players).length}
    Your Health: ${botState.bot.health ? botState.bot.health.toFixed(1) : 'N/A'}
    Your Food: ${botState.bot.food ? botState.bot.food.toFixed(1) : 'N/A'}`)
          } catch (error) {
            return createErrorResponse(error)
          }
        }
  • The server.tool() call that registers the getServerInfo tool, including its name, description, empty schema object, and inline handler function.
      // Tool to get server information
      server.tool(
        'getServerInfo',
        'Get information about the currently connected server',
        {},
        async () => {
          if (!botState.isConnected || !botState.bot) {
            return createNotConnectedResponse()
          }
    
          try {
            return createSuccessResponse(`Server Info:
    Host: ${botState.connectionInfo.host}
    Port: ${botState.connectionInfo.port}
    Version: ${botState.bot.version}
    Game Mode: ${botState.bot.game.gameMode}
    Difficulty: ${botState.bot.game.difficulty}
    Time: ${botState.bot.time.timeOfDay}
    Players Online: ${Object.keys(botState.bot.players).length}
    Your Health: ${botState.bot.health ? botState.bot.health.toFixed(1) : 'N/A'}
    Your Food: ${botState.bot.food ? botState.bot.food.toFixed(1) : 'N/A'}`)
          } catch (error) {
            return createErrorResponse(error)
          }
        }
      )
  • Call to registerInfoTools() within the registerAllTools() function, which indirectly registers the getServerInfo tool.
    // Information tools
    registerInfoTools()
Behavior2/5

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

No annotations are provided, so the description carries full burden. It states what the tool does but doesn't disclose behavioral traits like what information is returned (e.g., server version, player count, settings), whether it's safe to call frequently, or if it requires specific permissions. This leaves significant gaps for a tool with no annotation coverage.

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?

The description is a single, efficient sentence that directly states the tool's purpose with zero wasted words. It's appropriately sized and front-loaded, making it easy to understand at a glance.

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

Completeness2/5

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

Given the lack of annotations and output schema, the description is incomplete. It doesn't explain what information is returned (e.g., server properties, status), leaving the agent uncertain about the tool's output. For a tool with no structured data about behavior or results, more context is needed.

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 0 parameters with 100% schema description coverage, so the schema fully documents the absence of inputs. The description doesn't need to add parameter information, and it appropriately doesn't mention any parameters, earning a baseline score of 4 for this context.

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 clearly states the action ('Get information') and target ('currently connected server'), providing a specific verb+resource combination. However, it doesn't differentiate from siblings like 'getNearbyPlayers' or 'getPosition' that also retrieve information, so it lacks sibling distinction.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description provides no guidance on when to use this tool versus alternatives. With siblings like 'getNearbyPlayers' and 'getPosition' that retrieve specific information types, there's no indication of when server information is needed or what context warrants its use.

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

Install Server

Other Tools

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/nacal/mcp-minecraft-remote'

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