Skip to main content
Glama

release-check-versions

Check current app versions across App Store and Google Play to monitor release status and ensure consistent deployment across platforms.

Instructions

Check latest versions from App Store/Google Play.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
appNoRegistered app slug
packageNameNoGoogle Play package name
bundleIdNoApp Store bundle ID
storeNoTarget store (default: both)

Implementation Reference

  • Main handler function for the 'release-check-versions' tool. Resolves app identifiers, determines which stores to check, gathers skip messages if applicable, calls getLatestVersions helper, and returns formatted text response.
    export async function handleCheckLatestVersions(options: CheckVersionsOptions) {
      const { app, store } = options;
      let { packageName, bundleId } = options;
      const {
        store: selectedStore,
        includeAppStore,
        includeGooglePlay,
      } = getStoreTargets(store);
    
      console.error(`[MCP] šŸ” Checking latest versions (store: ${selectedStore})`);
    
      const resolved = appResolutionService.resolve({
        slug: app,
        packageName,
        bundleId,
      });
    
      if (!resolved.success) {
        return {
          content: [
            {
              type: "text" as const,
              text: resolved.error.message,
            },
          ],
        };
      }
    
      const {
        slug,
        bundleId: resolvedBundleId,
        packageName: resolvedPackageName,
        hasAppStore,
        hasGooglePlay,
      } = resolved.data;
    
      bundleId = resolvedBundleId;
      packageName = resolvedPackageName;
    
      // Check latest versions (without prompt message since this is a dedicated check tool)
      console.error(`[MCP]   App: ${slug}`);
      if (bundleId) console.error(`[MCP]   App Store bundleId: ${bundleId}`);
      if (packageName)
        console.error(`[MCP]   Google Play packageName: ${packageName}`);
    
      const skips: string[] = [];
      if (includeAppStore && !hasAppStore) {
        skips.push(`ā­ļø  Skipping App Store (not registered for App Store)`);
      } else if (includeAppStore && !bundleId) {
        skips.push(`ā­ļø  Skipping App Store (no bundleId provided)`);
      }
      if (includeGooglePlay && !hasGooglePlay) {
        skips.push(`ā­ļø  Skipping Google Play (not registered for Google Play)`);
      } else if (includeGooglePlay && !packageName) {
        skips.push(`ā­ļø  Skipping Google Play (no packageName provided)`);
      }
    
      const versionInfo = await getLatestVersions({
        bundleId,
        includePrompt: false,
        store: selectedStore,
        packageName,
        hasAppStore,
        hasGooglePlay,
      });
    
      console.error(`[MCP]   āœ… Version check completed`);
    
      const contentLines = [...skips, ...versionInfo.messages];
    
      return {
        content: [
          {
            type: "text" as const,
            text: contentLines.join("\n"),
          },
        ],
      };
    }
  • Core helper function that performs the actual API calls to AppStoreService and GooglePlayService to retrieve the latest version information for the given app identifiers, handling skips and errors, and compiling messages and structured results.
    export async function getLatestVersions(
      input: LatestVersionsInput
    ): Promise<LatestVersionsResult> {
      const {
        store,
        bundleId,
        packageName,
        hasAppStore,
        hasGooglePlay,
        includePrompt = true,
      } = input;
      const { includeAppStore, includeGooglePlay } = getStoreTargets(store);
      const config = loadConfig();
    
      const messages: string[] = [];
      messages.push(`\nšŸ“‹ Checking latest versions from stores...\n`);
    
      const result: LatestVersionsResult = { messages };
    
      if (includeAppStore) {
        if (!hasAppStore) {
          const skipped = `ā­ļø  Skipping App Store (not registered for App Store)`;
          messages.push(skipped);
          result.appStore = { found: false, skipped };
        } else if (!config.appStore) {
          const skipped = `ā­ļø  Skipping App Store (not configured in ~/.config/pabal-mcp/config.json)`;
          messages.push(skipped);
          result.appStore = { found: false, skipped };
        } else if (!bundleId) {
          const skipped = `ā­ļø  Skipping App Store (no bundleId provided)`;
          messages.push(skipped);
          result.appStore = { found: false, skipped };
        } else {
          const latest = await appStoreService.getLatestVersion(bundleId);
          if (!latest.found) {
            const errMsg =
              latest.error instanceof Error
                ? latest.error.message
                : (latest.error ?? "");
            const msg = errMsg
              ? `šŸŽ App Store: Check failed - ${errMsg}`
              : `šŸŽ App Store: No version found (can create first version)`;
            messages.push(msg);
            result.appStore = { found: false, error: errMsg || undefined };
          } else {
            const state = latest.state?.toUpperCase() || "UNKNOWN";
            messages.push(`šŸŽ App Store: ${latest.versionString} (${state})`);
            result.appStore = {
              found: true,
              versionString: latest.versionString,
              state,
            };
          }
        }
      }
    
      if (includeGooglePlay) {
        if (!hasGooglePlay) {
          const skipped = `ā­ļø  Skipping Google Play (not registered for Google Play)`;
          messages.push(skipped);
          result.googlePlay = { found: false, skipped };
        } else if (!config.playStore) {
          const skipped = `ā­ļø  Skipping Google Play (not configured in ~/.config/pabal-mcp/config.json)`;
          messages.push(skipped);
          result.googlePlay = { found: false, skipped };
        } else if (!packageName) {
          const skipped = `ā­ļø  Skipping Google Play (no packageName provided)`;
          messages.push(skipped);
          result.googlePlay = { found: false, skipped };
        } else {
          const latest =
            await googlePlayService.getLatestProductionRelease(packageName);
          if (!latest.found) {
            const errMsg =
              latest.error instanceof Error
                ? latest.error.message
                : (latest.error ?? "");
            const msg = errMsg
              ? `šŸ¤– Google Play: Check failed - ${errMsg}`
              : `šŸ¤– Google Play: No version found (can create first version)`;
            messages.push(msg);
            result.googlePlay = { found: false, error: errMsg || undefined };
          } else {
            const versionName = latest.versionName || latest.releaseName || "N/A";
            const status = latest.status?.toUpperCase() || "UNKNOWN";
            messages.push(
              `šŸ¤– Google Play: ${versionName} (versionCodes: ${latest.versionCodes.join(
                ", "
              )}, ${status})`
            );
            result.googlePlay = {
              found: true,
              versionName,
              versionCodes: latest.versionCodes,
              status,
              releaseName: latest.releaseName,
            };
          }
        }
      }
    
      if (includePrompt) {
        messages.push(
          `\nšŸ’” To create a new version, please provide the 'version' parameter.`
        );
        messages.push(`   Example: Call release-create tool with version="1.2.0".`);
      }
    
      return result;
    }
  • src/index.ts:284-297 (registration)
    Registers the 'release-check-versions' tool with the MCP server, including its name, description, input schema, handler function, and category.
    registerToolWithInfo(
      "release-check-versions",
      {
        description: "Check latest versions from App Store/Google Play.",
        inputSchema: z.object({
          app: z.string().optional().describe("Registered app slug"),
          packageName: z.string().optional().describe("Google Play package name"),
          bundleId: z.string().optional().describe("App Store bundle ID"),
          store: storeSchema.describe("Target store (default: both)"),
        }),
      },
      handleCheckLatestVersions,
      "Release Management"
    );
  • Zod input schema defining optional parameters: app slug, packageName, bundleId, and store (defaults to both). Used for input validation in the tool registration.
    inputSchema: z.object({
      app: z.string().optional().describe("Registered app slug"),
      packageName: z.string().optional().describe("Google Play package name"),
      bundleId: z.string().optional().describe("App Store bundle ID"),
      store: storeSchema.describe("Target store (default: both)"),
    }),
Behavior2/5

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

With no annotations provided, the description carries full burden for behavioral disclosure. While 'Check' implies a read-only operation, it doesn't specify whether this requires authentication, has rate limits, returns structured data versus raw text, or handles errors. For a tool that presumably queries external app stores, this represents significant behavioral gaps.

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 extremely concise at just 6 words, front-loading the core purpose with zero wasted language. Every word earns its place by specifying both the action and target platforms.

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 no annotations, no output schema, and multiple parameters, the description is incomplete. It doesn't explain what 'latest versions' means (version numbers? release dates? changelogs?), what format the results come in, or how the parameters interact (e.g., whether 'app' is required when specifying 'store'). For a tool that queries external APIs, this leaves too much undefined.

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 description coverage is 100%, so the schema already documents all 4 parameters thoroughly. The description doesn't add any parameter semantics beyond what's in the schema - it mentions 'App Store/Google Play' which aligns with the 'store' parameter but provides no additional context about parameter relationships or usage patterns.

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 ('Check latest versions') and target resources ('from App Store/Google Play'), providing a specific verb+resource combination. However, it doesn't distinguish this tool from potential sibling tools like 'release-create' or 'release-update-notes' that might also interact with release versions.

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 sibling tools like 'release-create', 'release-pull-notes', and 'release-update-notes' available, there's no indication of when checking versions is appropriate versus creating releases or managing release notes.

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/quartz-labs-dev/pabal-mcp'

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