Skip to main content
Glama

mgba_get_info

Retrieve the currently-loaded game title, code, platform, frame count, and capabilities list to detect which optional emulation methods are available.

Instructions

Get the currently-loaded game title, game code (e.g. AGBE), platform identifier, current frame count, and a capabilities object listing which optional emu methods this build of mGBA supports (pause, frameAdvance, saveStateSlot, etc.). Use the capabilities map to feature-detect before calling tools that depend on optional methods.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Implementation Reference

  • Tool definition for mgba_get_info including name, description, and empty inputSchema (no inputs required).
    {
      name: "mgba_get_info",
      description: "Get the currently-loaded game title, game code (e.g. AGBE), platform identifier, current frame count, and a `capabilities` object listing which optional emu methods this build of mGBA supports (pause, frameAdvance, saveStateSlot, etc.). Use the capabilities map to feature-detect before calling tools that depend on optional methods.",
      inputSchema: { type: "object", properties: {} },
    },
  • Handler for mgba_get_info: calls the 'get_info' RPC method on the mGBA bridge via MgbaClient, and formats the returned title, code, platform, frame count, and capabilities into a human-readable response.
    case "mgba_get_info": {
      const r = await mgba.call<{
        title?: string;
        code?: string;
        frame?: number;
        platform?: number | string;
        capabilities?: Record<string, boolean>;
      }>("get_info");
      const lines = [
        `Title:    ${r.title ?? "(unavailable)"}`,
        `Code:     ${r.code ?? "(unavailable)"}`,
        `Platform: ${r.platform ?? "(unavailable)"}`,
        `Frame:    ${r.frame ?? "(unavailable)"}`,
      ];
      if (r.capabilities) {
        const present = Object.entries(r.capabilities).filter(([, v]) => v).map(([k]) => k);
        const missing = Object.entries(r.capabilities).filter(([, v]) => !v).map(([k]) => k);
        lines.push("");
        lines.push(`Capabilities present: ${present.length ? present.join(", ") : "(none)"}`);
        if (missing.length) lines.push(`Missing on this build: ${missing.join(", ")}`);
      }
      return ok(lines.join("\n"));
    }
  • src/tools.ts:258-259 (registration)
    ListToolsRequestSchema handler registers the TOOLS array (including mgba_get_info) with the MCP server.
    export function registerTools(server: Server, mgba: MgbaClient): void {
      server.setRequestHandler(ListToolsRequestSchema, async () => ({ tools: TOOLS }));
Behavior4/5

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

With no annotations provided, the description carries full burden for disclosure. It reveals that the tool returns capabilities for optional methods, implying it is a safe read operation with no side effects. This is sufficient for a simple info tool.

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?

Two concise sentences, zero wasted words. First sentence enumerates return fields, second sentence provides actionable guidance.

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?

Given no output schema, the description adequately explains the return values (title, code, platform, frame count, capabilities). It could optionally mention data types, but the tool is simple and self-contained.

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 input schema has zero parameters, and the description correctly lists the returned values without needing to explain parameters. Per guidelines, 0-parameter tools baseline at 4.

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 it retrieves specific game info (title, code, platform, frame count, capabilities). It distinguishes from siblings like mgba_pause or mgba_read8 which are mutation or I/O tools, while this is a pure information read.

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

Usage Guidelines4/5

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

Explicitly advises using the capabilities map to feature-detect before calling tools that depend on optional methods. This gives clear context on when to invoke this tool, though it does not explicitly state when not to use it.

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/dmang-dev/mcp-mgba'

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