Skip to main content
Glama

check_compatibility

Read-onlyIdempotent

Check if a combination of package versions is verified to work together. Resolve version conflicts before pinning a stack or recommending a version matrix. Returns compatibility status, conflicts list, and notes.

Instructions

Is this specific multi-package version combo verified to work together? USE WHEN: pinning a stack (next@15 + react@19 + node@22); before recommending a version matrix. RETURNS: {compatible, conflicts[], notes}.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
packagesYesPackage -> version map, e.g. {"next":"15","react":"19"}.

Implementation Reference

  • Handler case for 'check_compatibility' in the handleToolCall dispatcher. Validates that 'packages' is a non-empty object (not array/string), then POSTs it to /api/compat on the backend API.
    case "check_compatibility": {
      let pkgs = args.packages;
      if (typeof pkgs === "string") { try { pkgs = JSON.parse(pkgs); } catch {} }
      if (!pkgs || typeof pkgs !== "object" || Array.isArray(pkgs) || Object.keys(pkgs).length === 0) {
        return fail("\"packages\" must be a non-empty object, e.g. {\"next\":\"16\",\"react\":\"19\"}");
      }
      return ok(await pJ("/api/compat", { packages: pkgs }));
    }
  • Tool registration definition for 'check_compatibility' including its inputSchema. Defines parameters: 'packages' (object of string->string, required) for the package-to-version map.
    {
      name: "check_compatibility",
      description:
        "Is this specific multi-package version combo verified to work together? USE WHEN: pinning a stack (next@15 + react@19 + node@22); before recommending a version matrix. RETURNS: {compatible, conflicts[], notes}.",
      annotations: {
        title: "check_compatibility",
        readOnlyHint: true,
        destructiveHint: false,
        idempotentHint: true,
        openWorldHint: true,
      },
      inputSchema: {
        type: "object",
        properties: {
          packages: {
            type: "object",
            description: "Package -> version map, e.g. {\"next\":\"15\",\"react\":\"19\"}.",
            additionalProperties: { type: "string" },
          },
        },
        required: ["packages"],
      },
  • Helper function 'postJson' (bound as 'pJ') used by the handler to POST the packages payload to the DepScope backend at /api/compat.
    async function postJson(path, body, toolName) {
      const res = await fetch(`${API_BASE}${path}`, {
        method: "POST",
        headers: { ...headers(toolName), "Content-Type": "application/json" },
        body: JSON.stringify(body),
      });
      if (!res.ok) throw new Error(`HTTP ${res.status}: ${await res.text()}`);
      return res.json();
    }
  • The 'check_compatibility' tool object is part of the exported TOOLS array, which is consumed by the MCP server entry points (index.js and http-server.js) for registration.
    export const TOOLS = [
Behavior4/5

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

Annotations already provide readOnlyHint, destructiveHint, idempotentHint, openWorldHint. Description adds return format {compatible, conflicts[], notes}, providing behavioral insight beyond annotations.

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: first states purpose, second provides usage and return format. No wasted words, front-loaded with key information.

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 simple read-only tool with rich annotations, clear schema, and no output schema needed, the description fully covers purpose, usage, and return format.

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?

Schema coverage is 100% with a clear description for the 'packages' parameter. Description only reiterates 'Package -> version map', adding minimal value beyond the schema.

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?

Description explicitly states the tool checks if a multi-package version combo is verified to work together, clearly distinguishing it from siblings like check_package (single package) or find_alternatives.

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?

Description provides explicit use cases: when pinning a stack or before recommending a version matrix. Does not explicitly mention when not to use, but context and sibling list help differentiate.

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/cuttalo/depscope'

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